blob: dc7bd794c6a0f4d9fe5beec2a888a711a420b8ac (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
|
#!/bin/sh
# This is a hack to allow per target cflags. It isn't very elegant, but it
# is the most portable idea we have come up with yet
# tridge@samba.org, July 2005
TARGET=$1
check_flags()
{
NAME=$1
(
while read tag flags; do
if [ "$tag" = "$NAME" ] || [ "./$tag" = "$NAME" ]; then
echo "$flags"
exit 0;
fi
done
) < extra_cflags.txt
}
NAME=$TARGET
while [ "$NAME" != "." ]; do
check_flags "$NAME"
NAME=`dirname $NAME`
done
exit 0;
|