rsync: Add new patch
This commit is contained in:
parent
4f156183ea
commit
071d9d9bcf
@ -2,7 +2,7 @@
|
||||
|
||||
pkgname=rsync
|
||||
pkgver=3.1.0
|
||||
pkgrel=2
|
||||
pkgrel=3
|
||||
pkgdesc="A file transfer program to keep remote files in sync"
|
||||
arch=('i686' 'x86_64')
|
||||
url="http://samba.anu.edu.au/rsync/"
|
||||
@ -12,36 +12,39 @@ depends=('perl')
|
||||
source=("http://rsync.samba.org/ftp/rsync/$pkgname-$pkgver.tar.gz"
|
||||
"http://rsync.samba.org/ftp/rsync/$pkgname-$pkgver.tar.gz.asc"
|
||||
rsync-3.1.0-msys2.patch
|
||||
CVE-2014-2855.patch)
|
||||
CVE-2014-2855.patch
|
||||
ssh-6-option.patch)
|
||||
md5sums=('3be148772a33224771a8d4d2a028b132'
|
||||
'SKIP'
|
||||
'6964f315300b3cfe8f663d1386628368'
|
||||
'dacfe77bd72fbf6b6ba65c741c57f74c')
|
||||
'dacfe77bd72fbf6b6ba65c741c57f74c'
|
||||
'2d66b179a84cafbec06968260cb85df4')
|
||||
|
||||
prepare() {
|
||||
cd "${srcdir}/${pkgname}-${pkgver}"
|
||||
|
||||
patch -p1 -i ${srcdir}/rsync-3.1.0-msys2.patch
|
||||
patch -p1 -i ${srcdir}/CVE-2014-2855.patch
|
||||
patch -p1 -i ${srcdir}/ssh-6-option.patch
|
||||
|
||||
autoreconf -fi
|
||||
}
|
||||
|
||||
build() {
|
||||
cd "$srcdir/$pkgname-$pkgver"
|
||||
./configure --build=${CHOST} \
|
||||
--prefix=/usr \
|
||||
--without-included-zlib
|
||||
make man all
|
||||
cd "$srcdir/$pkgname-$pkgver"
|
||||
./configure --build=${CHOST} \
|
||||
--prefix=/usr \
|
||||
--without-included-zlib
|
||||
make man all
|
||||
}
|
||||
|
||||
check() {
|
||||
cd "$srcdir/$pkgname-$pkgver"
|
||||
make test
|
||||
cd "$srcdir/$pkgname-$pkgver"
|
||||
make test
|
||||
}
|
||||
|
||||
package() {
|
||||
cd "$srcdir/$pkgname-$pkgver"
|
||||
make DESTDIR="$pkgdir" install
|
||||
install -Dm755 support/rrsync "$pkgdir/usr/lib/rsync/rrsync"
|
||||
cd "$srcdir/$pkgname-$pkgver"
|
||||
make DESTDIR="$pkgdir" install
|
||||
install -Dm755 support/rrsync "$pkgdir/usr/lib/rsync/rrsync"
|
||||
}
|
||||
|
||||
34
rsync/ssh-6-option.patch
Normal file
34
rsync/ssh-6-option.patch
Normal file
@ -0,0 +1,34 @@
|
||||
--- a/main.c 2008-03-01 21:01:41.000000000 +0100
|
||||
+++ b/main.c 2008-03-04 18:55:10.933488013 +0100
|
||||
@@ -82,6 +82,7 @@
|
||||
#ifdef ICONV_OPTION
|
||||
extern iconv_t ic_send;
|
||||
#endif
|
||||
+extern int default_af_hint;
|
||||
|
||||
uid_t our_uid;
|
||||
int local_server = 0;
|
||||
@@ -381,6 +382,23 @@
|
||||
*t++ = '\0';
|
||||
}
|
||||
|
||||
+#ifdef AF_INET
|
||||
+ if (default_af_hint == AF_INET) {
|
||||
+ if (strncmp(cmd, "ssh", 3) == 0 || strstr(cmd, "/ssh") != NULL) {
|
||||
+ /* we're using ssh so we can add a -4 option */
|
||||
+ args[argc++] = "-4";
|
||||
+ }
|
||||
+ }
|
||||
+#endif
|
||||
+#ifdef AF_INET6
|
||||
+ if (default_af_hint == AF_INET6) {
|
||||
+ if (strncmp(cmd, "ssh", 3) == 0 || strstr(cmd, "/ssh") != NULL) {
|
||||
+ /* we're using ssh so we can add a -6 option */
|
||||
+ args[argc++] = "-6";
|
||||
+ }
|
||||
+ }
|
||||
+#endif
|
||||
+
|
||||
/* check to see if we've already been given '-l user' in
|
||||
* the remote-shell command */
|
||||
for (i = 0; i < argc-1; i++) {
|
||||
Loading…
x
Reference in New Issue
Block a user