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

Fallback to default paths linux paths if no dpkg-architecture exists #3237

Closed
wants to merge 1 commit into from

Conversation

kkopachev
Copy link
Contributor

Fixes #3103 .

Changes proposed in this pull request:

  • When setup run on debian-like OS without dpkg-architecture installed, fallback to default linux guessing

For some reason debian docker image does not include dpkg-architecture, so trying to extract paths from it is pointless. Why don't we fallback to guessing already in place for other linux distros?

@kkopachev
Copy link
Contributor Author

there is another solution available #3245

@pslacerda
Copy link
Contributor

That if branch happens on linuxes that have an /etc/debian_version and with your change also only when dpkg-architecture is available. However install dpkg-dev on Fedora and run dpkg-architecture correctly shows an correct DEB_HOST_MULTIARCH variable.

So I would remove the check for /etc/debian_version and only test for the presence of dpkg-architecture, will only happen to work on more linuxes, at least Debian based ones and Fedora.

In #3245, the contents of /etc/ld.so.cache are searched because for sure there are linuxes that don't have dpkg-architecture available but has an /etc/ld.so.cache, expectedly with the same binary format. My guess is that if glibc is installed then this cache has the same format, but I'm not completly sure. I didn't called ldconfig -p directly because sometimes localization interfere on the output of commands and ldconfig don't have an option for a safe to parse output.

@kkopachev
Copy link
Contributor Author

closing in favor of #3245

@kkopachev kkopachev closed this Nov 13, 2018
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

Successfully merging this pull request may close these issues.

None yet

2 participants