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

pygobject: 3.24.1 → 3.26.1 #32034

Merged
merged 2 commits into from Dec 1, 2017
Merged

pygobject: 3.24.1 → 3.26.1 #32034

merged 2 commits into from Dec 1, 2017

Conversation

jtojnar
Copy link
Contributor

@jtojnar jtojnar commented Nov 25, 2017

Motivation for this change

Just an update, trying if it does not fix syncthing-gtk freeze. It does not.

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.

@jtojnar
Copy link
Contributor Author

jtojnar commented Nov 27, 2017

I do not like the postPatch section in the pycairo expression, is not there a better way to set the install_base? How do other python packages solve this?

postPatch = ''
# prefix is ${python} by default for some reason
substituteInPlace setup.py --replace '"prefix": self.install_base' "'prefix': '$out'"
'';
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

maybe the following works

setupPyBuildFlags = [ "--install-base=$out" ];

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Does not seem to work – no such option: --install-base. I also tried

installFlags = [ "--install-base=$out" ];

with the same result, and

installFlags = [ "--install-option=\"--install-base=$out\"" ];

which at least builds but the ${python} path is still used.

Copy link
Contributor Author

@jtojnar jtojnar Nov 27, 2017

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The option seems to be distutils-specific, while this package seems to be using setuptools. Edit: It is actually using distutils, no idea why it does not work.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Apparently, the problem is caused by pycairo reading an install flag during the build of the wheel. Just like with passing build flags to bdist_wheel, setuptools do not allow passing the install flags either – other than by using hacks like python setup.py install --root=_temp --prefix=/foo bdist_wheel (source). Let’s keep patching the source for now.

@jtojnar
Copy link
Contributor Author

jtojnar commented Nov 27, 2017

Verified by running d-feet.

@vcunat vcunat merged commit 8b8f17a into NixOS:staging Dec 1, 2017
vcunat added a commit that referenced this pull request Dec 1, 2017
@jtojnar jtojnar deleted the pygobject branch December 14, 2017 10:47
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

4 participants