@ -45,6 +45,8 @@ option(BUILD_STATIC "build a static lighttpd with all modules added")
if ( BUILD_STATIC )
set ( LIGHTTPD_STATIC 1 )
elseif ( APPLE )
set ( CMAKE_SHARED_MODULE_PREFIX "" )
else ( )
set ( CMAKE_SHARED_LIBRARY_PREFIX "" )
endif ( )
@ -221,7 +223,13 @@ else()
endif ( )
if ( WITH_OPENSSL )
if ( APPLE )
set ( CMAKE_REQUIRED_INCLUDES /opt/local/include )
endif ( )
check_include_files ( openssl/ssl.h HAVE_OPENSSL_SSL_H )
if ( APPLE )
set ( CMAKE_REQUIRED_INCLUDES )
endif ( )
if ( HAVE_OPENSSL_SSL_H )
check_library_exists ( crypto BIO_f_base64 "" HAVE_LIBCRYPTO )
if ( HAVE_LIBCRYPTO )
@ -599,6 +607,8 @@ if(HAVE_PCRE_H)
add_target_properties ( mod_redirect COMPILE_FLAGS ${ PCRE_CFLAGS } )
target_link_libraries ( mod_trigger_b4_dl ${ PCRE_LDFLAGS } )
add_target_properties ( mod_trigger_b4_dl COMPILE_FLAGS ${ PCRE_CFLAGS } )
target_link_libraries ( test_configfile ${ PCRE_LDFLAGS } )
add_target_properties ( test_configfile COMPILE_FLAGS ${ PCRE_CFLAGS } )
endif ( )
target_link_libraries ( mod_magnet ${ LUA_LDFLAGS } )
@ -667,7 +677,9 @@ if(CMAKE_COMPILER_IS_GNUCC)
add_definitions ( -D_GNU_SOURCE )
endif ( )
if ( ( NOT APPLE ) OR CMAKE_COMPILER_IS_GNUCC )
add_target_properties ( lighttpd LINK_FLAGS "-Wl,-export-dynamic" )
endif ( )
set_target_properties ( lighttpd PROPERTIES CMAKE_INSTALL_PREFIX ${ CMAKE_INSTALL_PREFIX } )