pkgname='potato'
pkgver='1.0.0' # this is the variable pkgver, can also be a function that will return dynamic version, but both are required for VCS packages
pkgrel=2 # If a PACBUILD is modified that could affect the resulting package but no package update
epoch='0' # force package to be seen as newer no matter what
pkgdesc='Pretty obvious
Long description'
url='https://potato.com'
license="Apache-2.0 OR MIT"
arch=('any' 'x86_64' 'x86') # Valid arches defined here: https://doc.rust-lang.org/std/env/consts/constant.ARCH.html. `any` and the other arches are mutually exclusive.
maintainer='Elsie19 <hwengerstickel@pm.me>'
repology=("project: ${pkgname}")
source=(
"https://potato.com/${pkgver}.tar.gz"
"potato.tar.gz::https://potato.com/${pkgver}.tar.gz" # with a forced download name
"${pkgname}::git+https://github.com/pacstall/pacstall" # git repo
"${pkgname}::https://github.com/pacstall/pacstall/releases/download/2.0.1/pacstall-2.0.1.deb::repology" # use changelog with repology
"${pkgname}::git+https://github.com/pacstall/pacstall#branch=master" # git repo with branch
"${pkgname}::git+file://home/henry/pacstall/pacstall" # local git repo
"patch-me-harder.patch::https://potato.com/patch-me.patch"
) # also source_amd64=(), source_i386=()
noextract=(
"${pkgver}.tar.gz"
)
sha256sums=(
'e69fcf51c211772d4f193f3dc59b1e91607bea7e53999f1d5e03ba401e5da969'
'SKIP'
'SKIP'
'etc'
) # can also do sha256sums_amd64=(), repeat for sha384, sha512, and b2
optdepends=(
'same as pacstall: yes'
) # rince and repeat optdepends_$arch=()
depends=(
'hashbrowns: >=1.8.0'
'mashed-potatos: ^1.9.0'
'gravy: ~2.3.0'
'applesauce: >3.*'
'chicken: <2.0.0'
'libappleslices.so'
'libdeepfryer.so: 3'
)
makedepends=(
'whisk'
'onions'
)
checkdepends=(
'customer_satisfaction'
)
ppa=('mcdonalds/ppa')
provides=(
'mashed-potatos'
'aaaaaaaaaaaaaaaaaaaaaaaaaa'
)
conflicts=(
'KFC'
'potato_rights'
) # can also do conflicts_$arch=()
replaces=(
'kidney_beans'
)
backup=(
'etc/potato/prepare.conf'
'r:etc/mashed_potato/prepare.conf'
)
options=(
'!strip'
'!docs'
'etc'
)
groups=('potato-clan')
incompatible=('debian::jessy' 'ubuntu::20.04')
prepare() {
cd "${pkgname}-${pkgver}"
patch -p1 -i "${srcdir}/patch-me-harder.patch"
}
build() {
cd "${pkgname}-${pkgver}"
./configure --prefix=/usr
make
}
check() {
cd "${pkgname}-${pkgver}"
make -k check
}
package() {
cd "${pkgname}-${pkgver}"
make DESTDIR="${pkgdir}/" install
}
pre_install() {
echo "potato"
}
post_install() {
echo "potato"
}
pre_upgrade() {
echo "potato"
}
post_upgrade() {
echo "potato"
}
pre_remove() {
echo "potato"
}
post_remove() {
echo "potato"
}
pre_purge() {
echo "potato"
}
post_purge() {
echo "potato"
}
Key changes from PKGBUILD
license is now a license expression that can be used to better describe software licenses.
Key changes from PKGBUILD
license
is now a license expression that can be used to better describe software licenses.pkgdesc
allows for long descriptions.maintainer
is now a variable.repology
array exists.{make,check,}depends
have more complex version specifiersppa
array exists.backup
array can haver:
specifier to remove stale config files on install/upgrade. Those denoted withr:
cannot be in the final deb.incompatible
array exists.install=file
to main file.Common code in both Pacscripts and PACBUILDs
maintainer
, we don't need to do much to convert if we end up using a variable instead of array.repology
, nothing to be changed.ppa
, nothing to be changed.backup
, nothing to be changed.incompatible
, add extra:
to align with PACBUILD style.optdepends
, nothing to be changed.depends
, nothing to be changed.build_depends
->makedepends
.Full list of stuff we need to implement from PKGBUILDs
https://wiki.archlinux.org/title/PKGBUILD