Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Allow old CMake versions without IPO support #20

Merged
merged 1 commit into from
Nov 10, 2024
Merged
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
12 changes: 9 additions & 3 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -21,8 +21,10 @@ endif()
if (${CMAKE_VERSION} VERSION_GREATER "3.15.0")
cmake_policy(SET CMP0091 NEW)
endif()
cmake_policy(SET CMP0069 NEW)
set(CMAKE_POLICY_DEFAULT_CMP0069 NEW)
if (NOT ${CMAKE_VERSION} VERSION_LESS "3.9.0")
cmake_policy(SET CMP0069 NEW)
set(CMAKE_POLICY_DEFAULT_CMP0069 NEW)
endif()
project(ASL)

cmake_minimum_required(VERSION 3.0)
Expand All @@ -38,7 +40,11 @@ option(BUILD_DYNRT_LIBS "Build the libraries linked against the dynamic runtime
option(BUILD_MT_LIBS "Build the multithreaded library" OFF)
option(BUILD_CPP "Build the cpp interface" OFF)
option(BUILD_F2C "Build the f2c library" OFF)
option(USE_LTO "Use link time optimization" ON)
if (${CMAKE_VERSION} VERSION_LESS "3.9.0")
option(USE_LTO "Use link time optimization" OFF)
else()
option(USE_LTO "Use link time optimization" ON)
endif()

if(NOT BUILD_ASL_EXAMPLES)
option(BUILD_ASL_EXAMPLES "Build the examples" OFF)
Expand Down
Loading