pkgbuild: follow AUR elemetary-git version naming.
authorCedric BAIL <cedric.bail@samsung.com>
Thu, 12 Dec 2013 02:39:29 +0000 (11:39 +0900)
committerCedric BAIL <cedric.bail@samsung.com>
Thu, 12 Dec 2013 03:22:12 +0000 (12:22 +0900)
configure.ac
pkgbuild/.gitignore
pkgbuild/PKGBUILD [moved from pkgbuild/PKGBUILD.in with 68% similarity]

index c51a1ab..1ffacde 100644 (file)
@@ -743,7 +743,6 @@ config/mobile/Makefile
 $po_makefile_in
 cmakeconfig/ElementaryConfig.cmake
 cmakeconfig/ElementaryConfigVersion.cmake
-pkgbuild/PKGBUILD
 ])
 
 AC_OUTPUT
index 913d3ff..39ef434 100644 (file)
@@ -1,4 +1,3 @@
-/PKGBUILD
 /pkg
 /src
 /*.tar.xz
similarity index 68%
rename from pkgbuild/PKGBUILD.in
rename to pkgbuild/PKGBUILD
index 6f1927c..6103dd0 100644 (file)
@@ -1,15 +1,34 @@
 # Maintainer: Enlightenment Developers <enlightenment-devel@enlightenment.org>
-pkgname=('elementary' 'elementary_test' 'elementary_doc')
-pkgver=@VERSION@
+pkgname=elementary-git
+_pkgname=${pkgname%-*}
+true && pkgname=('elementary-git' 'elementary_test-git' 'elementary_doc-git')
+pkgver=1.8.99.8967.a1cfce6
 pkgrel=1
 pkgdesc="Enlightenment GUI toolkit - GIT development snapshot"
 arch=('i686' 'x86_64' 'arm')
 url="http://www.enlightenment.org"
 license=('LGPL2.1' 'CCPL:cc-by-sa')
-makedepends=('doxygen' 'imagemagick')
-depends=('efl' 'evas_generic_loaders')
-optdepends=('emotion_generic_players')
+makedepends=('doxygen' 'imagemagick' 'git')
+depends=('efl-git')
+  [[ ! $(pacman -T ewebkit-svn) ]] && depends+=('ewebkit-svn')         # webkit-efl support is detected at build time
+  [[ ! $(pacman -T elocation-git) ]] && depends+=('elocation-git')     # elocation support is detected at build time
+  [[ ! $(pacman -T libeweather-git) ]] && depends+=('libeweather-git') # eweather support is detected at build time
+optdepends=('emotion_generic_players' 'evas_generic_loaders')
 options=('!libtool' 'debug')
+provides=('elementary')
+
+pkgver() {
+  cd "../.."
+
+  for _i in v_maj v_min v_mic; do
+    local v_ver=$v_ver.$(grep -m 1 $_i configure.ac | sed 's/m4//' | grep -o "[[:digit:]]*")
+  done
+
+  v_ver=$(awk -F , -v v_ver=${v_ver#.} '/^AC_INIT/ {gsub(/v_ver/, v_ver); gsub(/[\[\] -]/, ""); print $2}' configure.ac)
+
+  printf "$v_ver.$(git rev-list --count HEAD).$(git rev-parse --short HEAD)"
+}
+
 build() {
   cd "../.."
   export CFLAGS="$CFLAGS -fvisibility=hidden -fomit-frame-pointer"
@@ -25,7 +44,7 @@ build() {
 #  make -k check
 #}
 
-package_elementary() {
+package_elementary-git() {
   cd "../.."
   make -j1 DESTDIR="$pkgdir/" install
   install -Dm644 README "$pkgdir/usr/share/$pkgname/README"
@@ -43,7 +62,7 @@ package_elementary() {
   rm -rf "$pkgdir/usr/share/elementary/"{examples,images,objects}
 }
 
-package_elementary_test() {
+package_elementary_test-git() {
   pkgdesc="Test application for Elementary"
   depends=('elementary')
 
@@ -58,7 +77,7 @@ package_elementary_test() {
   rm -rf "$pkgdir/usr/share/"{icons,locale}
 }
 
-package_elementary_doc() {
+package_elementary_doc-git() {
   pkgdesc="Documentation for Elementary"
   arch=('any')
   unset depends optdepends