diff options
-rw-r--r-- | .SRCINFO | 15 | ||||
-rw-r--r-- | .editorconfig | 8 | ||||
-rw-r--r-- | .gitignore | 14 | ||||
-rw-r--r-- | PKGBUILD | 38 |
4 files changed, 75 insertions, 0 deletions
diff --git a/.SRCINFO b/.SRCINFO new file mode 100644 index 000000000000..47f619352860 --- /dev/null +++ b/.SRCINFO @@ -0,0 +1,15 @@ +pkgbase = certspotter-git + pkgdesc = Certificate Transparency Log Monitor - git version + pkgver = 0.9.r17.ge74cb79 + pkgrel = 1 + url = https://github.com/SSLMate/certspotter + arch = x86_64 + license = MPL2 + makedepends = git + makedepends = go-pie + provides = certspotter + conflicts = certspotter + source = certspotter-git::git+https://github.com/SSLMate/certspotter + sha256sums = SKIP + +pkgname = certspotter-git diff --git a/.editorconfig b/.editorconfig new file mode 100644 index 000000000000..a467ee9a97a6 --- /dev/null +++ b/.editorconfig @@ -0,0 +1,8 @@ +root = true + +[*] +charset = utf-8 +end_of_line = lf +insert_final_newline = true +indent_style = tab +tab_width = 4 diff --git a/.gitignore b/.gitignore new file mode 100644 index 000000000000..82b3c183d5d4 --- /dev/null +++ b/.gitignore @@ -0,0 +1,14 @@ +# from https://github.com/github/gitignore/blob/master/ArchLinuxPackages.gitignore +*.tar +*.tar.* +*.rpm +*.jar +*.exe +*.msi +*.zip +*.tgz +*.log +*.log.* +*.sig + +*/ diff --git a/PKGBUILD b/PKGBUILD new file mode 100644 index 000000000000..692b0547ae26 --- /dev/null +++ b/PKGBUILD @@ -0,0 +1,38 @@ +# Maintainer: Daniel Peukert <dan.peukert@gmail.com> +_pkgname='certspotter' +pkgname="$_pkgname-git" +pkgver='0.9.r17.ge74cb79' +pkgrel='1' +pkgdesc='Certificate Transparency Log Monitor - git version' +arch=('x86_64') +url="https://github.com/SSLMate/$_pkgname" +license=('MPL2') +makedepends=('git' 'go-pie') +provides=("$_pkgname") +conflicts=("$_pkgname") +source=("$pkgname::git+$url") +sha256sums=('SKIP') + +_gopath="$pkgname-gopath" + +pkgver() { + cd "$srcdir/$_gopath/src/software.sslmate.com/src/$_pkgname/" + git describe --long --tags | sed 's/\([^-]*-g\)/r\1/;s/-/./g' +} + +prepare() { + mkdir -p "$srcdir/$_gopath/src/software.sslmate.com/src/" + mv "$srcdir/$pkgname/" "$srcdir/$_gopath/src/software.sslmate.com/src/$_pkgname/" + + export GOPATH="$srcdir/$_gopath" + go get -d -v "software.sslmate.com/src/$_pkgname/cmd/$_pkgname" +} + +build() { + export GOPATH="$srcdir/$_gopath" + go install -gcflags "all=-trimpath=$PWD" -asmflags "all=-trimpath=$PWD" -ldflags "-extldflags $LDFLAGS" "software.sslmate.com/src/$_pkgname/cmd/$_pkgname" +} + +package() { + install -Dm755 "$srcdir/$_gopath/bin/$_pkgname" "$pkgdir/usr/bin/$_pkgname" +} |