Skip to content

Commit

Permalink
build: Modify PKGBUILDs to make package creation work on Arch Linux
Browse files Browse the repository at this point in the history
  • Loading branch information
pvshvp-oss committed May 19, 2024
1 parent a887db6 commit 277a8a0
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 47 deletions.
17 changes: 2 additions & 15 deletions packaging/archlinux/paxy-git/PKGBUILD
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
pkgver=0.0.1
pkgrel=1
pkgbase='paxy'
pkgname=('paxy-cli-git' 'paxy-gui-git' 'paxy-db-git')
pkgname=('paxy-cli-git' 'paxy-gui-git')
arch=('x86_64')
url="https://github.com/shivanandvp/paxy"
makedepends=('git' 'cargo' 'gtk4' 'base-devel')
Expand Down Expand Up @@ -33,14 +33,7 @@ build() {
cargo build \
--release \
--all-features \
--target-dir="target" \

cargo run \
--bin="paxy-cli" \
-- \
generate-database \
"$PROJECT_DIRECTORY/paxy-db/input-file.yaml" \
"$PROJECT_DIRECTORY/target/database.db"
--target-dir="target"
)
}

Expand All @@ -51,9 +44,6 @@ package_paxy-cli-git() {
license=('MPL2')
conflicts=("paxy-cli" "paxy-cli-local" "paxy-gui" "paxy-gui-local" "paxy-gui-git")

# To bypass makepkg's dependency check during build-time
optdepends+=("paxy-db")

(
cd "$PROJECT_DIRECTORY"

Expand All @@ -71,9 +61,6 @@ package_paxy-gui-git() {
depends=('gtk4')
license=('MPL2')
conflicts=("paxy-gui" "paxy-gui-local" "paxy-cli" "paxy-cli-local" "paxy-cli-git")

# To bypass makepkg's dependency check during build-time
optdepends+=("paxy-db")

(
cd "$PROJECT_DIRECTORY"
Expand Down
21 changes: 4 additions & 17 deletions packaging/archlinux/paxy-local/PKGBUILD
Original file line number Diff line number Diff line change
Expand Up @@ -3,18 +3,18 @@
# Maintainer: shivanandvp <pvshvp.oss@gmail.com, shivanandvp@rebornos.org>

PKGVER_STUB=0.0.1
pkgver=0.0.1.2023_08_31_04
pkgver=0.0.1.2024_05_19_01
pkgrel=1
pkgbase='paxy'
pkgname=('paxy-cli-local' 'paxy-gui-local' 'paxy-db-local')
pkgname=('paxy-cli-local' 'paxy-gui-local')
arch=('x86_64')
url="https://github.com/shivanandvp/paxy"
makedepends=('cargo' 'gtk4' 'base-devel')
source=()
sha256sums=()

prepare() {
export PROJECT_DIRECTORY="$(dirname -- "$(dirname -- "$(dirname -- "$(pwd)")")")"
export PROJECT_DIRECTORY="$(dirname -- "$(dirname -- "$(dirname -- "$(dirname -- "$(pwd)")")")")"
export RESOURCE_DIRECTORY="$PROJECT_DIRECTORY/packaging/resources"
export BUILD_DIRECTORY="$PROJECT_DIRECTORY/target"
}
Expand All @@ -30,14 +30,7 @@ build() {
cargo build \
--release \
--all-features \
--target-dir="target" \

cargo run \
--bin="paxy-cli" \
-- \
generate-database \
"$PROJECT_DIRECTORY/paxy-db/input-file.yaml" \
"$PROJECT_DIRECTORY/target/database.db"
--target-dir="target"
)
}

Expand All @@ -48,9 +41,6 @@ package_paxy-cli-local() {
license=('MPL2')
conflicts=("paxy-cli" "paxy-cli-git" "paxy-gui" "paxy-gui-local" "paxy-gui-git")

# To bypass makepkg's dependency check during build-time
optdepends+=("paxy-db")

(
cd "$PROJECT_DIRECTORY"

Expand All @@ -69,9 +59,6 @@ package_paxy-gui-local() {
license=('MPL2')
conflicts=("paxy-gui" "paxy-gui-git" "paxy-cli" "paxy-cli-local" "paxy-cli-git")

# To bypass makepkg's dependency check during build-time
optdepends+=("paxy-db")

(
cd "$PROJECT_DIRECTORY"

Expand Down
17 changes: 2 additions & 15 deletions packaging/archlinux/paxy/PKGBUILD
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
pkgver=0.0.1
pkgrel=1
pkgbase='paxy'
pkgname=('paxy-cli' 'paxy-gui' 'paxy-db')
pkgname=('paxy-cli' 'paxy-gui')
arch=('x86_64')
url="https://github.com/shivanandvp/paxy"
makedepends=('git' 'cargo' 'gtk4' 'base-devel')
Expand All @@ -25,14 +25,7 @@ build() {
cargo build \
--release \
--all-features \
--target-dir="target" \

cargo run \
--bin="paxy-cli" \
-- \
generate-database \
"$PROJECT_DIRECTORY/paxy-db/input-file.yaml" \
"$PROJECT_DIRECTORY/target/database.db"
--target-dir="target"
)
}

Expand All @@ -43,9 +36,6 @@ package_paxy-cli() {
license=('MPL2')
conflicts=("paxy-cli-local" "paxy-cli-git" "paxy-gui" "paxy-gui-local" "paxy-gui-git")

# To bypass makepkg's dependency check during build-time
optdepends+=("paxy-db")

(
cd "$PROJECT_DIRECTORY"

Expand All @@ -63,9 +53,6 @@ package_paxy-gui() {
depends=('gtk4')
license=('MPL2')
conflicts=("paxy-gui-local" "paxy-gui-git" "paxy-cli" "paxy-cli-local" "paxy-cli-git")

# To bypass makepkg's dependency check during build-time
optdepends+=("paxy-db")

(
cd "$PROJECT_DIRECTORY"
Expand Down

0 comments on commit 277a8a0

Please sign in to comment.