Fix some issues using MLX in C++ (#739)

* fix preamble build

* fix some issues with using MLX as a dep in C++
This commit is contained in:
Awni Hannun
2024-02-24 22:20:57 -08:00
committed by GitHub
parent 22364c40b7
commit ac02cf33bd
6 changed files with 18 additions and 19 deletions

View File

@@ -67,8 +67,6 @@ if (MLX_BUILD_METAL AND NOT METAL_LIB)
set(MLX_BUILD_METAL OFF)
elseif (MLX_BUILD_METAL)
message(STATUS "Building METAL sources")
add_compile_definitions(_METAL_)
# Throw an error if xcrun not found
execute_process(COMMAND zsh "-c" "/usr/bin/xcrun -sdk macosx --show-sdk-version"
OUTPUT_VARIABLE MACOS_VERSION