summarylogtreecommitdiffstats
path: root/PKGBUILD
diff options
context:
space:
mode:
authorjgmdev2016-10-06 03:44:00 -0400
committerjgmdev2016-10-06 03:44:00 -0400
commit5a12088e9c57361142a1dafa8020558355dead7c (patch)
tree40ea5fee2b074626b191265bdf00f0ca585dd99e /PKGBUILD
parentfee66a0e555953bf787666b84a01b20847d17b5d (diff)
downloadaur-5a12088e9c57361142a1dafa8020558355dead7c.tar.gz
Fixed to build again by using the php56 package and patches for wxwidgets found on wxgtk package.
Diffstat (limited to 'PKGBUILD')
-rw-r--r--PKGBUILD165
1 files changed, 88 insertions, 77 deletions
diff --git a/PKGBUILD b/PKGBUILD
index fd83f325f698..78febbe6aa79 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -2,7 +2,7 @@
pkgname=php-wxwidgets-git
_gitname=wxphp
-pkgver=v3.0.2.0.r5.gb1ea750
+pkgver=v3.0.2.0.r208.g0560d4f
_pkgver=3.0.2
pkgrel=1
pkgdesc="PHP bindings to the cross-platform wxWidgets GUI Toolkit library."
@@ -10,15 +10,19 @@ 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')
+depends=('gtk3' 'libgl' 'libxxf86vm' 'libsm' 'sdl' 'sdl_sound' 'gstreamer' 'php56' 'webkitgtk')
+makedepends=('mesa' 'glu' 'libxt' 'gstreamer' 'sdl' 'sdl_sound' 'php56' 'webkitgtk')
source=(
- "http://downloads.sourceforge.net/wxwindows/wxWidgets-${_pkgver}.tar.bz2"
- "git://github.com/wxphp/${_gitname}.git"
+ "http://downloads.sourceforge.net/wxwindows/wxWidgets-${_pkgver}.tar.bz2"
+ "git://github.com/wxphp/${_gitname}.git"
+ "make-abicheck-non-fatal.patch"
+ "wxgtk-gcc6.patch"
)
sha1sums=(
- '6461eab4428c0a8b9e41781b8787510484dea800'
- 'SKIP'
+ '6461eab4428c0a8b9e41781b8787510484dea800'
+ 'SKIP'
+ 'dfe38650c655395b90bf082b5734c4093508bfa3'
+ '498202334c69d49c1ebbc9d36ad382cfa237f3f8'
)
pkgver() {
@@ -27,80 +31,87 @@ pkgver() {
}
prepare() {
- cd "${srcdir}/${_gitname}"
- phpize
+ cd "${srcdir}/${_gitname}"
+ phpize56
}
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
+ if [ ! -e "${srcdir}/wxWidgets-${_pkgver}-static" ]; then
+ cd "${srcdir}/wxWidgets-${_pkgver}"
+
+ # C++ ABI check is too strict and breaks with GCC 5.1
+ # https://bugzilla.redhat.com/show_bug.cgi?id=1200611
+ patch -Np1 -i "${srcdir}/../make-abicheck-non-fatal.patch"
+
+ # Fix build with GCC 6
+ patch -p1 -i "${srcdir}/../wxgtk-gcc6.patch"
+
+ 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}"
+
+ php56 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}"
+ 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/php56 -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-config56 --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}"
}