| 1 | #!/bin/bashscip-shell filesystem . . `/bin/bash`. |
| 2 | # |
| 3 | # This script checks if cross compiling ECL itself from x86 to x86_64 |
| 4 | # and vice versa works. It assumes that you are running an x86_64 |
| 5 | # system which can also run and compile x86 programs. You might have |
| 6 | # to install additional packages for that (for example on debian, the |
| 7 | # gcc-multilib package is needed). |
| 8 | # |
| 9 | # Four versions of ECL will be compiled: |
| 10 | # - ecl-x86[_64]-native: direct (i.e. same host and target) x86[_64] build |
| 11 | # - ecl-x86[_64]-native: cross build for x86[_64] target |
| 12 | # |
| 13 | # The results of running the test suite will be put in the files |
| 14 | # test-results-x86[_64]-[native/cross]. It is recommended to also run |
| 15 | # the ansi-tests for the output binaries. |
| 16 | # |
| 17 | set -e |
| 18 | rmscip-shell system . . rm. -rf build/; CFLAGS="-g -O2" ./configure --prefix=`pwdscip-shell system . . pwd.`/ecl-x86_64-native && makescip-shell system . . make. -j${JOBS} && rmscip-shell system . . rm. -rf ecl-x86_64-native && makescip-shell system . . make. install && makescip-shell system . . make. check > test-results-x86_64-native |
| 19 | rmscip-shell system . . rm. -rf build/; ABI=32 CFLAGS="-g -O2 -m32" LDFLAGS="-m32" ./configure --prefix=`pwdscip-shell system . . pwd.`/ecl-x86-native && makescip-shell system . . make. -j${JOBS} && rmscip-shell system . . rm. -rf ecl-x86-native && makescip-shell system . . make. install && makescip-shell system . . make. check > test-results-x86-native |
| 20 | rmscip-shell system . . rm. -rf build/; CFLAGS="-g -O2" ECL_TO_RUN=`pwdscip-shell system . . pwd.`/ecl-x86-native/bin/ecl ./configure --prefix=`pwdscip-shell system . . pwd.`/ecl-x86_64-cross --build=x86_64-pc-linux-gnu --host=x86-pc-linux-gnu --with-cross-config=`pwdscip-shell system . . pwd.`/src/util/x86_64-linux-gnu.cross_config && makescip-shell system . . make. -j${JOBS} && rmscip-shell system . . rm. -rf ecl-x86_64-cross && makescip-shell system . . make. install && makescip-shell system . . make. check > test-results-x86_64-cross |
| 21 | rmscip-shell system . . rm. -rf build/; ABI=32 CFLAGS="-g -O2 -m32" LDFLAGS="-m32" ECL_TO_RUN=`pwdscip-shell system . . pwd.`/ecl-x86_64-native/bin/ecl ./configure --prefix=`pwdscip-shell system . . pwd.`/ecl-x86-cross --build=x86-pc-linux-gnu --host=x86_64-pc-linux-gnu --with-cross-config=`pwdscip-shell system . . pwd.`/src/util/x86-linux-gnu.cross_config && makescip-shell system . . make. -j${JOBS} && rmscip-shell system . . rm. -rf ecl-x86-cross && makescip-shell system . . make. install && makescip-shell system . . make. check > test-results-x86-cross |