Skip to content

Commit 5faab4a

Browse files
committed
Exclude things defined in test files from subdoc generation
1 parent f9fb763 commit 5faab4a

File tree

5 files changed

+15
-0
lines changed

5 files changed

+15
-0
lines changed

.github/workflows/subdoc.yml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -154,6 +154,8 @@ jobs:
154154
--out docs \
155155
--include-file-pattern /sus/ \
156156
--exclude-file-pattern /third_party/ \
157+
--exclude-file-pattern /test/ \
158+
--exclude-file-pattern test.cc \
157159
--copy-file subdoc/gen_tests/subdoc-test-style.css \
158160
--copy-file web/logo.png \
159161
--copy-file web/logo32.png \

.github/workflows/try.yml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -392,6 +392,8 @@ jobs:
392392
--out docs \
393393
--include-file-pattern /sus/ \
394394
--exclude-file-pattern /third_party/ \
395+
--exclude-file-pattern /test/ \
396+
--exclude-file-pattern test.cc \
395397
--copy-file subdoc/gen_tests/subdoc-test-style.css \
396398
--copy-file web/logo.png \
397399
--copy-file web/logo32.png \

tools/configure.sh

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@
99
# Default: true
1010
# * BENCHMARKS=[true|false] to build benchmarks.
1111
# Default: true
12+
# * USE_BREW=[true|false] to use clang/libc++ from homebrew on MacOS.
1213
#
1314
# Requires LLVM:
1415
# * SUBDOC=[true|false] to build subdoc. This requires an LLVM installation.
@@ -38,6 +39,7 @@ if [[ $LLVM_ROOT == "" ]]; then LLVM_ROOT=$HOME/s/llvm/install; fi
3839
if [[ $USE_ASAN == "" ]]; then USE_ASAN=false; fi
3940
if [[ $USE_LLD == "" ]]; then USE_LLD=false; fi
4041
if [[ $USE_LLVM_CLANG == "" ]]; then USE_LLVM_CLANG=false; fi
42+
if [[ $USE_BREW == "" ]]; then USE_BREW=false; fi
4143

4244
# System detection.
4345
if [[ $OSTYPE == darwin* ]]; then IS_MAC=true; else IS_MAC=false; fi
@@ -91,6 +93,11 @@ if [[ $IS_MAC == true && $USE_ASAN == true ]]; then
9193
RESOURCE_DIR=$($CLANG --print-resource-dir)
9294
run codesign -f -s - "$RESOURCE_DIR/lib/darwin/libclang_rt.asan_osx_dynamic.dylib"
9395
fi
96+
if [[ $USE_BREW == true ]]; then
97+
set_env CC="/opt/homebrew/opt/llvm/bin/clang"
98+
set_env CXX="/opt/homebrew/opt/llvm/bin/clang++"
99+
set_env LDFLAGS="-L/opt/homebrew/opt/llvm/lib/c++ -Wl,-rpath,/opt/homebrew/opt/llvm/lib/c++ $LDFLAGS"
100+
fi
94101

95102
set_env LLVM_DIR="$LLVM_ROOT/lib/cmake/llvm"
96103
set_env Clang_DIR="$LLVM_ROOT/lib/cmake/clang"

tools/run_subdoc.bat

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,8 @@
11
out\subdoc\subdoc -p out --out docs ^
22
--include-file-pattern /sus/ ^
33
--exclude-file-pattern /third_party/ ^
4+
--exclude-file-pattern /test/ ^
5+
--exclude-file-pattern test.cc ^
46
--css subdoc-test-style.css ^
57
--copy-file subdoc/gen_tests/subdoc-test-style.css ^
68
--copy-file web/logo.png ^

tools/run_subdoc.sh

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,8 @@
33
out/subdoc/subdoc -p out --out docs \
44
--include-file-pattern /sus/ \
55
--exclude-file-pattern /third_party/ \
6+
--exclude-file-pattern /test/ \
7+
--exclude-file-pattern test.cc \
68
--css subdoc-test-style.css \
79
--copy-file subdoc/gen_tests/subdoc-test-style.css \
810
--copy-file web/logo.png \

0 commit comments

Comments
 (0)