summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorLiqueur Librazy2016-10-30 00:10:30 +0800
committerLiqueur Librazy2016-10-30 00:10:30 +0800
commitded33dff185b49b276372d508c5b8e91de89f92f (patch)
tree3f6fe78a1d79677c1184d2a86cb23f97a138814c
downloadaur-ded33dff185b49b276372d508c5b8e91de89f92f.tar.gz
INIT tidb-bin PKGBUILD
-rw-r--r--.SRCINFO15
-rw-r--r--PKGBUILD40
2 files changed, 55 insertions, 0 deletions
diff --git a/.SRCINFO b/.SRCINFO
new file mode 100644
index 000000000000..5e68b3bbea49
--- /dev/null
+++ b/.SRCINFO
@@ -0,0 +1,15 @@
+pkgbase = tidb-bin
+ pkgdesc = A distributed NewSQL database compatible with MySQL protocol
+ pkgver = 0.0.1.20161029021623
+ pkgrel = 1
+ url = https://github.com/pingcap/tidb
+ arch = x86_64
+ license = APACHE
+ depends = gcc-libs
+ source = http://download.pingcap.org/tidb-latest-linux-amd64.tar.gz
+ source = http://download.pingcap.org/tidb-latest-linux-amd64.sha256
+ sha256sums = SKIP
+ sha256sums = SKIP
+
+pkgname = tidb-bin
+
diff --git a/PKGBUILD b/PKGBUILD
new file mode 100644
index 000000000000..95d0eeba792f
--- /dev/null
+++ b/PKGBUILD
@@ -0,0 +1,40 @@
+# This is an example PKGBUILD file. Use this as a start to creating your own,
+# and remove these comments. For more information, see 'man PKGBUILD'.
+# NOTE: Please fill out the license field for your package! If it is unknown,
+# then please put 'unknown'.
+
+# Maintainer: Liqueur Librazy <im@librazy.org>
+pkgname=tidb-bin
+pkgver=0.0.1.20161029021623
+pkgrel=1
+pkgdesc="A distributed NewSQL database compatible with MySQL protocol"
+arch=('x86_64')
+url="https://github.com/pingcap/tidb"
+license=('APACHE')
+depends=('gcc-libs')
+backup=()
+options=()
+
+source=("http://download.pingcap.org/tidb-latest-linux-amd64.tar.gz"
+ "http://download.pingcap.org/tidb-latest-linux-amd64.sha256")
+
+sha256sums=(
+ 'SKIP'
+ 'SKIP')
+
+pkgver() {
+ cd "tidb-latest-linux-amd64"
+ echo "0.0.1.$(./bin/tidb-server -v |grep 'Time:' | cut -c18-36| sed 's/[ :-]//g')"
+}
+
+prepare() {
+ sha256sum -c tidb-latest-linux-amd64.sha256
+}
+
+package() {
+ install -dm755 "$pkgdir"/{opt/tidb/conf,usr/bin}
+ cd "tidb-latest-linux-amd64/bin"
+ install -D -m755 *-server "${pkgdir}/usr/bin"
+ cd ..
+ cp -R conf "$pkgdir/opt/tidb/"
+}