Skip to content
Closed
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
38 changes: 38 additions & 0 deletions pkgs/by-name/ma/mathemagix/package.nix
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,18 @@
libtool,
gmp,
mpfr,
enable-algebramix ? true,

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

  1. As far as I remember, the current status quo is to use camelCase (enableAlgebramix)
  2. [RFC 0169] Feature parameter names rfcs#169 suggests snake case (enable_algebramix), because Bash has some problems with hyphenated names.

enable-automagix ? true,
enable-basix ? true,
enable-mmcompileregg ? true,
enable-mmcompiler ? true,
enable-mmdoc ? true,
enable-numerix ? true,
enable-analyziz ? true,
enable-graphix ? true,
enable-symbolix ? true,
enable-mmxlight ? true,
enable-caas ? true,
}:

stdenv.mkDerivation (finalAttrs: {
Expand All @@ -22,6 +34,32 @@ stdenv.mkDerivation (finalAttrs: {

strictDeps = true;

configureFlags = lib.optionals enable-algebramix [
"--enable-algebramix"

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Suggested change
configureFlags = lib.optionals enable-algebramix [
"--enable-algebramix"
configureFlags = [
(lib.enableFeature enableAlgebramix "algebramix")

and repeat the pattern

] ++ lib.optionals enable-automagix [
"--enable-automagix"
] ++ lib.optionals enable-analyziz [
"--enable-analyziz"
] ++ lib.optionals enable-basix [
"--enable-basix"
] ++ lib.optionals enable-caas [
"--enable-caas"
] ++ lib.optionals enable-graphix [
"--enable-graphix"
] ++ lib.optionals enable-mmcompileregg [
"--enable-mmcompileregg"
] ++ lib.optionals enable-mmcompiler [
"--enable-mmcompiler"
] ++ lib.optionals enable-mmdoc [
"--enable-mmdoc"
] ++ lib.optionals enable-mmxlight [
"--enable-mmxlight"
] ++ lib.optionals enable-numerix [
"--enable-numerix"
] ++ lib.optionals enable-symbolix [
"--enable-symbolix"
];

buildInputs = [
gmp
libtool
Expand Down