mirror of
https://github.com/boostorg/regex.git
synced 2025-07-24 01:27:36 +02:00
Add module support and tests. (#174)
This commit is contained in:
28
test/module/test_clang.sh
Executable file
28
test/module/test_clang.sh
Executable file
@ -0,0 +1,28 @@
|
||||
#!/bin/sh
|
||||
|
||||
#
|
||||
# Builds all of the tests in this folder using clang modules
|
||||
#
|
||||
: ${CXX:="clang++"}
|
||||
: ${CXXFLAGS:="-std=c++20 -g -I../../../.."}
|
||||
|
||||
rm *.o *.pcm *.exe
|
||||
|
||||
cmd="$CXX $CXXFLAGS -x c++-module ../../module/regex.cxx --precompile -o boost.regex.pcm"
|
||||
echo $cmd
|
||||
$cmd || exit 1
|
||||
cmd="$CXX $CXXFLAGS boost.regex.pcm -c -o regex.o"
|
||||
echo $cmd
|
||||
$cmd || exit 1
|
||||
cmd="$CXX $CXXFLAGS -fprebuilt-module-path=. -c ../../module/*.cpp"
|
||||
echo $cmd
|
||||
$cmd || exit 1
|
||||
|
||||
|
||||
for file in *.cpp; do
|
||||
|
||||
cmd="$CXX $CXXFLAGS -fprebuilt-module-path=. $file *.o -o ${file%.*}.exe"
|
||||
echo $cmd
|
||||
$cmd || exit 1
|
||||
|
||||
done
|
Reference in New Issue
Block a user