diff --git a/sys-devel/distcc/distcc-3.2~rc1.recipe b/sys-devel/distcc/distcc-3.2~rc1.recipe deleted file mode 100644 index 708d81827..000000000 --- a/sys-devel/distcc/distcc-3.2~rc1.recipe +++ /dev/null @@ -1,77 +0,0 @@ -SUMMARY="Distribute compilation of C code across several machines on a network" -DESCRIPTION=" -distcc is a program to distribute builds of C, C++, Objective C or Objective \ -C++ code across several machines on a network. distcc should always generate \ -the same results as a local build, is simple to install and use, and is \ -usually much faster than a local compile. - -distcc does not require all machines to share a filesystem, have synchronized \ -clocks, or to have the same libraries or header files installed. They can even \ -have different processors or operating systems, if cross-compilers are \ -installed. -" -HOMEPAGE="http://distcc.org/" -COPYRIGHT="2002-2004 by Martin Pool - 2005 Google Inc." -LICENSE="GNU GPL v2" -REVISION="1" -SOURCE_URI="https://github.com/distcc/distcc/archive/v3.2rc1.tar.gz" -CHECKSUM_SHA256="33e85981ff6afd94efc38b23b2d8b9036b3dff2dc6eac6982b9ff0ae1de64caa" -SOURCE_DIR="distcc-3.2rc1" -PATCHES="distcc-$portVersion.patchset" - -ARCHITECTURES="x86_gcc2 ?x86 x86_64" - -GLOBAL_WRITABLE_FILES=" - settings/default/distcc keep-old - settings/distcc/hosts keep-old - settings/distcc/clients.allow keep-old - settings/distcc/commands.allow.sh keep-old - " - -PROVIDES=" - distcc = $portVersion - cmd:distcc = $portVersion - cmd:distccd = $portVersion - cmd:distccmon_text = $portVersion - cmd:lsdistcc = $portVersion - cmd:pump =$portVersion - " -REQUIRES=" - haiku - lib:libpython2.7 - " - -BUILD_REQUIRES=" - haiku_devel - devel:libpython2.7 - " -BUILD_PREREQUIRES=" - cmd:aclocal - cmd:autoconf - cmd:g++ - cmd:gcc - #cmd:gdb # for testing - cmd:libtoolize - cmd:make - cmd:which - " - -BUILD() -{ - libtoolize --copy --force --install - ./autogen.sh - CFLAGS=-D_BSD_SOURCE runConfigure ./configure --disable-Werror \ - LDFLAGS=-L`python-config --prefix`/lib/python2.7/config - make $jobArgs -} - -INSTALL() -{ - make install -} - -TEST() -{ - make check RESTRICTED_PATH=/sources/distcc-3.1:/bin -} diff --git a/sys-devel/distcc/distcc-3.3.2.recipe b/sys-devel/distcc/distcc-3.3.5.recipe similarity index 78% rename from sys-devel/distcc/distcc-3.3.2.recipe rename to sys-devel/distcc/distcc-3.3.5.recipe index 0bcbed663..f633306a4 100644 --- a/sys-devel/distcc/distcc-3.3.2.recipe +++ b/sys-devel/distcc/distcc-3.3.5.recipe @@ -16,7 +16,7 @@ COPYRIGHT="2002-2004 by Martin Pool LICENSE="GNU GPL v2" REVISION="1" SOURCE_URI="https://github.com/distcc/distcc/archive/v$portVersion.tar.gz" -CHECKSUM_SHA256="dceb53b499a37abfc6ace80d2d5ec7dd02fbd560a1909fedb86e17cdd58e9048" +CHECKSUM_SHA256="13a4b3ce49dfc853a3de550f6ccac583413946b3a2fa778ddf503a9edc8059b0" SOURCE_DIR="distcc-$portVersion" SOURCE_FILENAME="distcc-v$portVersion.tar.gz" PATCHES="distcc-$portVersion.patchset" @@ -24,6 +24,8 @@ PATCHES="distcc-$portVersion.patchset" ARCHITECTURES="!x86_gcc2 ?x86 x86_64" SECONDARY_ARCHITECTURES="x86" +PYTHON_VERSION="3.7" + GLOBAL_WRITABLE_FILES=" settings/default/distcc keep-old settings/distcc/hosts keep-old @@ -43,13 +45,13 @@ PROVIDES=" REQUIRES=" haiku$secondaryArchSuffix lib:libpopt$secondaryArchSuffix - lib:libpython3.6m$secondaryArchSuffix + lib:libpython${PYTHON_VERSION}m$secondaryArchSuffix " BUILD_REQUIRES=" haiku${secondaryArchSuffix}_devel devel:libpopt$secondaryArchSuffix - devel:libpython3.6m$secondaryArchSuffix + devel:libpython${PYTHON_VERSION}m$secondaryArchSuffix " BUILD_PREREQUIRES=" cmd:aclocal @@ -66,9 +68,11 @@ BUILD() { libtoolize --copy --force --install ./autogen.sh - CFLAGS=-D_BSD_SOURCE runConfigure ./configure \ - --disable-Werror --without-libiberty \ - LDFLAGS=-L`python-config --prefix`/lib/python2.7/config + export CFLAGS="-DB_USE_POSITIVE_POSIX_ERRORS -D_BSD_SOURCE" + export LDFLAGS="-lbsd -lposix_error_mapper -L`python${PYTHON_VERSION}-config --prefix`/lib/python${PYTHON_VERSION}/config" + runConfigure ./configure \ + --disable-Werror \ + --without-libiberty make $jobArgs } @@ -79,5 +83,5 @@ INSTALL() TEST() { - make check RESTRICTED_PATH=/sources/distcc-3.1:/bin + make check RESTRICTED_PATH=/sources/distcc-${portVersion}:/bin } diff --git a/sys-devel/distcc/patches/distcc-3.2~rc1.patchset b/sys-devel/distcc/patches/distcc-3.2~rc1.patchset deleted file mode 100644 index 913fda34f..000000000 --- a/sys-devel/distcc/patches/distcc-3.2~rc1.patchset +++ /dev/null @@ -1,292 +0,0 @@ -From df9928369194977feac67e6775ad380849d62aff Mon Sep 17 00:00:00 2001 -From: Adrien Destugues -Date: Mon, 30 Sep 2013 21:16:54 +0200 -Subject: Convert existing patch to git patchset. - - -diff --git a/Makefile.in b/Makefile.in -index df70d08..dd96876 100644 ---- a/Makefile.in -+++ b/Makefile.in -@@ -565,7 +565,7 @@ distccmon-gnome@EXEEXT@: $(mon_obj) $(gnome_obj) - - # The include-server is a python app, so we use Python's build system. We pass - # the distcc version, the source location, the CPP flags (for location of the --# includes), and the build location. -+# includes), LD flags and the build location. - include-server: - if test -z "$(INCLUDESERVER_PYTHON)"; then \ - echo "Not building $@: No suitable python found"; \ -@@ -575,6 +575,7 @@ include-server: - SRCDIR="$(srcdir)" \ - CFLAGS="$(CFLAGS) $(PYTHON_CFLAGS)" \ - CPPFLAGS="$(CPPFLAGS)" \ -+ LDFLAGS="$(LDFLAGS)" \ - $(INCLUDESERVER_PYTHON) "$(srcdir)/include_server/setup.py" \ - build \ - --build-base="$(include_server_builddir)" \ -diff --git a/configure.ac b/configure.ac -index 3218801..0793a83 100644 ---- a/configure.ac -+++ b/configure.ac -@@ -329,9 +329,12 @@ AC_CHECK_TYPES([in_port_t, in_addr_t], , , - # only looks in /etc/hosts), so we only look for -lsocket if we need - # it. - AC_SEARCH_LIBS(gethostent, [nsl]) --AC_SEARCH_LIBS(setsockopt, [socket]) -+AC_SEARCH_LIBS(setsockopt, [socket network]) - AC_SEARCH_LIBS(hstrerror, [resolv]) - AC_SEARCH_LIBS(inet_aton, [resolv]) -+AC_SEARCH_LIBS(strsep, [bsd]) -+AC_SEARCH_LIBS(wait3, [bsd]) -+AC_SEARCH_LIBS(wait4, [bsd]) - - if test x"$with_included_popt" != x"yes" && test x"$with_included_popt" != xno - then -@@ -379,6 +382,7 @@ AC_CHECK_FUNCS([snprintf vsnprintf vasprintf asprintf getcwd getwd mkdtemp]) - AC_CHECK_FUNCS([getrusage strsignal gettimeofday]) - AC_CHECK_FUNCS([getaddrinfo getnameinfo inet_ntop inet_ntoa]) - AC_CHECK_FUNCS([strndup strsep mmap strlcpy]) -+AC_CHECK_FUNCS([nice]) - - AC_CHECK_FUNCS([getloadavg]) - AC_CHECK_FUNCS([getline]) -@@ -472,6 +476,8 @@ AC_CHECK_MEMBER([struct sockaddr_storage.ss_family], - AC_DEFINE(HAVE_SOCKADDR_STORAGE, 1, [define if you have struct sockaddr_storage]),, - [#include ]) - -+AC_CHECK_MEMBERS([struct rusage.ru_minflt, struct rusage.ru_majflt]) -+ - AC_ARG_WITH(avahi, - AC_HELP_STRING([--without-avahi], [build without avahi])) - -diff --git a/src/daemon.c b/src/daemon.c -index a1056f8..54dd775 100644 ---- a/src/daemon.c -+++ b/src/daemon.c -@@ -177,15 +177,19 @@ int main(int argc, char *argv[]) - if ((ret = dcc_set_lifetime()) != 0) - dcc_exit(ret); - -+#ifdef HAVE_NICE - /* do this before giving away root */ - if (nice(opt_niceness) == -1) { - rs_log_warning("nice %d failed: %s", opt_niceness, - strerror(errno)); - /* continue anyhow */ - } -+#endif - -+#ifndef __HAIKU__ - if ((ret = dcc_discard_root()) != 0) - dcc_exit(ret); -+#endif - - /* Discard privileges before opening log so that if it's created, it has - * the right ownership. */ -diff --git a/src/exec.c b/src/exec.c -index 43fcb21..87c2e90 100644 ---- a/src/exec.c -+++ b/src/exec.c -@@ -489,13 +489,19 @@ int dcc_collect_child(const char *what, pid_t pid, - * critique_status(). */ - rs_trace("%s child %ld terminated with status %#x", - what, (long) ret_pid, *wait_status); -+#if defined HAVE_RUSAGE_RU_MINFLT && defined HAVE_RUSAGE_RU_MAJFLT - rs_log_info("%s times: user %ld.%06lds, system %ld.%06lds, " - "%ld minflt, %ld majflt", - what, - ru.ru_utime.tv_sec, (long) ru.ru_utime.tv_usec, - ru.ru_stime.tv_sec, (long) ru.ru_stime.tv_usec, - ru.ru_minflt, ru.ru_majflt); -- -+#else -+ rs_log_info("%s times: user %ld.%06lds, system %ld.%06lds", -+ what, -+ ru.ru_utime.tv_sec, (long) ru.ru_utime.tv_usec, -+ ru.ru_stime.tv_sec, (long) ru.ru_stime.tv_usec); -+#endif - return 0; - } - --- -2.14.2 - - -From f6051130b18d85e1e098f3ffda34d12cb8744fe6 Mon Sep 17 00:00:00 2001 -From: Adrien Destugues -Date: Tue, 1 Oct 2013 17:26:29 +0200 -Subject: C89 fixes for gcc2 compatibility - - -diff --git a/src/compile.c b/src/compile.c -index 08c4c95..0597999 100644 ---- a/src/compile.c -+++ b/src/compile.c -@@ -109,6 +109,8 @@ int dcc_discrepancy_filename(char **filename) - return 0; - } else if (str_endswith(include_server_port_suffix, - include_server_port)) { -+ int slash_pos; -+ - /* We're going to make a longer string from include_server_port: one - * that replaces include_server_port_suffix with discrepancy_suffix. */ - int delta = strlen(discrepancy_suffix) - -@@ -120,7 +122,7 @@ int dcc_discrepancy_filename(char **filename) - return EXIT_OUT_OF_MEMORY; - } - strcpy(*filename, include_server_port); -- int slash_pos = strlen(include_server_port) -+ slash_pos = strlen(include_server_port) - - strlen(include_server_port_suffix); - /* Because include_server_port_suffix is a suffix of include_server_port - * we expect to find a '/' at slash_pos in filename. */ -@@ -139,8 +141,9 @@ int dcc_discrepancy_filename(char **filename) - **/ - static int dcc_read_number_discrepancies(const char *discrepancy_filename) - { -- if (!discrepancy_filename) return 0; - struct stat stat_record; -+ -+ if (!discrepancy_filename) return 0; - if (stat(discrepancy_filename, &stat_record) == 0) { - size_t size = stat_record.st_size; - /* Does size fit in an 'int'? */ -diff --git a/src/emaillog.c b/src/emaillog.c -index e106529..d5daa7b 100644 ---- a/src/emaillog.c -+++ b/src/emaillog.c -@@ -121,12 +121,12 @@ int dcc_add_file_to_log_email(const char *description, - void dcc_maybe_send_email(void) { - int child_pid = 0; - const char *whom_to_blame; -+ char *cant_send_message_to; -+ int ret; - if ((whom_to_blame = getenv("DISTCC_EMAILLOG_WHOM_TO_BLAME")) - == NULL) { - whom_to_blame = dcc_emaillog_whom_to_blame; - } -- char *cant_send_message_to; -- int ret; - - if (should_send_email == 0) return; - if (never_send_email) return; -diff --git a/src/lsdistcc.c b/src/lsdistcc.c -index 8bae7c8..13319e5 100644 ---- a/src/lsdistcc.c -+++ b/src/lsdistcc.c -@@ -922,6 +922,8 @@ int detect_distcc_servers(const char **argv, int argc, int opti, - const char *default_format = DEFAULT_FORMAT; - const char **sformat = &default_format; - const char *domain_name; -+ struct rlimit rlim = {0, 0}; -+ - if (opt_domain) { - if (dcc_get_dns_domain(&domain_name)) { - fprintf(stderr, "Can't get domain name\n"); -@@ -944,7 +946,6 @@ int detect_distcc_servers(const char **argv, int argc, int opti, - * We'll ideally use n + 2 fds in our poll loop, so ask for n + 10 - * fds total. - */ -- struct rlimit rlim = {0, 0}; - getrlimit(RLIMIT_NOFILE, &rlim); - if (rlim.rlim_cur < (rlim_t)n + 10) { - rlim.rlim_cur = (rlim_t)n + 10; --- -2.14.2 - - -From dee05d0645432f9678fe1497718e97c4c5c1751b Mon Sep 17 00:00:00 2001 -From: Adrien Destugues -Date: Thu, 18 Sep 2014 09:53:05 +0200 -Subject: strings.h fix. - - -diff --git a/src/filename.c b/src/filename.c -index 9b23b38..f19157c 100644 ---- a/src/filename.c -+++ b/src/filename.c -@@ -28,6 +28,7 @@ - #include - #include - #include -+#include - #include - - #include "distcc.h" --- -2.14.2 - - -From c1c813b47e02bb92c25e33ad10cd586ac2ce7290 Mon Sep 17 00:00:00 2001 -From: Adrien Destugues -Date: Sat, 20 Aug 2016 16:27:52 +0200 -Subject: distcc: fix gcc2build again - -elf.h is now available so we need this code to work. - -diff --git a/src/fix_debug_info.c b/src/fix_debug_info.c -index ea76624..225dd85 100644 ---- a/src/fix_debug_info.c -+++ b/src/fix_debug_info.c -@@ -435,8 +435,10 @@ int dcc_fix_debug_info(const char *path, const char *client_path, - */ - size_t client_path_len = strlen(client_path); - size_t server_path_len = strlen(server_path); -+ char *client_path_plus_slashes; -+ - assert(client_path_len <= server_path_len); -- char *client_path_plus_slashes = malloc(server_path_len + 1); -+ client_path_plus_slashes = malloc(server_path_len + 1); - if (!client_path_plus_slashes) { - rs_log_crit("failed to allocate memory"); - return 1; --- -2.14.2 - - -From dee05d0645432f9678fe1497718e97c4c5c1751b Mon Sep 17 00:00:00 2001 -From: Adrien Destugues -Date: Thu, 18 Sep 2014 09:53:05 +0200 -Subject: wrong position of definition of variables - - -diff --git a/src/compile.c b/src/compile.c -index 0597999..8f791f4 100644 ---- a/src/compile.c -+++ b/src/compile.c -@@ -77,11 +77,12 @@ static int dcc_get_max_discrepancies_before_demotion(void) - * pump.in script! */ - static const int default_setting = 1; - static int current_setting = 0; -+ const char* user_setting = NULL; - - if (current_setting > 0) - return current_setting; - -- const char *user_setting = getenv("DISTCC_MAX_DISCREPANCY"); -+ user_setting = getenv("DISTCC_MAX_DISCREPANCY"); - if (user_setting) { - int parsed_user_setting = atoi(user_setting); - if (parsed_user_setting <= 0) { -diff --git a/src/io.c b/src/io.c -index 5206035..c481fff 100644 ---- a/src/io.c -+++ b/src/io.c -@@ -68,11 +68,12 @@ int dcc_get_io_timeout(void) - * because compiling files can take a long time. **/ - static const int default_dcc_io_timeout = 300; /* seconds */ - static int current_timeout = 0; -+ const char* user_timeout = NULL; - - if (current_timeout > 0) - return current_timeout; - -- const char *user_timeout = getenv("DISTCC_IO_TIMEOUT"); -+ user_timeout = getenv("DISTCC_IO_TIMEOUT"); - if (user_timeout) { - int parsed_user_timeout = atoi(user_timeout); - if (parsed_user_timeout <= 0) { --- -2.14.2 - diff --git a/sys-devel/distcc/patches/distcc-3.3.2.patchset b/sys-devel/distcc/patches/distcc-3.3.5.patchset similarity index 92% rename from sys-devel/distcc/patches/distcc-3.3.2.patchset rename to sys-devel/distcc/patches/distcc-3.3.5.patchset index 372dfd769..e3c12e03e 100644 --- a/sys-devel/distcc/patches/distcc-3.3.2.patchset +++ b/sys-devel/distcc/patches/distcc-3.3.5.patchset @@ -1,11 +1,11 @@ -From a2f4c49256d7e6e021f17daeea57e1046a5274c2 Mon Sep 17 00:00:00 2001 +From 9d2e89179d0a8d9b09a2b996c92034bdd8836059 Mon Sep 17 00:00:00 2001 From: Adrien Destugues Date: Sun, 17 Feb 2019 07:12:36 +0100 Subject: Convert existing patch to git patchset. diff --git a/configure.ac b/configure.ac -index 8fd6a66..06759f1 100644 +index 59f9b81..1ed4a6b 100644 --- a/configure.ac +++ b/configure.ac @@ -314,9 +314,12 @@ AC_CHECK_TYPES([in_port_t, in_addr_t], , , @@ -30,7 +30,7 @@ index 8fd6a66..06759f1 100644 AC_CHECK_FUNCS([getloadavg]) AC_CHECK_FUNCS([getline]) -@@ -475,6 +479,8 @@ AC_CHECK_MEMBER([struct sockaddr_storage.ss_family], +@@ -477,6 +481,8 @@ AC_CHECK_MEMBER([struct sockaddr_storage.ss_family], AC_DEFINE(HAVE_SOCKADDR_STORAGE, 1, [define if you have struct sockaddr_storage]),, [#include ]) @@ -40,7 +40,7 @@ index 8fd6a66..06759f1 100644 AC_HELP_STRING([--without-avahi], [build without avahi])) diff --git a/src/daemon.c b/src/daemon.c -index 5765982..0c52d5d 100644 +index c8fee7c..169d846 100644 --- a/src/daemon.c +++ b/src/daemon.c @@ -197,15 +197,19 @@ int main(int argc, char *argv[]) @@ -89,10 +89,10 @@ index 46b377e..4dd86f3 100644 } -- -2.19.1 +2.30.0 -From 07c7f34e7354ab07242ed430544a04aed8a7b7fd Mon Sep 17 00:00:00 2001 +From fbff23b5e7a5f06307d47d83a8b397b051cdda92 Mon Sep 17 00:00:00 2001 From: Adrien Destugues Date: Sun, 17 Feb 2019 08:00:17 +0100 Subject: strings.h fix @@ -111,5 +111,5 @@ index 9b23b38..f19157c 100644 #include "distcc.h" -- -2.19.1 +2.30.0