You are not logged in.
I am trying to install the pup package as a dependency for my pkgbuild. I don't quite know how to go doing that.
Last edited by notprash (2022-03-05 10:19:49)
Offline
https://wiki.archlinux.org/title/Arch_U … g_packages
What specifically are you trying to do that does not work?
Edit: link
Last edited by a821 (2022-03-04 09:56:20)
Offline
First you need to explicitly install those AUR dependencies before you build your package with" --asdeps" flag and then build and install the package from your PKGBUILD. All this is not required while using a AUR helper like yay etc.
Offline
First you need to explicitly install those AUR dependencies before you build your package with" --asdeps" flag and then build and install the package from your PKGBUILD. All this is not required while using a AUR helper like yay etc.
Here is my current PKGBUILD
# 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: Your Name <youremail@domain.com>
pkgname=manga-cli
pkgver=1.0
pkgrel=1
pkgdesc="Script to read manga from cli."
arch=('any')
url="https://github.com/notprash/manga-cli.git"
license=('MIT')
depends=('curl', 'zathura', 'zathura-cb')
makedepends=('git')
optdepends=('zathura-pdf-poppler: view manga file as pdf', 'imagemagick: converting files to pdf')
provides=('manga-cli')
conflicts=('manga-cli')
replaces=()
backup=()
options=()
install=
changelog=
source=("git+$url")
noextract=()
md5sums=('SKIP')
validpgpkeys=()
pkgver() {
cd "$srcdir/manga-cli"
}
package() {
cd "$srcdir"
}
Now where do I add pup as a dependency
Offline
In the "depends" array. Remove the arrays that you don't need, eg, options, backup,
Edit: Issues I see
1. `pkgname` should be manga-cli-git as you do not use git-tags.
2. you need a `pkgver` function (https://wiki.archlinux.org/title/VCS_pa … )_function)
3. Don't forget to copy the LICENSE to "$pkgdir/usr/share/licenses/$pkgname/" (https://wiki.archlinux.org/title/PKGBUILD#license)
Last edited by a821 (2022-03-04 10:16:37)
Offline
In the "depends" array. Remove the arrays that you don't need, eg, options, backup
It gives me a error instead of installing deps
=> Making package: manga-cli r43.6f90d80-1 (Fri Mar 4 15:45:40 2022)
==> Checking runtime dependencies...
==> Missing dependencies:
-> pup
==> Checking buildtime dependencies...
==> ERROR: Could not resolve all dependencies.
Offline
you need to install "pup" first using makepkg. See my edit in post #5 for other issues.
Offline
In the "depends" array. Remove the arrays that you don't need, eg, options, backup,
Edit: Issues I see
1. `pkgname` should be manga-cli-git as you do not use git-tags.
2. you need a `pkgver` function (https://wiki.archlinux.org/title/VCS_pa … )_function)
3. Don't forget to copy the LICENSE to "$pkgdir/usr/share/licenses/$pkgname/" (https://wiki.archlinux.org/title/PKGBUILD#license)
there is already a packaged named manga-cli-git
Offline
there is already a packaged named manga-cli-git
I see, you need to choose another pkgname as it is already taken. In any case, the pkgname must have the suffix "-git" because yours is a VCS package.
Offline
pkgname='manga-cli-notprash-git'
_pkgname='manga-cli'
pkgver=1.0.r43.6f90d80
pkgrel=1
pkgdesc="Script to read manga from cli."
arch=('any')
url="https://github.com/notprash/manga-cli.git"
license=('MIT')
depends=('curl' 'zathura' 'zathura-cb' 'pup')
makedepends=('git')
optdepends=('zathura-pdf-poppler: view manga file as pdf', 'imagemagick: converting files to pdf'
provides=('manga-cli')
conflicts=('manga-cli')
source=("git+$url")
md5sums=('SKIP')
pkgver() {
cd "$srcdir/${_pkgname}"
printf "1.0.r%s.%s" "$(git rev-list --count HEAD)" "$(git rev-parse --short HEAD)"
}
package() {
cd "$srcdir/$_pkgname"
install -Dm755 ./manga-cli "$pkgdir/usr/bin/manga-cli"
}
my current PKGBUILD. It installs everything but does not move the manga-cli script to /usr/bin
Offline
optdepends=('zathura-pdf-poppler: view manga file as pdf', 'imagemagick: converting files to pdf'
missing closing bracket and remove extra comma
provides=('manga-cli')
As said, this is other package, so it should not provide it (unless both packages are equivalent). You can remove this line.
conflicts=('manga-cli')
that package does not exist, most likely you meant 'manga-cli-git' (both provide a binary called manga-cli).
printf "1.0.r%s.%s" "$(git rev-list --count HEAD)" "$(git rev-parse --short HEAD)"
remove the "1.0." part so you get r43.6f90d80. If you create tags, then the last tag will be added automatically (but that command line must change, see the wiki).
Add the license in `package()` (something like)
install -Dm644 -t "${pkgdir}/usr/share/licenses/${pkgname}" LICENSE
but does not move the manga-cli script to /usr/bin
The script does not need to be moved to /usr/bin. You get a package that you install with `pacman -U` (or you can run `makepkg -i` to install the package after building it)
Last edited by a821 (2022-03-04 11:16:17)
Offline