summaryrefslogtreecommitdiff
path: root/community/xdebug
diff options
context:
space:
mode:
authorParabola <dev@list.parabolagnulinux.org>2011-04-05 14:26:38 +0000
committerParabola <dev@list.parabolagnulinux.org>2011-04-05 14:26:38 +0000
commit415856bdd4f48ab4f2732996f0bae58595092bbe (patch)
treeede2018b591f6dfb477fe9341ba17b9bc000fab9 /community/xdebug
Tue Apr 5 14:26:38 UTC 2011
Diffstat (limited to 'community/xdebug')
-rw-r--r--community/xdebug/PKGBUILD45
-rw-r--r--community/xdebug/xdebug-5.2.ini5
-rw-r--r--community/xdebug/xdebug.ini5
-rw-r--r--community/xdebug/xdebug.install50
4 files changed, 105 insertions, 0 deletions
diff --git a/community/xdebug/PKGBUILD b/community/xdebug/PKGBUILD
new file mode 100644
index 000000000..942ee4a41
--- /dev/null
+++ b/community/xdebug/PKGBUILD
@@ -0,0 +1,45 @@
+# $Id: PKGBUILD 43879 2011-03-30 18:59:05Z spupykin $
+# Maintainer: Sergej Pupykin <pupykin.s+arch@gmail.com>
+# Maintainer: Jonathan Wiersma <arch aur at jonw dot org>
+# Contributor: Jonathan Wiersma <arch aur at jonw dot org>
+# Contributor: sracker <smb.sac@gmail.com>
+
+pkgname=xdebug
+pkgver=2.1.1
+pkgrel=1
+pkgdesc="PHP debugging extension"
+arch=('i686' 'x86_64')
+url="http://www.xdebug.org"
+license=('GPL')
+depends=('php')
+install="${pkgname}.install"
+backup=('etc/php/conf.d/xdebug.ini')
+source=(http://www.xdebug.org/files/$pkgname-$pkgver.tgz
+ xdebug-5.2.ini
+ xdebug.ini)
+md5sums=('fcdf078e715f44b77f13bac721ad63ce'
+ '6b7fdbbe0bf381bda40e77e29981f439'
+ '68de800943369d4c76bdf7eb35c8463b')
+
+build() {
+ local PHPVER=$(php -r 'echo phpversion();')
+
+ cd $srcdir/$pkgname-$pkgver || return 1
+ phpize || return 1
+ ./configure --prefix=/usr --enable-xdebug || return 1
+ make || return 1
+
+ cd debugclient || return 1
+ ./configure --prefix=/usr || return 1
+ make || return 1
+ make DESTDIR=$pkgdir install || return 1
+
+ cd $srcdir/$pkgname-$pkgver || return 1
+ if [ "$PHPVER" \< "5.3.0" ] ; then
+ install -D -m 744 modules/xdebug.so $pkgdir/usr/lib/php/xdebug.so || return 1
+ install -D -m 644 $srcdir/xdebug-5.2.ini $pkgdir/etc/php/conf.d/xdebug.ini || return 1
+ else
+ install -D -m 744 modules/xdebug.so $pkgdir/usr/lib/php/modules/xdebug.so || return 1
+ install -D -m 644 $srcdir/xdebug.ini $pkgdir/etc/php/conf.d/xdebug.ini || return 1
+ fi
+}
diff --git a/community/xdebug/xdebug-5.2.ini b/community/xdebug/xdebug-5.2.ini
new file mode 100644
index 000000000..9beb7fc30
--- /dev/null
+++ b/community/xdebug/xdebug-5.2.ini
@@ -0,0 +1,5 @@
+zend_extension=/usr/lib/php/xdebug.so
+;xdebug.remote_enable=on
+;xdebug.remote_host=127.0.0.1
+;xdebug.remote_port=9000
+;xdebug.remote_handler=dbgp
diff --git a/community/xdebug/xdebug.ini b/community/xdebug/xdebug.ini
new file mode 100644
index 000000000..c6c9222ea
--- /dev/null
+++ b/community/xdebug/xdebug.ini
@@ -0,0 +1,5 @@
+zend_extension=/usr/lib/php/modules/xdebug.so
+;xdebug.remote_enable=on
+;xdebug.remote_host=127.0.0.1
+;xdebug.remote_port=9000
+;xdebug.remote_handler=dbgp
diff --git a/community/xdebug/xdebug.install b/community/xdebug/xdebug.install
new file mode 100644
index 000000000..fc2fcbc84
--- /dev/null
+++ b/community/xdebug/xdebug.install
@@ -0,0 +1,50 @@
+pre_upgrade() {
+ local _configfile=/etc/php/conf.d/xdebug.ini
+
+ if [ $2 \< "2.0.4-2" -a -f $_configfile ] ; then
+ mv -f $_configfile $_configfile.pacold
+ fi
+ /bin/true
+}
+
+post_install() {
+ local _configfile=/etc/php/conf.d/xdebug.ini
+ echo " ==> You may wish to uncomment/change the settings found in "
+ echo " $_configfile"
+ echo ""
+ /bin/true
+}
+
+post_upgrade() {
+ local _configfile=/etc/php/conf.d/xdebug.ini
+ local PHPVER=$(php -r 'echo phpversion();')
+ post_install $1
+
+ if [ $2 \< "2.0.4-2" ] ; then
+ if [ -f $_configfile.pacold ] ; then
+ mv $_configfile $_configfile.pacnew
+ mv $_configfile.pacold $_configfile
+ echo " ==> There is a new xdebug.ini at $_configfile.pacnew."
+ echo " You may wish to copy it or modify your existing file: "
+ echo " $_configfile."
+ echo ""
+ else
+ echo " ==> A configuration file for xdebug has been placed at:"
+ echo " $_configfile."
+ echo " Please remove the following lines from /etc/php/php.ini and move them"
+ echo " to $_configfile:"
+ echo " zend_extension=/usr/lib/php/xdebug.so"
+ echo " xdebug.remote_enable=on"
+ echo " xdebug.remote_host=<ip address>"
+ echo " xdebug.remote_port=<port>"
+ echo " xdebug.remote_handler=dbgp"
+ echo ""
+ fi
+ fi
+
+ if [ "$PHPVER" \< "5.3" ] ; then
+ echo " ==> You are currenty running a version of php < 5.3."
+ echo " When/if you upgrade php to a version >= 5.3, you will need to reinstall $pkgname."
+ echo ""
+ fi
+}