diff options
| -rw-r--r-- | meta-oe/recipes-extended/zsync/zsync-curl/fixes.patch | 115 | ||||
| -rw-r--r-- | meta-oe/recipes-extended/zsync/zsync-curl/make.patch | 50 | ||||
| -rw-r--r-- | meta-oe/recipes-extended/zsync/zsync-curl_git.bb | 20 |
3 files changed, 185 insertions, 0 deletions
diff --git a/meta-oe/recipes-extended/zsync/zsync-curl/fixes.patch b/meta-oe/recipes-extended/zsync/zsync-curl/fixes.patch new file mode 100644 index 0000000000..1ec4993a1c --- /dev/null +++ b/meta-oe/recipes-extended/zsync/zsync-curl/fixes.patch | |||
| @@ -0,0 +1,115 @@ | |||
| 1 | Upstream-Status: Submitted [https://github.com/probonopd/zsync-curl/pull/41] | ||
| 2 | Signed-off-by: Ross Burton <ross.burton@arm.com> | ||
| 3 | |||
| 4 | diff --git a/src/configure.ac b/src/configure.ac | ||
| 5 | index 10de8c4..6488140 100644 | ||
| 6 | --- a/src/configure.ac | ||
| 7 | +++ b/src/configure.ac | ||
| 8 | @@ -9,7 +9,6 @@ AC_CONFIG_MACRO_DIR([autotools]) | ||
| 9 | AC_CANONICAL_HOST | ||
| 10 | |||
| 11 | AM_INIT_AUTOMAKE([dist-bzip2 no-dist-gzip foreign check-news -Woverride -Wobsolete -Wportability -Wsyntax -Wunsupported]) | ||
| 12 | -AM_MAINTAINER_MODE | ||
| 13 | |||
| 14 | dnl --- Check for programs | ||
| 15 | AC_PROG_CC | ||
| 16 | @@ -23,6 +22,7 @@ AS_IF([test "x$enable_profile" = "xyes"], [ | ||
| 17 | ZS_CFLAGS="${ZS_CFLAGS} -pg" ]) | ||
| 18 | |||
| 19 | dnl --- Header files, typedefs, structures, libraries | ||
| 20 | +AC_USE_SYSTEM_EXTENSIONS | ||
| 21 | AC_C_CONST | ||
| 22 | AC_HEADER_STDC | ||
| 23 | # string.h, memory.h, stdlib.h both included in the default header checks | ||
| 24 | @@ -55,10 +55,6 @@ case $host_os in | ||
| 25 | host_os_mingw32=yes | ||
| 26 | LIBS="${LIBS} -lwsock32" | ||
| 27 | ;; | ||
| 28 | - *) | ||
| 29 | - AC_DEFINE([_XOPEN_SOURCE], 600, [Enable POSIX extensions if present]) | ||
| 30 | - AC_DEFINE([_BSD_SOURCE],1, [Enable BSD extensions if present]) | ||
| 31 | - ;; | ||
| 32 | esac | ||
| 33 | AM_CONDITIONAL([MINGW32], test "x$host_os_mingw32" = "xyes") | ||
| 34 | |||
| 35 | diff --git a/src/librcksum/Makefile.am b/src/librcksum/Makefile.am | ||
| 36 | index f4fce72..47754eb 100644 | ||
| 37 | --- a/src/librcksum/Makefile.am | ||
| 38 | +++ b/src/librcksum/Makefile.am | ||
| 39 | @@ -1,4 +1,4 @@ | ||
| 40 | - | ||
| 41 | +AM_CPPFLAGS = "-I$(top_srcdir)" | ||
| 42 | |||
| 43 | noinst_LIBRARIES = librcksum.a | ||
| 44 | |||
| 45 | diff --git a/src/librcksum/md4.h b/src/librcksum/md4.h | ||
| 46 | index e90603a..0ed7485 100644 | ||
| 47 | --- a/src/librcksum/md4.h | ||
| 48 | +++ b/src/librcksum/md4.h | ||
| 49 | @@ -18,11 +18,8 @@ | ||
| 50 | |||
| 51 | #include "zsglobal.h" | ||
| 52 | |||
| 53 | -#ifdef HAVE_INTTYPES_H | ||
| 54 | -#include <inttypes.h> | ||
| 55 | -#else | ||
| 56 | +#include <stdint.h> | ||
| 57 | #include <sys/types.h> | ||
| 58 | -#endif | ||
| 59 | |||
| 60 | #define MD4_BLOCK_LENGTH 64 | ||
| 61 | #define MD4_DIGEST_LENGTH 16 | ||
| 62 | diff --git a/src/libzsync/Makefile.am b/src/libzsync/Makefile.am | ||
| 63 | index 0a6ae85..33a5951 100644 | ||
| 64 | --- a/src/libzsync/Makefile.am | ||
| 65 | +++ b/src/libzsync/Makefile.am | ||
| 66 | @@ -1,3 +1,4 @@ | ||
| 67 | +AM_CPPFLAGS = "-I$(top_srcdir)" | ||
| 68 | |||
| 69 | noinst_LIBRARIES = libzsync.a | ||
| 70 | |||
| 71 | diff --git a/src/libzsync/sha1.h b/src/libzsync/sha1.h | ||
| 72 | index 3946505..87f3794 100644 | ||
| 73 | --- a/src/libzsync/sha1.h | ||
| 74 | +++ b/src/libzsync/sha1.h | ||
| 75 | @@ -11,11 +11,8 @@ | ||
| 76 | |||
| 77 | #include "config.h" | ||
| 78 | |||
| 79 | -#ifdef HAVE_INTTYPES_H | ||
| 80 | -#include <inttypes.h> | ||
| 81 | -#else | ||
| 82 | +#include <stdint.h> | ||
| 83 | #include <sys/types.h> | ||
| 84 | -#endif | ||
| 85 | |||
| 86 | #define SHA1_BLOCK_LENGTH 64 | ||
| 87 | #define SHA1_DIGEST_LENGTH 20 | ||
| 88 | diff --git a/src/libzsync/zmap.c b/src/libzsync/zmap.c | ||
| 89 | index f052dba..030b2a5 100644 | ||
| 90 | --- a/src/libzsync/zmap.c | ||
| 91 | +++ b/src/libzsync/zmap.c | ||
| 92 | @@ -28,9 +28,6 @@ | ||
| 93 | #include <string.h> | ||
| 94 | #include <sys/types.h> | ||
| 95 | #include <arpa/inet.h> | ||
| 96 | -#ifdef HAVE_INTTYPES_H | ||
| 97 | -#include <inttypes.h> | ||
| 98 | -#endif | ||
| 99 | |||
| 100 | #ifdef WITH_DMALLOC | ||
| 101 | # include <dmalloc.h> | ||
| 102 | diff --git a/src/make.c b/src/make.c | ||
| 103 | index 191b527..ba7f3a9 100644 | ||
| 104 | --- a/src/make.c | ||
| 105 | +++ b/src/make.c | ||
| 106 | @@ -28,9 +28,6 @@ | ||
| 107 | #include <time.h> | ||
| 108 | |||
| 109 | #include <arpa/inet.h> | ||
| 110 | -#ifdef HAVE_INTTYPES_H | ||
| 111 | -#include <inttypes.h> | ||
| 112 | -#endif | ||
| 113 | |||
| 114 | #include <sys/types.h> | ||
| 115 | #include <sys/stat.h> | ||
diff --git a/meta-oe/recipes-extended/zsync/zsync-curl/make.patch b/meta-oe/recipes-extended/zsync/zsync-curl/make.patch new file mode 100644 index 0000000000..ef19b5e85e --- /dev/null +++ b/meta-oe/recipes-extended/zsync/zsync-curl/make.patch | |||
| @@ -0,0 +1,50 @@ | |||
| 1 | Upstream-Status: Pending | ||
| 2 | Signed-off-by: Ross Burton <ross.burton@arm.com> | ||
| 3 | |||
| 4 | From 3b9d64cf3c33ad235ed444f8715732e509ab023f Mon Sep 17 00:00:00 2001 | ||
| 5 | From: Ross Burton <ross.burton@arm.com> | ||
| 6 | Date: Wed, 9 Jun 2021 16:11:25 +0100 | ||
| 7 | Subject: [PATCH] Build zsyncmake | ||
| 8 | |||
| 9 | No point having the zsync client without the server-side tool. | ||
| 10 | |||
| 11 | Closes #42 | ||
| 12 | --- | ||
| 13 | .gitignore | 1 + | ||
| 14 | src/Makefile.am | 5 ++++- | ||
| 15 | 2 files changed, 5 insertions(+), 1 deletion(-) | ||
| 16 | |||
| 17 | diff --git a/.gitignore b/.gitignore | ||
| 18 | index 36f7bd8..728658e 100644 | ||
| 19 | --- a/.gitignore | ||
| 20 | +++ b/.gitignore | ||
| 21 | @@ -22,3 +22,4 @@ src/librcksum/md4test | ||
| 22 | src/libzsync/sha1test | ||
| 23 | stamp-h1 | ||
| 24 | zsync_curl | ||
| 25 | +zsyncmake_curl | ||
| 26 | diff --git a/src/Makefile.am b/src/Makefile.am | ||
| 27 | index 5f8ff73..ffa2280 100644 | ||
| 28 | --- a/src/Makefile.am | ||
| 29 | +++ b/src/Makefile.am | ||
| 30 | @@ -4,13 +4,16 @@ ACLOCAL_AMFLAGS = -I autotools | ||
| 31 | |||
| 32 | SUBDIRS = librcksum zlib libzsync doc | ||
| 33 | |||
| 34 | -bin_PROGRAMS = zsync_curl | ||
| 35 | +bin_PROGRAMS = zsync_curl zsyncmake_curl | ||
| 36 | |||
| 37 | zsync_curl_SOURCES = client.c http.c http.h url.c url.h progress.c progress.h base64.c format_string.h zsglobal.h | ||
| 38 | zsync_curl_LDADD = libzsync/libzsync.a librcksum/librcksum.a zlib/libinflate.a $(LIBOBJS) | ||
| 39 | |||
| 40 | EXTRA_zsync_curl_SOURCES = getaddrinfo.h | ||
| 41 | |||
| 42 | +zsyncmake_curl_SOURCES = make.c makegz.c makegz.h format_string.h | ||
| 43 | +zsyncmake_curl_LDADD = libzsync/libzsync.a librcksum/librcksum.a zlib/libinflate.a zlib/libdeflate.a -lm | ||
| 44 | + | ||
| 45 | # From "GNU autoconf, automake and libtool" Vaughan, Elliston, | ||
| 46 | # # Tromey and Taylor, publisher New Riders, p.134 | ||
| 47 | # # They made me do it! :-) | ||
| 48 | -- | ||
| 49 | 2.25.1 | ||
| 50 | |||
diff --git a/meta-oe/recipes-extended/zsync/zsync-curl_git.bb b/meta-oe/recipes-extended/zsync/zsync-curl_git.bb new file mode 100644 index 0000000000..adb72d5de2 --- /dev/null +++ b/meta-oe/recipes-extended/zsync/zsync-curl_git.bb | |||
| @@ -0,0 +1,20 @@ | |||
| 1 | SUMMARY = "File transfer tool optimised for large files (curl port)" | ||
| 2 | HOMEPAGE = "http://zsync.moria.org.uk/" | ||
| 3 | DEPENDS = "curl" | ||
| 4 | |||
| 5 | LICENSE = "Artistic-2.0" | ||
| 6 | LIC_FILES_CHKSUM = "file://src/COPYING;md5=71c0ac4d86266533509aa0825b8d323c" | ||
| 7 | |||
| 8 | SRC_URI = "git://github.com/probonopd/zsync-curl;protocol=https \ | ||
| 9 | file://fixes.patch \ | ||
| 10 | file://make.patch" | ||
| 11 | SRCREV = "00141c2806ccc4ddf2ff6263ee1612d19c0b713f" | ||
| 12 | |||
| 13 | PV = "0.6.2+git${SRCPV}" | ||
| 14 | |||
| 15 | inherit autotools | ||
| 16 | |||
| 17 | S = "${WORKDIR}/git" | ||
| 18 | AUTOTOOLS_SCRIPT_PATH = "${S}/src" | ||
| 19 | |||
| 20 | BBCLASSEXTEND = "native nativesdk" | ||
