Skip to content

Commit 7d323dc

Browse files
committed
Add Bazel support for LLVM_WINDOWS_PREFER_FORWARD_SLASH
This was added in df0ba47
1 parent 5fd406e commit 7d323dc

File tree

2 files changed

+6
-0
lines changed

2 files changed

+6
-0
lines changed

utils/bazel/llvm-project-overlay/llvm/config.bzl

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -36,6 +36,7 @@ posix_defines = [
3636
"HAVE_STRERROR_R=1",
3737
"HAVE_SYSEXITS_H=1",
3838
"HAVE_UNISTD_H=1",
39+
"LLVM_WINDOWS_PREFER_FORWARD_SLASH=0",
3940
]
4041

4142
linux_defines = posix_defines + [
@@ -70,6 +71,7 @@ win32_defines = [
7071
# LLVM features
7172
r'LTDL_SHLIB_EXT=\".dll\"',
7273
r'LLVM_PLUGIN_EXT=\".dll\"',
74+
"LLVM_WINDOWS_PREFER_FORWARD_SLASH=1",
7375
]
7476

7577
# TODO: We should switch to platforms-based config settings to make this easier

utils/bazel/llvm_configs/config.h.cmake

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,10 @@
1919
/* Define to 1 to enable crash memory dumps, and to 0 otherwise. */
2020
#cmakedefine01 LLVM_ENABLE_CRASH_DUMPS
2121

22+
/* Define to 1 to prefer forward slashes on Windows, and to 0 prefer
23+
backslashes. */
24+
#cmakedefine01 LLVM_WINDOWS_PREFER_FORWARD_SLASH
25+
2226
/* Define to 1 if you have the `backtrace' function. */
2327
#cmakedefine HAVE_BACKTRACE ${HAVE_BACKTRACE}
2428

0 commit comments

Comments
 (0)