Summary: | dev-util/ostree-2022.6 - In function '_checkout_overlayfs_whiteout_at': src/libostree/ostree-repo-checkout.c:689:30: error: 'ALLPERMS' undeclared (first use in this function) (on musl) | ||
---|---|---|---|
Product: | Gentoo Linux | Reporter: | ernsteiswuerfel <erhard_f> |
Component: | Current packages | Assignee: | Zac Medico <zmedico> |
Status: | RESOLVED FIXED | ||
Severity: | normal | Keywords: | PATCH, REGRESSION |
Priority: | Normal | ||
Version: | unspecified | ||
Hardware: | All | ||
OS: | Linux | ||
Whiteboard: | |||
Package list: | Runtime testing required: | --- | |
Bug Depends on: | |||
Bug Blocks: | 430702 | ||
Attachments: |
build.log
emerge --info musl-missing_include.patch |
Created attachment 826867 [details]
emerge --info
Regression over ostree-2022.2 which builds fine on musl. Created attachment 827135 [details, diff]
musl-missing_include.patch
Seems the ALLPERMS missing here is a glibc-ism. The patch simply adds ALLPERMS when missing. ostree-2022.6 builds fine then.
Patch borrowed from dev-libs/elfutils-0.187-r2 where the same logic is applied in several files. Luckily it's only needed in one place in ostree-2022.6.
(In reply to ernsteiswuerfel from comment #3) > Created attachment 827135 [details, diff] [details, diff] > musl-missing_include.patch > > Seems the ALLPERMS missing here is a glibc-ism. The patch simply adds > ALLPERMS when missing. ostree-2022.6 builds fine then. > > Patch borrowed from dev-libs/elfutils-0.187-r2 where the same logic is > applied in several files. Luckily it's only needed in one place in > ostree-2022.6. Thanks @ernsteiswuerfel, this looks good. Will you please send this patch as a pull request to https://github.com/ostreedev/ostree/pulls? The bug has been closed via the following commit(s): https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=b09efe8df162f8c422196ef872235a06b0f622bd commit b09efe8df162f8c422196ef872235a06b0f622bd Author: Zac Medico <zmedico@gentoo.org> AuthorDate: 2022-11-05 22:48:44 +0000 Commit: Zac Medico <zmedico@gentoo.org> CommitDate: 2022-11-05 23:08:56 +0000 dev-util/ostree: add patch to fix musl build Closes: https://bugs.gentoo.org/879321 Signed-off-by: Zac Medico <zmedico@gentoo.org> dev-util/ostree/files/ostree-2022.6-musl-allperms.patch | 17 +++++++++++++++++ dev-util/ostree/ostree-2022.6.ebuild | 4 ++++ 2 files changed, 21 insertions(+) |
Created attachment 826865 [details] build.log [...] libtool: compile: x86_64-gentoo-linux-musl-gcc -DHAVE_CONFIG_H -I. -DDATADIR=\"/usr/share\" -DLIBEXECDIR=\"/usr/libexec\" -DLOCALEDIR=\"/usr/share/locale\" -DSYSCONFDIR=\"/etc\" -DTARGET_PREFIX=\"/usr\" -DSHORTENED_SYSCONFDIR=\"etc\" "-DOSTREE_FEATURES=\"libcurl libsoup gpgme ex-fsverity openssl release p2p\"" -DOSTREE_COMPILATION -DG_LOG_DOMAIN=\"OSTree\" -DOSTREE_GITREV=\"\" -DGLIB_VERSION_MIN_REQUIRED=GLIB_VERSION_2_66 "-DGLIB_VERSION_MAX_ALLOWED=G_ENCODE_VERSION(2,70)" -DSOUP_VERSION_MIN_REQUIRED=SOUP_VERSION_2_40 "-DSOUP_VERSION_MAX_ALLOWED=G_ENCODE_VERSION(2,48)" -std=gnu99 -fno-strict-aliasing -pipe -Wall -Werror=shadow -Werror=empty-body -Werror=strict-prototypes -Werror=missing-prototypes -Werror=implicit-function-declaration -Werror=format=2 -Werror=format-security -Werror=format-nonliteral -Werror=pointer-arith -Werror=init-self -Werror=missing-declarations -Werror=return-type -Werror=switch -Werror=overflow -Werror=int-conversion -Werror=parentheses -Werror=undef -Werror=incompatible-pointer-types -Werror=misleading-indentation -Werror=missing-include-dirs -Wstrict-aliasing=2 -Werror=unused-result -I./bsdiff -I./libglnx -I./src/libotutil -I./src/libostree -I./src/libostree -I/usr/include/gio-unix-2.0 -I/usr/include/glib-2.0 -I/usr/lib/glib-2.0/include -I/usr/lib/libffi/include -pthread -I/usr/include/libmount -I/usr/include/blkid -fvisibility=hidden "-D_OSTREE_PUBLIC=__attribute__((visibility(\"default\"))) extern" -DPKGLIBEXECDIR=\"/usr/libexec/libostree\" -Os -march=bdver3 -mtune=bdver3 -pipe -c src/libostree/ostree-repo-checkout.c -fPIC -DPIC -o src/libostree/.libs/libostree_1_la-ostree-repo-checkout.o src/libostree/ostree-repo-checkout.c: In function '_checkout_overlayfs_whiteout_at': src/libostree/ostree-repo-checkout.c:689:30: error: 'ALLPERMS' undeclared (first use in this function) 689 | if ((file_mode & ALLPERMS) != (dest_stbuf.st_mode & ALLPERMS)) | ^~~~~~~~ src/libostree/ostree-repo-checkout.c:689:30: note: each undeclared identifier is reported only once for each function it appears in make[2]: *** [Makefile:5280: src/libostree/libostree_1_la-ostree-repo-checkout.lo] Error 1 make[2]: Leaving directory '/var/tmp/portage/dev-util/ostree-2022.6/work/libostree-2022.6' make[1]: *** [Makefile:7859: all-recursive] Error 1 make[1]: Leaving directory '/var/tmp/portage/dev-util/ostree-2022.6/work/libostree-2022.6' make: *** [Makefile:3208: all] Error 2 * ERROR: dev-util/ostree-2022.6::gentoo failed (compile phase): * emake failed