Merge pull request #2099 from ioangogo/LinuxCaptionFix

cmake: Compile option to fix libcaption linking
master
Jim 2019-10-15 11:25:05 -07:00 committed by GitHub
commit 7d34034ee2
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 5 additions and 1 deletions

View File

@ -8,4 +8,4 @@ fi
set -ex
ccache -s || echo "CCache is not available."
mkdir build && cd build
cmake ..
cmake -DBUILD_CAPTIONS=ON ..

View File

@ -5,6 +5,10 @@ if (WIN32)
add_definitions(-D_CRT_SECURE_NO_WARNINGS)
endif()
if (UNIX AND NOT APPLE)
add_compile_options("-fPIC")
endif()
# Don't need to prefix local includes with "caption/*"
include_directories(${CMAKE_CURRENT_SOURCE_DIR}/caption)