View previous topic :: View next topic |
Author |
Message |
Zucca Moderator
Joined: 14 Jun 2007 Posts: 3406 Location: Rasi, Finland
|
Posted: Sat May 06, 2023 7:08 pm Post subject: Compiler missing in llvm profile [solved already, but] |
|
|
I've been installing Gentoo to a (underpowered) laptop and I chose musl-llvm profile (I wish there was musl-llvm-nomultilib too).
Aaanyway. I oneshotted gcc to test if I could just simply compile refind using package.env, but It did not work. I guess setting CC and CXX wasn't enough, but that's another topic.
However, upon --depcleaning I saw gcc being removed. I let it happen since I had no use for gcc anymore. Oh boy... Then the ... dark orange pudding hit the fan.
When emerging anything that needed c or c++ compiler I got some strange errors like "clang: no gcc installation found at /usr/lib/gcc/x86_64-gentoo-linux-musl/12". (Sorry, my backlog doesn't reach that far anymore to give here an exact error messages and log.)
I don't know why clang needs gcc, but oh well... Eventually I found /etc/clang/gentoo-common.cfg, which had inclusion of contents of /etc/clang/gentoo-gcc-install.cfg: | # This file is maintained by gcc-config.
# It is used to specify the selected GCC installation.
--gcc-install-dir="/usr/lib/gcc/x86_64-gentoo-linux-musl/12" |
Commenting the line which includes /etc/clang/gentoo-gcc-install.cfg in /etc/clang/gentoo-common.cfg [solved] the problem.
But there are lot's of references to "gcc/x86_64-gentoo-linux-musl/12" or alike inside /etc at least.
For now I guess I just mask gcc and gcc-config, but before I do that... Can I remove all the references to gcc by re-emerging gcc-config and use it to remove any "traces"?
Also this may be a case for a bug report. I mean with "vanilla" configs doing Code: | emerge -1 gcc; emerge -c gcc | ... results in "missing" compiler situation. I can reproduce this if really needed. _________________ ..: Zucca :..
Gentoo IRC channels reside on Libera.Chat.
--
Quote: | I am NaN! I am a man! |
|
|
Back to top |
|
|
sam_ Developer
Joined: 14 Aug 2020 Posts: 1707
|
Posted: Sun May 07, 2023 8:47 am Post subject: |
|
|
Yeah, gcc-config needs to handle this in pkg_postrm (or perhaps prerm to reduce the raise). Or in gcc's toolchain.eclass.
Please do file a bug. I appreciate your testing on these experimental profiles. |
|
Back to top |
|
|
Zucca Moderator
Joined: 14 Jun 2007 Posts: 3406 Location: Rasi, Finland
|
Posted: Mon May 08, 2023 6:38 pm Post subject: |
|
|
sam_ wrote: | Please do file a bug. | Against gcc-config? sam_ wrote: | I appreciate your testing on these experimental profiles. | Learning things here out of curiosity. Testing comes as a bonus effect. _________________ ..: Zucca :..
Gentoo IRC channels reside on Libera.Chat.
--
Quote: | I am NaN! I am a man! |
|
|
Back to top |
|
|
stefan11111 l33t
Joined: 29 Jan 2023 Posts: 922 Location: Romania
|
Posted: Mon May 08, 2023 10:18 pm Post subject: Re: Compiler missing in llvm profile [solved already, but] |
|
|
Zucca wrote: | I've been installing Gentoo to a (underpowered) laptop and I chose musl-llvm profile (I wish there was musl-llvm-nomultilib too).
|
Isn't musl x86_64 only? _________________ My overlay: https://github.com/stefan11111/stefan_overlay
INSTALL_MASK="/etc/systemd /lib/systemd /usr/lib/systemd /usr/lib/modules-load.d *udev* /usr/lib/tmpfiles.d *tmpfiles* /var/lib/dbus /usr/bin/gdbus /lib/udev" |
|
Back to top |
|
|
GDH-gentoo Veteran
Joined: 20 Jul 2019 Posts: 1569 Location: South America
|
Posted: Mon May 08, 2023 10:47 pm Post subject: Re: Compiler missing in llvm profile [solved already, but] |
|
|
stefan11111 wrote: | Isn't musl x86_64 only? |
musl supports both 32-bit and 64-bit variants, but Gentoo doesn't provide multilib musl profiles indeed, if that's what you meant. _________________
NeddySeagoon wrote: | I'm not a witch, I'm a retired electronics engineer |
Ionen wrote: | As a packager I just don't want things to get messier with weird build systems and multiple toolchains requirements though |
|
|
Back to top |
|
|
stefan11111 l33t
Joined: 29 Jan 2023 Posts: 922 Location: Romania
|
Posted: Mon May 08, 2023 11:24 pm Post subject: Re: Compiler missing in llvm profile [solved already, but] |
|
|
GDH-gentoo wrote: | stefan11111 wrote: | Isn't musl x86_64 only? |
musl supports both 32-bit and 64-bit variants, but Gentoo doesn't provide multilib musl profiles indeed, if that's what you meant. |
Does upstream support multilib musl? I thought it was 64-bit . If so, why does gentoo not support multilib musl? _________________ My overlay: https://github.com/stefan11111/stefan_overlay
INSTALL_MASK="/etc/systemd /lib/systemd /usr/lib/systemd /usr/lib/modules-load.d *udev* /usr/lib/tmpfiles.d *tmpfiles* /var/lib/dbus /usr/bin/gdbus /lib/udev" |
|
Back to top |
|
|
GDH-gentoo Veteran
Joined: 20 Jul 2019 Posts: 1569 Location: South America
|
Posted: Mon May 08, 2023 11:51 pm Post subject: Re: Compiler missing in llvm profile [solved already, but] |
|
|
stefan11111 wrote: | Does upstream support multilib musl? I thought it was 64-bit . |
An amd64 multilib setup is basically having two copies of selected libraries, paired with a clever setup of build tools (compilers, linkers, pkg-config, etc.). So providing that is in the distribution's 'jurisdiction', not upstream's. And since you can have two copies of musl on the same computer, it could be theoretically possible, I think. But...
stefan11111 wrote: | If so, why does gentoo not support multilib musl? |
... Gentoo developers probably consider that possible usefulness of such a setup is not worth the maintenance effort, given available resources.
EDIT: There is a pure 32-bit musl profile though (GCC-only), it is default/linux/x86/17.0/musl _________________
NeddySeagoon wrote: | I'm not a witch, I'm a retired electronics engineer |
Ionen wrote: | As a packager I just don't want things to get messier with weird build systems and multiple toolchains requirements though |
|
|
Back to top |
|
|
sam_ Developer
Joined: 14 Aug 2020 Posts: 1707
|
Posted: Tue May 09, 2023 2:45 pm Post subject: |
|
|
musl upstream explicitly doesn't support multilib and there's no real point given there's no 32-bit ancient games built against musl you want to use on 64-bit systems. Note that it needs some ld.so support.
As for bug: yes, against gcc-config, but it doesn't really matter as I'll triage it anyway. |
|
Back to top |
|
|
Zucca Moderator
Joined: 14 Jun 2007 Posts: 3406 Location: Rasi, Finland
|
Posted: Tue May 09, 2023 6:50 pm Post subject: |
|
|
The deed is done.
Haven't filled a bug report in some time. I hope there's enough information. _________________ ..: Zucca :..
Gentoo IRC channels reside on Libera.Chat.
--
Quote: | I am NaN! I am a man! |
|
|
Back to top |
|
|
GDH-gentoo Veteran
Joined: 20 Jul 2019 Posts: 1569 Location: South America
|
Posted: Tue May 09, 2023 9:44 pm Post subject: |
|
|
sam_ wrote: | musl upstream explicitly doesn't support multilib and there's no real point given there's no 32-bit ancient games built against musl you want to use on 64-bit systems. Note that it needs some ld.so support. |
I believe that the dynamic linker's support is already there: each musl variant gets information about directories to search for shared libraries named in DT_NEEDED entries of PT_DYNAMIC segments of ELF executables from different files: /etc/ld-musl-i386.path for the 32-bit libc.so, /etc/ld-musl-x86_64.path for the 64-bit libc.so. I don't know if there is any other needed support. But yes, there is the question about the usefulness of such a setup. _________________
NeddySeagoon wrote: | I'm not a witch, I'm a retired electronics engineer |
Ionen wrote: | As a packager I just don't want things to get messier with weird build systems and multiple toolchains requirements though |
|
|
Back to top |
|
|
sam_ Developer
Joined: 14 Aug 2020 Posts: 1707
|
Posted: Tue May 09, 2023 9:47 pm Post subject: |
|
|
GDH-gentoo wrote: | sam_ wrote: | musl upstream explicitly doesn't support multilib and there's no real point given there's no 32-bit ancient games built against musl you want to use on 64-bit systems. Note that it needs some ld.so support. |
I believe that the dynamic linker's support is already there: each musl variant gets information about directories to search for shared libraries named in DT_NEEDED entries of PT_DYNAMIC segments of ELF executables from different files: /etc/ld-musl-i386.path for the 32-bit libc.so, /etc/ld-musl-x86_64.path for the 64-bit libc.so. I don't know if there is any other needed support. But yes, there is the question about the usefulness of such a setup. |
You're right, but see also https://wiki.musl-libc.org/guidelines-for-distributions.html#Multilib/multi-arch. |
|
Back to top |
|
|
Zucca Moderator
Joined: 14 Jun 2007 Posts: 3406 Location: Rasi, Finland
|
Posted: Wed May 10, 2023 7:42 am Post subject: |
|
|
If I manage to fix this in Portage's bashrc then It should be easily merged into ebuild or eclass. _________________ ..: Zucca :..
Gentoo IRC channels reside on Libera.Chat.
--
Quote: | I am NaN! I am a man! |
|
|
Back to top |
|
|
Zucca Moderator
Joined: 14 Jun 2007 Posts: 3406 Location: Rasi, Finland
|
Posted: Mon May 29, 2023 6:46 pm Post subject: Also this... |
|
|
Also portage/emerge seems to warn user if gcc isn't found from the system (see this comment).
I tried to remove every reference to gcc from /etc (after removing gcc-config). But I still got the warning.
I think this is a separate bug. Portage should recognize llvm profile (or clang as a system compiler).
I'll conduct more tests before raising (yet) another bug. _________________ ..: Zucca :..
Gentoo IRC channels reside on Libera.Chat.
--
Quote: | I am NaN! I am a man! |
|
|
Back to top |
|
|
|