about summary refs log tree commit diff
path: root/pkgs/development/interpreters
diff options
context:
space:
mode:
authorRob Vermaas <rob.vermaas@gmail.com>2012-12-01 21:17:50 +0100
committerRob Vermaas <rob.vermaas@gmail.com>2012-12-01 21:19:19 +0100
commit86a5ad6d80adb9e4d79f43bf8f63c17307e26fa7 (patch)
treea529de02f83b1586a0a389d66367721fc227add4 /pkgs/development/interpreters
parente9c35e9381ebb915d442fa3a8a0ee3cf040eabbb (diff)
downloadnixlib-86a5ad6d80adb9e4d79f43bf8f63c17307e26fa7.tar
nixlib-86a5ad6d80adb9e4d79f43bf8f63c17307e26fa7.tar.gz
nixlib-86a5ad6d80adb9e4d79f43bf8f63c17307e26fa7.tar.bz2
nixlib-86a5ad6d80adb9e4d79f43bf8f63c17307e26fa7.tar.lz
nixlib-86a5ad6d80adb9e4d79f43bf8f63c17307e26fa7.tar.xz
nixlib-86a5ad6d80adb9e4d79f43bf8f63c17307e26fa7.tar.zst
nixlib-86a5ad6d80adb9e4d79f43bf8f63c17307e26fa7.zip
Add some PHP support for gettext and gd/freetype needed for zabbix 2.0
Diffstat (limited to 'pkgs/development/interpreters')
-rw-r--r--pkgs/development/interpreters/php/5.3.nix13
-rw-r--r--pkgs/development/interpreters/php/fix.patch22
2 files changed, 31 insertions, 4 deletions
diff --git a/pkgs/development/interpreters/php/5.3.nix b/pkgs/development/interpreters/php/5.3.nix
index e073a51c92da..014ce9d3b971 100644
--- a/pkgs/development/interpreters/php/5.3.nix
+++ b/pkgs/development/interpreters/php/5.3.nix
@@ -1,6 +1,6 @@
 { stdenv, fetchurl, composableDerivation, autoconf, automake, flex, bison
-, apacheHttpd, mysql, libxml2, readline, zlib, curl, gd, postgresql
-, openssl, pkgconfig, sqlite, config, libiconv, libjpeg, libpng }:
+, apacheHttpd, mysql, libxml2, readline, zlib, curl, gd, postgresql, gettext
+, openssl, pkgconfig, sqlite, config, libiconv, libjpeg, libpng, freetype }:
 
 composableDerivation.composableDerivation {} ( fixed : let inherit (fixed.fixed) version; in {
 
@@ -84,8 +84,8 @@ composableDerivation.composableDerivation {} ( fixed : let inherit (fixed.fixed)
       };
 
       gd = {
-        configureFlags = ["--with-gd=${gd}"];
-        buildInputs = [gd libpng libjpeg ];
+        configureFlags = ["--with-gd=${gd} --with-freetype-dir=${freetype}"];
+        buildInputs = [gd libpng libjpeg freetype];
       };
 
       soap = {
@@ -105,6 +105,11 @@ composableDerivation.composableDerivation {} ( fixed : let inherit (fixed.fixed)
         configureFlags = ["--enable-mbstring"];
       };
 
+      gettext = {
+        configureFlags = ["--with-gettext=${gettext}"];
+        buildInputs = [gettext];
+      };
+
       /*
          php is build within this derivation in order to add the xdebug lines to the php.ini.
          So both Apache and command line php both use xdebug without having to configure anything.
diff --git a/pkgs/development/interpreters/php/fix.patch b/pkgs/development/interpreters/php/fix.patch
index 1cec8fea0fe2..02f2c9c6c93f 100644
--- a/pkgs/development/interpreters/php/fix.patch
+++ b/pkgs/development/interpreters/php/fix.patch
@@ -54,3 +54,25 @@
      if test -z `$APXS -q SYSCONFDIR`; then
        APACHE_HOOKS_INSTALL="\$(mkinstalldirs) '$APXS_LIBEXECDIR' && \
                         $APXS -S LIBEXECDIR='$APXS_LIBEXECDIR' \
+diff -rc php-5.3.18/configure php-5.3.18-new/configure
+*** php-5.3.18/configure	2012-10-17 18:29:10.000000000 +0200
+--- php-5.3.18-new/configure	2012-11-13 05:36:24.730136551 +0100
+***************
+*** 45113,45121 ****
+  
+  
+  if test "$PHP_GETTEXT" != "no"; then
+!   for i in $PHP_GETTEXT /usr/local /usr; do
+!     test -r $i/include/libintl.h && GETTEXT_DIR=$i && break
+!   done
+  
+    if test -z "$GETTEXT_DIR"; then
+      { echo "configure: error: Cannot locate header file libintl.h" 1>&2; exit 1; }
+--- 45113,45119 ----
+  
+  
+  if test "$PHP_GETTEXT" != "no"; then
+!   GETTEXT_DIR=$PHP_GETTEXT
+  
+    if test -z "$GETTEXT_DIR"; then
+      { echo "configure: error: Cannot locate header file libintl.h" 1>&2; exit 1; }