Merge PR #23290 into master

* refs/pull/23290/head:
	tools/ceph-dencoder: include types.h with full path
	tools/ceph-dencoder: move ceph-dencoder to tools/ceph-dencoder

Reviewed-by: Patrick Donnelly <pdonnell@redhat.com>
This commit is contained in:
Patrick Donnelly 2018-08-01 21:42:16 -07:00
commit a1a5a60354
No known key found for this signature in database
GPG Key ID: 3A2A7E25BEA8AADB
6 changed files with 62 additions and 61 deletions

View File

@ -107,60 +107,4 @@ if(WITH_RBD)
endif()
endif(WITH_RBD)
## dencoder
set_source_files_properties(
${CMAKE_SOURCE_DIR}/src/test/encoding/ceph_dencoder.cc
APPEND PROPERTY OBJECT_DEPENDS ${CMAKE_BINARY_DIR}/src/include/ceph_ver.h)
if(HAS_VTA)
set_source_files_properties(test/encoding/ceph_dencoder.cc
PROPERTIES COMPILE_FLAGS -fno-var-tracking-assignments)
endif()
set(dencoder_srcs
ceph_dencoder.cc
$<TARGET_OBJECTS:common_texttable_obj>)
if(WITH_RADOSGW)
list(APPEND dencoder_srcs
${CMAKE_SOURCE_DIR}/src/rgw/rgw_dencoder.cc)
endif()
add_executable(ceph-dencoder ${dencoder_srcs})
if(WITH_RADOSGW)
list(APPEND DENCODER_EXTRALIBS
rgw_a
cls_rgw_client)
endif()
if(WITH_RBD)
list(APPEND DENCODER_EXTRALIBS
cls_rbd_client
rbd_mirror_types
rbd_types
rbd_replay_types)
if(WITH_KRBD)
list(APPEND DENCODER_EXTRALIBS
krbd)
endif()
endif()
target_link_libraries(ceph-dencoder
global
os
osd
mds
mon
journal
${DENCODER_EXTRALIBS}
cls_lock_client
cls_refcount_client
cls_log_client
cls_statelog_client
cls_version_client
cls_user_client
cls_journal_client
cls_timeindex_client
${EXTRALIBS}
${CMAKE_DL_LIBS})
install(TARGETS ceph-dencoder DESTINATION bin)
add_subdirectory(ceph-dencoder)

View File

@ -0,0 +1,57 @@
## dencoder
set_source_files_properties(
ceph_dencoder.cc
APPEND PROPERTY OBJECT_DEPENDS ${CMAKE_BINARY_DIR}/src/include/ceph_ver.h)
if(HAS_VTA)
set_source_files_properties(ceph_dencoder.cc
PROPERTIES COMPILE_FLAGS -fno-var-tracking-assignments)
endif()
set(dencoder_srcs
ceph_dencoder.cc
$<TARGET_OBJECTS:common_texttable_obj>)
if(WITH_RADOSGW)
list(APPEND dencoder_srcs
${CMAKE_SOURCE_DIR}/src/rgw/rgw_dencoder.cc)
endif()
add_executable(ceph-dencoder ${dencoder_srcs})
if(WITH_RADOSGW)
list(APPEND DENCODER_EXTRALIBS
rgw_a
cls_rgw_client)
endif()
if(WITH_RBD)
list(APPEND DENCODER_EXTRALIBS
cls_rbd_client
rbd_mirror_types
rbd_types
rbd_replay_types)
if(WITH_KRBD)
list(APPEND DENCODER_EXTRALIBS
krbd)
endif()
endif()
target_link_libraries(ceph-dencoder
global
os
osd
mds
mon
journal
${DENCODER_EXTRALIBS}
cls_lock_client
cls_refcount_client
cls_log_client
cls_statelog_client
cls_version_client
cls_user_client
cls_journal_client
cls_timeindex_client
${EXTRALIBS}
${CMAKE_DL_LIBS})
install(TARGETS ceph-dencoder DESTINATION bin)

View File

@ -33,7 +33,7 @@
#define TYPE_FEATUREFUL_NOCOPY(t)
#define TYPE_NOCOPY(t)
#define MESSAGE(t)
#include "include/types.h"
#include "tools/ceph-dencoder/types.h"
#undef TYPE
#undef TYPE_STRAYDATA
#undef TYPE_NONDETERMINISTIC
@ -302,7 +302,7 @@ int main(int argc, const char **argv)
#define TYPE_FEATUREFUL_NOCOPY(t) dencoders[T_STRINGIFY(t)] = new DencoderImplFeaturefulNoCopy<t>(false, false);
#define TYPE_NOCOPY(t) dencoders[T_STRINGIFY(t)] = new DencoderImplNoFeatureNoCopy<t>(false, false);
#define MESSAGE(t) dencoders[T_STRINGIFY(t)] = new MessageDencoderImpl<t>;
#include "include/types.h"
#include "tools/ceph-dencoder/types.h"
#undef TYPE
#undef TYPE_STRAYDATA
#undef TYPE_NONDETERMINISTIC

View File

@ -1,9 +1,9 @@
#include "test_ceph_time.h"
#include "ceph_time.h"
TYPE(real_time_wrapper)
TYPE(coarse_real_time_wrapper)
TYPE(timespan_wrapper)
#include "test_sstring.h"
#include "sstring.h"
TYPE(sstring_wrapper)
#include "include/CompatSet.h"