Skip to content

Commit

Permalink
[CMake] Add possibility to enable or disable HTTP (disable by default)
Browse files Browse the repository at this point in the history
  • Loading branch information
ljanyst committed Jan 23, 2014
1 parent 689cdf2 commit 003b6cb
Show file tree
Hide file tree
Showing 4 changed files with 14 additions and 1 deletion.
1 change: 1 addition & 0 deletions cmake/XRootDDefaults.cmake
Expand Up @@ -16,3 +16,4 @@ define_default( ENABLE_READLINE TRUE )
define_default( ENABLE_LIBEVENT TRUE )
define_default( ENABLE_XRDCL TRUE )
define_default( ENABLE_TESTS FALSE )
define_default( ENABLE_HTTP FALSE )
8 changes: 8 additions & 0 deletions cmake/XRootDFindLibs.cmake
Expand Up @@ -70,3 +70,11 @@ if( ENABLE_TESTS )
set( BUILD_TESTS FALSE )
endif()
endif()

if( ENABLE_HTTP )
if( OPENSSL_FOUND AND BUILD_CRYPTO )
set( BUILD_HTTP TRUE )
else()
set( BUILD_HTTP FALSE )
endif()
endif()
2 changes: 2 additions & 0 deletions cmake/XRootDSummary.cmake
Expand Up @@ -9,6 +9,7 @@ component_status( KRB5 BUILD_KRB5 KERBEROS5_FOUND )
component_status( LIBEVENT BUILD_LIBEVENT LIBEVENT_FOUND )
component_status( XRDCL ENABLE_XRDCL TRUE_VAR )
component_status( TESTS BUILD_TESTS CPPUNIT_FOUND )
component_status( HTTP BUILD_HTTP OPENSSL_FOUND )

message( STATUS "----------------------------------------" )
message( STATUS "Installation path: " ${CMAKE_INSTALL_PREFIX} )
Expand All @@ -23,4 +24,5 @@ message( STATUS "Kerberos5 support: " ${STATUS_KRB5} )
message( STATUS "XrdCl: " ${STATUS_XRDCL} )
message( STATUS "LibEvent support: " ${STATUS_LIBEVENT} )
message( STATUS "Tests: " ${STATUS_TESTS} )
message( STATUS "HTTP support: " ${STATUS_HTTP} )
message( STATUS "----------------------------------------" )
4 changes: 3 additions & 1 deletion src/CMakeLists.txt
Expand Up @@ -33,7 +33,9 @@ include( XrdApps )
include( XrdCns )
include( XrdHeaders )

include( XrdHTTP )
if( BUILD_HTTP )
include( XrdHTTP )
endif()

#-------------------------------------------------------------------------------
# Install the utility scripts
Expand Down

0 comments on commit 003b6cb

Please sign in to comment.