-
Notifications
You must be signed in to change notification settings - Fork 236
Closed
Description
Hi there! 👋
I'm trying to build a package that depends on libtool in its configure.ac on musllinux_1_2. Unfortunately, running ./bootstrap fails with the following error message:
configure.ac:56: error: possibly undefined macro: AC_PROG_LIBTOOL
If this token and others are legitimate, please use m4_pattern_allow.
See the Autoconf documentation.
That's because the libtool m4 files are not in aclocal's search path:
2e287b27d346:/# aclocal --print-ac-dir
/usr/share/aclocal
2e287b27d346:/# ls -al $(aclocal --print-ac-dir)
total 208
drwxr-xr-x 1 root root 382 May 16 20:04 .
drwxr-xr-x 1 root root 364 May 16 20:04 ..
-rw-r--r-- 1 root root 368 Jul 15 2024 README
-rw-r--r-- 1 root root 1939 Oct 14 2024 bison-i18n.m4
-rw-r--r-- 1 root root 3235 Mar 27 2024 build-to-host.m4
-rw-r--r-- 1 root root 15479 Mar 27 2024 gettext.m4
-rw-r--r-- 1 root root 8371 Feb 23 20:27 glib-2.0.m4
-rw-r--r-- 1 root root 15744 Feb 23 20:27 glib-gettext.m4
-rw-r--r-- 1 root root 3589 Feb 23 20:27 gsettings.m4
-rw-r--r-- 1 root root 17132 Mar 27 2024 host-cpu-c-abi.m4
-rw-r--r-- 1 root root 9681 Mar 27 2024 iconv.m4
-rw-r--r-- 1 root root 3504 Mar 27 2024 intlmacosx.m4
-rw-r--r-- 1 root root 5384 Mar 27 2024 lib-ld.m4
-rw-r--r-- 1 root root 35740 Mar 27 2024 lib-link.m4
-rw-r--r-- 1 root root 12502 Mar 27 2024 lib-prefix.m4
-rw-r--r-- 1 root root 1234 Mar 27 2024 nls.m4
-rw-r--r-- 1 root root 13230 Aug 7 2024 pkg.m4
-rw-r--r-- 1 root root 19019 Mar 27 2024 po.m4
-rw-r--r-- 1 root root 3089 Mar 27 2024 progtest.m4
-rw-r--r-- 1 root root 6505 Dec 2 08:38 xtrans.m4
Instead, they're in /usr/local/share/aclocal:
2e287b27d346:/# ls -al /usr/local/share/aclocal/
total 372
drwxr-xr-x 1 root root 148 May 16 20:04 .
drwxr-xr-x 1 root root 30 May 16 20:09 ..
-rw-r--r-- 1 root root 307116 May 16 20:04 libtool.m4
-rw-r--r-- 1 root root 2670 May 16 20:04 ltargz.m4
-rw-r--r-- 1 root root 30029 May 16 20:04 ltdl.m4
-rw-r--r-- 1 root root 15441 May 16 20:04 ltoptions.m4
-rw-r--r-- 1 root root 4395 May 16 20:04 ltsugar.m4
-rw-r--r-- 1 root root 714 May 16 20:04 ltversion.m4
-rw-r--r-- 1 root root 6151 May 16 20:04 lt~obsolete.m4
Running apk add libtool once more inside the container solves the problem, because it installs the m4 files in the correct locations:
c986cc20ae97:/# apk add libtool
(1/2) Installing libltdl (2.4.7-r3)
(2/2) Installing libtool (2.4.7-r3)
Executing busybox-1.37.0-r12.trigger
OK: 942 MiB in 242 packages
c986cc20ae97:/# ls -al $(aclocal --print-ac-dir)
total 580
drwxr-xr-x 1 root root 148 May 29 13:49 .
drwxr-xr-x 1 root root 28 May 29 13:49 ..
-rw-r--r-- 1 root root 368 Jul 15 2024 README
-rw-r--r-- 1 root root 1939 Oct 14 2024 bison-i18n.m4
-rw-r--r-- 1 root root 3235 Mar 27 2024 build-to-host.m4
-rw-r--r-- 1 root root 15479 Mar 27 2024 gettext.m4
-rw-r--r-- 1 root root 8371 Feb 23 20:27 glib-2.0.m4
-rw-r--r-- 1 root root 15744 Feb 23 20:27 glib-gettext.m4
-rw-r--r-- 1 root root 3589 Feb 23 20:27 gsettings.m4
-rw-r--r-- 1 root root 17132 Mar 27 2024 host-cpu-c-abi.m4
-rw-r--r-- 1 root root 9681 Mar 27 2024 iconv.m4
-rw-r--r-- 1 root root 3504 Mar 27 2024 intlmacosx.m4
-rw-r--r-- 1 root root 5384 Mar 27 2024 lib-ld.m4
-rw-r--r-- 1 root root 35740 Mar 27 2024 lib-link.m4
-rw-r--r-- 1 root root 12502 Mar 27 2024 lib-prefix.m4
-rw-r--r-- 1 root root 307049 May 15 2023 libtool.m4
-rw-r--r-- 1 root root 2670 May 15 2023 ltargz.m4
-rw-r--r-- 1 root root 30061 May 15 2023 ltdl.m4
-rw-r--r-- 1 root root 14525 May 15 2023 ltoptions.m4
-rw-r--r-- 1 root root 4395 May 15 2023 ltsugar.m4
-rw-r--r-- 1 root root 714 May 15 2023 ltversion.m4
-rw-r--r-- 1 root root 6151 May 15 2023 lt~obsolete.m4
-rw-r--r-- 1 root root 1234 Mar 27 2024 nls.m4
-rw-r--r-- 1 root root 13230 Aug 7 2024 pkg.m4
-rw-r--r-- 1 root root 19019 Mar 27 2024 po.m4
-rw-r--r-- 1 root root 3089 Mar 27 2024 progtest.m4
-rw-r--r-- 1 root root 6505 Dec 2 08:38 xtrans.m4
I'm not sure whether this is a problem with how the musllinux images are built, but it used to work on musllinux_1_1, probably due to the fact that aclocal's search path was different there:
# This is musllinux_1_1 now
bash-5.0# aclocal --print-ac-dir
/usr/local/share/aclocal
bash-5.0# ls -al $(aclocal --print-ac-dir)
total 376
drwxr-xr-x 1 root root 148 Oct 16 2024 .
drwxr-xr-x 1 root root 30 Oct 16 2024 ..
-rw-r--r-- 1 root root 368 Oct 16 2024 README
-rw-r--r-- 1 root root 307116 Oct 16 2024 libtool.m4
-rw-r--r-- 1 root root 2670 Oct 16 2024 ltargz.m4
-rw-r--r-- 1 root root 30029 Oct 16 2024 ltdl.m4
-rw-r--r-- 1 root root 15441 Oct 16 2024 ltoptions.m4
-rw-r--r-- 1 root root 4395 Oct 16 2024 ltsugar.m4
-rw-r--r-- 1 root root 714 Oct 16 2024 ltversion.m4
-rw-r--r-- 1 root root 6151 Oct 16 2024 lt~obsolete.m4
Metadata
Metadata
Assignees
Labels
No labels