4b97cd2fb4
```sh git grep -l '^patch_args=-Np0' "srcpkgs/$1*/template" | while read template; do for p in ${template%/template}/patches/*; do sed -i ' \,^[+-][+-][+-] /dev/null,b /^[*-]\+ [0-9]\+\(,[0-9]\+\)\? [*-]\+$/b s,^[*][*][*] ,&a/, /^--- /{ s,\(^--- \)\(./\)*,\1a/, s,[.-][Oo][Rr][Ii][Gg]\([ /]\),\1, s/[.-][Oo][Rr][Ii][Gg]$// s/[.]patched[.]\([^.]\)/.\1/ h } /^+++ -/{ g s/^--- a/+++ b/ b } s,\(^+++ \)\(./\)*,\1b/, ' "$p" done sed -i '/^patch_args=/d' $template done ```
30 lines
1 KiB
Bash
30 lines
1 KiB
Bash
# Template file for 'stack'
|
|
pkgname=stack
|
|
version=2.5.1
|
|
revision=1
|
|
_stackage="lts-16.13"
|
|
hostmakedepends="cabal-install pkg-config unzip"
|
|
makedepends="zlib-devel pcre-devel"
|
|
depends="git gmp-devel iana-etc"
|
|
short_desc="Cross-platform program for developing Haskell projects"
|
|
maintainer="Leah Neukirchen <leah@vuxu.org>"
|
|
license="BSD-3-Clause"
|
|
homepage="https://haskellstack.org"
|
|
distfiles="https://github.com/commercialhaskell/${pkgname}/archive/v${version}.tar.gz
|
|
https://www.stackage.org/${_stackage}/cabal.config>cabal.config-${_stackage}"
|
|
checksum="f29d63b91ff2bddd130b29ddee90a1f450706271a13d5d80b653b50379ffa076
|
|
b9ac16e957c91b698bc8c06166b5fa61e8443ef97f87ab591a21d6fda4327b58"
|
|
skip_extraction="cabal.config-${_stackage}"
|
|
nocross=yes
|
|
nopie_files="/usr/bin/stack"
|
|
|
|
do_build() {
|
|
cp ${XBPS_SRCDISTDIR}/${pkgname}-${version}/cabal.config-${_stackage} cabal.config
|
|
HOME=$PWD cabal update
|
|
HOME=$PWD cabal new-build ${makejobs} --flag disable-git-info
|
|
}
|
|
|
|
do_install() {
|
|
eval vbin dist-newstyle/build/*/*/*/build/stack/stack
|
|
vlicense LICENSE
|
|
}
|