Skip to content

Instantly share code, notes, and snippets.

@mdemierre
Created December 26, 2016 22:39
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save mdemierre/b2cddd2b262207fb5ab14778d01cce7d to your computer and use it in GitHub Desktop.
Save mdemierre/b2cddd2b262207fb5ab14778d01cce7d to your computer and use it in GitHub Desktop.
chrome-gnome-shell-git 7.2.r59.g73a1997
# Contributor: Andrew Querol <andrew@querol.me>
# Maintainer: Rafael Fontenelle <rafaelff@gnome.org>
pkgname=chrome-gnome-shell-git
pkgver=7.2.r59.g73a1997
pkgrel=1
pkgdesc="Native connector for extensions.gnome.org"
arch=('any')
url="https://wiki.gnome.org/Projects/GnomeShellIntegrationForChrome"
license=('GPL')
depends=('gnome-shell' 'python-requests')
makedepends=('git' 'cmake' 'jq')
provides=("${pkgname%-git}")
replaces=('gs-chrome-connector') # Old name, renamed at request of the maintainer
conflicts=($replaces)
source=("git+https://git.gnome.org/browse/chrome-gnome-shell")
md5sums=('SKIP')
pkgver() {
cd "$srcdir/${pkgname%-git}"
# git describe --long | sed 's/\([^-]*-g\)/r\1/;s/-/./g;s/^v//'
_tag=$(git describe --abbrev=0)
v=$(grep 'set(PROJECT_VERSION' CMakeLists.txt | cut -d'"' -f2)
r="$(git rev-list --count $_tag..HEAD)"
h="$(git rev-parse --short HEAD)"
echo $v.r$r.g$h
}
prepare() {
cd "$srcdir/${pkgname%-git}"
mkdir -p 'build'
}
build() {
cd "$srcdir/${pkgname%-git}/build"
cmake ../ \
-DCMAKE_INSTALL_PREFIX=/usr \
-DCMAKE_INSTALL_LIBDIR='/usr/lib' \
-DBUILD_EXTENSION=OFF
}
package() {
cd "$srcdir/${pkgname%-git}/build"
make DESTDIR="$pkgdir/" install
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment