Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Inconsistencies with dnf/apt install gcc #1040

Open
PhilipDeegan opened this issue Oct 11, 2024 · 5 comments
Open

Inconsistencies with dnf/apt install gcc #1040

PhilipDeegan opened this issue Oct 11, 2024 · 5 comments

Comments

@PhilipDeegan
Copy link

Hi

I've been testing out pkgx recently to see if I can use it to replace usage of dnf or apt across different linux distros.

I've run into two separate issues when trying to use gcc on fedora and ubuntu.
Such that, compilation works when I dnf or apt install gcc, and does not when I pkgx install gcc

Is this something that I should report here or elsewhere?

Thanks

@jhheider
Copy link
Contributor

jhheider commented Oct 11, 2024

It depends on what problem you're having. If it's a problem with the environment construction, then this is the correct repo. If it's a problem with the gnu.org/gcc formula, then pkgxdev/pantry.

It might specifically be an issue with the pkgx install scripts. If you instead use pkgx +gcc^{version} ... as your command line instead of using install, do you experience the same issues? That would point to a problem with the install methodology.

You could try running your makefile (or whatever) with CC='pkgx +gnu.org/gcc^14 gcc' or pkgx +gcc^14 +make make, as an example, to use pkgx to manage the full environment.

@PhilipDeegan
Copy link
Author

The errors, were during compilation of python package during a pip install.

I think the ubuntu issue was, the build system couldn't find x86_64-linux-gnu-gcc

and the fedora issue was a missing standard header

 fatal error: stdlib.h: No such file or directory

it's possible what you suggest might work, but I'm not sure compilation during pip install uses CC or CXX

@mxcl
Copy link
Member

mxcl commented Oct 11, 2024

This is probably a deeper problem with how we add the gcc headers to the env.

@jhheider
Copy link
Contributor

the build system couldn't find x86_64-linux-gnu-gcc

yes, we don't add the system-target binaries to the provides: key for gnu.org/gcc. this would be solved using pkgx +gnu.org/gcc, but because they aren't listed as a provided binary, no installation shim exists.

@PhilipDeegan
Copy link
Author

you can see the fedora error here

the ubuntu issue was happening locally for me during a docker build (but still during pip install internally)

you should be able to reproduce this via

comment out this line

and add if_install gcc -v here

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants