diff options
author | jgmdev | 2015-06-14 02:38:18 -0400 |
---|---|---|
committer | jgmdev | 2015-06-14 02:38:18 -0400 |
commit | fee66a0e555953bf787666b84a01b20847d17b5d (patch) | |
tree | a71f18efcd12ab46e5f12ba842c0953e2ae31137 | |
download | aur-fee66a0e555953bf787666b84a01b20847d17b5d.tar.gz |
Initial Import.
-rw-r--r-- | .SRCINFO | 33 | ||||
-rw-r--r-- | PKGBUILD | 106 | ||||
-rw-r--r-- | php-wxwidgets-git.install | 7 |
3 files changed, 146 insertions, 0 deletions
diff --git a/.SRCINFO b/.SRCINFO new file mode 100644 index 000000000000..de5fad6a3e24 --- /dev/null +++ b/.SRCINFO @@ -0,0 +1,33 @@ +pkgbase = php-wxwidgets-git + pkgdesc = PHP bindings to the cross-platform wxWidgets GUI Toolkit library. + pkgver = v3.0.2.0.r5.gb1ea750 + pkgrel = 1 + url = http://wxphp.org + install = php-wxwidgets-git.install + arch = i686 + arch = x86_64 + license = PHP + makedepends = mesa + makedepends = glu + makedepends = libxt + makedepends = gstreamer + makedepends = sdl + makedepends = sdl_sound + makedepends = php + makedepends = webkitgtk + depends = gtk3 + depends = libgl + depends = libxxf86vm + depends = libsm + depends = sdl + depends = sdl_sound + depends = gstreamer + depends = php + depends = webkitgtk + source = http://downloads.sourceforge.net/wxwindows/wxWidgets-3.0.2.tar.bz2 + source = git://github.com/wxphp/wxphp.git + sha1sums = 6461eab4428c0a8b9e41781b8787510484dea800 + sha1sums = SKIP + +pkgname = php-wxwidgets-git + diff --git a/PKGBUILD b/PKGBUILD new file mode 100644 index 000000000000..fd83f325f698 --- /dev/null +++ b/PKGBUILD @@ -0,0 +1,106 @@ +# Maintainer: Jefferson González <jgmdev@gmail.com> + +pkgname=php-wxwidgets-git +_gitname=wxphp +pkgver=v3.0.2.0.r5.gb1ea750 +_pkgver=3.0.2 +pkgrel=1 +pkgdesc="PHP bindings to the cross-platform wxWidgets GUI Toolkit library." +arch=('i686' 'x86_64') +url="http://wxphp.org" +install=php-wxwidgets-git.install +license=('PHP') +depends=('gtk3' 'libgl' 'libxxf86vm' 'libsm' 'sdl' 'sdl_sound' 'gstreamer' 'php' 'webkitgtk') +makedepends=('mesa' 'glu' 'libxt' 'gstreamer' 'sdl' 'sdl_sound' 'php' 'webkitgtk') +source=( + "http://downloads.sourceforge.net/wxwindows/wxWidgets-${_pkgver}.tar.bz2" + "git://github.com/wxphp/${_gitname}.git" +) +sha1sums=( + '6461eab4428c0a8b9e41781b8787510484dea800' + 'SKIP' +) + +pkgver() { + cd "${_gitname}" + git describe --tags --long | sed 's/\([^-]*-g\)/r\1/;s/-/./g' +} + +prepare() { + cd "${srcdir}/${_gitname}" + phpize +} + +build() { + if [ ! -e "${srcdir}/wxWidgets-${_pkgver}-static" ]; then + cd "${srcdir}/wxWidgets-${_pkgver}" + + CFLAGS="-fPIC -O2 -Wall -W" CXXFLAGS="-fPIC -O2" \ + ./configure --prefix="${srcdir}/wxWidgets-${_pkgver}-static" \ + --with-{gtk=3,libjpeg=sys,libpng=sys,libtiff=sys,libxpm=sys,opengl,regex=builtin,sdl} \ + --enable-{graphics_ctx,unicode,monolithic} \ + --disable-shared + + make + make -C locale allmo + make install + fi + + cd "${srcdir}/${_gitname}" + + php tools/reference_generator.php + + ./configure \ + --with-wxwidgets="${srcdir}/wxWidgets-${_pkgver}-static" \ + --enable-wxwidgets-monolithic \ + --enable-wxwidgets-static + + make +} + +package() { + mkdir -p "${pkgdir}/usr/bin" + mkdir -p "${pkgdir}/usr/lib/wxphp" + mkdir -p "${pkgdir}/usr/share/applications/" + mkdir -p "${pkgdir}/usr/share/doc/${pkgname}" + mkdir -p "${pkgdir}/usr/share/icons/hicolor/48x48/apps/" + mkdir -p "${pkgdir}/usr/share/icons/hicolor/scalable/apps/" + + # Add documentation to package + cd "${srcdir}/${_gitname}" + cp -rf doc/* "${pkgdir}/usr/share/doc/${pkgname}/" + + # Add wxphp shell script to package + echo "#!/bin/sh" > "${pkgdir}/usr/bin/wxphp" + echo "exec /usr/bin/php -d extension=wxwidgets.so \"\$@\"" >> "${pkgdir}/usr/bin/wxphp" + chmod 0755 "${pkgdir}/usr/bin/wxphp" + + # Add desktop file + echo "[Desktop Entry]" > "${pkgdir}/usr/share/applications/wxphp.desktop" + echo "Name=wxPHP Shell" >> "${pkgdir}/usr/share/applications/wxphp.desktop" + echo "GenericName=wxPHP Shell" >> "${pkgdir}/usr/share/applications/wxphp.desktop" + echo "Comment=Shell for launching wxphp scripts." >> "${pkgdir}/usr/share/applications/wxphp.desktop" + echo "Exec=/usr/lib/wxphp/launcher.sh" >> "${pkgdir}/usr/share/applications/wxphp.desktop" + echo "Icon=wxphp" >> "${pkgdir}/usr/share/applications/wxphp.desktop" + echo "Categories=Development;" >> "${pkgdir}/usr/share/applications/wxphp.desktop" + echo "Version=1.0" >> "${pkgdir}/usr/share/applications/wxphp.desktop" + echo "Type=Application" >> "${pkgdir}/usr/share/applications/wxphp.desktop" + echo "Terminal=false" >> "${pkgdir}/usr/share/applications/wxphp.desktop" + + # Copy wxphp shell launcher scripts + cp -rf tools/linux_shell/* "${pkgdir}/usr/lib/wxphp/" + chmod -R 0755 $pkgdir/usr/lib/wxphp/* + chmod 0644 "${pkgdir}/usr/lib/wxphp/README" + + # Copy icons + cp artwork/icon.png "${pkgdir}/usr/share/icons/hicolor/48x48/apps/wxphp.png" + cp artwork/icon.svg "${pkgdir}/usr/share/icons/hicolor/scalable/apps/wxphp.svg" + + # Copy wxwidgets php module + EXTENSIONS_DIR=`php-config --extension-dir` + CHROOT_EXTENSION_DIR="${pkgdir}${EXTENSIONS_DIR}" + + mkdir -p "${CHROOT_EXTENSION_DIR}" + strip -s modules/wxwidgets.so + cp -rf modules/wxwidgets.so "${CHROOT_EXTENSION_DIR}" +} diff --git a/php-wxwidgets-git.install b/php-wxwidgets-git.install new file mode 100644 index 000000000000..4063311ea1c2 --- /dev/null +++ b/php-wxwidgets-git.install @@ -0,0 +1,7 @@ +post_install() { + xdg-icon-resource forceupdate +} + +post_remove() { + xdg-icon-resource forceupdate +} |