mirror of
ssh://git.janware.com/srv/git/janware/proj/jw-pkg
synced 2026-01-15 03:53:32 +01:00
create-pkg-config.sh: Fix search path for jw-build-functions.sh
Signed-off-by: Jan Lindemann <jan@janware.com>
This commit is contained in:
parent
32e4a703d7
commit
735fe13720
1 changed files with 28 additions and 2 deletions
|
|
@ -1,10 +1,26 @@
|
|||
#!/bin/bash
|
||||
|
||||
log()
|
||||
{
|
||||
echo $@
|
||||
}
|
||||
|
||||
err()
|
||||
{
|
||||
echo $@ >&2
|
||||
}
|
||||
|
||||
fatal()
|
||||
{
|
||||
err "Fatal: $@"
|
||||
exit 1
|
||||
}
|
||||
|
||||
try_assign_sec()
|
||||
{
|
||||
local file="$1"
|
||||
local sec="$2"
|
||||
local val=`_jw-build_cat_section "$file" "$sec"`
|
||||
local val=`_jwbuild_cat_section "$file" "$sec"`
|
||||
[ -n "$val" ] && eval $3=\"$val\"
|
||||
}
|
||||
|
||||
|
|
@ -106,7 +122,17 @@ shift
|
|||
set +e
|
||||
|
||||
[ -r "$project_descr_file" ] && {
|
||||
. jw-build-functions.sh
|
||||
|
||||
build_functions_sh=jw-build-functions.sh
|
||||
for d in `dirname $0`; do
|
||||
[ -f "$d/$build_functions_sh" ] && {
|
||||
build_functions_sh_path=$d/$build_functions_sh
|
||||
break
|
||||
}
|
||||
done
|
||||
[ "$build_functions_sh_path" ] || fatal "$build_functions_sh not found"
|
||||
. $build_functions_sh_path
|
||||
|
||||
try_assign_sec $project_descr_file description descr
|
||||
try_assign_sec $project_descr_file summary summary
|
||||
try_assign_sec $project_descr_file requires_run requires_run
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue