dnsmasqv2.69pretest920140213
[tomato.git] / release / src / router / dnsmasq / bld / pkg-wrapper
blobefb848a97a373c2eac7d41a86b6416ec824cb85f
1 #!/bin/sh
3 search=$1
4 shift
5 pkg=$1
6 shift
7 op=$1
8 shift
10 in=`cat`
12 if grep "^\#[[:space:]]*define[[:space:]]*$search" config.h >/dev/null 2>&1 || \
13 echo $in | grep $search >/dev/null 2>&1; then
15 if [ $op = "--copy" ]; then
16 pkg="$*"
17 else
18 pkg=`$pkg $op $*`
21 if grep "^\#[[:space:]]*define[[:space:]]*${search}_STATIC" config.h >/dev/null 2>&1 || \
22 echo $in | grep ${search}_STATIC >/dev/null 2>&1; then
23 if [ $op = "--libs" ] || [ $op = "--copy" ]; then
24 echo "-Wl,-Bstatic $pkg -Wl,-Bdynamic"
25 else
26 echo "$pkg"
28 else
29 echo "$pkg"