diff options
| author | 2017-05-05 18:43:17 +0200 | |
|---|---|---|
| committer | 2018-01-28 14:24:30 +0100 | |
| commit | 5ec4cbb0630d630807af09d25689fb1a0bda8785 (patch) | |
| tree | 1bda7bd063fcfafd0246221d2691425eeeb129a4 | |
| parent | layout.conf: use BLAKE2B and SHA512 like upstream (diff) | |
| download | musl-5ec4cbb0630d630807af09d25689fb1a0bda8785.tar.gz musl-5ec4cbb0630d630807af09d25689fb1a0bda8785.tar.bz2 musl-5ec4cbb0630d630807af09d25689fb1a0bda8785.zip | |
net-misc/rsync: IPv6 compatibility fix
Bug: https://bugs.gentoo.org/609694
Bug: https://bugzilla.samba.org/show_bug.cgi?id=10715
| -rw-r--r-- | net-misc/rsync/Manifest | 1 | ||||
| -rw-r--r-- | net-misc/rsync/files/rsync-fix-musl-ipv6.patch | 605 | ||||
| -rw-r--r-- | net-misc/rsync/files/rsyncd.conf-3.0.9-r1 | 15 | ||||
| -rw-r--r-- | net-misc/rsync/files/rsyncd.conf.d | 5 | ||||
| -rw-r--r-- | net-misc/rsync/files/rsyncd.init.d-r1 | 11 | ||||
| -rw-r--r-- | net-misc/rsync/files/rsyncd.logrotate | 9 | ||||
| -rw-r--r-- | net-misc/rsync/files/rsyncd.service | 12 | ||||
| -rw-r--r-- | net-misc/rsync/files/rsyncd.xinetd-3.0.9-r1 | 10 | ||||
| -rw-r--r-- | net-misc/rsync/rsync-3.1.2-r2.ebuild | 89 |
9 files changed, 757 insertions, 0 deletions
diff --git a/net-misc/rsync/Manifest b/net-misc/rsync/Manifest new file mode 100644 index 00000000..87500d8c --- /dev/null +++ b/net-misc/rsync/Manifest @@ -0,0 +1 @@ +DIST rsync-3.1.2.tar.gz 892724 BLAKE2B e366514ae9835ba7c201a9e09fb9342c5e52fa36d45d46300d080403de25a64ba3ed7a703e56b4f47a743a597694a2d0a50bb4bab6cfa0aa7b59a4f7b93b9f21 SHA512 4c55fd69f436ead0cb5a0b7c6fdfef9bb28ddb9c63534eb619e756b118d5b08cfc5e696498650932c86e865b37e06633da947e6720ca0c27ed5c034313ae208b diff --git a/net-misc/rsync/files/rsync-fix-musl-ipv6.patch b/net-misc/rsync/files/rsync-fix-musl-ipv6.patch new file mode 100644 index 00000000..53d7381b --- /dev/null +++ b/net-misc/rsync/files/rsync-fix-musl-ipv6.patch @@ -0,0 +1,605 @@ +From 78621d2d5e12c9e7c54ab0a15bb90495d7927251 Mon Sep 17 00:00:00 2001 +From: Pierre-Olivier Mercier <nemunaire@nemunai.re> +Date: Wed, 8 Mar 2017 12:44:11 +0100 +Subject: [PATCH] musl compatibility + +--- + configure.ac | 138 +++++------------------- + configure.sh | 348 +++++++++++++---------------------------------------------- + 2 files changed, 102 insertions(+), 384 deletions(-) + +diff --git a/configure.ac b/configure.ac +index 1b32dfb..891f7b9 100644 +--- a/configure.ac ++++ b/configure.ac +@@ -204,119 +204,37 @@ if test x"$rsync_cv_HAVE_BROKEN_LARGEFILE" != x"yes"; then + AC_SYS_LARGEFILE + fi + +-ipv6type=unknown +-ipv6lib=none +-ipv6trylibc=yes + ++# Checks if IPv6 is requested ++AC_MSG_CHECKING([whether to enable ipv6]) + AC_ARG_ENABLE(ipv6, +- AS_HELP_STRING([--disable-ipv6],[do not even try to use IPv6])) +-if test x"$enable_ipv6" != x"no"; then +- AC_MSG_CHECKING([ipv6 stack type]) +- for i in inria kame linux-glibc linux-inet6 solaris toshiba v6d zeta cygwin; do +- case $i in +- inria) +- # http://www.kame.net/ +- AC_EGREP_CPP(yes, [ +-#include <netinet/in.h> +-#ifdef IPV6_INRIA_VERSION +-yes +-#endif], +- [ipv6type=$i; +- AC_DEFINE(INET6, 1, [true if you have IPv6]) +- ]) +- ;; +- kame) +- # http://www.kame.net/ +- AC_EGREP_CPP(yes, [ +-#include <netinet/in.h> +-#ifdef __KAME__ +-yes +-#endif], +- [ipv6type=$i; +- AC_DEFINE(INET6, 1, [true if you have IPv6])]) +- ;; +- linux-glibc) +- # http://www.v6.linux.or.jp/ +- AC_EGREP_CPP(yes, [ +-#include <features.h> +-#if defined(__GLIBC__) && __GLIBC__ >= 2 && __GLIBC_MINOR__ >= 1 +-yes +-#endif], +- [ipv6type=$i; +-AC_DEFINE(INET6, 1, [true if you have IPv6])]) +- ;; +- linux-inet6) +- # http://www.v6.linux.or.jp/ +- if test -d /usr/inet6 -o -f /usr/inet6/lib/libinet6.a; then +- ipv6type=$i +- ipv6lib=inet6 +- ipv6libdir=/usr/inet6/lib +- ipv6trylibc=yes; +- AC_DEFINE(INET6, 1, [true if you have IPv6]) +- CFLAGS="-I/usr/inet6/include $CFLAGS" +- fi +- ;; +- solaris) +- # http://www.sun.com +- AC_EGREP_CPP(yes, [ +-#include <netinet/ip6.h> +-#ifdef __sun +-yes +-#endif], +- [ipv6type=$i; +- AC_DEFINE(INET6, 1, [true if you have IPv6])]) +- ;; +- toshiba) +- AC_EGREP_CPP(yes, [ +-#include <sys/param.h> +-#ifdef _TOSHIBA_INET6 +-yes +-#endif], +- [ipv6type=$i; +- ipv6lib=inet6; +- ipv6libdir=/usr/local/v6/lib; +- AC_DEFINE(INET6, 1, [true if you have IPv6])]) +- ;; +- v6d) +- AC_EGREP_CPP(yes, [ +-#include </usr/local/v6/include/sys/v6config.h> +-#ifdef __V6D__ +-yes +-#endif], +- [ipv6type=$i; +- ipv6lib=v6; +- ipv6libdir=/usr/local/v6/lib; +- AC_DEFINE(INET6, 1, [true if you have IPv6])]) +- ;; +- zeta) +- AC_EGREP_CPP(yes, [ +-#include <sys/param.h> +-#ifdef _ZETA_MINAMI_INET6 +-yes +-#endif], +- [ipv6type=$i; +- ipv6lib=inet6; +- ipv6libdir=/usr/local/v6/lib; +- AC_DEFINE(INET6, 1, [true if you have IPv6])]) +- ;; +- cygwin) +- AC_EGREP_CPP(yes, [ +-#include <netinet/in.h> +-#ifdef _CYGWIN_IN6_H +-yes +-#endif], +- [ipv6type=$i; +- AC_DEFINE(INET6, 1, [true if you have IPv6])]) +- ;; +- esac +- if test "$ipv6type" != "unknown"; then +- break +- fi +- done +- AC_MSG_RESULT($ipv6type) ++[ --disable-ipv6 disable ipv6 support], ++[ case "$enableval" in ++ no) ++ AC_MSG_RESULT(no) ++ ;; ++ *) AC_MSG_RESULT(yes) ++ AC_DEFINE(INET6, 1, [true if you have IPv6]) ++ ;; ++ esac ], + +- AC_SEARCH_LIBS(getaddrinfo, inet6) +-fi ++ AC_TRY_RUN([ /* AF_INET6 avalable check */ ++#include <sys/types.h> ++#include <sys/socket.h> ++main() ++{ ++ exit(0); ++ if (socket(AF_INET6, SOCK_STREAM, 0) < 0) ++ exit(1); ++ else ++ exit(0); ++} ++], ++ AC_MSG_RESULT(yes) ++ AC_DEFINE(INET6, 1, [true if you have IPv6]), ++ AC_MSG_RESULT(no), ++ AC_MSG_RESULT(no) ++)) + + dnl Do you want to disable use of locale functions + AC_ARG_ENABLE([locale], +diff --git a/configure.sh b/configure.sh +index d6e9c8d..cfaaa99 100755 +--- a/configure.sh ++++ b/configure.sh +@@ -1349,7 +1349,7 @@ Optional Features: + --enable-maintainer-mode + turn on extra debug features + --disable-largefile omit support for large files +- --disable-ipv6 do not even try to use IPv6 ++ --disable-ipv6 disable ipv6 support + --disable-locale disable locale features + --disable-iconv-open disable all use of iconv_open() function + --disable-iconv disable rsync's --iconv option +@@ -1577,6 +1577,37 @@ fi + + } # ac_fn_c_try_run + ++# ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES ++# ------------------------------------------------------- ++# Tests whether HEADER exists and can be compiled using the include files in ++# INCLUDES, setting the cache variable VAR accordingly. ++ac_fn_c_check_header_compile () ++{ ++ as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack ++ { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 ++$as_echo_n "checking for $2... " >&6; } ++if eval \${$3+:} false; then : ++ $as_echo_n "(cached) " >&6 ++else ++ cat confdefs.h - <<_ACEOF >conftest.$ac_ext ++/* end confdefs.h. */ ++$4 ++#include <$2> ++_ACEOF ++if ac_fn_c_try_compile "$LINENO"; then : ++ eval "$3=yes" ++else ++ eval "$3=no" ++fi ++rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext ++fi ++eval ac_res=\$$3 ++ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 ++$as_echo "$ac_res" >&6; } ++ eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno ++ ++} # ac_fn_c_check_header_compile ++ + # ac_fn_c_try_link LINENO + # ----------------------- + # Try to link conftest.$ac_ext, and return whether this succeeded. +@@ -1623,37 +1654,6 @@ fi + + } # ac_fn_c_try_link + +-# ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES +-# ------------------------------------------------------- +-# Tests whether HEADER exists and can be compiled using the include files in +-# INCLUDES, setting the cache variable VAR accordingly. +-ac_fn_c_check_header_compile () +-{ +- as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack +- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 +-$as_echo_n "checking for $2... " >&6; } +-if eval \${$3+:} false; then : +- $as_echo_n "(cached) " >&6 +-else +- cat confdefs.h - <<_ACEOF >conftest.$ac_ext +-/* end confdefs.h. */ +-$4 +-#include <$2> +-_ACEOF +-if ac_fn_c_try_compile "$LINENO"; then : +- eval "$3=yes" +-else +- eval "$3=no" +-fi +-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +-fi +-eval ac_res=\$$3 +- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 +-$as_echo "$ac_res" >&6; } +- eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno +- +-} # ac_fn_c_check_header_compile +- + # ac_fn_c_check_header_mongrel LINENO HEADER VAR INCLUDES + # ------------------------------------------------------- + # Tests whether HEADER exists, giving a warning if it cannot be compiled using +@@ -4548,7 +4548,7 @@ else + We can't simply define LARGE_OFF_T to be 9223372036854775807, + since some C++ compilers masquerading as C compilers + incorrectly reject 9223372036854775807. */ +-#define LARGE_OFF_T ((((off_t) 1 << 31) << 31) - 1 + (((off_t) 1 << 31) << 31)) ++#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62)) + int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721 + && LARGE_OFF_T % 2147483647 == 1) + ? 1 : -1]; +@@ -4594,7 +4594,7 @@ else + We can't simply define LARGE_OFF_T to be 9223372036854775807, + since some C++ compilers masquerading as C compilers + incorrectly reject 9223372036854775807. */ +-#define LARGE_OFF_T ((((off_t) 1 << 31) << 31) - 1 + (((off_t) 1 << 31) << 31)) ++#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62)) + int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721 + && LARGE_OFF_T % 2147483647 == 1) + ? 1 : -1]; +@@ -4618,7 +4618,7 @@ rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + We can't simply define LARGE_OFF_T to be 9223372036854775807, + since some C++ compilers masquerading as C compilers + incorrectly reject 9223372036854775807. */ +-#define LARGE_OFF_T ((((off_t) 1 << 31) << 31) - 1 + (((off_t) 1 << 31) << 31)) ++#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62)) + int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721 + && LARGE_OFF_T % 2147483647 == 1) + ? 1 : -1]; +@@ -4663,7 +4663,7 @@ else + We can't simply define LARGE_OFF_T to be 9223372036854775807, + since some C++ compilers masquerading as C compilers + incorrectly reject 9223372036854775807. */ +-#define LARGE_OFF_T ((((off_t) 1 << 31) << 31) - 1 + (((off_t) 1 << 31) << 31)) ++#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62)) + int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721 + && LARGE_OFF_T % 2147483647 == 1) + ? 1 : -1]; +@@ -4687,7 +4687,7 @@ rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + We can't simply define LARGE_OFF_T to be 9223372036854775807, + since some C++ compilers masquerading as C compilers + incorrectly reject 9223372036854775807. */ +-#define LARGE_OFF_T ((((off_t) 1 << 31) << 31) - 1 + (((off_t) 1 << 31) << 31)) ++#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62)) + int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721 + && LARGE_OFF_T % 2147483647 == 1) + ? 1 : -1]; +@@ -4725,262 +4725,61 @@ fi + + fi + +-ipv6type=unknown +-ipv6lib=none +-ipv6trylibc=yes + ++# Checks if IPv6 is requested ++{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to enable ipv6" >&5 ++$as_echo_n "checking whether to enable ipv6... " >&6; } + # Check whether --enable-ipv6 was given. + if test "${enable_ipv6+set}" = set; then : +- enableval=$enable_ipv6; +-fi +- +-if test x"$enable_ipv6" != x"no"; then +- { $as_echo "$as_me:${as_lineno-$LINENO}: checking ipv6 stack type" >&5 +-$as_echo_n "checking ipv6 stack type... " >&6; } +- for i in inria kame linux-glibc linux-inet6 solaris toshiba v6d zeta cygwin; do +- case $i in +- inria) +- # http://www.kame.net/ +- +-cat confdefs.h - <<_ACEOF >conftest.$ac_ext +-/* end confdefs.h. */ +- +-#include <netinet/in.h> +-#ifdef IPV6_INRIA_VERSION +-yes +-#endif +-_ACEOF +-if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | +- $EGREP "yes" >/dev/null 2>&1; then : +- ipv6type=$i; +- +-$as_echo "#define INET6 1" >>confdefs.h +- +- +-fi +-rm -f conftest* +- +- ;; +- kame) +- # http://www.kame.net/ +- cat confdefs.h - <<_ACEOF >conftest.$ac_ext +-/* end confdefs.h. */ +- +-#include <netinet/in.h> +-#ifdef __KAME__ +-yes +-#endif +-_ACEOF +-if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | +- $EGREP "yes" >/dev/null 2>&1; then : +- ipv6type=$i; +- +-$as_echo "#define INET6 1" >>confdefs.h +- +-fi +-rm -f conftest* +- +- ;; +- linux-glibc) +- # http://www.v6.linux.or.jp/ +- cat confdefs.h - <<_ACEOF >conftest.$ac_ext +-/* end confdefs.h. */ +- +-#include <features.h> +-#if defined(__GLIBC__) && __GLIBC__ >= 2 && __GLIBC_MINOR__ >= 1 +-yes +-#endif +-_ACEOF +-if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | +- $EGREP "yes" >/dev/null 2>&1; then : +- ipv6type=$i; +- +-$as_echo "#define INET6 1" >>confdefs.h +- +-fi +-rm -f conftest* +- +- ;; +- linux-inet6) +- # http://www.v6.linux.or.jp/ +- if test -d /usr/inet6 -o -f /usr/inet6/lib/libinet6.a; then +- ipv6type=$i +- ipv6lib=inet6 +- ipv6libdir=/usr/inet6/lib +- ipv6trylibc=yes; +- +-$as_echo "#define INET6 1" >>confdefs.h +- +- CFLAGS="-I/usr/inet6/include $CFLAGS" +- fi +- ;; +- solaris) +- # http://www.sun.com +- cat confdefs.h - <<_ACEOF >conftest.$ac_ext +-/* end confdefs.h. */ +- +-#include <netinet/ip6.h> +-#ifdef __sun +-yes +-#endif +-_ACEOF +-if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | +- $EGREP "yes" >/dev/null 2>&1; then : +- ipv6type=$i; +- +-$as_echo "#define INET6 1" >>confdefs.h +- +-fi +-rm -f conftest* +- +- ;; +- toshiba) +- cat confdefs.h - <<_ACEOF >conftest.$ac_ext +-/* end confdefs.h. */ +- +-#include <sys/param.h> +-#ifdef _TOSHIBA_INET6 +-yes +-#endif +-_ACEOF +-if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | +- $EGREP "yes" >/dev/null 2>&1; then : +- ipv6type=$i; +- ipv6lib=inet6; +- ipv6libdir=/usr/local/v6/lib; +- +-$as_echo "#define INET6 1" >>confdefs.h +- +-fi +-rm -f conftest* +- +- ;; +- v6d) +- cat confdefs.h - <<_ACEOF >conftest.$ac_ext +-/* end confdefs.h. */ +- +-#include </usr/local/v6/include/sys/v6config.h> +-#ifdef __V6D__ +-yes +-#endif +-_ACEOF +-if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | +- $EGREP "yes" >/dev/null 2>&1; then : +- ipv6type=$i; +- ipv6lib=v6; +- ipv6libdir=/usr/local/v6/lib; +- +-$as_echo "#define INET6 1" >>confdefs.h +- +-fi +-rm -f conftest* +- +- ;; +- zeta) +- cat confdefs.h - <<_ACEOF >conftest.$ac_ext +-/* end confdefs.h. */ +- +-#include <sys/param.h> +-#ifdef _ZETA_MINAMI_INET6 +-yes +-#endif +-_ACEOF +-if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | +- $EGREP "yes" >/dev/null 2>&1; then : +- ipv6type=$i; +- ipv6lib=inet6; +- ipv6libdir=/usr/local/v6/lib; +- +-$as_echo "#define INET6 1" >>confdefs.h +- +-fi +-rm -f conftest* +- +- ;; +- cygwin) +- cat confdefs.h - <<_ACEOF >conftest.$ac_ext +-/* end confdefs.h. */ +- +-#include <netinet/in.h> +-#ifdef _CYGWIN_IN6_H +-yes +-#endif +-_ACEOF +-if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | +- $EGREP "yes" >/dev/null 2>&1; then : +- ipv6type=$i; ++ enableval=$enable_ipv6; case "$enableval" in ++ no) ++ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 ++$as_echo "no" >&6; } ++ ;; ++ *) { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 ++$as_echo "yes" >&6; } + + $as_echo "#define INET6 1" >>confdefs.h + +-fi +-rm -f conftest* ++ ;; ++ esac ++else ++ if test "$cross_compiling" = yes; then : ++ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 ++$as_echo "no" >&6; } + +- ;; +- esac +- if test "$ipv6type" != "unknown"; then +- break +- fi +- done +- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ipv6type" >&5 +-$as_echo "$ipv6type" >&6; } +- +- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing getaddrinfo" >&5 +-$as_echo_n "checking for library containing getaddrinfo... " >&6; } +-if ${ac_cv_search_getaddrinfo+:} false; then : +- $as_echo_n "(cached) " >&6 + else +- ac_func_search_save_LIBS=$LIBS +-cat confdefs.h - <<_ACEOF >conftest.$ac_ext ++ cat confdefs.h - <<_ACEOF >conftest.$ac_ext + /* end confdefs.h. */ +- +-/* Override any GCC internal prototype to avoid an error. +- Use char because int might match the return type of a GCC +- builtin and then its argument prototype would still apply. */ +-#ifdef __cplusplus +-extern "C" +-#endif +-char getaddrinfo (); +-int +-main () ++ /* AF_INET6 avalable check */ ++#include <sys/types.h> ++#include <sys/socket.h> ++main() + { +-return getaddrinfo (); +- ; +- return 0; ++ exit(0); ++ if (socket(AF_INET6, SOCK_STREAM, 0) < 0) ++ exit(1); ++ else ++ exit(0); + } ++ + _ACEOF +-for ac_lib in '' inet6; do +- if test -z "$ac_lib"; then +- ac_res="none required" +- else +- ac_res=-l$ac_lib +- LIBS="-l$ac_lib $ac_func_search_save_LIBS" +- fi +- if ac_fn_c_try_link "$LINENO"; then : +- ac_cv_search_getaddrinfo=$ac_res +-fi +-rm -f core conftest.err conftest.$ac_objext \ +- conftest$ac_exeext +- if ${ac_cv_search_getaddrinfo+:} false; then : +- break +-fi +-done +-if ${ac_cv_search_getaddrinfo+:} false; then : ++if ac_fn_c_try_run "$LINENO"; then : ++ { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 ++$as_echo "yes" >&6; } ++ ++$as_echo "#define INET6 1" >>confdefs.h + + else +- ac_cv_search_getaddrinfo=no ++ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 ++$as_echo "no" >&6; } + fi +-rm conftest.$ac_ext +-LIBS=$ac_func_search_save_LIBS ++rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ ++ conftest.$ac_objext conftest.beam conftest.$ac_ext + fi +-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_getaddrinfo" >&5 +-$as_echo "$ac_cv_search_getaddrinfo" >&6; } +-ac_res=$ac_cv_search_getaddrinfo +-if test "$ac_res" != no; then : +- test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" + + fi + +-fi + + # Check whether --enable-locale was given. + if test "${enable_locale+set}" = set; then : +@@ -5006,6 +4805,7 @@ $as_echo "#define SHUTDOWN_ALL_SOCKETS 1" >>confdefs.h + $as_echo "no" >&6; };; + esac + ++ + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5 + $as_echo_n "checking for ANSI C header files... " >&6; } + if ${ac_cv_header_stdc+:} false; then : +-- +2.10.2 diff --git a/net-misc/rsync/files/rsyncd.conf-3.0.9-r1 b/net-misc/rsync/files/rsyncd.conf-3.0.9-r1 new file mode 100644 index 00000000..20dcf3af --- /dev/null +++ b/net-misc/rsync/files/rsyncd.conf-3.0.9-r1 @@ -0,0 +1,15 @@ +# /etc/rsyncd.conf + +# Minimal configuration file for rsync daemon +# See rsync(1) and rsyncd.conf(5) man pages for help + +# This line is required by the /etc/init.d/rsyncd script +pid file = @GENTOO_PORTAGE_EPREFIX@/run/rsyncd.pid +use chroot = yes +read only = yes + +# Simple example for enabling your own local rsync server +#[gentoo-portage] +# path = @GENTOO_PORTAGE_EPREFIX@/usr/portage +# comment = Gentoo Portage tree +# exclude = /distfiles /packages diff --git a/net-misc/rsync/files/rsyncd.conf.d b/net-misc/rsync/files/rsyncd.conf.d new file mode 100644 index 00000000..c3d897ed --- /dev/null +++ b/net-misc/rsync/files/rsyncd.conf.d @@ -0,0 +1,5 @@ +# /etc/conf.d/rsyncd: config file for /etc/init.d/rsyncd + +# see man pages for rsync or run `rsync --help` +# for valid cmdline options +#RSYNC_OPTS="" diff --git a/net-misc/rsync/files/rsyncd.init.d-r1 b/net-misc/rsync/files/rsyncd.init.d-r1 new file mode 100644 index 00000000..243e107b --- /dev/null +++ b/net-misc/rsync/files/rsyncd.init.d-r1 @@ -0,0 +1,11 @@ +#!/sbin/openrc-run +# Copyright 1999-2012 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 + +command="/usr/bin/rsync" +command_args="--daemon ${RSYNC_OPTS}" +pidfile="/var/run/${SVCNAME}.pid" + +depend() { + use net +} diff --git a/net-misc/rsync/files/rsyncd.logrotate b/net-misc/rsync/files/rsyncd.logrotate new file mode 100644 index 00000000..34bcf72d --- /dev/null +++ b/net-misc/rsync/files/rsyncd.logrotate @@ -0,0 +1,9 @@ +/var/log/rsync.log { + compress + maxage 365 + rotate 7 + size=+1024k + notifempty + missingok + copytruncate +} diff --git a/net-misc/rsync/files/rsyncd.service b/net-misc/rsync/files/rsyncd.service new file mode 100644 index 00000000..a2c1de0a --- /dev/null +++ b/net-misc/rsync/files/rsyncd.service @@ -0,0 +1,12 @@ +[Unit] +Description=rsync daemon +After=networking.target + +[Service] +Type=simple +ExecStart=/usr/bin/rsync --daemon --no-detach +StandardOutput=syslog +StandardError=syslog + +[Install] +WantedBy=multi-user.target diff --git a/net-misc/rsync/files/rsyncd.xinetd-3.0.9-r1 b/net-misc/rsync/files/rsyncd.xinetd-3.0.9-r1 new file mode 100644 index 00000000..90d07f07 --- /dev/null +++ b/net-misc/rsync/files/rsyncd.xinetd-3.0.9-r1 @@ -0,0 +1,10 @@ +service rsync +{ + socket_type = stream + protocol = tcp + wait = no + user = root + server = @GENTOO_PORTAGE_EPREFIX@/usr/bin/rsync + server_args = --daemon + disable = yes +} diff --git a/net-misc/rsync/rsync-3.1.2-r2.ebuild b/net-misc/rsync/rsync-3.1.2-r2.ebuild new file mode 100644 index 00000000..08473b53 --- /dev/null +++ b/net-misc/rsync/rsync-3.1.2-r2.ebuild @@ -0,0 +1,89 @@ +# Copyright 1999-2017 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 + +EAPI=6 + +inherit eutils flag-o-matic prefix systemd + +DESCRIPTION="File transfer program to keep remote files into sync" +HOMEPAGE="http://rsync.samba.org/" +SRC_URI="http://rsync.samba.org/ftp/rsync/src/${P}.tar.gz" +[[ "${PV}" = *_pre* ]] && SRC_URI="http://rsync.samba.org/ftp/rsync/src-previews/${P/_/}.tar.gz" + +LICENSE="GPL-3" +SLOT="0" +if [[ ${PV} != *_pre ]] ; then +KEYWORDS="alpha amd64 arm arm64 hppa ia64 m68k ~mips ppc ppc64 s390 sh sparc x86 ~ppc-aix ~x64-cygwin ~amd64-fbsd ~sparc-fbsd ~x86-fbsd ~amd64-linux ~arm-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~m68k-mint ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris" +fi +IUSE="acl iconv ipv6 static stunnel xattr" + +LIB_DEPEND="acl? ( virtual/acl[static-libs(+)] ) + xattr? ( kernel_linux? ( sys-apps/attr[static-libs(+)] ) ) + >=dev-libs/popt-1.5[static-libs(+)]" +RDEPEND="!static? ( ${LIB_DEPEND//\[static-libs(+)]} ) + iconv? ( virtual/libiconv )" +DEPEND="${RDEPEND} + static? ( ${LIB_DEPEND} )" + +S=${WORKDIR}/${P/_/} + +PATCHES=( + "${FILESDIR}"/${PN}-fix-musl-ipv6.patch +) + +src_configure() { + use static && append-ldflags -static + econf \ + --without-included-popt \ + $(use_enable acl acl-support) \ + $(use_enable xattr xattr-support) \ + $(use_enable ipv6) \ + $(use_enable iconv) \ + --with-rsyncd-conf="${EPREFIX}"/etc/rsyncd.conf + touch proto.h-tstamp #421625 +} + +src_install() { + emake DESTDIR="${D}" install + newconfd "${FILESDIR}"/rsyncd.conf.d rsyncd + newinitd "${FILESDIR}"/rsyncd.init.d-r1 rsyncd + dodoc NEWS OLDNEWS README TODO tech_report.tex + insinto /etc + newins "${FILESDIR}"/rsyncd.conf-3.0.9-r1 rsyncd.conf + + insinto /etc/logrotate.d + newins "${FILESDIR}"/rsyncd.logrotate rsyncd + + insinto /etc/xinetd.d + newins "${FILESDIR}"/rsyncd.xinetd-3.0.9-r1 rsyncd + + # Install stunnel helpers + if use stunnel ; then + emake DESTDIR="${D}" install-ssl-client + emake DESTDIR="${D}" install-ssl-daemon + fi + + # Install the useful contrib scripts + exeinto /usr/share/rsync + doexe support/* + rm -f "${ED}"/usr/share/rsync/{Makefile*,*.c} + + eprefixify "${ED}"/etc/{,xinetd.d}/rsyncd* + + systemd_dounit "${FILESDIR}/rsyncd.service" +} + +pkg_postinst() { + if egrep -qis '^[[:space:]]use chroot[[:space:]]*=[[:space:]]*(no|0|false)' \ + "${EROOT}"/etc/rsyncd.conf "${EROOT}"/etc/rsync/rsyncd.conf ; then + ewarn "You have disabled chroot support in your rsyncd.conf. This" + ewarn "is a security risk which you should fix. Please check your" + ewarn "/etc/rsyncd.conf file and fix the setting 'use chroot'." + fi + if use stunnel ; then + einfo "Please install \">=net-misc/stunnel-4\" in order to use stunnel feature." + einfo + einfo "You maybe have to update the certificates configured in" + einfo "${EROOT}/etc/stunnel/rsync.conf" + fi +} |
