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

cypari2: init at 1.1.4 #38782

Merged
merged 1 commit into from Apr 22, 2018
Merged

cypari2: init at 1.1.4 #38782

merged 1 commit into from Apr 22, 2018

Conversation

timokau
Copy link
Member

@timokau timokau commented Apr 11, 2018

Motivation for this change

This depends on #38781, do not merge before that

Package cypari2. The installPhase should probably be reviewed as it is non-standarad and I'm not entirely sure if thats the best way to do it. With the standard installPhase the required file auto_paridecl.pxd is not generated.

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.

@FRidh
Copy link
Member

FRidh commented Apr 14, 2018

The installPhase should probably be reviewed as it is non-standarad and I'm not entirely sure if thats the best way to do it.

It looks good.

With the standard installPhase the required file auto_paridecl.pxd is not generated.

Does upstream know?

I've removed the installPhase and the package seems to build fine.

@timokau
Copy link
Member Author

timokau commented Apr 15, 2018

Does upstream know?

From the README:

Any other way to install cypari2 is not supported. In particular, python setup.py install will produce an error.

I've removed the installPhase and the package seems to build fine.

Yes it builds, but it does not generate that one file, which is supposed to be generated and dependet upon by sagelib.

@FRidh
Copy link
Member

FRidh commented Apr 15, 2018

Can you add the explanation as a comment to the expression.

@timokau
Copy link
Member Author

timokau commented Apr 15, 2018

Done

];

checkPhase = ''
make check
Copy link
Member

Choose a reason for hiding this comment

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

This should be the default. See https://github.com/NixOS/nixpkgs/blob/master/pkgs/stdenv/generic/setup.sh for future reference.

Copy link
Member

Choose a reason for hiding this comment

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

Actually that's not the default for Python so nevermind.

# This differs slightly from the default python installPhase in that it pip-installs
# "." instead of "*.whl".
# That is because while the default install phase succeeds to build the package,
# it fails to generate the file "auto_paridecl.pxd".
Copy link
Member

Choose a reason for hiding this comment

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

This is interesting... Could you try something like this instead of the installPhase (not sure if will work):

installFlags = "*.pxd";

That makes things a little simpler hopefully.

Copy link
Member Author

Choose a reason for hiding this comment

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

That doesn't work. The default installPhase runs:

    ${bootstrapped-pip}/bin/pip install *.whl --no-index --prefix=$out --no-cache ${toString installFlags} --build tmpbuild

@matthewbauer matthewbauer merged commit a037da9 into NixOS:master Apr 22, 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

4 participants