diff --git a/include/CMakeLists.txt b/include/CMakeLists.txt index 7f1cb98..facfab1 100644 --- a/include/CMakeLists.txt +++ b/include/CMakeLists.txt @@ -1,2 +1,6 @@ file(GLOB INCLUDE_FILES "json/*.h") -install(FILES ${INCLUDE_FILES} DESTINATION ${CMAKE_INSTALL_INCLUDEDIR}/json) +install(FILES + ${INCLUDE_FILES} + ${PROJECT_BINARY_DIR}/include/json/version.h + DESTINATION ${CMAKE_INSTALL_INCLUDEDIR}/json) + diff --git a/include/json/version.h b/include/json/version.h deleted file mode 100644 index 027f731..0000000 --- a/include/json/version.h +++ /dev/null @@ -1,22 +0,0 @@ -// DO NOT EDIT. This file (and "version") is generated by CMake. -// Run CMake configure step to update it. -#ifndef JSON_VERSION_H_INCLUDED -#define JSON_VERSION_H_INCLUDED - -#define JSONCPP_VERSION_STRING "1.8.4" -#define JSONCPP_VERSION_MAJOR 1 -#define JSONCPP_VERSION_MINOR 8 -#define JSONCPP_VERSION_PATCH 4 -#define JSONCPP_VERSION_QUALIFIER -#define JSONCPP_VERSION_HEXA \ - ((JSONCPP_VERSION_MAJOR << 24) | (JSONCPP_VERSION_MINOR << 16) | \ - (JSONCPP_VERSION_PATCH << 8)) - -#ifdef JSONCPP_USING_SECURE_MEMORY -#undef JSONCPP_USING_SECURE_MEMORY -#endif -#define JSONCPP_USING_SECURE_MEMORY 0 -// If non-zero, the library zeroes any memory that it has allocated before -// it frees its memory. - -#endif // JSON_VERSION_H_INCLUDED diff --git a/src/lib_json/CMakeLists.txt b/src/lib_json/CMakeLists.txt index 034f438..2392092 100644 --- a/src/lib_json/CMakeLists.txt +++ b/src/lib_json/CMakeLists.txt @@ -47,7 +47,7 @@ set( PUBLIC_HEADERS ${JSONCPP_INCLUDE_DIR}/json/reader.h ${JSONCPP_INCLUDE_DIR}/json/writer.h ${JSONCPP_INCLUDE_DIR}/json/assertions.h - ${JSONCPP_INCLUDE_DIR}/json/version.h + ${PROJECT_BINARY_DIR}/include/json/version.h ) source_group( "Public API" FILES ${PUBLIC_HEADERS} ) @@ -141,5 +141,6 @@ install( TARGETS jsoncpp_lib ${INSTALL_EXPORT} if(NOT CMAKE_VERSION VERSION_LESS 2.8.11) target_include_directories( jsoncpp_lib PUBLIC $ - $) + $ + $) endif()