Skip to content

Commit

Permalink
Merge pull request ceph#12008 from linuxbox2/civet-copy-target
Browse files Browse the repository at this point in the history
cmake: produce civetweb.h, again

ok, w/upstream acks, merging--jenkins build did succeed (this is a build-only change)
  • Loading branch information
mattbenjamin authored Nov 17, 2016
2 parents f61b7ce + 53f6462 commit 3f16167
Showing 1 changed file with 9 additions and 6 deletions.
15 changes: 9 additions & 6 deletions src/rgw/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,13 @@ install(TARGETS
DESTINATION bin)
endif(WITH_TESTS)

add_custom_target(civetweb_h
COMMAND ${CMAKE_COMMAND} -E make_directory
"${CMAKE_BINARY_DIR}/src/include/civetweb"
COMMAND ${CMAKE_COMMAND} -E copy_if_different
"${CMAKE_SOURCE_DIR}/src/civetweb/include/civetweb.h"
"${CMAKE_BINARY_DIR}/src/include/civetweb"
COMMENT "keep civetweb.h up-to-date")

set(rgw_a_srcs
rgw_acl.cc
Expand Down Expand Up @@ -96,16 +103,12 @@ set(rgw_a_srcs

add_library(rgw_a STATIC ${rgw_a_srcs})

add_dependencies(rgw_a civetweb_h)

target_include_directories(rgw_a PUBLIC
"../Beast/include"
${FCGI_INCLUDE_DIR})

# we want to include civetweb.h as "civetweb/civetweb.h". Make it so.
file(MAKE_DIRECTORY "${CMAKE_BINARY_DIR}/src/include/civetweb")
file(COPY
"${CMAKE_SOURCE_DIR}/src/civetweb/include/civetweb.h"
DESTINATION "${CMAKE_BINARY_DIR}/src/include/civetweb")

target_link_libraries(rgw_a librados cls_lock_client 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 common common_utf8 global
Expand Down

0 comments on commit 3f16167

Please sign in to comment.