summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorShadowKyogre2016-05-07 12:22:46 -0700
committerShadowKyogre2016-05-07 14:50:31 -0700
commit7ad3db36cb01fe85a833ed2fc72269dd97c77e80 (patch)
tree3295dba4b70625b3e05a7c107c2b14e4df719675
parentd7dbf946b3a0e22d116dc7c80cb89a2beff39f9d (diff)
downloadaur-7ad3db36cb01fe85a833ed2fc72269dd97c77e80.tar.gz
PKGBUILD shouldn't fail on not building gtk deco
However, compiz-gtk-git shouldn't be created if gtk2's missing. Also, add .gitignore for easier maintenance
-rw-r--r--.SRCINFO5
-rw-r--r--.gitignore3
-rw-r--r--PKGBUILD43
3 files changed, 41 insertions, 10 deletions
diff --git a/.SRCINFO b/.SRCINFO
index f13dffa4deb2..6cae7902b7b0 100644
--- a/.SRCINFO
+++ b/.SRCINFO
@@ -1,9 +1,9 @@
# Generated by mksrcinfo v8
-# Tue Apr 12 01:50:54 UTC 2016
+# Sat May 7 21:50:05 UTC 2016
pkgbase = compiz-core
pkgdesc = This is the latest stable release of Compiz without DE deps
pkgver = 0.8.12.3
- pkgrel = 1
+ pkgrel = 2
url = https://github.com/compiz-reloaded/compiz/
arch = i686
arch = x86_64
@@ -44,5 +44,6 @@ pkgname = compiz-gtk
depends = libsm
depends = libxcomposite
depends = libxinerama
+ depends = gtk2
conflicts = compiz-gtk-git
diff --git a/.gitignore b/.gitignore
new file mode 100644
index 000000000000..a5401c5d685d
--- /dev/null
+++ b/.gitignore
@@ -0,0 +1,3 @@
+pkg/
+src/
+*.pkg.tar.xz
diff --git a/PKGBUILD b/PKGBUILD
index b3a64bd55ad5..e92b3dc246ac 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -9,7 +9,7 @@ _micro=.3
pkgbase=compiz-core
pkgname=(compiz-core compiz-gtk)
pkgver="${_pkgver}${_micro}"
-pkgrel=1
+pkgrel=2
pkgdesc="This is the latest stable release of Compiz without DE deps"
url="https://github.com/compiz-reloaded/${_upstream}/"
license=('GPL' 'LGPL' 'MIT')
@@ -45,7 +45,12 @@ build()
NOCONFIGURE=1 ./autogen.sh
./configure "${_configure_opts[@]}"
-
+
+ if ! grep -q pkg_cv_GTK config.log;then
+ # make sure only compiz-core is created if gtk is missing
+ msg "Making sure only $pkgbase is made, gtk+2 is missing"
+ pkgname=("$pkgbase")
+ fi
make
}
@@ -57,9 +62,19 @@ package_compiz-core() {
conflicts=('compiz' 'compiz-core-git' 'compiz-git')
make DESTDIR="${pkgdir}" install
- rm "${pkgdir}/usr/bin/gtk-window-decorator"
- rm "${pkgdir}/usr/share/glib-2.0/schemas/org.compiz-0.gwd.gschema.xml"
- rm "${pkgdir}/usr/share/icons/hicolor/"*"/apps/gtk-decorator."*
+
+ local REMOVE_THESE=(
+ "${pkgdir}/usr/bin/gtk-window-decorator"
+ "${pkgdir}/usr/share/glib-2.0/schemas/org.compiz-0.gwd.gschema.xml"
+ "${pkgdir}/usr/share/icons/hicolor/"*"/apps/gtk-decorator."*
+ )
+ # Believe it or not, you CAN fill an array using wildcards in bash
+
+ for fname in "${REMOVE_THESE[@]}";do
+ if [ -e "$fname" ];then
+ rm "$fname"
+ fi
+ done
}
package_compiz-gtk()
@@ -67,18 +82,30 @@ package_compiz-gtk()
if (("${_use_marco}"));then
#separating libmarco-private would be nice, but this is a workaround for now
depends+=('marco')
+ else
+ depends+=('gtk2')
fi
pkgdesc+=" (GTK+ window decorator)"
conflicts=('compiz-gtk-git')
cd "${srcdir}/${_upstream}-${pkgver}/gtk"
make DESTDIR="${pkgdir}" install
- rm "${pkgdir}/usr/share/applications/compiz.desktop"
cd "${srcdir}/${_upstream}-${pkgver}/images"
make DESTDIR="${pkgdir}" install
- rm "${pkgdir}/usr/share/icons/hicolor/"*"/apps/compiz."*
- rm "${pkgdir}/usr/share/compiz/"*.png
+
+ local REMOVE_THESE=(
+ "${pkgdir}/usr/share/icons/hicolor/"*"/apps/compiz."*
+ "${pkgdir}/usr/share/compiz/"*.png
+ "${pkgdir}/usr/share/applications/compiz.desktop"
+ )
+ # Believe it or not, you CAN fill an array using wildcards in bash
+
+ for fname in "${REMOVE_THESE[@]}";do
+ if [ -e "$fname" ];then
+ rm "$fname"
+ fi
+ done
}
sha256sums=('6fc5176e3af5d6f434f26d1b654460aeeb3faf723db37f0957b46c2c23955032')