Skip to content
This repository was archived by the owner on Mar 26, 2020. It is now read-only.

Commit 8d7936d

Browse files
authored
Merge pull request #90 from njwhite/master
don't override CMAKE_INSTALL_PREFIX if specified
2 parents a501d06 + f6b4989 commit 8d7936d

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

CMakeLists.txt

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,9 @@ option(JSON11_ENABLE_DR1467_CANARY "Enable canary test for DR 1467" OFF)
88

99
set(CMAKE_CXX_STANDARD 11)
1010
set(CMAKE_CXX_STANDARD_REQUIRED ON)
11-
set(CMAKE_INSTALL_PREFIX /usr)
11+
if(CMAKE_INSTALL_PREFIX_INITIALIZED_TO_DEFAULT)
12+
set(CMAKE_INSTALL_PREFIX /usr)
13+
endif()
1214

1315
add_library(json11 json11.cpp)
1416
target_include_directories(json11 PUBLIC ${CMAKE_SOURCE_DIR})

0 commit comments

Comments
 (0)