Skip to content

Commit

Permalink
luabind: now can build with -fvisibility=hidden
Browse files Browse the repository at this point in the history
  • Loading branch information
eagleivg committed Nov 6, 2018
1 parent ce3c000 commit 7da1ad0
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 5 deletions.
6 changes: 2 additions & 4 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -65,17 +65,15 @@ if(CMAKE_CXX_COMPILER_ID MATCHES "GNU")
endif()
endif()

set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -fpermissive --std=c++17 -Wno-attributes -pipe -Wl,--no-undefined")
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -fpermissive --std=c++17 -Wno-attributes -pipe -Wl,--no-undefined -fvisibility=hidden")

set(LUA_LIBRARIES luajit)

if(NOT CMAKE_BUILD_TYPE)
set(CMAKE_BUILD_TYPE "Release" CACHE STRING "" FORCE)
endif()

if(${CMAKE_BUILD_TYPE} STREQUAL "Release")
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -fvisibility=hidden")
elseif(${CMAKE_BUILD_TYPE} STREQUAL "Debug")
if(${CMAKE_BUILD_TYPE} STREQUAL "Debug")
add_definitions(-DDEBUG -DMIXED)
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Og")
set(LUA_LIBRARIES luajit-debug)
Expand Down
2 changes: 1 addition & 1 deletion Externals/luabind

0 comments on commit 7da1ad0

Please sign in to comment.