@@ -1,11 +1,11 @@
1diff --git a/CMakeLists.txt b/CMakeLists.txt
1diff --git a/CMakeLists.txt b/CMakeLists.txt
2−index 40a685b7e..c452efd09 100644
2+index 4ba384324..7e23038f7 100644
3--- a/CMakeLists.txt
3--- a/CMakeLists.txt
4+++ b/CMakeLists.txt
4+++ b/CMakeLists.txt
5−@@ -49,10 +49,10 @@ set(CMAKE_RUNTIME_OUTPUT_DIRECTORY "${CMAKE_BINARY_DIR}/bin")
5+@@ -75,10 +75,10 @@ set(CMAKE_RUNTIME_OUTPUT_DIRECTORY "${CMAKE_BINARY_DIR}/bin")
7 set(LLVM_VERSION "${LLVM_VERSION_MAJOR}${LLVM_VERSION_MINOR}")
7 set(LLVM_VERSION "${LLVM_VERSION_MAJOR}${LLVM_VERSION_MINOR}")
9-file(TO_NATIVE_PATH "${LLVM_TOOLS_BINARY_DIR}/llvm-as${CMAKE_EXECUTABLE_SUFFIX}" LLVM_AS)
9-file(TO_NATIVE_PATH "${LLVM_TOOLS_BINARY_DIR}/llvm-as${CMAKE_EXECUTABLE_SUFFIX}" LLVM_AS)
10-file(TO_NATIVE_PATH "${LLVM_TOOLS_BINARY_DIR}/llvm-nm${CMAKE_EXECUTABLE_SUFFIX}" LLVM_NM)
10-file(TO_NATIVE_PATH "${LLVM_TOOLS_BINARY_DIR}/llvm-nm${CMAKE_EXECUTABLE_SUFFIX}" LLVM_NM)
11-file(TO_NATIVE_PATH "${LLVM_TOOLS_BINARY_DIR}/clang${CMAKE_EXECUTABLE_SUFFIX}" CLANG)
11-file(TO_NATIVE_PATH "${LLVM_TOOLS_BINARY_DIR}/clang${CMAKE_EXECUTABLE_SUFFIX}" CLANG)
@@ -14,7 +14,7 @@ index 40a685b7e..c452efd09 100644
14+find_program(LLVM_NM llvm-nm HINTS ${LLVM_TOOLS_BINARY_DIR})
14+find_program(LLVM_NM llvm-nm HINTS ${LLVM_TOOLS_BINARY_DIR})
15+find_program(CLANG clang HINTS ${LLVM_TOOLS_BINARY_DIR})
15+find_program(CLANG clang HINTS ${LLVM_TOOLS_BINARY_DIR})
16+find_program(LLVM_CONFIG llvm-config HINTS ${LLVM_TOOLS_BINARY_DIR})
16+find_program(LLVM_CONFIG llvm-config HINTS ${LLVM_TOOLS_BINARY_DIR})
18 # LLVM doesn't appear to expose --system-libs via its CMake interface,
18 # LLVM doesn't appear to expose --system-libs via its CMake interface,
19 # so we must shell out to llvm-config to find this info
19 # so we must shell out to llvm-config to find this info
20diff --git a/apps/linear_algebra/CMakeLists.txt b/apps/linear_algebra/CMakeLists.txt
20diff --git a/apps/linear_algebra/CMakeLists.txt b/apps/linear_algebra/CMakeLists.txt
@@ -27,7 +27,7 @@ index 132c80e6a..36ce865f2 100644
27 set(OpenBLAS_EXTRA_LIBS)
27 set(OpenBLAS_EXTRA_LIBS)
28- set(BLAS_VENDORS OpenBLAS ATLAS)
28- set(BLAS_VENDORS OpenBLAS ATLAS)
29+ set(BLAS_VENDORS OpenBLAS)
29+ set(BLAS_VENDORS OpenBLAS)
32 # there are more vendors we could add here that support the cblas interface
32 # there are more vendors we could add here that support the cblas interface
33@@ -41,6 +41,7 @@ if (CBLAS_FOUND)
33@@ -41,6 +41,7 @@ if (CBLAS_FOUND)
@@ -39,17 +39,18 @@ index 132c80e6a..36ce865f2 100644
40 endforeach()
40 endforeach()
41diff --git a/apps/linear_algebra/tests/CMakeLists.txt b/apps/linear_algebra/tests/CMakeLists.txt
41diff --git a/apps/linear_algebra/tests/CMakeLists.txt b/apps/linear_algebra/tests/CMakeLists.txt
42−index 4b95eb3bb..1daa97437 100644
42+index cc02eb0a4..c20419a0d 100644
43--- a/apps/linear_algebra/tests/CMakeLists.txt
43--- a/apps/linear_algebra/tests/CMakeLists.txt
44+++ b/apps/linear_algebra/tests/CMakeLists.txt
44+++ b/apps/linear_algebra/tests/CMakeLists.txt
45−@@ -19,6 +19,6 @@ target_compile_options(test_halide_blas PRIVATE -Wno-unused-variable)
45+@@ -19,7 +19,7 @@ target_compile_options(test_halide_blas PRIVATE -Wno-unused-variable)
46 target_link_libraries(test_halide_blas
46 target_link_libraries(test_halide_blas
48 halide_blas
48 halide_blas
49- cblas # XXX fragile
49- cblas # XXX fragile
50+ ${BLAS_LIBRARIES}
50+ ${BLAS_LIBRARIES}
51− Halide
51+ ${HALIDE_COMPILER_LIB}