1a06b0d5d7
```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 ```
57 lines
1.5 KiB
Bash
57 lines
1.5 KiB
Bash
# Template file for 'jedit'
|
|
pkgname=jedit
|
|
version=5.6.0
|
|
revision=1
|
|
wrksrc=jEdit
|
|
hostmakedepends="apache-ant openjdk11 docbook-xsl"
|
|
depends="openjdk11 desktop-file-utils"
|
|
short_desc="Plugin-based editor for programmers"
|
|
maintainer="q66 <daniel@octaforge.org>"
|
|
license="GPL-2.0-or-later"
|
|
homepage="http://jedit.org"
|
|
distfiles="${SOURCEFORGE_SITE}/${pkgname}/${version}/${pkgname}${version}source.tar.bz2"
|
|
checksum=76c16ae0168d9b64ecddd8bf08aa49ab352adb2c9687191bc71895a96a8dfe1d
|
|
|
|
post_patch() {
|
|
# skip junit stuff, fails in chroot
|
|
vsed -i 's/,test//' build.xml
|
|
}
|
|
|
|
do_build() {
|
|
. /etc/profile.d/apache-ant.sh
|
|
. /etc/profile.d/10_openjdk11.sh
|
|
|
|
ant -propertyfile ${FILESDIR}/build.properties build
|
|
ant -propertyfile ${FILESDIR}/build.properties docs-html
|
|
}
|
|
|
|
do_install() {
|
|
# stuff from build/
|
|
vmkdir usr/share/jedit
|
|
vinstall build/jedit.jar 644 usr/share/jedit
|
|
vcopy build/jars usr/share/jedit
|
|
vcopy build/keymaps usr/share/jedit
|
|
vcopy build/macros usr/share/jedit
|
|
vcopy build/modes usr/share/jedit
|
|
vcopy build/properties usr/share/jedit
|
|
vcopy build/startup usr/share/jedit
|
|
|
|
# documentation
|
|
vmkdir usr/share/doc/${pkgname}
|
|
vcopy "build/doc/*" usr/share/doc/${pkgname}
|
|
|
|
# man page
|
|
cp package-files/linux/jedit.1 build
|
|
vsed -i "s,@jedit.version@,${version},g" build/jedit.1
|
|
vman build/jedit.1
|
|
|
|
# desktop file
|
|
vmkdir usr/share/applications
|
|
cp package-files/linux/deb/jedit.desktop build
|
|
vsed -i "s,usr/share/jEdit/doc,usr/share/doc/${pkgname},g" \
|
|
build/jedit.desktop
|
|
vinstall build/jedit.desktop 755 usr/share/applications
|
|
|
|
# launcher
|
|
vbin ${FILESDIR}/jedit
|
|
}
|