aboutsummaryrefslogtreecommitdiff
path: root/update.sh
diff options
context:
space:
mode:
Diffstat (limited to 'update.sh')
-rwxr-xr-xupdate.sh76
1 files changed, 3 insertions, 73 deletions
diff --git a/update.sh b/update.sh
index 435c888..7222266 100755
--- a/update.sh
+++ b/update.sh
@@ -208,82 +208,12 @@ $CP $libssl_regress/ssl/testssl tests
208for i in `find $libssl_regress -name '*.c'`; do 208for i in `find $libssl_regress -name '*.c'`; do
209 $CP "$i" tests 209 $CP "$i" tests
210done 210done
211
211$CP $libssl_regress/certs/ca.pem tests 212$CP $libssl_regress/certs/ca.pem tests
212$CP $libssl_regress/certs/server.pem tests 213$CP $libssl_regress/certs/server.pem tests
213
214# setup test drivers
215# do not directly run all test programs
216test_drivers=(
217 aeadtest
218 evptest
219 pq_test
220 ssltest
221 arc4randomforktest
222 pidwraptest
223)
224tests_posix_only=(
225 arc4randomforktest
226 explicit_bzero
227 pidwraptest
228)
229# the BIO tests rely on resolver results that are OS and environment-specific
230# explicit_bzero relies on SA_ONSTACK, not available on all systems
231# pidwraptest relies on an OS-specific way to give out pids and is generally
232# awkward on systems with slow fork
233tests_disabled=(
234 biotest
235 explicit_bzero
236 pidwraptest
237)
238$CP $libc_src/string/memmem.c tests/
239(cd tests
240 $CP Makefile.am.tpl Makefile.am
241
242 for i in `ls -1 *.c|sort|grep -v memmem.c`; do
243 TEST=`echo $i|sed -e "s/\.c//"`
244 if ! [[ ${tests_disabled[*]} =~ "$TEST" ]]; then
245 if [[ ${tests_posix_only[*]} =~ "$TEST" ]]; then
246 echo "if !HOST_WIN" >> Makefile.am
247 fi
248 if ! [[ ${test_drivers[*]} =~ "$TEST" ]]; then
249 echo "TESTS += $TEST" >> Makefile.am
250 fi
251 echo "check_PROGRAMS += $TEST" >> Makefile.am
252 echo "${TEST}_SOURCES = $i" >> Makefile.am
253 if [[ ${TEST} = "explicit_bzero" ]]; then
254 echo "if !HAVE_MEMMEM" >> Makefile.am
255 echo "explicit_bzero_SOURCES += memmem.c" >> Makefile.am
256 echo "endif" >> Makefile.am
257 fi
258 if [[ ${tests_posix_only[*]} =~ "$TEST" ]]; then
259 echo "endif" >> Makefile.am
260 fi
261 fi
262 done
263)
264$CP $libcrypto_regress/evp/evptests.txt tests
265$CP $libcrypto_regress/aead/aeadtests.txt tests
266$CP $libcrypto_regress/pqueue/expected.txt tests/pq_expected.txt
267chmod 755 tests/testssl 214chmod 755 tests/testssl
268for i in "${test_drivers[@]}"; do
269 if [ -e tests/${i}.sh ]; then
270 if ! [[ ${tests_disabled[*]} =~ "$i" ]]; then
271 if [[ ${tests_posix_only[*]} =~ "$i" ]]; then
272 echo "if !HOST_WIN" >> tests/Makefile.am
273 fi
274 echo "TESTS += ${i}.sh" >> tests/Makefile.am
275 if [[ ${tests_posix_only[*]} =~ "$i" ]]; then
276 echo "endif" >> tests/Makefile.am
277 fi
278 echo "EXTRA_DIST += ${i}.sh" >> tests/Makefile.am
279 fi
280 fi
281done
282echo "EXTRA_DIST += aeadtests.txt" >> tests/Makefile.am
283echo "EXTRA_DIST += evptests.txt" >> tests/Makefile.am
284echo "EXTRA_DIST += pq_expected.txt" >> tests/Makefile.am
285echo "EXTRA_DIST += testssl ca.pem server.pem" >> tests/Makefile.am
286 215
216# add headers
287(cd include/openssl 217(cd include/openssl
288 $CP Makefile.am.tpl Makefile.am 218 $CP Makefile.am.tpl Makefile.am
289 for i in `ls -1 *.h|sort`; do 219 for i in `ls -1 *.h|sort`; do
@@ -291,8 +221,8 @@ echo "EXTRA_DIST += testssl ca.pem server.pem" >> tests/Makefile.am
291 done 221 done
292) 222)
293 223
294echo "copying manpages"
295# copy manpages 224# copy manpages
225echo "copying manpages"
296(cd man 226(cd man
297 $CP Makefile.am.tpl Makefile.am 227 $CP Makefile.am.tpl Makefile.am
298 228