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

[WIP] Proof of concept: Provide default libGL aliases #34461

Merged
merged 12 commits into from Mar 5, 2018

Conversation

avnik
Copy link
Contributor

@avnik avnik commented Jan 31, 2018

Motivation for this change

Alternative attempt to resolve libGL hell, via smooth transition to libglvnd
(this is first step, where no hashes shoudl be changes (or at least minimise rebuild as possible).

(second commit to chromium/default.nix) marked as treewide is just placeholder, I plan to have 3 commits replacing mesa-* with libGL* everywhere.

So next step will provide function to make derivation for /run/opengl-drivers, something, which can be useed as:

mkOpenglDriversSet {
    libGL_provider = mesa_drivers;
    libGLvnd_drivers = [];
    vulcan_drivers = [];
    opencl_drivers = [];
}

or

mkOpenglDriverSet {
    libGL_provider = libglvnd;
    libGLvnd_drivers = [ mesa_drivers_glvnd nvidia_drivers ...];
    vulcan_drivers = [ some_package_providing_icd_file ];
    opencl_drivers = [ some_package_providing_icd_file ];
}

At some moment, we can swtich default libGL alias (introduced in first commit) to libglvnd, and it will be single mass-rebuild. Folks, who have runtime issues with libglvnd, can use first of examples above to use old-style libGL.so.

@vcunat @gnidorah Any thoughts?

Things done
  • Tested using sandboxing (nix.useSandbox on NixOS, or option build-use-sandbox in nix.conf on non-NixOS)
  • Built on platform(s)
    • NixOS
    • macOS
    • other Linux distributions
  • Tested via one or more NixOS test(s) if existing and applicable for the change (look inside nixos/tests)
  • Tested compilation of all pkgs that depend on this change using nix-shell -p nox --run "nox-review wip"
  • Tested execution of all binary files (usually in ./result/bin/)
  • Fits CONTRIBUTING.md.

@grahamc
Copy link
Member

grahamc commented Jan 31, 2018

I introduced a failure in the evaluator today, sorry about that. Testing for a fix:

@GrahamcOfBorg eval

@vcunat
Copy link
Member

vcunat commented Feb 3, 2018

Well, OK, I like the libGL name, and it will finally fit even on Darwin; now it's close before release, so that's the ideal time for larger renames. This PR should be verified to rebuild zero packages – I can do that easily by ./maintainers/scripts/rebuild-amount.sh. I suppose we should keep the old names in ./aliases.nix for now (one release cycle?).

Any other ideas/opinions before creating the mass-renaming commit?

@avnik
Copy link
Contributor Author

avnik commented Feb 24, 2018

@vcunat I perform libGL/libGLU transition for most packages. Take a look please. This PR shouldn't affect most hashes

@vcunat vcunat merged commit 25a78f7 into NixOS:master Mar 5, 2018
vcunat added a commit that referenced this pull request Mar 5, 2018
This will just bit rot otherwise.  Almost nothing gets rebuilt.
peti added a commit to NixOS/cabal2nix that referenced this pull request Mar 6, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

6 participants