diff options
author | Scarlett | 2023-04-26 08:52:55 -0400 |
---|---|---|
committer | Scarlett | 2023-04-26 08:52:55 -0400 |
commit | 54b014d54d0971e3b32855a8bb8b4d047ed696ed (patch) | |
tree | 9c38c11daae6fa93f131516474100f9234e4bb21 | |
parent | f61505c6f272bb838019f320c43ae21216487f17 (diff) | |
download | aur-54b014d54d0971e3b32855a8bb8b4d047ed696ed.tar.gz |
update to gdrive3, rust version
-rw-r--r-- | .SRCINFO | 15 | ||||
-rw-r--r-- | PKGBUILD | 51 |
2 files changed, 28 insertions, 38 deletions
@@ -1,17 +1,16 @@ pkgbase = gdrive-git - pkgdesc = Google Drive CLI Client - pkgver = 2.1.0.r35.gfb08fe2 - pkgrel = 2 - url = https://github.com/prasmussen/gdrive + pkgdesc = Google Drive CLI Client (Version 3) + pkgver = 3.9.0.r2.g57e5ea6 + pkgrel = 1 + url = https://github.com/glotlabs/gdrive arch = x86_64 + arch = aarch64 license = MIT makedepends = git - makedepends = go + makedepends = cargo provides = gdrive conflicts = gdrive - options = !strip - options = !emptydirs - source = gdrive-git::git+https://github.com/prasmussen/gdrive.git + source = gdrive-git::git+https://github.com/glotlabs/gdrive.git sha256sums = SKIP pkgname = gdrive-git @@ -1,49 +1,40 @@ +# Maintainer: scarlettekk <scarlett AT enby DOT site> # Maintainer: willemw <willemw12@gmail.com> pkgname=gdrive-git -pkgver=2.1.0.r35.gfb08fe2 -pkgrel=2 -pkgdesc="Google Drive CLI Client" -arch=('x86_64') -url="https://github.com/prasmussen/gdrive" +pkgver=3.9.0.r2.g57e5ea6 +pkgrel=1 +pkgdesc="Google Drive CLI Client (Version 3)" +arch=('x86_64' 'aarch64') +url="https://github.com/glotlabs/gdrive" license=('MIT') -makedepends=('git' 'go') -provides=("${pkgname%-git}") -conflicts=("${pkgname%-git}") -options=('!strip' '!emptydirs') +makedepends=('git' 'cargo') +provides=('gdrive') +conflicts=('gdrive') source=("$pkgname::git+$url.git") sha256sums=('SKIP') -_gopkg="${url#https://}" -_gobuild=build/src/$_gopkg - -export CGO_CPPFLAGS="${CPPFLAGS}" -export CGO_CFLAGS="${CFLAGS}" -export CGO_CXXFLAGS="${CXXFLAGS}" -export CGO_LDFLAGS="${LDFLAGS}" -export GOFLAGS="-buildmode=pie -trimpath -ldflags=-linkmode=external -modcacherw" # -mod=readonly - pkgver() { - git -C $pkgname describe --long | sed 's/\([^-]*-g\)/r\1/;s/-/./g' + git -C $pkgname describe --long --tags | sed 's/\([^-]*-g\)/r\1/;s/-/./g' + cd $pkgname } prepare() { - mkdir -p "$(dirname $_gobuild)" - cp -a "$srcdir/$pkgname" $_gobuild - - export GOCACHE="$srcdir/cache" - export GOPATH="$srcdir/build" - go mod init $_gopkg - go mod tidy -e + cd $pkgname + export RUSTUP_TOOLCHAIN=stable + cargo fetch --locked --target "$CARCH-unknown-linux-gnu" } build() { - export GOCACHE="$srcdir/cache" - export GOPATH="$srcdir/build" - go install $_gopkg@latest + cd $pkgname + export RUSTUP_TOOLCHAIN=stable + export CARGO_TARGET_DIR=target + cargo build --frozen --release --all-features } package() { - install -Dm755 build/bin/gdrive -t "$pkgdir/usr/bin" + cd $pkgname + install -Dm0755 -t "$pkgdir/usr/bin/" "target/release/gdrive" + install -Dm644 LICENSE "$pkgdir/usr/share/licenses/$pkgname/LICENSE" } |