]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
cmake fix: build civetweb with the right include path. 7825/head
authorMarcus Watts <mwatts@redhat.com>
Sat, 27 Feb 2016 07:34:14 +0000 (02:34 -0500)
committerMarcus Watts <mwatts@redhat.com>
Sat, 27 Feb 2016 07:34:14 +0000 (02:34 -0500)
In an earlier commit, civetweb.c got moved into a separate cmake 'object'
library civetweb_common_objs so that it could be built just once for use
with several different targets.  At the time, there was a separate global
"include_directory" to give the right include path for including "civetweb.h".
A later commit in master created an rgw_a library, and restricted civetweb.h's
include path for only building rgw_a objects.  So, as the product of
these these two commits, the target_include_directories command for the
civetweb include path now needs to be applied to civetweb_common_objs
and not rgw_a.

Signed-off-by: Marcus Watts <mwatts@redhat.com>
src/CMakeLists.txt

index 2172b510863092ddd19128f5ec0ce9731286a399..e0eebf17aec4d25f56bdc5cb4eb62e26c1c1407c 100644 (file)
@@ -1197,11 +1197,12 @@ if(${WITH_RADOSGW})
 
   set(civetweb_common_files civetweb/src/civetweb.c)
   add_library(civetweb_common_objs OBJECT ${civetweb_common_files})
+  target_include_directories(civetweb_common_objs PUBLIC
+       "${CMAKE_SOURCE_DIR}/src/civetweb/include")
   set_property(TARGET civetweb_common_objs
               APPEND PROPERTY COMPILE_DEFINITIONS NO_SSL_DL=1)
 
   add_library(rgw_a STATIC ${rgw_a_srcs})
-  target_include_directories(rgw_a PUBLIC "${CMAKE_SOURCE_DIR}/src/civetweb/include")
   target_link_libraries(rgw_a librados cls_rgw_client cls_refcount_client
     cls_log_client cls_statelog_client cls_timeindex_client cls_version_client
     cls_replica_log_client cls_user_client curl global expat)