Source: opensmtpd-filter-dkimsign
Version: 0.5-2
Severity: important
Tags: ftbfs
Justification: FTBFS
X-Debbugs-Cc: ni...@thykier.net
User: ni...@thykier.net
Usertags: rrr-no-as-default-issue

Dear maintainer,

During a test rebuild for building packages with
`Rules-Requires-Root: no` as the default in `dpkg`,
opensmtpd-filter-dkimsign failed to rebuild.

Log Summary:
-------------------------------------------------------------------------------
[...]
dpkg-buildpackage: info: source changed by Ryan Kavanagh <r...@debian.org>
 dpkg-source --before-build .
dpkg-buildpackage: info: host architecture arm64
 debian/rules clean
dh clean --buildsystem=makefile
   debian/rules override_dh_auto_clean
make[1]: Entering directory '/<<PKGBUILDDIR>>'
dh_auto_clean -- -f Makefile.gnu
        make -j8 clean -f Makefile.gnu
make[2]: Entering directory '/<<PKGBUILDDIR>>'
rm -f filter-dkimsign.8.gz main.d mheader.d /<<PKGBUILDDIR>>/openbsd-compat/reallocarray.d /<<PKGBUILDDIR>>/openbsd-compat/recallocarray.d /<<PKGBUILDDIR>>/openbsd-compat/strlcat.d /<<PKGBUILDDIR>>/openbsd-compat/strtonum.d main.o mheader.o reallocarray.o recallocarray.o strlcat.o strtonum.o filter-dkimsign
make[2]: Leaving directory '/<<PKGBUILDDIR>>'
make[1]: Leaving directory '/<<PKGBUILDDIR>>'
   dh_autoreconf_clean -O--buildsystem=makefile
   dh_clean -O--buildsystem=makefile
 debian/rules binary
dh binary --buildsystem=makefile
   dh_update_autotools_config -O--buildsystem=makefile
   dh_autoreconf -O--buildsystem=makefile
   debian/rules override_dh_auto_configure
make[1]: Entering directory '/<<PKGBUILDDIR>>'
dh_auto_configure -- -f Makefile.gnu
make[1]: Leaving directory '/<<PKGBUILDDIR>>'
   debian/rules override_dh_auto_build
make[1]: Entering directory '/<<PKGBUILDDIR>>'
dh_auto_build -- -f Makefile.gnu HAVE_ED25519=1
make -j8 "INSTALL=install --strip-program=true" -f Makefile.gnu HAVE_ED25519=1
make[2]: Entering directory '/<<PKGBUILDDIR>>'
cc -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/<<PKGBUILDDIR>>=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -DHAVE_ED25519 -I/usr//include -Wall -I -Wstrict-prototypes -Wmissing-prototypes -Wmissing-declarations -Wshadow -Wpointer-arith -Wcast-qual -Wsign-compare -I/<<PKGBUILDDIR>> -I/<<PKGBUILDDIR>>/openbsd-compat/ -DNEED_REALLOCARRAY=1 -DNEED_RECALLOCARRAY=1 -DNEED_STRLCAT=1 -DNEED_STRTONUM=1 -DNEED_PLEDGE=1 -Wdate-time -D_FORTIFY_SOURCE=2 -c -o main.o main.c cc -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/<<PKGBUILDDIR>>=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -DHAVE_ED25519 -I/usr//include -Wall -I -Wstrict-prototypes -Wmissing-prototypes -Wmissing-declarations -Wshadow -Wpointer-arith -Wcast-qual -Wsign-compare -I/<<PKGBUILDDIR>> -I/<<PKGBUILDDIR>>/openbsd-compat/ -DNEED_REALLOCARRAY=1 -DNEED_RECALLOCARRAY=1 -DNEED_STRLCAT=1 -DNEED_STRTONUM=1 -DNEED_PLEDGE=1 -Wdate-time -D_FORTIFY_SOURCE=2 -c -o mheader.o mheader.c cc -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/<<PKGBUILDDIR>>=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -DHAVE_ED25519 -I/usr//include -Wall -I -Wstrict-prototypes -Wmissing-prototypes -Wmissing-declarations -Wshadow -Wpointer-arith -Wcast-qual -Wsign-compare -I/<<PKGBUILDDIR>> -I/<<PKGBUILDDIR>>/openbsd-compat/ -DNEED_REALLOCARRAY=1 -DNEED_RECALLOCARRAY=1 -DNEED_STRLCAT=1 -DNEED_STRTONUM=1 -DNEED_PLEDGE=1 -c -o reallocarray.o /<<PKGBUILDDIR>>/openbsd-compat/reallocarray.c cc -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/<<PKGBUILDDIR>>=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -DHAVE_ED25519 -I/usr//include -Wall -I -Wstrict-prototypes -Wmissing-prototypes -Wmissing-declarations -Wshadow -Wpointer-arith -Wcast-qual -Wsign-compare -I/<<PKGBUILDDIR>> -I/<<PKGBUILDDIR>>/openbsd-compat/ -DNEED_REALLOCARRAY=1 -DNEED_RECALLOCARRAY=1 -DNEED_STRLCAT=1 -DNEED_STRTONUM=1 -DNEED_PLEDGE=1 -c -o recallocarray.o /<<PKGBUILDDIR>>/openbsd-compat/recallocarray.c cc -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/<<PKGBUILDDIR>>=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -DHAVE_ED25519 -I/usr//include -Wall -I -Wstrict-prototypes -Wmissing-prototypes -Wmissing-declarations -Wshadow -Wpointer-arith -Wcast-qual -Wsign-compare -I/<<PKGBUILDDIR>> -I/<<PKGBUILDDIR>>/openbsd-compat/ -DNEED_REALLOCARRAY=1 -DNEED_RECALLOCARRAY=1 -DNEED_STRLCAT=1 -DNEED_STRTONUM=1 -DNEED_PLEDGE=1 -c -o strlcat.o /<<PKGBUILDDIR>>/openbsd-compat/strlcat.c cc -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/<<PKGBUILDDIR>>=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -DHAVE_ED25519 -I/usr//include -Wall -I -Wstrict-prototypes -Wmissing-prototypes -Wmissing-declarations -Wshadow -Wpointer-arith -Wcast-qual -Wsign-compare -I/<<PKGBUILDDIR>> -I/<<PKGBUILDDIR>>/openbsd-compat/ -DNEED_REALLOCARRAY=1 -DNEED_RECALLOCARRAY=1 -DNEED_STRLCAT=1 -DNEED_STRTONUM=1 -DNEED_PLEDGE=1 -c -o strtonum.o /<<PKGBUILDDIR>>/openbsd-compat/strtonum.c sed -e 's_$Mdocdate$_August 25, 2022_' filter-dkimsign.8 | mandoc -Tman | gzip > filter-dkimsign.8.gz
main.c: In function ‘dkim_sign’:
main.c:693:56: warning: pointer targets in passing argument 2 of ‘EVP_DigestSignFinal’ differ in signedness [-Wpointer-sign] 693 | if (EVP_DigestSignFinal(message->dctx, tmp, &linelen) != 1) {
      |                                                        ^~~
      |                                                        |
      |                                                        char *
In file included from main.c:17:
/usr/include/openssl/evp.h:837:64: note: expected ‘unsigned char *’ but argument is of type ‘char *’ 837 | __owur int EVP_DigestSignFinal(EVP_MD_CTX *ctx, unsigned char *sigret, | ~~~~~~~~~~~~~~~^~~~~~ main.c:699:51: warning: pointer targets in passing argument 2 of ‘EVP_DigestSign’ differ in signedness [-Wpointer-sign] 699 | if (EVP_DigestSign(message->dctx, tmp, &linelen, bdigest,
      |                                                   ^~~
      |                                                   |
      |                                                   char *
/usr/include/openssl/evp.h:815:59: note: expected ‘unsigned char *’ but argument is of type ‘char *’
  815 | __owur int EVP_DigestSign(EVP_MD_CTX *ctx, unsigned char *sigret,
      |                                            ~~~~~~~~~~~~~~~^~~~~~
main.c:710:28: warning: pointer targets in passing argument 2 of ‘EVP_EncodeBlock’ differ in signedness [-Wpointer-sign]
  710 |         EVP_EncodeBlock(b, tmp, linelen);
      |                            ^~~
      |                            |
      |                            char *
/usr/include/openssl/evp.h:869:60: note: expected ‘const unsigned char *’ but argument is of type ‘char *’ 869 | int EVP_EncodeBlock(unsigned char *t, const unsigned char *f, int n);
      |                                       ~~~~~~~~~~~~~~~~~~~~~^
cc -Wl,-z,relro -Wl,-z,now -L/usr//lib -o filter-dkimsign main.o mheader.o reallocarray.o recallocarray.o strlcat.o strtonum.o -lcrypto -lopensmtpd
make[2]: Leaving directory '/<<PKGBUILDDIR>>'
make[1]: Leaving directory '/<<PKGBUILDDIR>>'
   debian/rules override_dh_auto_test
make[1]: Entering directory '/<<PKGBUILDDIR>>'
# no tests
make[1]: Leaving directory '/<<PKGBUILDDIR>>'
   create-stamp debian/debhelper-build-stamp
   dh_testroot -O--buildsystem=makefile
   dh_prep -O--buildsystem=makefile
   debian/rules override_dh_auto_install
make[1]: Entering directory '/<<PKGBUILDDIR>>'
dh_auto_install -- -f Makefile.gnu LOCALBASE=/usr
make -j8 install DESTDIR=/<<PKGBUILDDIR>>/debian/opensmtpd-filter-dkimsign AM_UPDATE_INFO_DIR=no "INSTALL=install --strip-program=true" -f Makefile.gnu LOCALBASE=/usr
make[2]: Entering directory '/<<PKGBUILDDIR>>'
install --strip-program=true -D -o root -g root -m 755 filter-dkimsign /<<PKGBUILDDIR>>/debian/opensmtpd-filter-dkimsign/usr/libexec/opensmtpd//filter-dkimsign install: WARNING: ignoring --strip-program option as -s option was not specified install: cannot change ownership of '/<<PKGBUILDDIR>>/debian/opensmtpd-filter-dkimsign/usr/libexec/opensmtpd//filter-dkimsign': Operation not permitted
make[2]: *** [Makefile.gnu:122: install] Error 1
make[2]: Leaving directory '/<<PKGBUILDDIR>>'
dh_auto_install: error: make -j8 install DESTDIR=/<<PKGBUILDDIR>>/debian/opensmtpd-filter-dkimsign AM_UPDATE_INFO_DIR=no "INSTALL=install --strip-program=true" -f Makefile.gnu LOCALBASE=/usr returned exit code 2
make[1]: *** [debian/rules:17: override_dh_auto_install] Error 25
make[1]: Leaving directory '/<<PKGBUILDDIR>>'
make: *** [debian/rules:8: binary] Error 2
dpkg-buildpackage: error: debian/rules binary subprocess returned exit status 2
--------------------------------------------------------------------------------
Build finished at 2024-11-17T17:01:49Z

-------------------------------------------------------------------------------


The above is just how the build ends and not necessarily the most
relevant part. If required, the full build log is available here:

https://people.debian.org/~nthykier/rrr-no-as-default/logs/1026066.gz

You can find common solutions at
https://people.debian.org/~nthykier/rrr-no-as-default/docs/solutions.md

If this is really a bug in one of the build-depends, please use
reassign and affects, so that this is still visible in the BTS web
page for this package.

If this package is listed in
https://people.debian.org/~nthykier/rrr-no-as-default/docs/static-ownership.list,
then please just set `Rules-Requires-Root: binary-targets` to the source
stanza of `debian/control` as a fix to this bug.

If this package is listed in
https://people.debian.org/~nthykier/rrr-no-as-default/docs/maybe-misbuilds.list,
then the package was deemed at risk for misbuilding (having wrong
ownership) but had a FTBFS problem we tested it. Please test whether the
package works with `Rules-Requires-Root: no` validating that the
resulting deb has the correct ownership for all paths in the deb.

The goal is to have the default changed in `dpkg` either in `Trixie` or
`Forky`, depending on progress and feasibility with the release schedule
for Trixie.

For more information on this bug filing, please see:
https://lists.debian.org/debian-dpkg/2024/11/msg00016.html

Thanks,


PS: The builds were performed in mid-November. If you fixed the problem
between between then and this bug being filed, then please just close
the bug with the version it was fixed in.

Attachment: OpenPGP_signature.asc
Description: OpenPGP digital signature

Reply via email to