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

p11-kit: fix static build #147171

Closed
wants to merge 3 commits into from
Closed

Conversation

SCOTT-HAMILTON
Copy link
Contributor

Motivation for this change

Part of a bigger project to build Qt 5 statically #136107.

Things done

Fixed build of pkgsStatic.p11-kit,
created mesonShlibsToStaticHook: a preconfigure setup hook that replaces all shared_library calls to static_library calls in meson.build files.

  • Built on platform(s)
    • x86_64-linux
    • aarch64-linux
    • x86_64-darwin
    • aarch64-darwin
  • For non-Linux: Is sandbox = true set in nix.conf? (See Nix manual)
  • Tested, as applicable:
  • Tested compilation of all packages that depend on this change using nix-shell -p nixpkgs-review --run "nixpkgs-review rev HEAD". Note: all changes have to be committed, also see nixpkgs-review usage
  • Tested basic functionality of all binary files (usually in ./result/bin/)
  • 21.11 Release Notes (or backporting 21.05 Release notes)
    • (Package updates) Added a release notes entry if the change is major or breaking
    • (Module updates) Added a release notes entry if the change is significant
    • (Module addition) Added a release notes entry if adding a new NixOS module
    • (Release notes changes) Ran nixos/doc/manual/md-to-db.sh to update generated release notes
  • Fits CONTRIBUTING.md.

@alyssais
Copy link
Member

Hi, thanks for breaking these out into smaller PRs.

My understanding is that it doesn't make sense to build p11-kit statically. Am I misunderstanding?

I've been working on a bunch of static stuff recently, with some overlap with your work. From what I've found, Meson projects that are explicitly calling shared_library are doing that for a reason (libglvnd is another example that doesn't make sense to build statically).

So unless there's something I'm missing, I think a better path forward would be to disable p11-kit support in packages that optionally use it. I have a patch to do this for gnutls I could submit.

@SCOTT-HAMILTON
Copy link
Contributor Author

OK, I didn't really ask myself this question so thanks for pointing it out.

@SCOTT-HAMILTON SCOTT-HAMILTON deleted the p11-kit branch November 23, 2021 20:28
@alyssais alyssais mentioned this pull request Nov 23, 2021
13 tasks
@nixos-discourse
Copy link

This pull request has been mentioned on NixOS Discourse. There might be relevant details there:

https://discourse.nixos.org/t/libudev-as-static-library/16272/2

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.

3 participants