diff --git a/srcpkgs/elfutils/patches/musl-fts-obstack.patch b/srcpkgs/elfutils/patches/musl-fts-obstack.patch index 4cc2e152822..cf9c9e48dfa 100644 --- a/srcpkgs/elfutils/patches/musl-fts-obstack.patch +++ b/srcpkgs/elfutils/patches/musl-fts-obstack.patch @@ -74,49 +74,42 @@ @$(textrel_check) $(AM_V_at)ln -fs $@ $@.$(VERSION) ---- src/Makefile.am.orig 2016-04-02 12:20:57.175729538 +0200 -+++ src/Makefile.am 2016-04-02 12:26:24.247746411 +0200 -@@ -104,28 +104,28 @@ +--- src/Makefile.am.orig 2016-08-29 21:38:11.179295769 +0200 ++++ src/Makefile.am 2016-08-03 18:19:47.000000000 +0200 +@@ -67,22 +67,22 @@ ar_no_Wstack_usage = yes unstrip_no_Wstack_usage = yes --readelf_LDADD = $(libdw) $(libebl) $(libelf) $(libeu) $(argp_LDADD) -ldl --nm_LDADD = $(libdw) $(libebl) $(libelf) $(libeu) $(argp_LDADD) -ldl \ +readelf_LDADD = $(libdw) $(libebl) $(libelf) $(libeu) $(argp_LDADD) $(fts_LDADD) $(obstack_LDADD) -ldl +nm_LDADD = $(libdw) $(libebl) $(libelf) $(libeu) $(argp_LDADD) $(fts_LDADD) $(obstack_LDADD) -ldl \ +-readelf_LDADD = $(libdw) $(libebl) $(libelf) $(libeu) $(argp_LDADD) -ldl +-nm_LDADD = $(libdw) $(libebl) $(libelf) $(libeu) $(argp_LDADD) -ldl \ $(demanglelib) --size_LDADD = $(libelf) $(libeu) $(argp_LDADD) --strip_LDADD = $(libebl) $(libelf) $(libeu) $(argp_LDADD) -ldl --ld_LDADD = $(libebl) $(libelf) $(libeu) $(argp_LDADD) -ldl +size_LDADD = $(libelf) $(libeu) $(argp_LDADD) $(fts_LDADD) $(obstack_LDADD) -+strip_LDADD = $(libebl) $(libelf) $(libeu) $(argp_LDADD) $(fts_LDADD) $(obstack_LDADD) -ldl -+ld_LDADD = $(libebl) $(libelf) $(libeu) $(argp_LDADD) $(fts_LDADD) $(obstack_LDADD) -ldl - if NATIVE_LD - # -ldl is always needed for libebl. - ld_LDADD += libld_elf.a - endif - ld_LDFLAGS = -rdynamic --elflint_LDADD = $(libebl) $(libelf) $(libeu) $(argp_LDADD) -ldl --findtextrel_LDADD = $(libdw) $(libelf) $(argp_LDADD) --addr2line_LDADD = $(libdw) $(libelf) $(argp_LDADD) $(demanglelib) --elfcmp_LDADD = $(libebl) $(libelf) $(argp_LDADD) -ldl ++strip_LDADD = $(libebl) $(libelf) $(libdw) $(libeu) $(argp_LDADD) $(fts_LDADD) $(obstack_LDADD) -ldl +elflint_LDADD = $(libebl) $(libelf) $(libeu) $(argp_LDADD) $(fts_LDADD) $(obstack_LDADD) -ldl +findtextrel_LDADD = $(libdw) $(libelf) $(argp_LDADD) $(fts_LDADD) $(obstack_LDADD) +addr2line_LDADD = $(libdw) $(libelf) $(argp_LDADD) $(fts_LDADD) $(obstack_LDADD) $(demanglelib) +elfcmp_LDADD = $(libebl) $(libelf) $(argp_LDADD) $(fts_LDADD) $(obstack_LDADD) -ldl +-size_LDADD = $(libelf) $(libeu) $(argp_LDADD) +-strip_LDADD = $(libebl) $(libelf) $(libdw) $(libeu) $(argp_LDADD) -ldl +-elflint_LDADD = $(libebl) $(libelf) $(libeu) $(argp_LDADD) -ldl +-findtextrel_LDADD = $(libdw) $(libelf) $(argp_LDADD) +-addr2line_LDADD = $(libdw) $(libelf) $(argp_LDADD) $(demanglelib) +-elfcmp_LDADD = $(libebl) $(libelf) $(argp_LDADD) -ldl objdump_LDADD = $(libasm) $(libebl) $(libelf) $(libeu) $(argp_LDADD) -ldl --ranlib_LDADD = libar.a $(libelf) $(libeu) $(argp_LDADD) --strings_LDADD = $(libelf) $(libeu) $(argp_LDADD) --ar_LDADD = libar.a $(libelf) $(libeu) $(argp_LDADD) --unstrip_LDADD = $(libebl) $(libelf) $(libdw) $(libeu) $(argp_LDADD) -ldl --stack_LDADD = $(libebl) $(libelf) $(libdw) $(libeu) $(argp_LDADD) -ldl $(demanglelib) --elfcompress_LDADD = $(libebl) $(libelf) $(libdw) $(libeu) $(argp_LDADD) +ranlib_LDADD = libar.a $(libelf) $(libeu) $(argp_LDADD) $(fts_LDADD) $(obstack_LDADD) +strings_LDADD = $(libelf) $(libeu) $(argp_LDADD) $(fts_LDADD) $(obstack_LDADD) +ar_LDADD = libar.a $(libelf) $(libeu) $(argp_LDADD) $(fts_LDADD) $(obstack_LDADD) +unstrip_LDADD = $(libebl) $(libelf) $(libdw) $(libeu) $(argp_LDADD) $(fts_LDADD) $(obstack_LDADD) -ldl +stack_LDADD = $(libebl) $(libelf) $(libdw) $(libeu) $(argp_LDADD) $(fts_LDADD) $(obstack_LDADD) -ldl $(demanglelib) +elfcompress_LDADD = $(libebl) $(libelf) $(libdw) $(libeu) $(argp_LDADD) $(fts_LDADD) $(obstack_LDADD) +-ranlib_LDADD = libar.a $(libelf) $(libeu) $(argp_LDADD) +-strings_LDADD = $(libelf) $(libeu) $(argp_LDADD) +-ar_LDADD = libar.a $(libelf) $(libeu) $(argp_LDADD) +-unstrip_LDADD = $(libebl) $(libelf) $(libdw) $(libeu) $(argp_LDADD) -ldl +-stack_LDADD = $(libebl) $(libelf) $(libdw) $(libeu) $(argp_LDADD) -ldl $(demanglelib) +-elfcompress_LDADD = $(libebl) $(libelf) $(libdw) $(libeu) $(argp_LDADD) - ldlex.o: ldscript.c - ldlex_no_Werror = yes + installcheck-binPROGRAMS: $(bin_PROGRAMS) + bad=0; pid=$$$$; list="$(bin_PROGRAMS)"; for p in $$list; do \ diff --git a/srcpkgs/elfutils/patches/musl-macros.patch b/srcpkgs/elfutils/patches/musl-macros.patch index df3b8983da7..1185ee94391 100644 --- a/srcpkgs/elfutils/patches/musl-macros.patch +++ b/srcpkgs/elfutils/patches/musl-macros.patch @@ -28,28 +28,6 @@ #if __GNUC__ > 3 || (__GNUC__ == 3 && __GNUC_MINOR__ >= 3) # define __nonnull_attribute__(...) __attribute__ ((__nonnull__ (__VA_ARGS__))) ---- src/ld.h 2015-08-21 14:22:37.000000000 +0200 -+++ src/ld.h 2015-11-20 07:58:05.722222192 +0100 -@@ -24,6 +24,19 @@ - #include - #include "xelf.h" - -+#if !defined(DL_CALL_FCT) -+# define DL_CALL_FCT(fctp, args) (*fctp) args -+#endif /* !defined(DL_CALL_FCT) */ -+ -+#if !defined(ACCESSPERMS) -+# define ACCESSPERMS (S_IRWXU|S_IRWXG|S_IRWXO) /* 0777 */ -+#endif -+#if !defined(ALLPERMS) -+# define ALLPERMS (S_ISUID|S_ISGID|S_ISVTX|S_IRWXU|S_IRWXG|S_IRWXO) /* 07777 */ -+#endif -+#if !defined(DEFFILEMODE) -+# define DEFFILEMODE (S_IRUSR|S_IWUSR|S_IRGRP|S_IWGRP|S_IROTH|S_IWOTH)/* 0666*/ -+#endif - - /* Recommended size of the buffer passed to ld_strerror. */ - #define ERRBUFSIZE (512) --- src/arlib.h 2015-08-21 14:22:37.000000000 +0200 +++ src/arlib.h 2015-11-20 08:02:55.153199611 +0100 @@ -29,6 +29,16 @@ diff --git a/srcpkgs/elfutils/patches/musl-on_exit.patch b/srcpkgs/elfutils/patches/musl-on_exit.patch deleted file mode 100644 index 2ad8f632cda..00000000000 --- a/srcpkgs/elfutils/patches/musl-on_exit.patch +++ /dev/null @@ -1,27 +0,0 @@ ---- src/ldgeneric.c 2015-08-21 14:22:37.000000000 +0200 -+++ src/ldgeneric.c 2015-11-20 08:25:42.003092970 +0100 -@@ -2628,12 +2628,12 @@ - } - - --/* Callback function registered with on_exit to make sure the temporary -+/* Callback function registered with atexit to make sure the temporary - files gets removed if something goes wrong. */ - static void --remove_tempfile (int status, void *arg) -+remove_tempfile (void) - { -- if (status != 0 && ld_state.tempfname != NULL) -+ if (error_message_count != 0 && ld_state.tempfname != NULL) - unlink (ld_state.tempfname); - } - -@@ -2680,7 +2680,7 @@ - - /* Make sure we remove the temporary file in case something goes - wrong. */ -- on_exit (remove_tempfile, NULL); -+ atexit (remove_tempfile); - - /* Create the ELF file data for the output file. */ - Elf *elf = ld_state.outelf = elf_begin (fd, diff --git a/srcpkgs/elfutils/patches/musl-wmempcpy.patch b/srcpkgs/elfutils/patches/musl-wmempcpy.patch deleted file mode 100644 index abd8d64f6e8..00000000000 --- a/srcpkgs/elfutils/patches/musl-wmempcpy.patch +++ /dev/null @@ -1,11 +0,0 @@ ---- libebl/eblwstrtab.c 2015-08-21 14:22:37.000000000 +0200 -+++ libebl/eblwstrtab.c 2015-11-20 05:07:55.650018773 +0100 -@@ -305,7 +305,7 @@ - - /* Process the current node. */ - nodep->offset = *offsetp; -- *freep = wmempcpy (*freep, nodep->string, nodep->len); -+ *freep = wmemcpy (*freep, nodep->string, nodep->len) + nodep->len; - *offsetp += nodep->len * sizeof (wchar_t); - - for (subs = nodep->next; subs != NULL; subs = subs->next) diff --git a/srcpkgs/elfutils/template b/srcpkgs/elfutils/template index 41eb57f20a3..1d920a95dea 100644 --- a/srcpkgs/elfutils/template +++ b/srcpkgs/elfutils/template @@ -1,7 +1,7 @@ # Template file for 'elfutils' pkgname=elfutils -version=0.166 -revision=2 +version=0.167 +revision=1 build_style=gnu-configure configure_args="--program-prefix=eu-" hostmakedepends="automake libtool" @@ -11,7 +11,7 @@ maintainer="Juan RP " license="GPL-3" homepage="https://fedorahosted.org/elfutils/" distfiles="https://fedorahosted.org/releases/e/l/${pkgname}/${version}/${pkgname}-${version}.tar.bz2" -checksum=3c056914c8a438b210be0d790463b960fc79d234c3f05ce707cbff80e94cba30 +checksum=3f300087c42b6f35591163b48246b4098ce39c4c6f5d55a83023c903c5776553 # Suppress certain warnings to not fail for -Werror CFLAGS="-Wno-unused-result -Wno-format-nonliteral" @@ -20,6 +20,11 @@ case "$XBPS_TARGET_MACHINE" in *-musl) makedepends+=" argp-standalone musl-fts-devel musl-obstack" ;; esac +if [ "$CROSS_BUILD" ]; then + # kernel headers in our cross-* packages are too old (need >= 4.1) + CFLAGS+=" -DBPF_PSEUDO_MAP_FD=1" +fi + post_extract() { case "$XBPS_TARGET_MACHINE" in *-musl) cp ${FILESDIR}/error.h lib