]> git.proxmox.com Git - ceph.git/blob - ceph/src/boost/libs/regex/build/bc_gen.sh
bump version to 12.2.2-pve1
[ceph.git] / ceph / src / boost / libs / regex / build / bc_gen.sh
1 #! /bin/bash
2
3 # copyright John Maddock 2003
4 # Distributed under the Boost Software License, Version 1.0.
5 # (See accompanying file LICENSE_1_0.txt or copy at
6 # http://www.boost.org/LICENSE_1_0.txt.
7
8 libname=""
9 src=""
10 header=""
11 all_dep=""
12
13 # current makefile:
14 out=""
15 # temporary file:
16 tout=""
17 # install target temp file:
18 iout=""
19 # debug flag:
20 debug="no"
21 # compile options:
22 opts=""
23 # main output sub-directory:
24 subdir=""
25
26 #######################################################################
27 #
28 # section for C++ Builder
29 #
30 #######################################################################
31
32 function bcb_gen_lib()
33 {
34 all_dep="$all_dep $subdir\\$libname $subdir\\$libname.lib"
35 echo " copy $subdir\\$libname.lib \$(BCROOT)\\lib" >> $iout
36 #
37 # set up section comments:
38 cat >> $tout << EOF
39 ########################################################
40 #
41 # section for $libname.lib
42 #
43 ########################################################
44 EOF
45 #
46 # process source files:
47 all_obj=""
48 all_lib_obj=""
49 for file in $src
50 do
51 obj=`echo "$file" | sed 's/.*src\/\(.*\)cpp/\1obj/g'`
52 obj="$subdir\\$libname\\$obj"
53 all_obj="$all_obj $obj"
54 all_lib_obj="$all_lib_obj +\"$obj\""
55 echo "$obj: $file \$(ALL_HEADER)" >> $tout
56 echo " bcc32 @&&|" >> $tout
57 echo "-c \$(INCLUDES) $opts \$(CXXFLAGS) -o$obj $file" >> $tout
58 echo "|" >> $tout
59 echo "" >> $tout
60 done
61 #
62 # now for the directories for this library:
63 echo "$subdir\\$libname : " >> $tout
64 echo " -@mkdir $subdir\\$libname" >> $tout
65 echo "" >> $tout
66 #
67 # now for the clean options for this library:
68 all_clean="$all_clean $libname""_clean"
69 echo "$libname"_clean : >> $tout
70 echo " del $subdir\\$libname\\"'*.obj' >> $tout
71 echo " del $subdir\\$libname\\"'*.il?' >> $tout
72 echo " del $subdir\\$libname\\"'*.csm' >> $tout
73 echo " del $subdir\\$libname\\"'*.tds' >> $tout
74 echo "" >> $tout
75 #
76 # now for the main target for this library:
77 echo $subdir\\$libname.lib : $all_obj >> $tout
78 echo " if exist $subdir\\$libname.lib del $subdir\\$libname.lib " >> $tout
79 echo " tlib @&&|" >> $tout
80 echo "/P128 /C /u /a \$(XSFLAGS) \"$subdir\\$libname.lib\" $all_lib_obj" >> $tout
81 echo "|" >> $tout
82 echo "" >> $tout
83 }
84
85 function bcb_gen_dll()
86 {
87 all_dep="$all_dep $subdir\\$libname $subdir\\$libname.lib"
88 echo " copy $subdir\\$libname.lib \$(BCROOT)\\lib" >> $iout
89 echo " copy $subdir\\$libname.dll \$(BCROOT)\\bin" >> $iout
90 echo " copy $subdir\\$libname.tds \$(BCROOT)\\bin" >> $iout
91 #
92 # set up section comments:
93 cat >> $tout << EOF
94 ########################################################
95 #
96 # section for $libname.lib
97 #
98 ########################################################
99 EOF
100 #
101 # process source files:
102 all_obj=""
103 for file in $src
104 do
105 obj=`echo "$file" | sed 's/.*src\/\(.*\)cpp/\1obj/g'`
106 obj="$subdir\\$libname\\$obj"
107 all_obj="$all_obj $obj"
108 echo "$obj: $file \$(ALL_HEADER)" >> $tout
109 echo " bcc32 @&&|" >> $tout
110 echo "-c \$(INCLUDES) $opts \$(CXXFLAGS) -DBOOST_REGEX_DYN_LINK -o$obj $file" >> $tout
111 echo "|" >> $tout
112 echo "" >> $tout
113 done
114 #
115 # now for the directories for this library:
116 echo "$subdir\\$libname :" >> $tout
117 echo " -@mkdir $subdir\\$libname" >> $tout
118 echo "" >> $tout
119 #
120 # now for the clean options for this library:
121 all_clean="$all_clean $libname""_clean"
122 echo "$libname"_clean : >> $tout
123 echo " del $subdir\\$libname\\"'*.obj' >> $tout
124 echo " del $subdir\\$libname\\"'*.il?' >> $tout
125 echo " del $subdir\\$libname\\"'*.csm' >> $tout
126 echo " del $subdir\\$libname\\"'*.tds' >> $tout
127 echo " del $subdir\\"'*.tds' >> $tout
128 echo "" >> $tout
129 #
130 # now for the main target for this library:
131 echo $subdir\\$libname.lib : $all_obj >> $tout
132 echo " bcc32 @&&|" >> $tout
133 echo "-lw-dup -lw-dpl $opts -e$subdir\\$libname.dll \$(XLFLAGS) $all_obj \$(LIBS)" >> $tout
134 echo "|" >> $tout
135 echo " implib -w $subdir\\$libname.lib $subdir\\$libname.dll" >> $tout
136 echo "" >> $tout
137 }
138
139
140
141 function bcb_gen()
142 {
143 tout="temp"
144 iout="temp_install"
145 all_dep="$subdir"
146 all_clean=""
147 echo > $out
148 echo > $tout
149 rm -f $iout
150
151 libname="libboost_regex-${subdir}-s-${boost_version}"
152 opts="-tWM- -D_NO_VCL -O2 -Ve -Vx -w-inl -w-aus -w-rch -w-8012 -w-8037 -w-8057 -DSTRICT; -I\$(BCROOT)\include;../../../"
153 bcb_gen_lib
154
155 libname="libboost_regex-${subdir}-mt-s-${boost_version}"
156 opts="-tWM -D_NO_VCL -O2 -Ve -Vx -w-inl -w-aus -w-rch -w-8012 -w-8057 -w-8037 -DSTRICT; -I\$(BCROOT)\include;../../../"
157 bcb_gen_lib
158
159 libname="boost_regex-${subdir}-mt-${boost_version}"
160 opts="-tWD -tWM -tWR -D_NO_VCL -D_RTLDLL -O2 -Ve -Vx -w-inl -w-aus -w-rch -w-8012 -w-8057 -w-8037 -DSTRICT; -I\$(BCROOT)\include;../../../ -L\$(BCROOT)\lib;\$(BCROOT)\lib\release;"
161 bcb_gen_dll
162
163 libname="boost_regex-${subdir}-${boost_version}"
164 opts="-tWD -tWR -tWM- -D_NO_VCL -D_RTLDLL -O2 -Ve -Vx -w-inl -w-aus -w-rch -w-8012 -w-8057 -w-8037 -DSTRICT; -I\$(BCROOT)\include;../../../ -L\$(BCROOT)\lib;\$(BCROOT)\lib\release;"
165 bcb_gen_dll
166
167 libname="libboost_regex-${subdir}-mt-${boost_version}"
168 opts="-tWD -tWM -tWR -DBOOST_REGEX_STATIC_LINK -D_NO_VCL -D_RTLDLL -O2 -Ve -Vx -w-inl -w-aus -w-rch -w-8012 -w-8057 -w-8037 -DSTRICT; -I\$(BCROOT)\include;../../../ -L\$(BCROOT)\lib;\$(BCROOT)\lib\release;"
169 bcb_gen_lib
170
171 libname="libboost_regex-${subdir}-${boost_version}"
172 opts="-tWD -tWR -tWM- -DBOOST_REGEX_STATIC_LINK -D_NO_VCL -D_RTLDLL -O2 -Ve -Vx -w-inl -w-aus -w-rch -w-8012 -w-8057 -w-8037 -DSTRICT; -I\$(BCROOT)\include;../../../ -L\$(BCROOT)\lib;\$(BCROOT)\lib\release;"
173 bcb_gen_lib
174
175 libname="libboost_regex-${subdir}-sd-${boost_version}"
176 opts="-tWM- -D_NO_VCL -v -Ve -Vx -w-inl -w-aus -w-rch -w-8012 -w-8037 -w-8057 -DSTRICT; -I\$(BCROOT)\include;../../../"
177 bcb_gen_lib
178
179 libname="libboost_regex-${subdir}-mt-sd-${boost_version}"
180 opts="-tWM -D_NO_VCL -v -Ve -Vx -w-inl -w-aus -w-rch -w-8012 -w-8057 -w-8037 -DSTRICT; -I\$(BCROOT)\include;../../../"
181 bcb_gen_lib
182
183 libname="boost_regex-${subdir}-mt-d-${boost_version}"
184 opts="-tWD -tWM -tWR -D_NO_VCL -D_RTLDLL -v -Ve -Vx -w-inl -w-aus -w-rch -w-8012 -w-8057 -w-8037 -DSTRICT; -I\$(BCROOT)\include;../../../ -L\$(BCROOT)\lib;\$(BCROOT)\lib\release;"
185 bcb_gen_dll
186
187 libname="boost_regex-${subdir}-d-${boost_version}"
188 opts="-tWD -tWR -tWM- -D_NO_VCL -D_RTLDLL -v -Ve -Vx -w-inl -w-aus -w-rch -w-8012 -w-8057 -w-8037 -DSTRICT; -I\$(BCROOT)\include;../../../ -L\$(BCROOT)\lib;\$(BCROOT)\lib\release;"
189 bcb_gen_dll
190
191 libname="libboost_regex-${subdir}-mt-d-${boost_version}"
192 opts="-tWD -tWM -tWR -DBOOST_REGEX_STATIC_LINK -D_NO_VCL -D_RTLDLL -v -Ve -Vx -w-inl -w-aus -w-rch -w-8012 -w-8057 -w-8037 -DSTRICT; -I\$(BCROOT)\include;../../../ -L\$(BCROOT)\lib;\$(BCROOT)\lib\release;"
193 bcb_gen_lib
194
195 libname="libboost_regex-${subdir}-d-${boost_version}"
196 opts="-tWD -tWR -tWM- -DBOOST_REGEX_STATIC_LINK -D_NO_VCL -D_RTLDLL -v -Ve -Vx -w-inl -w-aus -w-rch -w-8012 -w-8057 -w-8037 -DSTRICT; -I\$(BCROOT)\include;../../../ -L\$(BCROOT)\lib;\$(BCROOT)\lib\release;"
197 bcb_gen_lib
198
199 cat > $out << EOF
200 # copyright John Maddock 2006
201 # Distributed under the Boost Software License, Version 1.0.
202 # (See accompanying file LICENSE_1_0.txt or copy at
203 # http://www.boost.org/LICENSE_1_0.txt.
204 #
205 # auto generated makefile for C++ Builder
206 #
207 # usage:
208 # make
209 # brings libraries up to date
210 # make install
211 # brings libraries up to date and copies binaries to your C++ Builder /lib and /bin directories (recomended)
212 # make clean
213 # removes all temporary files.
214
215 #
216 # Add additional compiler options here:
217 #
218 CXXFLAGS=
219 #
220 # Add additional include directories here:
221 #
222 INCLUDES=
223 #
224 # add additional linker flags here:
225 #
226 XLFLAGS=
227 #
228 # add additional libraries to link to here:
229 #
230 LIBS=
231 #
232 # add additional static-library creation flags here:
233 #
234 XSFLAGS=
235
236 !ifndef BCROOT
237 BCROOT=\$(MAKEDIR)\\..
238 !endif
239
240 EOF
241 echo "" >> $out
242 echo "ALL_HEADER=$header" >> $out
243 echo "" >> $out
244 echo "all : $all_dep" >> $out
245 echo >> $out
246 echo "clean : $all_clean" >> $out
247 echo >> $out
248 echo "install : all" >> $out
249 cat $iout >> $out
250 echo >> $out
251 echo $subdir : >> $out
252 echo " -@mkdir $subdir" >> $out
253 echo "" >> $out
254
255 cat $tout >> $out
256 }
257
258 . common.sh
259
260 #
261 # generate C++ Builder 6 files:
262 out="bcb6.mak"
263 subdir="bcb"
264 has_stlport="yes"
265 bcb_gen
266
267
268
269
270
271