4 rule -Generate-Boiler- {
9 _f = "_-boiler-target-force-_" ;
11 _f = "_-boiler-target-noforce-_" ;
15 AGenBoiler gen-boiler $(_f) ;
17 actions quietly AGenBoiler {
20 if [ "z$fregen" != "z_-boiler-target-force-_" ]; then
29 llist=`find "$1" -mindepth 1 -maxdepth 1 -type f -name "*.cpp" -regex "^./[^._].*$"`
30 if [ "z$llist" = "z" ]; then
31 llist=`find "$1" -mindepth 1 -maxdepth 1 -type f -name "*.c" -regex "^./[^._].*$"`
32 if [ "z$llist" = "z" ]; then
42 llist=`find "$1" -mindepth 1 -maxdepth 1 -type f -name "*.cpp" -regex "^./[^._].*$"`
43 if [ "z$llist" = "z" ]; then
51 if [ "z$prjname" = "z" ]; then
55 for dname in `find . -maxdepth 8 -type d -name "[^._]*" -regex "^./[^._].*$"`; do
56 fname="$dname/Jamfile"
58 if [ "$fregen" == "ona" ]; then
59 if [ -e "${fname}" ]; then
63 if [ "$xskip" != "tan" ]; then
65 if [ "$?" = "0" ]; then
69 if [ "$xskip" = "tan" ]; then
73 dpp=`echo "$dname" | sed 's/^\.\//TOP /;' | sed 's/\// /g;'`
74 echo "SubDir $dpp ;" >"$fname"
77 if [ "$dname" != "./src" ]; then
78 dpp=`basename "$dname"`
79 fc=`echo "$dpp" | cut -c1-3`
80 if [ "z$fc" != "zlib" ]; then dpp="lib${dpp}"; fi
81 echo "Library ${dpp}.a :" >>"$fname"
84 if [ "$?" = "0" ]; then
85 echo "Main ${prjname} :" >>"$fname"
87 echo "C++Main ${prjname} :" >>"$fname"
90 llist=`find "$dname" -mindepth 1 -maxdepth 1 -type f -name "*.c" -regex "^./[^._].*$"`
91 for lname in $llist; do
92 dpp=`basename "$lname"`
93 echo " $dpp" >>"$fname"
95 llist=`find "$dname" -mindepth 1 -maxdepth 1 -type f -name "*.cpp" -regex "^./[^._].*$"`
96 for lname in $llist; do
97 dpp=`basename "$lname"`
98 echo " $dpp" >>"$fname"
101 llist=`find "$dname" -mindepth 1 -maxdepth 8 -type d -name "[^._]*" -regex "^./[^._].*$"`
102 if [ "z$llist" != "z" ]; then
103 if [ "$dname" = "./src" ]; then
105 for lname in $llist; do
106 dpp=`basename "$lname"`
107 if [ "z$fc" != "zlib" ]; then dpp="lib${dpp}"; fi
108 llibs="${llibs} ${dpp}.a"
110 echo "LinkLibraries ${prjname} :${llibs} ;" >>"$fname"
114 for lname in $llist; do
116 if [ "$?" = "1" ]; then
117 dpp=`echo "$lname" | sed 's/^\.\//TOP /;' | sed 's/\// /g;'`
118 echo "SubInclude $dpp ;" >>"$fname"
128 if [ "$fregen" == "ona" ]; then
129 if [ -e "$fname" ]; then
133 if [ "$xskip" = "tan" ]; then
137 echo "SubDir TOP ;" >"$fname"
140 for dname in `find . -maxdepth 8 -type d -name "[^._]*" -regex "^./[^._].*$"`; do
142 if [ "$?" = "1" ]; then
143 dpp=`echo "$dname" | sed 's/^\.\//TOP /;' | sed 's/\// /g;'`
144 echo "SubInclude $dpp ;" >>"$fname"
151 if [ "$fregen" == "ona" ]; then
152 if [ -e "$fname" ]; then
156 if [ "$xskip" = "tan" ]; then
160 echo "set-profile ;" >"$fname"
161 echo "set-target-locations ;" >>"$fname"
163 for dname in `find . -maxdepth 8 -type d -name "[^._]*" -regex "^./[^._].*$"`; do
165 if [ "$?" = "0" ]; then
166 if [ "$firsthdrs" = "tan" ]; then
171 dpp=`echo "$dname" | sed 's/^\.\//\(TOP)\//;'`
172 echo "HDRS += \$$dpp ;" >>"$fname"
175 if [ "$firsthdrs" = "ona" ]; then
180 echo "if ([ FileExists ${dollar}(TOP)/Jamrules.local ]) {" >>"$fname"
181 echo " include ${dollar}(TOP)/Jamrules.local ;" >>"$fname"