aboutsummaryrefslogtreecommitdiff
path: root/svn
diff options
context:
space:
mode:
authorEinhard Leichtfuß <alguien@respiranto.de>2022-04-29 20:50:20 +0200
committerEinhard Leichtfuß <alguien@respiranto.de>2022-04-29 20:50:20 +0200
commitcf41d66d911beaf3c65906c9d40a95f38bcbd681 (patch)
tree1a4e223925110b91a7a3abcd47a61c686337ae3a /svn
parent4c3e069581b71b5a50a997f932936628f3729b9d (diff)
Fix svn PKGBUILD: move sources to $_lang
This required allowing a fixed prepare() function and, for the optional, dictionary-specific prepare() part to be inserted into such a fixed prepare() function.
Diffstat (limited to 'svn')
-rw-r--r--svn/sample.PKGBUILD16
1 files changed, 11 insertions, 5 deletions
diff --git a/svn/sample.PKGBUILD b/svn/sample.PKGBUILD
index db637a3..a29aaf0 100644
--- a/svn/sample.PKGBUILD
+++ b/svn/sample.PKGBUILD
@@ -21,18 +21,24 @@ install="${pkgname}.install"
source=("${pkgname}::svn+https://github.com/freedict/fd-dictionaries/trunk/${_lang}")
sha512sums=('SKIP')
-%PREPARE%
+prepare()
+{
+ # The Makefile expects the TEI XML file to reside in a directory named
+ # ${_lang}.
+ mv "$pkgname" "$_lang"
+%PREPARE_CONTENT%
+}
pkgver()
{
- cd "$pkgname"
+ cd "$_lang"
local _ver="$(svnversion)"
printf "r%s" "${_ver//[[:alpha:]]}"
}
build()
{
- cd "$pkgname"
+ cd "$_lang"
make FREEDICT_TOOLS=/usr/lib/freedict-tools build-dictd
}
@@ -40,9 +46,9 @@ package()
{
install -m 755 -d "${pkgdir}/usr/share/dictd"
install -m 644 -t "${pkgdir}/usr/share/dictd/" \
- "${pkgname}/build/dictd/${_lang}".{dict.dz,index}
+ "${_lang}/build/dictd/${_lang}".{dict.dz,index}
- for file in "$pkgname"/{AUTHORS,README,NEWS,ChangeLog}
+ for file in "$_lang"/{AUTHORS,README,NEWS,ChangeLog}
do
if test -f "$file"
then