summarylogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--.SRCINFO21
-rw-r--r--PKGBUILD44
-rw-r--r--cernvm-webapi.service8
3 files changed, 73 insertions, 0 deletions
diff --git a/.SRCINFO b/.SRCINFO
new file mode 100644
index 000000000000..48dca981a85c
--- /dev/null
+++ b/.SRCINFO
@@ -0,0 +1,21 @@
+pkgbase = cernvm-webapi
+ pkgdesc = CernVM WebAPI Based on URI-Handlers
+ pkgver = r206.44badf3
+ pkgrel = 1
+ url = https://test4theory.cern.ch/challenge/
+ arch = i686
+ arch = x86_64
+ license = GPL3
+ depends = gcc
+ depends = cmake
+ depends = gksu
+ depends = virtualbox
+ source = git+https://github.com/wavesoft/cernvm-webapi.git
+ source = git+https://github.com/wavesoft/libcernvm.git
+ source = cernvm-webapi.service
+ md5sums = SKIP
+ md5sums = SKIP
+ md5sums = 61d5a2e39d22a46447b2655ed428f7bf
+
+pkgname = cernvm-webapi
+
diff --git a/PKGBUILD b/PKGBUILD
new file mode 100644
index 000000000000..66896333d551
--- /dev/null
+++ b/PKGBUILD
@@ -0,0 +1,44 @@
+pkgname=cernvm-webapi
+pkgver=r206.44badf3
+pkgrel=1
+pkgdesc="CernVM WebAPI Based on URI-Handlers"
+arch=('i686' 'x86_64')
+url="https://test4theory.cern.ch/challenge/"
+license=('GPL3')
+depends=('gcc' 'cmake' 'gksu' 'virtualbox')
+makedepends=('')
+source=("git+https://github.com/wavesoft/cernvm-webapi.git"
+ "git+https://github.com/wavesoft/libcernvm.git"
+ "cernvm-webapi.service")
+md5sums=('SKIP'
+ 'SKIP'
+ '61d5a2e39d22a46447b2655ed428f7bf')
+
+pkgver() {
+ cd "$pkgname"
+ printf "r%s.%s" "$(git rev-list --count HEAD)" "$(git rev-parse --short HEAD)"
+}
+
+build() {
+ cd "$pkgname"
+
+ if [[ $CARCH == "i686" ]]; then
+ chmod +x prepare-linux32.sh
+ ./prepare-linux32.sh
+ cd build_linux_i386-Release
+ elif [[ $CARCH == "x86_64" ]]; then
+ chmod +x prepare-linux64.sh
+ ./prepare-linux64.sh
+ cd build_linux_amd64-Release
+ fi
+
+ make
+ export _BUILDIR=$(pwd)
+}
+
+package() {
+ cd "$_BUILDIR"
+
+ make DESTDIR="$pkgdir/" install
+ install -D "../../cernvm-webapi.service" "$pkgdir/usr/lib/systemd/system/cernvm-webapi.service"
+}
diff --git a/cernvm-webapi.service b/cernvm-webapi.service
new file mode 100644
index 000000000000..b7ba29583034
--- /dev/null
+++ b/cernvm-webapi.service
@@ -0,0 +1,8 @@
+[Unit]
+Description=CernVM WebAPI Based on URI-Handlers
+
+[Service]
+ExecStart=/usr/local/bin/cernvm-webapi
+
+[Install]
+WantedBy=multi-user.target