From 4928b908328a95ed5b2b25a5d22a6084fbe1aa4f Mon Sep 17 00:00:00 2001 From: Jason Ramapuram Date: Thu, 17 Sep 2015 21:23:42 +0200 Subject: [PATCH] resolve osx build error with opencl and fix f77 issue --- build.rs | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/build.rs b/build.rs index f074ddf0a..682d83b14 100644 --- a/build.rs +++ b/build.rs @@ -278,7 +278,7 @@ fn run_cmake_command(conf: &Config, build_dir: &std::path::PathBuf) { _ => fail("Invalid FFT upstream option set"), }; match conf.cpu_blas_type.as_ref() { - "LAPACKE" => { blas_options.push(format!("-DUSE_CPU_F77_BLAS:BOOL={}", "ON")); }, + "LAPACKE" => { blas_options.push(format!("-DUSE_CPU_F77_BLAS:BOOL={}", "OFF")); }, "MKL" => { blas_options.push(format!("-DUSE_CPU_MKL:BOOL={}", "ON")); }, _ => fail("Invalid BLAS upstream option set"), }; @@ -356,7 +356,9 @@ fn blob_backends(conf: &Config, build_dir: &std::path::PathBuf) -> (Vec, } } else if conf.use_backend == "opencl" { backends.push(("afopencl".to_string())); - backends.push("OpenCL".to_string()); + if ! cfg!(target_os = "macos"){ + backends.push("OpenCL".to_string()); + } if cfg!(windows) { backend_dirs.push(format!("{}\\lib\\x64", conf.opencl_sdk)); } else {