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

pythonPackages.sip: do not build tools for non-default sip module #52968

wants to merge 1 commit into from


Copy link

@orivej orivej commented Dec 27, 2018

Motivation for this change

This ensures that the default sip and alternative sips do not have any files in common: #52956 (comment)

Things done
  • Tested using sandboxing (nix.useSandbox on NixOS, or option 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/)
  • Determined the impact on package closure size (by running nix path-info -S before and after)
  • Assured whether relevant documentation is up to date
  • Fits
configureFlags = (
if (!withModule) then [ "--no-module" ] else [
"--sip-module" sipModule
"-d" "${placeholder "out"}/lib/${python.libPrefix}/site-packages"
Copy link

@FRidh FRidh Dec 27, 2018


Copy link
Contributor Author

@orivej orivej Dec 27, 2018


This ensures that the default sip and alternative sips do not have common files.
@@ -32,9 +32,9 @@ in buildPythonPackage {

outputs = [ "out" "dev" ];

nativeBuildInputs = [ pkgconfig qmake lndir ];
nativeBuildInputs = [ pkgconfig qmake lndir sip ];
Copy link

@FRidh FRidh Dec 29, 2018

Should this be pyqt5-sip?

Copy link
Contributor Author

@orivej orivej Dec 31, 2018

No, it seems that the upstream envisions that there is one tool sip which generates multiple modules according to sip -n module_name parameter. This is why sip-the-tool is a native build input, and pyqt5-sip-module is a propagated build input.

After this PR sip ships both the tool and the module sip (as before), but pyqt5-sip ships only the module PyQt5.sip.

Copy link

@FRidh FRidh Dec 31, 2018

Ok. Could you include the explanation as a comment?

Copy link

@mmahut mmahut commented Aug 13, 2019

Are there any updates on this pull request, please?

Copy link

@FRidh FRidh commented Aug 13, 2019

I should have seen this when working on the pyqt5 upgrade done in c3839de. I suppose that could be changed to use this approach if this is what upstream wants. IMO they should document this better though.

Copy link

@stale stale bot commented Jun 1, 2020

Thank you for your contributions.
This has been automatically marked as stale because it has had no activity for 180 days.
If this is still important to you, we ask that you leave a comment below. Your comment can be as simple as "still important to me". This lets people see that at least one person still cares about this. Someone will have to do this at most twice a year if there is no other activity.
Here are suggestions that might help resolve this more quickly:

  1. Search for maintainers and people that previously touched the
    related code and @ mention them in a comment.
  2. Ask on the NixOS Discourse. 3. Ask on the #nixos channel on

Copy link

@doronbehar doronbehar commented Oct 7, 2020

Would this change be relevant if sip will be upgraded? #99936

Copy link

@FRidh FRidh commented Oct 8, 2020

rebased in #100050.

@FRidh FRidh closed this Oct 8, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
None yet
Linked issues

Successfully merging this pull request may close these issues.

None yet

6 participants