From 9326cafe9b5ed835047348fe0768348b3cb9e8a8 Mon Sep 17 00:00:00 2001 From: Ben Jargowsky Date: Tue, 4 Jan 2022 16:11:43 -0800 Subject: [PATCH 1/4] New package: R-cran-RInside-0.2.16 --- common/shlibs | 4 ++++ srcpkgs/R-cran-RInside/template | 12 ++++++++++++ 2 files changed, 16 insertions(+) create mode 100644 srcpkgs/R-cran-RInside/template diff --git a/common/shlibs b/common/shlibs index edcf9daee61c..f5f11b419292 100644 --- a/common/shlibs +++ b/common/shlibs @@ -4103,3 +4103,7 @@ libkaddressbookprivate.so.5 kaddressbook-21.08.3_1 libcodec2.so.1.0 codec2-1.0.1_1 libx86emu.so.3 libx86emu-3.4_1 libdeflate.so.0 libdeflate-1.8_1 +libRInside.so R-cran-RInside-0.2.16_1 +libXrdUtils.so.2 root-6.24.06_1 +libXrdClient.so.2 root-6.24.06_1 +libXrdCl.so.2 root-6.24.06_1 diff --git a/srcpkgs/R-cran-RInside/template b/srcpkgs/R-cran-RInside/template new file mode 100644 index 000000000000..c15b30293151 --- /dev/null +++ b/srcpkgs/R-cran-RInside/template @@ -0,0 +1,12 @@ +# Template file for 'R-cran-RInside' +pkgname=R-cran-RInside +version=0.2.16 +revision=1 +build_style=R-cran +makedepends="R-cran-Rcpp" +short_desc="C++ classes to embed R in C++ (and C) applications" +maintainer="Ben Jargowsky " +license="GPL-2.0-or-later" +homepage="https://CRAN.R-project.org/package=RInside" +checksum=7ae4ade128ea05f37068d59e610822ff0b277f9d39d8900f7eb31759ad5a2a0e +shlib_provides="libRInside.so" From deeb43358c7ae05aa3e86097d17572635e1b9545 Mon Sep 17 00:00:00 2001 From: Ben Jargowsky Date: Tue, 11 Jan 2022 12:36:46 -0800 Subject: [PATCH 2/4] New package: xrootd-5.4.0 --- common/shlibs | 8 ++++++++ srcpkgs/xrootd/template | 13 +++++++++++++ 2 files changed, 21 insertions(+) create mode 100644 srcpkgs/xrootd/template diff --git a/common/shlibs b/common/shlibs index f5f11b419292..f66ec5da6933 100644 --- a/common/shlibs +++ b/common/shlibs @@ -4107,3 +4107,11 @@ libRInside.so R-cran-RInside-0.2.16_1 libXrdUtils.so.2 root-6.24.06_1 libXrdClient.so.2 root-6.24.06_1 libXrdCl.so.2 root-6.24.06_1 +libXrdUtils.so.3 xrootd-5.4.0_1 +libXrdCl.so.3 xrootd-5.4.0_1 +libXrdServer.so.3 xrootd-5.4.0_1 +libXrdCrypto.so.2 xrootd-5.4.0_1 +libXrdPosix.so.3 xrootd-5.4.0_1 +libXrdHttpUtils.so.2 xrootd-5.4.0_1 +libXrdSsiLib.so.2 xrootd-5.4.0_1 +libXrdCryptoLite.so.2 xrootd-5.4.0_1 diff --git a/srcpkgs/xrootd/template b/srcpkgs/xrootd/template new file mode 100644 index 000000000000..c4fbe1c16e39 --- /dev/null +++ b/srcpkgs/xrootd/template @@ -0,0 +1,13 @@ +# Template file for 'xrootd' +pkgname=xrootd +version=5.4.0 +revision=1 +archs="~*-musl" +build_style=cmake +makedepends="zlib-devel openssl-devel libuuid-devel readline-devel" +short_desc="Low latency, scalable and fault tolerant access to data" +maintainer="Ben Jargowsky " +license="LGPL-3.0-or-later" +homepage="https://xrootd.slac.stanford.edu" +distfiles="http://xrootd.org/download/v${version}/xrootd-${version}.tar.gz" +checksum=23bf63bbc63c8fb45dad8b907a7692624f31427001a1688135e9c8d182a3ee7d From 221a59f07d2504e6292a1b426e85d1fdefe41042 Mon Sep 17 00:00:00 2001 From: Ben Jargowsky Date: Tue, 11 Jan 2022 12:38:46 -0800 Subject: [PATCH 3/4] New package: libvdt-0.4.3 --- srcpkgs/libvdt-devel | 1 + srcpkgs/libvdt/template | 28 ++++++++++++++++++++++++++++ 2 files changed, 29 insertions(+) create mode 120000 srcpkgs/libvdt-devel create mode 100644 srcpkgs/libvdt/template diff --git a/srcpkgs/libvdt-devel b/srcpkgs/libvdt-devel new file mode 120000 index 000000000000..4bf35cfc4ed5 --- /dev/null +++ b/srcpkgs/libvdt-devel @@ -0,0 +1 @@ +./libvdt \ No newline at end of file diff --git a/srcpkgs/libvdt/template b/srcpkgs/libvdt/template new file mode 100644 index 000000000000..3caa629d6eb2 --- /dev/null +++ b/srcpkgs/libvdt/template @@ -0,0 +1,28 @@ +# Template file for 'libvdt' +pkgname=libvdt +version=0.4.3 +revision=1 +wrksrc="vdt-${version}" +build_style=cmake +case "$XBPS_TARGET_MACHINE" in + aarch64*|arm*) + configure_args="-DSSE=OFF -DNEON=OFF" + make_cmd=make + export CMAKE_GENERATOR="Unix Makefiles" + ;; +esac +hostmakedepends="python3" +short_desc="Collection of fast and inline implementations of mathematical functions" +maintainer="Ben Jargowsky " +license="LGPL-3.0-or-later" +homepage="https://github.com/dpiparo/vdt" +distfiles="https://github.com/dpiparo/vdt/archive/refs/tags/v${version}.tar.gz" +checksum=705674612ebb5c182b65a8f61f4d173eb7fe7cdeee2235b402541a492e08ace1 + +libvdt-devel_package() { + short_desc+=" - development files" + depends="${sourcepkg}>=${version}_${revision}" + pkg_install() { + vmove usr/include + } +} From a0cf192df78b0ce7475c1b62d66b619d705751b5 Mon Sep 17 00:00:00 2001 From: Ben Jargowsky Date: Mon, 20 Dec 2021 23:55:36 -0500 Subject: [PATCH 4/4] New package: root-6.24.06 --- common/shlibs | 10 +- srcpkgs/python3-pyroot | 1 + srcpkgs/root-R | 1 + srcpkgs/root/INSTALL.msg | 3 + srcpkgs/root/patches/musl.patch | 424 ++++++++++++++++++++++++++++++++ srcpkgs/root/template | 108 ++++++++ 6 files changed, 544 insertions(+), 3 deletions(-) create mode 120000 srcpkgs/python3-pyroot create mode 120000 srcpkgs/root-R create mode 100644 srcpkgs/root/INSTALL.msg create mode 100644 srcpkgs/root/patches/musl.patch create mode 100644 srcpkgs/root/template diff --git a/common/shlibs b/common/shlibs index f66ec5da6933..1f8904b9afd2 100644 --- a/common/shlibs +++ b/common/shlibs @@ -4104,9 +4104,6 @@ libcodec2.so.1.0 codec2-1.0.1_1 libx86emu.so.3 libx86emu-3.4_1 libdeflate.so.0 libdeflate-1.8_1 libRInside.so R-cran-RInside-0.2.16_1 -libXrdUtils.so.2 root-6.24.06_1 -libXrdClient.so.2 root-6.24.06_1 -libXrdCl.so.2 root-6.24.06_1 libXrdUtils.so.3 xrootd-5.4.0_1 libXrdCl.so.3 xrootd-5.4.0_1 libXrdServer.so.3 xrootd-5.4.0_1 @@ -4115,3 +4112,10 @@ libXrdPosix.so.3 xrootd-5.4.0_1 libXrdHttpUtils.so.2 xrootd-5.4.0_1 libXrdSsiLib.so.2 xrootd-5.4.0_1 libXrdCryptoLite.so.2 xrootd-5.4.0_1 +libCore.so root-6.24.06_1 +libTree.so root-6.24.06_1 +libRIO.so root-6.24.06_1 +libMatrix.so root-6.24.06_1 +libThread.so root-6.24.06_1 +libTMVA.so root-6.24.06_1 +libMathCore.so root-6.24.06_1 diff --git a/srcpkgs/python3-pyroot b/srcpkgs/python3-pyroot new file mode 120000 index 000000000000..9f64bd473b46 --- /dev/null +++ b/srcpkgs/python3-pyroot @@ -0,0 +1 @@ +./root \ No newline at end of file diff --git a/srcpkgs/root-R b/srcpkgs/root-R new file mode 120000 index 000000000000..9f64bd473b46 --- /dev/null +++ b/srcpkgs/root-R @@ -0,0 +1 @@ +./root \ No newline at end of file diff --git a/srcpkgs/root/INSTALL.msg b/srcpkgs/root/INSTALL.msg new file mode 100644 index 000000000000..4d92c4ced6bc --- /dev/null +++ b/srcpkgs/root/INSTALL.msg @@ -0,0 +1,3 @@ +Before using ROOT, source 'thisroot.sh' to set up environmental variables. + +$ source /usr/bin/thisroot.sh # also available: thisroot.{csh,fish} diff --git a/srcpkgs/root/patches/musl.patch b/srcpkgs/root/patches/musl.patch new file mode 100644 index 000000000000..cd0a2a46dbef --- /dev/null +++ b/srcpkgs/root/patches/musl.patch @@ -0,0 +1,424 @@ +diff --git a/core/base/inc/Varargs.h b/core/base/inc/Varargs.h +index 525f1f64a6..30983e0124 100644 +--- a/core/base/inc/Varargs.h ++++ b/core/base/inc/Varargs.h +@@ -44,12 +44,10 @@ + #endif + + #if !defined(R__VA_COPY) +-# if defined(__GNUC__) && !defined(__FreeBSD__) +-# define R__VA_COPY(to, from) __va_copy((to), (from)) ++# if defined(va_copy) ++# define R__VA_COPY(to, from) va_copy((to), (from)) + # elif defined(__va_copy) + # define R__VA_COPY(to, from) __va_copy((to), (from)) +-# elif defined(va_copy) +-# define R__VA_COPY(to, from) va_copy((to), (from)) + # elif defined(_WIN32) && _MSC_VER < 1310 + # define R__VA_COPY(to, from) (*(to) = *(from)) + # else +diff --git a/core/clib/src/mmapsup.c b/core/clib/src/mmapsup.c +index 6017afd91b..daf0109977 100644 +--- a/core/clib/src/mmapsup.c ++++ b/core/clib/src/mmapsup.c +@@ -42,13 +42,6 @@ typedef char* caddr_t; + #include + #endif /* __CYGWIN__ */ + +-#if defined(R__LINUX) && !defined(R__GLIBC) && !defined(__CYGWIN__) \ +- || (defined(__CYGWIN__) && (CYGWIN_VERSION_API_MAJOR > 0 || CYGWIN_VERSION_API_MINOR < 213)) +-extern size_t getpagesize PARAMS ((void)); +-#else +-extern int getpagesize PARAMS ((void)); +-#endif +- + #ifndef SEEK_SET + #define SEEK_SET 0 + #endif +diff --git a/core/clib/src/mvalloc.c b/core/clib/src/mvalloc.c +index ef0fdc8196..e062c2d20d 100644 +--- a/core/clib/src/mvalloc.c ++++ b/core/clib/src/mvalloc.c +@@ -29,13 +29,6 @@ Boston, MA 02111-1307, USA. */ + #include + #endif /* __CYGWIN__ */ + +-#if defined(R__LINUX) && !defined(R__GLIBC) && !defined(__CYGWIN__) \ +- || (defined(__CYGWIN__) && (CYGWIN_VERSION_API_MAJOR > 0 || CYGWIN_VERSION_API_MINOR < 213)) +-extern size_t getpagesize PARAMS ((void)); +-#else +-extern int getpagesize PARAMS ((void)); +-#endif +- + #ifdef VMS + #undef _SC_PAGE_SIZE + #undef _SC_PAGESIZE +diff --git a/core/unix/src/TUnixSystem.cxx b/core/unix/src/TUnixSystem.cxx +index 25dfe1cf87..7f92c1146f 100644 +--- a/core/unix/src/TUnixSystem.cxx ++++ b/core/unix/src/TUnixSystem.cxx +@@ -148,17 +148,6 @@ + # define UTMP_NO_ADDR + #endif + +-#if (defined(R__AIX) && !defined(_AIX43)) || \ +- (defined(R__SUNGCC3) && !defined(__arch64__)) +-# define USE_SIZE_T +-#elif defined(R__GLIBC) || defined(R__FBSD) || \ +- (defined(R__SUNGCC3) && defined(__arch64__)) || \ +- defined(R__OBSD) || defined(MAC_OS_X_VERSION_10_4) || \ +- (defined(R__AIX) && defined(_AIX43)) || \ +- (defined(R__SOLARIS) && defined(_SOCKLEN_T)) +-# define USE_SOCKLEN_T +-#endif +- + #if defined(R__LYNXOS) + extern "C" { + extern int putenv(const char *); +@@ -214,7 +203,6 @@ extern "C" { + + // FPE handling includes + #if (defined(R__LINUX) && !defined(R__WINGCC)) +-#include + #include + #include // for prctl() function used in StackTrace() + #endif +@@ -3074,13 +3062,7 @@ TInetAddress TUnixSystem::GetHostByName(const char *hostname) + TInetAddress TUnixSystem::GetSockName(int sock) + { + struct sockaddr addr; +-#if defined(USE_SIZE_T) +- size_t len = sizeof(addr); +-#elif defined(USE_SOCKLEN_T) + socklen_t len = sizeof(addr); +-#else +- int len = sizeof(addr); +-#endif + + TInetAddress ia; + if (getsockname(sock, &addr, &len) == -1) { +@@ -3110,13 +3092,7 @@ TInetAddress TUnixSystem::GetSockName(int sock) + TInetAddress TUnixSystem::GetPeerName(int sock) + { + struct sockaddr addr; +-#if defined(USE_SIZE_T) +- size_t len = sizeof(addr); +-#elif defined(USE_SOCKLEN_T) + socklen_t len = sizeof(addr); +-#else +- int len = sizeof(addr); +-#endif + + TInetAddress ia; + if (getpeername(sock, &addr, &len) == -1) { +@@ -3483,13 +3459,7 @@ int TUnixSystem::GetSockOpt(int sock, int opt, int *val) + { + if (sock < 0) return -1; + +-#if defined(USE_SOCKLEN_T) || defined(_AIX43) + socklen_t optlen = sizeof(*val); +-#elif defined(USE_SIZE_T) +- size_t optlen = sizeof(*val); +-#else +- int optlen = sizeof(*val); +-#endif + + switch (opt) { + case kSendBuffer: +diff --git a/interpreter/cling/lib/Interpreter/Interpreter.cpp b/interpreter/cling/lib/Interpreter/Interpreter.cpp +index d061f04e4b..e6dca5dd90 100644 +--- a/interpreter/cling/lib/Interpreter/Interpreter.cpp ++++ b/interpreter/cling/lib/Interpreter/Interpreter.cpp +@@ -453,7 +453,7 @@ namespace cling { + + // Intercept all atexit calls, as the Interpreter and functions will be long + // gone when the -native- versions invoke them. +-#if defined(__linux__) ++#if defined(__GLIBC__) + const char* LinkageCxx = "extern \"C++\""; + const char* Attr = LangOpts.CPlusPlus ? " throw () " : ""; + #else +diff --git a/io/io/src/TMapFile.cxx b/io/io/src/TMapFile.cxx +index 7fbad8621f..fddd5a9e95 100644 +--- a/io/io/src/TMapFile.cxx ++++ b/io/io/src/TMapFile.cxx +@@ -107,9 +107,7 @@ robust Streamer mechanism I opted for 3). + #include + #include + #include +-#if defined(R__HPUX) || \ +- defined (R__SOLARIS) || defined(R__AIX) || defined(R__HIUX) || \ +- __GLIBC_MINOR__ > 0 ++#ifndef WIN32 + union semun { + int val; // value for SETVAL + struct semid_ds *buf; // buffer for IPC_STAT & IPC_SET +diff --git a/math/mathcore/inc/TMath.h b/math/mathcore/inc/TMath.h +index 55bbdbf1df..eea42c55a7 100644 +--- a/math/mathcore/inc/TMath.h ++++ b/math/mathcore/inc/TMath.h +@@ -577,63 +577,13 @@ struct Limits { + // Trig and other functions + + #include ++#include + + #if defined(R__WIN32) && !defined(__CINT__) + # ifndef finite + # define finite _finite + # endif + #endif +-#if defined(R__AIX) || defined(R__SOLARIS_CC50) || \ +- defined(R__HPUX11) || defined(R__GLIBC) || \ +- (defined(R__MACOSX) ) +-// math functions are defined inline so we have to include them here +-# include +-# ifdef R__SOLARIS_CC50 +- extern "C" { int finite(double); } +-# endif +-// # if defined(R__GLIBC) && defined(__STRICT_ANSI__) +-// # ifndef finite +-// # define finite __finite +-// # endif +-// # ifndef isnan +-// # define isnan __isnan +-// # endif +-// # endif +-#else +-// don't want to include complete +-extern "C" { +- extern double sin(double); +- extern double cos(double); +- extern double tan(double); +- extern double sinh(double); +- extern double cosh(double); +- extern double tanh(double); +- extern double asin(double); +- extern double acos(double); +- extern double atan(double); +- extern double atan2(double, double); +- extern double sqrt(double); +- extern double exp(double); +- extern double pow(double, double); +- extern double log(double); +- extern double log10(double); +-#ifndef R__WIN32 +-# if !defined(finite) +- extern int finite(double); +-# endif +-# if !defined(isnan) +- extern int isnan(double); +-# endif +- extern double ldexp(double, int); +- extern double ceil(double); +- extern double floor(double); +-#else +- _CRTIMP double ldexp(double, int); +- _CRTIMP double ceil(double); +- _CRTIMP double floor(double); +-#endif +-} +-#endif + + //////////////////////////////////////////////////////////////////////////////// + inline Double_t TMath::Sin(Double_t x) +diff --git a/math/mathcore/src/triangle.c b/math/mathcore/src/triangle.c +index e1990a9484..58d47cfdc9 100644 +--- a/math/mathcore/src/triangle.c ++++ b/math/mathcore/src/triangle.c +@@ -324,7 +324,7 @@ + #include + #endif /* CPU86 */ + #ifdef LINUX +-#include ++#include + #endif /* LINUX */ + #ifdef TRILIBRARY + #include "triangle.h" +@@ -4867,7 +4867,7 @@ void exactinit() + REAL check, lastcheck; + int every_other; + #ifdef LINUX +- int cword; ++ fenv_t fenv; + #endif /* LINUX */ + + #ifdef CPU86 +@@ -4879,13 +4879,13 @@ void exactinit() + #endif /* CPU86 */ + #ifdef LINUX + #ifdef SINGLE +- /* cword = 4223; */ +- cword = 4210; /* set FPU control word for single precision */ ++ /* fenv.__control_word = 4223; */ ++ fenv.__control_word = 4210; /* set FPU control word for single precision */ + #else /* not SINGLE */ +- /* cword = 4735; */ +- cword = 4722; /* set FPU control word for double precision */ ++ /* fenv.__control_word = 4735; */ ++ fenv.__control_word = 4722; /* set FPU control word for double precision */ + #endif /* not SINGLE */ +- _FPU_SETCW(cword); ++ fesetenv(&fenv); + #endif /* LINUX */ + + every_other = 1; +diff --git a/net/rpdutils/src/daemon.cxx b/net/rpdutils/src/daemon.cxx +index 9bdb4294a5..0d25986dc4 100644 +--- a/net/rpdutils/src/daemon.cxx ++++ b/net/rpdutils/src/daemon.cxx +@@ -24,9 +24,7 @@ + #include + #include + #include +-#if defined(__sun) || defined(__sgi) +-# include +-#endif ++#include + + #if defined(__linux__) && !defined(linux) + # define linux +@@ -44,15 +42,6 @@ + # define NOFILE 0 + #endif + +-#if defined(__hpux) +-#define USE_SIGCHLD +-#endif +- +-#if defined(__FreeBSD__) || defined(__OpenBSD__) || defined(__APPLE__) +-#define USE_SIGCHLD +-#define SIGCLD SIGCHLD +-#endif +- + #if defined(linux) || defined(__hpux) || defined(__sun) || defined(__sgi) || \ + defined(_AIX) || defined(__FreeBSD__) || defined(__OpenBSD__) || \ + defined(__APPLE__) || defined(__MACH__) || \ +@@ -69,23 +58,16 @@ namespace ROOT { + + extern ErrorHandler_t gErrSys; + +-#if defined(USE_SIGCHLD) + //////////////////////////////////////////////////////////////////////////////// + + static void SigChild(int) + { +- int pid; +-#if defined(__hpux) || defined(__FreeBSD__) || defined(__OpenBSD__) || \ +- defined(__APPLE__) ++ int pid; + int status; +-#else +- union wait status; +-#endif + + while ((pid = wait3(&status, WNOHANG, 0)) > 0) + ; + } +-#endif + + //////////////////////////////////////////////////////////////////////////////// + /// Detach a daemon process from login session context. +@@ -208,15 +190,7 @@ out: + // and execute the wait3() system call. + + if (ignsigcld) { +-#ifdef USE_SIGCHLD +- signal(SIGCLD, SigChild); +-#else +-#if defined(__sun) +- sigignore(SIGCHLD); +-#else +- signal(SIGCLD, SIG_IGN); +-#endif +-#endif ++ signal(SIGCHLD, SigChild); + } + } + +diff --git a/net/rpdutils/src/net.cxx b/net/rpdutils/src/net.cxx +index d258e71e62..b532848985 100644 +--- a/net/rpdutils/src/net.cxx ++++ b/net/rpdutils/src/net.cxx +@@ -31,17 +31,6 @@ + #include + #include + +-#if (defined(R__AIX) && !defined(_AIX43)) || \ +- (defined(R__SUNGCC3) && !defined(__arch64__)) +-# define USE_SIZE_T +-#elif defined(R__GLIBC) || defined(R__FBSD) || \ +- (defined(R__SUNGCC3) && defined(__arch64__)) || \ +- defined(R__OBSD) || defined(MAC_OS_X_VERSION_10_4) || \ +- (defined(R__AIX) && defined(_AIX43)) || \ +- (defined(R__SOLARIS) && defined(_SOCKLEN_T)) +-# define USE_SOCKLEN_T +-#endif +- + #include "rpdp.h" + #include "rpderr.h" + +@@ -357,13 +346,7 @@ int NetRecv(char *msg, int max) + + int NetOpen(int inetdflag, EService service) + { +-#if defined(USE_SIZE_T) +- size_t clilen = sizeof(gTcpCliAddr); +-#elif defined(USE_SOCKLEN_T) + socklen_t clilen = sizeof(gTcpCliAddr); +-#else +- int clilen = sizeof(gTcpCliAddr); +-#endif + + if (inetdflag) { + +@@ -588,13 +571,7 @@ void NetSetOptions(EService serv, int sock, int tcpwindowsize) + ErrorInfo("NetSetOptions: set SO_RCVBUF %d", val); + + if (gDebug > 0) { +-#if defined(USE_SIZE_T) +- size_t optlen = sizeof(val); +-#elif defined(USE_SOCKLEN_T) + socklen_t optlen = sizeof(val); +-#else +- int optlen = sizeof(val); +-#endif + if (serv == kROOTD) { + getsockopt(sock, IPPROTO_TCP, TCP_NODELAY, (char*)&val, &optlen); + ErrorInfo("NetSetOptions: get TCP_NODELAY: %d", val); +diff --git a/net/rpdutils/src/netpar.cxx b/net/rpdutils/src/netpar.cxx +index 00f759a6c9..a781ca9658 100644 +--- a/net/rpdutils/src/netpar.cxx ++++ b/net/rpdutils/src/netpar.cxx +@@ -37,17 +37,6 @@ + #include + #endif + +-#if (defined(R__AIX) && !defined(_AIX43)) || \ +- (defined(R__SUNGCC3) && !defined(__arch64__)) +-# define USE_SIZE_T +-#elif defined(R__GLIBC) || defined(R__FBSD) || \ +- (defined(R__SUNGCC3) && defined(__arch64__)) || \ +- defined(R__OBSD) || defined(MAC_OS_X_VERSION_10_4) || \ +- (defined(R__AIX) && defined(_AIX43)) || \ +- (defined(R__SOLARIS) && defined(_SOCKLEN_T)) +-# define USE_SOCKLEN_T +-#endif +- + #include "rpdp.h" + + extern int gDebug; +@@ -201,13 +190,7 @@ int NetParOpen(int port, int size) + struct sockaddr_in remote_addr; + memset(&remote_addr, 0, sizeof(remote_addr)); + +-#if defined(USE_SIZE_T) +- size_t remlen = sizeof(remote_addr); +-#elif defined(USE_SOCKLEN_T) + socklen_t remlen = sizeof(remote_addr); +-#else +- int remlen = sizeof(remote_addr); +-#endif + + if (!getpeername(NetGetSockFd(), (struct sockaddr *)&remote_addr, &remlen)) { + remote_addr.sin_family = AF_INET; diff --git a/srcpkgs/root/template b/srcpkgs/root/template new file mode 100644 index 000000000000..83c61b909f48 --- /dev/null +++ b/srcpkgs/root/template @@ -0,0 +1,108 @@ +# Template file for 'root' +pkgname=root +version=6.24.06 +revision=1 +# Only i686 and x86_64 seem to be officially supported +archs="i686* x86_64*" +build_style=cmake +configure_args="-Dgnuinstall=ON -Druntime_cxxmodules=OFF + -Dclad=OFF $(vopt_if fortran '-Dfortran=ON') + -DXROOTD_XrdCl_LIBRARY=/usr/lib/libXrdCl.so.3 + -DCMAKE_INSTALL_LIBDIR=/usr/lib/root + -DCMAKE_INSTALL_SYSCONFDIR='../etc/root' + -DCMAKE_INSTALL_PYTHONDIR=${py3_sitelib/'usr/'}" +hostmakedepends="gcc-fortran" +makedepends="libX11-devel libXpm-devel libXft-devel libXext-devel + openssl-devel libpng-devel readline-devel tbb-devel liblz4-devel + pcre-devel xxHash-devel libzstd-devel liblzma-devel libvdt-devel + python3-devel python3-numpy" +depends="gcc" +case "$XBPS_TARGET_MACHINE" in + *-musl) + configure_args+=" -Dssl=OFF -Dxrootd=OFF" + ;; + *) + makedepends+=" xrootd R-cran-Rcpp R-cran-RInside" + configure_args+=" -Dr=ON" + ;; +esac +short_desc="C++ framework for data processing created by CERN" +maintainer="Ben Jargowsky " +license="LGPL-2.1-or-later" +homepage="https://root.cern" +distfiles="https://root.cern/download/root_v${version}.source.tar.gz" +checksum=907f69f4baca1e4f30eeb4979598ca7599b6aa803ca046e80e25b6bbaa0ef522 +build_options="fortran" +build_options_default="fortran" +python_version=3 +subpackages="python3-pyroot" + +if [ "$XBPS_TARGET_LIBC" != "musl" ]; then + subpackages+=" root-R" +fi + +post_install() { + rm ${DESTDIR}/usr/share/root/fonts/LICENSE + rm ${DESTDIR}/usr/share/root/fonts/arialbd.ttf + rm ${DESTDIR}/usr/share/root/fonts/arialbi.ttf + rm ${DESTDIR}/usr/share/root/fonts/ariali.ttf + rm ${DESTDIR}/usr/share/root/fonts/arial.ttf + rm ${DESTDIR}/usr/share/root/fonts/ariblk.ttf + rm ${DESTDIR}/usr/share/root/fonts/comicbd.ttf + rm ${DESTDIR}/usr/share/root/fonts/comic.ttf + rm ${DESTDIR}/usr/share/root/fonts/courbd.ttf + rm ${DESTDIR}/usr/share/root/fonts/courbi.ttf + rm ${DESTDIR}/usr/share/root/fonts/couri.ttf + rm ${DESTDIR}/usr/share/root/fonts/cour.ttf + rm ${DESTDIR}/usr/share/root/fonts/georgiab.ttf + rm ${DESTDIR}/usr/share/root/fonts/georgiai.ttf + rm ${DESTDIR}/usr/share/root/fonts/georgia.ttf + rm ${DESTDIR}/usr/share/root/fonts/georgiaz.ttf + rm ${DESTDIR}/usr/share/root/fonts/impact.ttf + rm ${DESTDIR}/usr/share/root/fonts/monotype.ttf + rm ${DESTDIR}/usr/share/root/fonts/timesbd.ttf + rm ${DESTDIR}/usr/share/root/fonts/timesbi.ttf + rm ${DESTDIR}/usr/share/root/fonts/timesi.ttf + rm ${DESTDIR}/usr/share/root/fonts/times.ttf + rm ${DESTDIR}/usr/share/root/fonts/trebucbd.ttf + rm ${DESTDIR}/usr/share/root/fonts/trebucbi.ttf + rm ${DESTDIR}/usr/share/root/fonts/trebucit.ttf + rm ${DESTDIR}/usr/share/root/fonts/trebuc.ttf + rm ${DESTDIR}/usr/share/root/fonts/verdanab.ttf + rm ${DESTDIR}/usr/share/root/fonts/verdanai.ttf + rm ${DESTDIR}/usr/share/root/fonts/verdana.ttf + rm ${DESTDIR}/usr/share/root/fonts/verdanaz.ttf + rm ${DESTDIR}/usr/share/root/fonts/webdings.ttf + rm ${DESTDIR}/usr/share/root/fonts/wingding.ttf + ln -s ${DESTDIR}/usr/lib/root/libCore.so ${DESTDIR}/usr/lib/ + ln -s ${DESTDIR}/usr/lib/root/libTree.so ${DESTDIR}/usr/lib/ + ln -s ${DESTDIR}/usr/lib/root/libRIO.so ${DESTDIR}/usr/lib/ + ln -s ${DESTDIR}/usr/lib/root/libMatrix.so ${DESTDIR}/usr/lib/ + ln -s ${DESTDIR}/usr/lib/root/libThread.so ${DESTDIR}/usr/lib/ + ln -s ${DESTDIR}/usr/lib/root/libTMVA.so ${DESTDIR}/usr/lib/ + ln -s ${DESTDIR}/usr/lib/root/libMathCore.so ${DESTDIR}/usr/lib/ +} + +python3-pyroot_package() { + short_desc="Python interface to ROOT" + depends="root>=${version}_${revision} python3" + pkg_install() { + vmove ${py3_sitelib} + } +} +root-R_package() { + short_desc="ROOT interface to R" + depends="root>=${version}_${revision}" + pkg_install() { + vmove usr/include/root/RExports.h + vmove usr/include/root/TRDataFrame.h + vmove usr/include/root/TRFunctionExport.h + vmove usr/include/root/TRFunctionImport.h + vmove usr/include/root/TRInterface.h + vmove usr/include/root/TRInternalFunction.h + vmove usr/include/root/TRObject.h + vmove usr/lib/root/libRInterface.so + vmove usr/lib/root/libRMVA.so + vmove usr/lib/root/libRtools.so + } +}