|
|
@ -3,7 +3,7 @@ |
|
|
|
# This copyright note is auto-generated by ./scripts/Create-CopyPatch. |
|
|
|
# |
|
|
|
# Filename: bin/sde-build-tools |
|
|
|
# Copyright (C) 2006 - 2009 The OpenSDE Project |
|
|
|
# Copyright (C) 2006 - 2010 The OpenSDE Project |
|
|
|
# Copyright (C) 2004 - 2006 The T2 SDE Project |
|
|
|
# Copyright (C) 1998 - 2003 Clifford Wolf |
|
|
|
# |
|
|
@ -322,23 +322,34 @@ EOT |
|
|
|
|
|
|
|
# Create Parse-Config Collection |
|
|
|
# |
|
|
|
prio_find() { |
|
|
|
local name="$1"; shift |
|
|
|
local mode="$1"; shift |
|
|
|
|
|
|
|
wrapper() { |
|
|
|
if [ "$mode" = "preserve" ]; then |
|
|
|
grep -n ^ |
|
|
|
else |
|
|
|
sed -e "s|^|$mode:|" |
|
|
|
fi |
|
|
|
} |
|
|
|
|
|
|
|
bin/find "$@" -type f '(' -name "$name" -o -name "$name-[0-9]" ')' | wrapper | |
|
|
|
sed -e "s|^.*/$name\$|5:\0|" -e "s|^.*/$name-\(.\)\$|\1\:\0|" -e 's|/\./|/|' |
|
|
|
} |
|
|
|
|
|
|
|
echo_status "Creating $toolsdir/lib/parse-config." |
|
|
|
bin/find \ |
|
|
|
architecture/$arch/. lib/*/. package/. $( get_reverted `get_expanded target/%/. $targetchain` ) -type f \ |
|
|
|
'(' -name 'parse-config' -o -name 'parse-config-[0-9]' ')' \ |
|
|
|
-printf '%f\t%p\n' | sed \ |
|
|
|
-e 's,^parse-config\t,5\t,g' -e 's,^parse-config-\(.\)\t,\1\t,g' | \ |
|
|
|
sort -n | awk '{ $1="."; print; }' \ |
|
|
|
| grep -v lib/output/ \ |
|
|
|
> $TOOLSDIR/lib/parse-config.$$ |
|
|
|
( |
|
|
|
prio_find parse-config 0 architecture/$arch/. lib/*/. package/. | grep -v lib/output |
|
|
|
prio_find parse-config preserve $( get_reverted `get_expanded target/%/. $targetchain` ) |
|
|
|
) | sort -n -t: | sed -e 's|^....|\. |' > $TOOLSDIR/lib/parse-config.$$ |
|
|
|
mv $TOOLSDIR/lib/parse-config.$$ \ |
|
|
|
$TOOLSDIR/lib/parse-config |
|
|
|
|
|
|
|
bin/find \ |
|
|
|
architecture/$arch/. lib/*/. package/. $( get_reverted `get_expanded target/%/. $targetchain` ) -type f \ |
|
|
|
-name 'parse-config-fixarch' \ |
|
|
|
-printf '%f\t%p\n' | sort | awk '{ $1="."; print; }' \ |
|
|
|
> $TOOLSDIR/lib/parse-config-fixarch.$$ |
|
|
|
( |
|
|
|
prio_find parse-config-fixarch 0 architecture/$arch/. lib/*/. package/. | grep -v lib/output |
|
|
|
prio_find parse-config-fixarch preserve $( get_reverted `get_expanded target/%/. $targetchain` ) |
|
|
|
) | sort -n -t: | sed -e 's|^....|\. |' > $TOOLSDIR/lib/parse-config-fixarch.$$ |
|
|
|
mv $TOOLSDIR/lib/parse-config-fixarch.$$ \ |
|
|
|
$TOOLSDIR/lib/parse-config-fixarch |
|
|
|
|
|
|
|