2017-08-27 06:07:06 +01:00
|
|
|
#!/bin/sh
|
|
|
|
|
2017-08-27 06:25:34 +01:00
|
|
|
set -x
|
|
|
|
|
2017-08-27 06:07:06 +01:00
|
|
|
export CC=clang-5.0
|
|
|
|
export CXX=clang++-5.0
|
|
|
|
which $CC
|
|
|
|
which $CXX
|
|
|
|
echo $PATH
|
|
|
|
mkdir build
|
|
|
|
cd build
|
2017-09-06 03:55:56 +01:00
|
|
|
cmake .. -DCMAKE_INSTALL_PREFIX=$(pwd) -DZIG_LIBC_LIB_DIR=$(dirname $($CC -print-file-name=crt1.o)) -DZIG_LIBC_INCLUDE_DIR=$(echo -n | $CC -E -x c - -v 2>&1 | grep -B1 "End of search list." | head -n1 | cut -c 2- | sed "s/ .*//") -DZIG_LIBC_STATIC_LIB_DIR=$(dirname $($CC -print-file-name=crtbegin.o))
|
2017-08-27 06:07:06 +01:00
|
|
|
make VERBOSE=1
|
|
|
|
make install
|
2017-09-06 03:55:56 +01:00
|
|
|
./zig build --build-file ../build.zig test
|