Skip to content

Commit

Permalink
fix: Enable NTS versions.
Browse files Browse the repository at this point in the history
  • Loading branch information
drupol committed Jan 12, 2022
1 parent 49dd0f3 commit 15d8a8a
Show file tree
Hide file tree
Showing 2 changed files with 26 additions and 27 deletions.
48 changes: 24 additions & 24 deletions flake.nix
Original file line number Diff line number Diff line change
Expand Up @@ -21,191 +21,191 @@
phps = phps.packages.${system};
version = "php80";
phpExtensions = default: { all, ... }: builtins.filter (x: !builtins.elem x []) (default all);
ztsSupport = true;
apxs2Support = true;
};

default-nts = import ./resources/dev/common.nix {
inherit pkgs;
phps = phps.packages.${system};
version = "php80";
phpExtensions = default: { all, ... }: builtins.filter (x: !builtins.elem x []) (default all);
ztsSupport = false;
apxs2Support = false;
};

php56 = import ./resources/dev/common.nix {
inherit pkgs;
phps = phps.packages.${system};
version = "php56";
phpExtensions = default: { all, ... }: builtins.filter (x: !builtins.elem x []) (default all);
ztsSupport = true;
apxs2Support = true;
};

php56-nts = import ./resources/dev/common.nix {
inherit pkgs;
phps = phps.packages.${system};
version = "php56";
phpExtensions = default: { all, ... }: builtins.filter (x: !builtins.elem x []) (default all);
ztsSupport = false;
apxs2Support = false;
};

php70 = import ./resources/dev/common.nix {
inherit pkgs;
phps = phps.packages.${system};
version = "php70";
phpExtensions = default: { all, ... }: builtins.filter (x: !builtins.elem x []) (default all);
ztsSupport = true;
apxs2Support = true;
};

php70-nts = import ./resources/dev/common.nix {
inherit pkgs;
phps = phps.packages.${system};
version = "php70";
phpExtensions = default: { all, ... }: builtins.filter (x: !builtins.elem x []) (default all);
ztsSupport = false;
apxs2Support = false;
};

php71 = import ./resources/dev/common.nix {
inherit pkgs;
phps = phps.packages.${system};
version = "php71";
phpExtensions = default: { all, ... }: builtins.filter (x: !builtins.elem x []) (default all);
ztsSupport = true;
apxs2Support = true;
};

php71-nts = import ./resources/dev/common.nix {
inherit pkgs;
phps = phps.packages.${system};
version = "php71";
phpExtensions = default: { all, ... }: builtins.filter (x: !builtins.elem x []) (default all);
ztsSupport = false;
apxs2Support = false;
};

php72 = import ./resources/dev/common.nix {
inherit pkgs;
phps = phps.packages.${system};
version = "php72";
phpExtensions = default: { all, ... }: builtins.filter (x: !builtins.elem x []) (default all);
ztsSupport = true;
apxs2Support = true;
};

php72-nts = import ./resources/dev/common.nix {
inherit pkgs;
phps = phps.packages.${system};
version = "php72";
phpExtensions = default: { all, ... }: builtins.filter (x: !builtins.elem x []) (default all);
ztsSupport = false;
apxs2Support = false;
};

php73 = import ./resources/dev/common.nix {
inherit pkgs;
phps = phps.packages.${system};
version = "php73";
phpExtensions = default: { all, ... }: builtins.filter (x: !builtins.elem x []) (default all);
ztsSupport = true;
apxs2Support = true;
};

php73-nts = import ./resources/dev/common.nix {
inherit pkgs;
phps = phps.packages.${system};
version = "php73";
phpExtensions = default: { all, ... }: builtins.filter (x: !builtins.elem x []) (default all);
ztsSupport = false;
apxs2Support = false;
};

php74 = import ./resources/dev/common.nix {
inherit pkgs;
phps = phps.packages.${system};
version = "php74";
phpExtensions = default: { all, ... }: builtins.filter (x: !builtins.elem x []) (default all);
ztsSupport = true;
apxs2Support = true;
};

php74-nts = import ./resources/dev/common.nix {
inherit pkgs;
phps = phps.packages.${system};
version = "php74";
phpExtensions = default: { all, ... }: builtins.filter (x: !builtins.elem x []) (default all);
ztsSupport = false;
apxs2Support = false;
};

php74-nodebug = import ./resources/dev/common.nix {
inherit pkgs;
phps = phps.packages.${system};
version = "php74";
phpExtensions = default: { all, ... }: builtins.filter (x: !builtins.elem x [all.xdebug all.pcov]) (default all);
ztsSupport = true;
apxs2Support = true;
};

php74-nts-nodebug = import ./resources/dev/common.nix {
inherit pkgs;
phps = phps.packages.${system};
version = "php74";
phpExtensions = default: { all, ... }: builtins.filter (x: !builtins.elem x [all.xdebug all.pcov]) (default all);
ztsSupport = false;
apxs2Support = false;
};

php80 = import ./resources/dev/common.nix {
inherit pkgs;
phps = phps.packages.${system};
version = "php80";
phpExtensions = default: { all, ... }: builtins.filter (x: !builtins.elem x []) (default all);
ztsSupport = true;
apxs2Support = true;
};

php80-nts = import ./resources/dev/common.nix {
inherit pkgs;
phps = phps.packages.${system};
version = "php80";
phpExtensions = default: { all, ... }: builtins.filter (x: !builtins.elem x []) (default all);
ztsSupport = false;
apxs2Support = false;
};

php80-nodebug = import ./resources/dev/common.nix {
inherit pkgs;
phps = phps.packages.${system};
version = "php80";
phpExtensions = default: { all, ... }: builtins.filter (x: !builtins.elem x [all.xdebug all.pcov]) (default all);
ztsSupport = true;
apxs2Support = true;
};

php80-nts-nodebug = import ./resources/dev/common.nix {
inherit pkgs;
phps = phps.packages.${system};
version = "php80";
phpExtensions = default: { all, ... }: builtins.filter (x: !builtins.elem x [all.xdebug all.pcov]) (default all);
ztsSupport = false;
apxs2Support = false;
};

php81 = import ./resources/dev/common.nix {
inherit pkgs;
phps = phps.packages.${system};
version = "php81";
phpExtensions = default: { all, ... }: builtins.filter (x: !builtins.elem x []) (default all);
ztsSupport = true;
apxs2Support = true;
};

php81-nts = import ./resources/dev/common.nix {
inherit pkgs;
phps = phps.packages.${system};
version = "php81";
phpExtensions = default: { all, ... }: builtins.filter (x: !builtins.elem x []) (default all);
ztsSupport = false;
apxs2Support = false;
};

php81-nodebug = import ./resources/dev/common.nix {
inherit pkgs;
phps = phps.packages.${system};
version = "php81";
phpExtensions = default: { all, ... }: builtins.filter (x: !builtins.elem x [all.xdebug all.pcov]) (default all);
ztsSupport = true;
apxs2Support = true;
};

php81-nts-nodebug = import ./resources/dev/common.nix {
inherit pkgs;
phps = phps.packages.${system};
version = "php81";
phpExtensions = default: { all, ... }: builtins.filter (x: !builtins.elem x [all.xdebug all.pcov]) (default all);
ztsSupport = false;
apxs2Support = false;
};
};
}
Expand Down
5 changes: 2 additions & 3 deletions resources/dev/common.nix
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
pkgs,
phps,
version,
ztsSupport,
apxs2Support,
phpExtensions ? { all, ... }: with all; [],
defaultExtensions ? { all, ... }: with all; []
}:
Expand Down Expand Up @@ -49,10 +49,9 @@ let
# This is the reason why we use --impure flag.
phpIniFile = "${builtins.getEnv "PWD"}/.php.ini";

phpOverride = phps.${version}.buildEnv {
phpOverride = (phps.${version}.override { apxs2Support = apxs2Support; }).buildEnv {
extensions = phpExtensions defaultPhpExtensions;
extraConfig = if builtins.pathExists "${phpIniFile}" then builtins.readFile "${phpIniFile}" else "";
inherit ztsSupport;
};

mkShellNoCC = pkgs.mkShell.override { stdenv = pkgs.stdenvNoCC; };
Expand Down

0 comments on commit 15d8a8a

Please sign in to comment.