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

petsc: refactor inputs, configureFlags; add tests, petscPackages scope #392392

Open
wants to merge 14 commits into
base: master
Choose a base branch
from

Conversation

qbisi
Copy link
Contributor

@qbisi qbisi commented Mar 23, 2025

big changes in petsc.

  1. Some cleanup to unnecessary flags.
  2. Add two petsc variant 'serial' and 'fullDeps' in passthr.tests to valid combination of different build flags
  3. Add a scope petscPackages

The third change 'Add a scope petscPackages' in commit 1458623
is very important to build petsc with appropriate buildInputs.

Petsc would like to passthrough its global override options to its buildInputs,
e.g.
petsc with mpiSupport/fortran require its dep to be built with mpiSupport/fortran too,
petsc with precision "single" require fftw use the same precision "single"
petsc built with mpich would like all its dep to be built with mpich

and in the future, i would like to introduce enableOpenMP,isILP64,cudaSupport as global override options to petsc.

This petscPackages is functional similar to nixpkgs overlay, but it allow us to override and test petsc varient simply, without ovelay the whole nixpkgs.

Things done

  • Built on platform(s)
    • x86_64-linux
    • aarch64-linux
    • x86_64-darwin
    • aarch64-darwin
  • For non-Linux: Is sandboxing enabled in nix.conf? (See Nix manual)
    • sandbox = relaxed
    • sandbox = true
  • 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/)
  • 25.05 Release Notes (or backporting 24.11 and 25.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
  • Fits CONTRIBUTING.md.

Add a 👍 reaction to pull requests you find important.

qbisi added 5 commits March 23, 2025 22:29
This option is only used when PETsc download and build hdf5 with fortran
support for other project depend on petsc. PETsc does not need it.
@qbisi
Copy link
Contributor Author

qbisi commented Mar 23, 2025

nixpkgs-review result

Generated using nixpkgs-review.

Command: nixpkgs-review pr 392392


aarch64-darwin

✅ 12 packages built:
  • petsc
  • pflotran
  • precice
  • python312Packages.petsc4py
  • python312Packages.pyprecice
  • python312Packages.pyprecice.dist
  • python312Packages.slepc4py
  • python313Packages.petsc4py
  • python313Packages.pyprecice
  • python313Packages.pyprecice.dist
  • python313Packages.slepc4py
  • slepc

@qbisi
Copy link
Contributor Author

qbisi commented Mar 23, 2025

nixpkgs-review result

Generated using nixpkgs-review.

Command: nixpkgs-review pr 392392


x86_64-linux

✅ 13 packages built:
  • getdp
  • petsc
  • pflotran
  • precice
  • python312Packages.petsc4py
  • python312Packages.pyprecice
  • python312Packages.pyprecice.dist
  • python312Packages.slepc4py
  • python313Packages.petsc4py
  • python313Packages.pyprecice
  • python313Packages.pyprecice.dist
  • python313Packages.slepc4py
  • slepc

@qbisi
Copy link
Contributor Author

qbisi commented Mar 23, 2025

nixpkgs-review result

Generated using nixpkgs-review.

Command: nixpkgs-review pr 392392


aarch64-linux

✅ 13 packages built:
  • getdp
  • petsc
  • pflotran
  • precice
  • python312Packages.petsc4py
  • python312Packages.pyprecice
  • python312Packages.pyprecice.dist
  • python312Packages.slepc4py
  • python313Packages.petsc4py
  • python313Packages.pyprecice
  • python313Packages.pyprecice.dist
  • python313Packages.slepc4py
  • slepc

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.

1 participant