1 # Maintainer: FzerorubigD <fzerorubigd {AT} Gmail {Dot} Com
2 # Contributor: Evangelos Foutras <foutrelis@gmail.com>
3 # Contributor:Xemertix <arch88(at)katamail(dot)com>
5 # Install instructions:
6 # Build without MAKEFLAGS="-j{n}"(/etc/makepkg.conf) if you have multicore processor. See http://marc.info/?l=php-gtk-dev&m=125993195018983
7 # Run makepkg --holdver 295934 (last known working revision according to http://old.nabble.com/php-gtk-configure-bug-td28460862.html)
12 pkgdesc="PHP bindings for the Gtk+ 2 library"
13 arch=('i686' 'x86_64')
14 url="http://gtk.php.net/"
16 depends=('php' 'gtk2>=2.12.0' 'libglade>=2.6.2' 'php-pecl-cairo-svn')
17 makedepends=('pkgconfig' 'gtk2+extra' 'gtkhtml' 'libsexy' 'xulrunner'
18 'gtksourceview' 'gtkspell')
19 optdepends=('gtk2+extra: extra extension'
20 'gtkhtml: html extension'
21 'libsexy: libsexy extension'
22 'xulrunner: mozembed extension'
23 'gtksourceview: sourceview extension'
24 'gtkspell: spell extension')
27 backup=(etc/php/php-gtk.ini)
28 install=php-gtk.install
29 source=(php.ini-template
30 disable-open_basedir.patch)
31 md5sums=('219a7f7f336a4ed3fe27bb352b8199c3'
32 '1654fc571317e32791ebf2db7791dbe5')
35 _svntrunk="http://svn.php.net/repository/gtk/php-gtk/trunk"
41 msg "Connecting to SVN server...."
43 if [ -d ${_svnmod}/.svn ]; then
44 (cd ${_svnmod} && svn up -r $pkgver)
46 svn co ${_svntrunk} --config-dir ./ -r $pkgver ${_svnmod}
49 msg "SVN checkout done or the server timed out"
50 msg "Starting make..."
52 svn export ${_svnmod} ${_svnmod}-build
58 #Temporary way to fix build problem.
59 sed -i -e 's/gen_gtk-1\.c//g' configure
60 ./configure --prefix=/usr \
63 --with-libsexy=shared \
64 --with-mozembed=shared \
65 --with-sourceview=shared \
67 # We need to allow php to open files outside of open_basedir (defined
68 # in /etc/php/php.ini) during the build
69 patch -Np1 -i "$srcdir/disable-open_basedir.patch" || return 1
72 make INSTALL_ROOT="$pkgdir" install
73 install -D -m644 "$srcdir/php.ini-template" "$pkgdir/etc/php/php-gtk.ini"
74 EXTENSION_DIR=$(php-config --extension-dir)
75 sed -i "/^extension_dir/cextension_dir = \"$EXTENSION_DIR\"" \
76 "$pkgdir/etc/php/php-gtk.ini"