Use add_definitions instead of add_compile_definitions, to support older cmake < 3.12

This commit is contained in:
serkixenos 2021-12-02 12:20:03 -04:00
parent 77791b2d20
commit 732cae963d

View file

@ -54,7 +54,8 @@ set(CMAKE_EXPORT_COMPILE_COMMANDS "ON")
if (BUILD_PEERPLAYS_TESTNET)
set(GRAPHENE_EGENESIS_JSON "${CMAKE_CURRENT_SOURCE_DIR}/genesis-testnet.json" CACHE PATH "location of the genesis.json to embed in the executable" )
add_compile_definitions(BUILD_PEERPLAYS_TESTNET=1)
#add_compile_definitions(BUILD_PEERPLAYS_TESTNET=1)
add_definitions(-DBUILD_PEERPLAYS_TESTNET=1)
message ("\n====================\nBuilding for Testnet\n====================\n")
else (BUILD_PEERPLAYS_TESTNET)
set(GRAPHENE_EGENESIS_JSON "${CMAKE_CURRENT_SOURCE_DIR}/genesis-mainnet.json" CACHE PATH "location of the genesis.json to embed in the executable" )