Skip to content
This repository has been archived by the owner on Aug 30, 2018. It is now read-only.

Commit

Permalink
Do not use BUILD_SHARED_LIBS as define in the code. When this define …
Browse files Browse the repository at this point in the history
…is used in other libraries as well, it can have a different value.

If so, it leads to wrongly defined export symbols.
  • Loading branch information
Frederik Vannoote committed Feb 15, 2017
1 parent 51765e6 commit c03df5c
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion CommonConfig.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ if (NOT DEFINED BUILD_SHARED_LIBS)
endif()
# When set to OFF, the library will be built as a static library
if (${BUILD_SHARED_LIBS})
add_definitions(-DBUILD_SHARED_LIBS)
add_definitions(-D${PROJECT_NAME}_BUILD_SHARED_LIBS)
endif()


Expand Down
2 changes: 1 addition & 1 deletion config.cmake.in
Original file line number Diff line number Diff line change
Expand Up @@ -29,5 +29,5 @@ set(CMAKE_CXX_STANDARD_REQUIRED ON)
include_directories(@TARGET_INCLUDE_INSTALL_DIRS@)

if (@BUILD_SHARED_LIBS@)
add_definitions(-DBUILD_SHARED_LIBS)
add_definitions(-D@PROJECT_NAME@_BUILD_SHARED_LIBS)
endif()

0 comments on commit c03df5c

Please sign in to comment.