Skip to content

Commit

Permalink
Forward the LLVM_ENABLE_LIBCXX CMake parameter to the mlir standalo…
Browse files Browse the repository at this point in the history
…ne test

This allows to build and test MLIR with `-DLLVM_ENABLE_LIBCXX=ON`.
  • Loading branch information
joker-eph committed Mar 8, 2021
1 parent df9158c commit e94e557
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 1 deletion.
1 change: 1 addition & 0 deletions mlir/examples/standalone/test/lit.site.cfg.py.in
Expand Up @@ -23,6 +23,7 @@ config.llvm_bindings = "@LLVM_BINDINGS@".split(' ')
config.host_os = "@HOST_OS@"
config.host_cc = "@HOST_CC@"
config.host_cxx = "@HOST_CXX@"
config.enable_libcxx = "@LLVM_ENABLE_LIBCXX@"
# Note: ldflags can contain double-quoted paths, so must use single quotes here.
config.host_ldflags = '@HOST_LDFLAGS@'
config.llvm_use_sanitizer = "@LLVM_USE_SANITIZER@"
Expand Down
1 change: 1 addition & 0 deletions mlir/test/Examples/standalone/lit.local.cfg
@@ -1,3 +1,4 @@
config.substitutions.append(("%cmake", config.host_cmake))
config.substitutions.append(("%host_cxx", config.host_cxx))
config.substitutions.append(("%host_cc", config.host_cc))
config.substitutions.append(("%enable_libcxx", config.enable_libcxx))
2 changes: 1 addition & 1 deletion mlir/test/Examples/standalone/test.toy
@@ -1,4 +1,4 @@
# RUN: %cmake %mlir_src_root/examples/standalone -DCMAKE_CXX_COMPILER=%host_cxx -DCMAKE_C_COMPILER=%host_cc -DMLIR_DIR=%llvm_lib_dir/cmake/mlir ; %cmake --build . --target check-standalone | tee %t | FileCheck %s
# RUN: %cmake %mlir_src_root/examples/standalone -DCMAKE_CXX_COMPILER=%host_cxx -DCMAKE_C_COMPILER=%host_cc -DLLVM_ENABLE_LIBCXX=%enable_libcxx -DMLIR_DIR=%llvm_lib_dir/cmake/mlir ; %cmake --build . --target check-standalone | tee %t | FileCheck %s

# CHECK: Passed: 3
# UNSUPPORTED: windows, android
1 change: 1 addition & 0 deletions mlir/test/lit.site.cfg.py.in
Expand Up @@ -23,6 +23,7 @@ config.llvm_bindings = "@LLVM_BINDINGS@".split(' ')
config.host_os = "@HOST_OS@"
config.host_cc = "@HOST_CC@"
config.host_cxx = "@HOST_CXX@"
config.enable_libcxx = "@LLVM_ENABLE_LIBCXX@"
config.host_cmake = "@CMAKE_COMMAND@"
# Note: ldflags can contain double-quoted paths, so must use single quotes here.
config.host_ldflags = '@HOST_LDFLAGS@'
Expand Down

0 comments on commit e94e557

Please sign in to comment.