CMake build system: Linux fixes

This commit is contained in:
Vojtech Bubnik 2017-08-18 22:45:24 +02:00
parent ba1c0b0137
commit d0c43c99c3
2 changed files with 3 additions and 0 deletions

View File

@ -73,6 +73,7 @@ if (PerlEmbed_DEBUG)
message(STATUS " PERL_EXTRA_C_FLAGS = ${PERL_EXTRA_C_FLAGS}") message(STATUS " PERL_EXTRA_C_FLAGS = ${PERL_EXTRA_C_FLAGS}")
# Second show the configuration extracted by this module (FindPerlEmbed): # Second show the configuration extracted by this module (FindPerlEmbed):
message(STATUS " PerlEmbed_CCFLAGS = ${PerlEmbed_CCFLAGS}") message(STATUS " PerlEmbed_CCFLAGS = ${PerlEmbed_CCFLAGS}")
message(STATUS " PerlEmbed_CCCDLFLAGS = ${PerlEmbed_CCCDLFLAGS}")
message(STATUS " LD = ${PerlEmbed_LD}") message(STATUS " LD = ${PerlEmbed_LD}")
message(STATUS " PerlEmbed_LDFLAGS = ${PerlEmbed_LDFLAGS}") message(STATUS " PerlEmbed_LDFLAGS = ${PerlEmbed_LDFLAGS}")
message(STATUS " PerlEmbed_LDDLFLAGS = ${PerlEmbed_LDDLFLAGS}") message(STATUS " PerlEmbed_LDDLFLAGS = ${PerlEmbed_LDDLFLAGS}")

View File

@ -394,6 +394,8 @@ target_compile_options(XS PRIVATE ${PerlEmbed_CCFLAGS})
# set(CMAKE_CXX_FLAGS_RELEASE /Od) # set(CMAKE_CXX_FLAGS_RELEASE /Od)
# set(CMAKE_C_FLAGS_RELEASE /Od) # set(CMAKE_C_FLAGS_RELEASE /Od)
#endif() #endif()
# The following line will add -fPIC on Linux to make the XS.so rellocable.
add_definitions(${PerlEmbed_CCCDLFLAGS})
target_link_libraries(XS ${PERL_LIBRARY}) target_link_libraries(XS ${PERL_LIBRARY})
## REQUIRED packages ## REQUIRED packages