Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -151,6 +151,7 @@ cmake_policy(SET CMP0135 NEW)

add_library(mlx)

target_compile_features(mlx INTERFACE cxx_std_20)
target_compile_options(mlx PUBLIC ${SANITIZER_COMPILE_FLAGS})
target_link_options(mlx PUBLIC ${SANITIZER_LINK_FLAGS})

Expand Down
2 changes: 1 addition & 1 deletion examples/cmake_project/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ cmake_minimum_required(VERSION 3.27)

project(example LANGUAGES CXX)

set(CMAKE_CXX_STANDARD 17)
set(CMAKE_CXX_STANDARD 20)
set(CMAKE_CXX_STANDARD_REQUIRED ON)

# Comment the following two commands only the MLX C++ library is installed and
Expand Down
2 changes: 1 addition & 1 deletion examples/export/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ cmake_minimum_required(VERSION 3.27)

project(import_mlx LANGUAGES CXX)

set(CMAKE_CXX_STANDARD 17)
set(CMAKE_CXX_STANDARD 20)
set(CMAKE_CXX_STANDARD_REQUIRED ON)

find_package(
Expand Down
2 changes: 1 addition & 1 deletion examples/extensions/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ cmake_minimum_required(VERSION 3.27)
project(_ext LANGUAGES CXX)

# ----------------------------- Setup -----------------------------
set(CMAKE_CXX_STANDARD 17)
set(CMAKE_CXX_STANDARD 20)
set(CMAKE_CXX_STANDARD_REQUIRED ON)
set(CMAKE_POSITION_INDEPENDENT_CODE ON)

Expand Down
1 change: 0 additions & 1 deletion mlx.pc.in
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,6 @@ if (@MLX_BUILD_METAL@)
endif()

set_target_properties(mlx PROPERTIES
CXX_STANDARD 17
INTERFACE_COMPILE_OPTIONS "${MLX_CXX_FLAGS}"
)

Expand Down
Loading