summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorJianfeng Zhang2019-02-12 02:25:24 -0800
committerJianfeng Zhang2019-02-12 02:25:24 -0800
commit728764ef3c71187c8fc009b62552d6eb379d90f6 (patch)
treea29d2ef17b5f0068ba7aa5eaf9a28a3ea90f36b5
downloadaur-728764ef3c71187c8fc009b62552d6eb379d90f6.tar.gz
initial commit
-rw-r--r--.SRCINFO18
-rw-r--r--PKGBUILD42
2 files changed, 60 insertions, 0 deletions
diff --git a/.SRCINFO b/.SRCINFO
new file mode 100644
index 000000000000..1e35de3dd0e2
--- /dev/null
+++ b/.SRCINFO
@@ -0,0 +1,18 @@
+pkgbase = google-drive-ocamlfuse-opam
+ pkgdesc = FUSE-based file system backed by Google Drive, written in OCaml (installed from opam)
+ pkgver = 0.7.2
+ pkgrel = 1
+ url = https://astrada.github.io/google-drive-ocamlfuse/
+ arch = x86_64
+ license = MIT
+ makedepends = opam
+ depends = glibc
+ depends = zlib
+ depends = curl
+ depends = fuse2
+ depends = sqlite
+ provides = google-drive-ocamlfuse
+ conflicts = google-drive-ocamlfuse
+
+pkgname = google-drive-ocamlfuse-opam
+
diff --git a/PKGBUILD b/PKGBUILD
new file mode 100644
index 000000000000..78dd6dcaf6b8
--- /dev/null
+++ b/PKGBUILD
@@ -0,0 +1,42 @@
+# Maintainer: Jianfeng Zhang <swordfeng123@gmail.com>
+
+pkgname=google-drive-ocamlfuse-opam
+_pkgname=google-drive-ocamlfuse
+pkgver=0.7.2
+pkgrel=1
+pkgdesc="FUSE-based file system backed by Google Drive, written in OCaml (installed from opam)"
+arch=('x86_64')
+url='https://astrada.github.io/google-drive-ocamlfuse/'
+license=('MIT')
+depends=('glibc' 'zlib' 'curl' 'fuse2' 'sqlite')
+makedepends=('opam')
+provides=("${_pkgname}")
+conflicts=("${_pkgname}")
+source=()
+sha256sums=()
+options=()
+
+prepare() {
+ cd ${srcdir}
+ opam init -a
+ opam update
+}
+
+pkgver() {
+ cd "${srcdir}"
+ opam list ${_pkgname} --columns=version | awk '/^[^#]/{print}' | sort -V | tail -n 1
+}
+
+build() {
+ cd "${srcdir}"
+ opam switch create .
+ eval $(opam env --switch=. --set-switch)
+ opam install -y ${_pkgname}.${pkgver}
+ cp "_opam/bin/${_pkgname}" "${_pkgname}"
+ opam switch -y remove .
+}
+
+package() {
+ install -Dm755 "${srcdir}/${_pkgname}" "${pkgdir}/usr/bin/${_pkgname}"
+}
+