uwsgi: set UWSGICONFIG_PHPPATH to the php.dev store
uwsgi needs to run php-config to get the include path. set the UWSGICONFIG_PHPPATH to the php-config in the php.dev store. Patch common.h to directly include php_session.h (since it's a separate package on nixos). NIX_CFLAGS_LINK was removed since it doesn't seem to be used at all https://github.com/unbit/uwsgi/blob/master/plugins/php/common.h
This commit is contained in:
@@ -38,8 +38,12 @@ let php-embed = php.override {
|
||||
(lib.nameValuePair "php" {
|
||||
# usage: https://uwsgi-docs.readthedocs.io/en/latest/PHP.html#running-php-apps-with-nginx
|
||||
path = "plugins/php";
|
||||
inputs = [ php-embed ] ++ php-embed.buildInputs;
|
||||
NIX_CFLAGS_LINK = [ "-L${libmysqlclient}/lib/mysql" ];
|
||||
inputs = [
|
||||
php-embed
|
||||
php-embed.extensions.session
|
||||
php-embed.extensions.session.dev
|
||||
php-embed.unwrapped.dev
|
||||
] ++ php-embed.unwrapped.buildInputs;
|
||||
})
|
||||
];
|
||||
|
||||
@@ -61,6 +65,8 @@ stdenv.mkDerivation rec {
|
||||
sha256 = "0256v72b7zr6ds4srpaawk1px3bp0djdwm239w3wrxpw7dzk1gjn";
|
||||
};
|
||||
|
||||
patches = [ ./0001-no-ext-session-php_session.h-on-NixOS.patch ];
|
||||
|
||||
nativeBuildInputs = [ python3 pkgconfig ];
|
||||
|
||||
buildInputs = [ jansson pcre ]
|
||||
@@ -94,8 +100,6 @@ stdenv.mkDerivation rec {
|
||||
${lib.concatMapStringsSep "\n" (x: x.install or "") needed}
|
||||
'';
|
||||
|
||||
NIX_CFLAGS_LINK = toString (lib.optional withSystemd "-lsystemd" ++ lib.concatMap (x: x.NIX_CFLAGS_LINK or []) needed);
|
||||
|
||||
meta = with stdenv.lib; {
|
||||
homepage = "https://uwsgi-docs.readthedocs.org/en/latest/";
|
||||
description = "A fast, self-healing and developer/sysadmin-friendly application container server coded in pure C";
|
||||
|
||||
Reference in New Issue
Block a user