Trust non-returning functions during sb-xc.
[sbcl.git] / tests / lzcore.test.sh
blob63f608c91fd3ab0121a8720b62193cbda104de7f
1 #!/bin/sh
3 # tests related to compressed .core files
5 # This software is part of the SBCL system. See the README file for
6 # more information.
8 # While most of SBCL is derived from the CMU CL system, the test
9 # files (like this one) were written from scratch after the fork
10 # from CMU CL.
12 # This software is in the public domain and is provided with
13 # absolutely no warranty. See the COPYING and CREDITS files for
14 # more information.
16 . ./subr.sh
18 use_test_subdirectory
20 tmpcore=$TEST_FILESTEM.core
22 run_sbcl <<EOF
23 (save-lisp-and-die "$tmpcore" :toplevel (lambda () 42)
24 :compression (and (member :sb-core-compression *features*) t))
25 EOF
26 run_sbcl_with_core "$tmpcore" --noinform --no-userinit --no-sysinit \
27 --eval "(setf sb-ext:*evaluator-mode* :${TEST_SBCL_EVALUATOR_MODE:-compile})"
28 check_status_maybe_lose "SAVE-LISP-AND-DIE :COMPRESS" $? 0 "(compressed saved core ran)"
30 rm "$tmpcore"
31 run_sbcl <<EOF
32 (save-lisp-and-die "$tmpcore" :toplevel (lambda () 42) :executable t
33 :compression (and (member :sb-core-compression *features*) t))
34 EOF
35 chmod u+x "$tmpcore"
36 ./"$tmpcore" --no-userinit --no-sysinit
37 check_status_maybe_lose "SAVE-LISP-AND-DIE :EXECUTABLE-COMPRESS" $? 0 "(executable compressed saved core ran)"
39 exit $EXIT_TEST_WIN