-
Notifications
You must be signed in to change notification settings - Fork 5
/
PKGBUILD
69 lines (55 loc) · 2.2 KB
/
PKGBUILD
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
#! /usr/bin/env sh
# Maintainer: shivanandvp <[email protected], [email protected]>
pkgver=0.0.1
pkgrel=1
pkgbase='paxy'
pkgname=('paxy-cli' 'paxy-gui')
arch=('x86_64')
url="https://github.com/shivanandvp/paxy"
makedepends=('git' 'cargo' 'gtk4' 'base-devel')
source=("${url}/archive/refs/tags/v${pkgver}.tar.gz")
sha256sums=('SKIP')
prepare() {
export PROJECT_DIRECTORY="${srcdir}/paxy-${pkgver}"
export RESOURCE_DIRECTORY="$PROJECT_DIRECTORY/packaging/resources"
export BUILD_DIRECTORY="$PROJECT_DIRECTORY/target"
}
build() {
(
cd "$PROJECT_DIRECTORY"
cargo build \
--release \
--all-features \
--target-dir="target"
)
}
package_paxy-cli() {
pkgdesc='(CLI-only package) A package manager that gets out of your way.'
provides=('paxy')
depends=()
license=('MPL2')
conflicts=("paxy-cli-local" "paxy-cli-git" "paxy-gui" "paxy-gui-local" "paxy-gui-git")
(
cd "$PROJECT_DIRECTORY"
install -Dm644 "$PROJECT_DIRECTORY/paxy/LICENSE" "$pkgdir/usr/share/licenses/paxy/LICENSE"
install -Dm644 "$PROJECT_DIRECTORY/paxy-cli/LICENSE" "$pkgdir/usr/share/licenses/paxy-cli/LICENSE"
install -Dm755 "$PROJECT_DIRECTORY/target/release/paxy-cli" "$pkgdir/usr/bin/paxy-cli"
ln -s "/usr/bin/paxy-cli" "$pkgdir/usr/bin/paxy"
)
}
package_paxy-gui() {
pkgdesc='(CLI GUI package) A package manager that gets out of your way.'
provides=('paxy')
depends=('gtk4')
license=('MPL2')
conflicts=("paxy-gui-local" "paxy-gui-git" "paxy-cli" "paxy-cli-local" "paxy-cli-git")
(
cd "$PROJECT_DIRECTORY"
install -Dm644 "$PROJECT_DIRECTORY/paxy/LICENSE" "$pkgdir/usr/share/licenses/paxy/LICENSE"
install -Dm644 "$PROJECT_DIRECTORY/paxy-cli/LICENSE" "$pkgdir/usr/share/licenses/paxy-cli/LICENSE"
install -Dm644 "$PROJECT_DIRECTORY/paxy-gui/LICENSE" "$pkgdir/usr/share/licenses/paxy-gui/LICENSE"
install -Dm755 "$PROJECT_DIRECTORY/target/release/paxy-cli" "$pkgdir/usr/bin/paxy-cli"
ln -s "/usr/bin/paxy-cli" "$pkgdir/usr/bin/paxy"
install -Dm755 "$PROJECT_DIRECTORY/target/release/paxy-gui" "$pkgdir/usr/bin/paxy-gui"
)
}