[Swan-dev] Bug#853947: libreswan FTBFS on mips and mipsel: error: "_ABI64" is not defined [-Werror=undef]
Daniel Kahn Gillmor
dkg at fifthhorseman.net
Fri Feb 3 00:40:43 UTC 2017
Hi Radovan--
Over on https://bugs.debian.org/853947 you wrote:
On Thu 2017-02-02 07:02:59 -0500, Radovan Birdic wrote:
> Package: libreswan
> Version: 3.19-1
> Severity: important
> Tags: sid + patch
> Justification: FTBFS
> User: debian-mips at lists.debian.org
> Usertags: mips-patch
>
>
> Package libreswan_3.19-1 FTBFS on mips and mipsel with following error:
>
>> In file included from /usr/include/nspr/prtypes.h:26:0,
>> from /usr/include/nspr/plarena.h:15,
>> from /usr/include/nss/cert.h:13,
>> from /«PKGBUILDDIR»/lib/libswan/nss_copies.c:6:
>> /usr/include/nspr/prcpucfg.h:511:18: error: "_ABI64" is not defined [-Werror=undef]
>> #if _MIPS_SIM == _ABI64
>> ^~~~~~
>> cc1: all warnings being treated as errors
>> ../../../mk/depend.mk:28: recipe for target 'nss_copies.o' failed
>> make[5]: *** [nss_copies.o] Error 1
>
> Full build log:
> https://buildd.debian.org/status/fetch.php?pkg=libreswan&arch=mips&ver=3.19-1&stamp=1485409760&raw=0
>
> On 32-bit mips (ABIO32) _ABI64 is not defined so using -Wundef flag causes build failure.
>
> I have created and attached a patch that exclude this flag for mips/mipsel.
> With this patch package builds successfully on mips, mipsel and mips64el.
>
> Regards,
> Radovan
> --- libreswan-3.19_orig/debian/rules 2017-01-25 23:37:04.000000000 +0000
> +++ libreswan-3.19/debian/rules 2017-02-02 20:01:47.654502204 +0000
> @@ -1,5 +1,12 @@
> #!/usr/bin/make -f
>
> +DEB_BUILD_ARCH ?= $(shell dpkg-architecture -qDEB_BUILD_ARCH)
> +ifneq (,$(filter $(DEB_BUILD_ARCH),mips mipsel))
> + ADDITIONAL_WARNING_CFLAGS = -Wall -Wextra -Wformat -Wformat-nonliteral -Wformat-security -Wmissing-declarations -Wredundant-decls -Wnested-externs
> +else
> + ADDITIONAL_WARNING_CFLAGS = -Wall -Wextra -Wformat -Wformat-nonliteral -Wundef -Wformat-security -Wmissing-declarations -Wredundant-decls -Wnested-externs
> +endif
> +
> %:
> dh $@ --with systemd
>
> @@ -17,7 +24,8 @@ override_dh_auto_build:
> USE_LIBCAP_NG=true \
> USE_LABELED_IPSEC=false \
> USE_KLIPS=false \
> - USE_DNSSEC=true
> + USE_DNSSEC=true \
> + WARNING_CFLAGS="$(ADDITIONAL_WARNING_CFLAGS)"
>
> override_dh_auto_install-arch:
> # Add here commands to install the package into debian/libreswan
I appreciate the patch, but i think excluding the warning is probably
not a great idea -- presumably, upstream should be doing something
differently there.
I'm cc'ing upstream on this.
upstream folks, you can see build logs for 3.1.19-1 on debian over here:
https://buildd.debian.org/status/logs.php?pkg=libreswan&ver=3.19-1&suite=sid
The failing mips build log is here:
https://buildd.debian.org/status/fetch.php?pkg=libreswan&arch=mips&ver=3.19-1&stamp=1485409760&raw=0
and the failing mipsel build log is here:
https://buildd.debian.org/status/fetch.php?pkg=libreswan&arch=mipsel&ver=3.19-1&stamp=1485507191&raw=0
If this is something you can fix upstream, i'm happy to pull the patch
into debian's packaging directly.
Regards,
--dkg
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 832 bytes
Desc: not available
URL: <https://lists.libreswan.org/pipermail/swan-dev/attachments/20170202/2bb56880/attachment.sig>
More information about the Swan-dev
mailing list