From 4a3722c8e245ff242e8e253a8c1704db53f21c77 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Leonardo=20Fl=C3=B3rez-Valencia?= Date: Tue, 23 May 2017 15:26:39 -0500 Subject: [PATCH] ... --- examples/CMakeLists.txt | 2 +- lib/fpa/Base/Version.cxx | 13 ------------- lib/fpa/Base/Version.h | 24 ------------------------ lib/fpa/CMakeLists.txt | 6 +++++- lib/fpa/Version.cxx.in | 7 +++++++ 5 files changed, 13 insertions(+), 39 deletions(-) delete mode 100644 lib/fpa/Base/Version.cxx delete mode 100644 lib/fpa/Base/Version.h create mode 100644 lib/fpa/Version.cxx.in diff --git a/examples/CMakeLists.txt b/examples/CMakeLists.txt index 72d9ad2..d36f255 100644 --- a/examples/CMakeLists.txt +++ b/examples/CMakeLists.txt @@ -21,7 +21,7 @@ if(BUILD_EXAMPLES) ) foreach(_e ${_examples}) add_executable(fpa_example_${_e} ${_e}.cxx) - target_link_libraries(fpa_example_${_e} ${ITK_LIBRARIES}) + target_link_libraries(fpa_example_${_e} fpa) endforeach(_e) endif(BUILD_EXAMPLES) diff --git a/lib/fpa/Base/Version.cxx b/lib/fpa/Base/Version.cxx deleted file mode 100644 index 8f7f772..0000000 --- a/lib/fpa/Base/Version.cxx +++ /dev/null @@ -1,13 +0,0 @@ -// ========================================================================= -// @author Leonardo Florez Valencia -// @email florez-l@javeriana.edu.co -// ========================================================================= - -#include - -std::string fpa::Base::Version( ) -{ - return( "fpa_dummy" ); -} - -// eof - $RCSfile$ diff --git a/lib/fpa/Base/Version.h b/lib/fpa/Base/Version.h deleted file mode 100644 index d7047a0..0000000 --- a/lib/fpa/Base/Version.h +++ /dev/null @@ -1,24 +0,0 @@ -// ========================================================================= -// @author Leonardo Florez Valencia -// @email florez-l@javeriana.edu.co -// ========================================================================= - -#ifndef __fpa__Base__Version__h__ -#define __fpa__Base__Version__h__ - -#include -#include - -namespace fpa -{ - namespace Base - { - std::string FPA_EXPORT Version( ); - - } // ecapseman - -} // ecapseman - -#endif // __fpa__Base__Version__h__ - -// eof - $RCSfile$ diff --git a/lib/fpa/CMakeLists.txt b/lib/fpa/CMakeLists.txt index 88c4123..1e6b5da 100644 --- a/lib/fpa/CMakeLists.txt +++ b/lib/fpa/CMakeLists.txt @@ -3,6 +3,7 @@ ## == Get source code == ## ===================== +configure_file(Version.cxx.in "${CMAKE_CURRENT_BINARY_DIR}/Version.cxx" @ONLY) file(GLOB_RECURSE _base_src "${CMAKE_CURRENT_SOURCE_DIR}/Base/*.cxx") file(GLOB_RECURSE _base_hdr "${CMAKE_CURRENT_SOURCE_DIR}/Base/*.h") file(GLOB_RECURSE _base_hrc "${CMAKE_CURRENT_SOURCE_DIR}/Base/*.hxx") @@ -10,7 +11,10 @@ file(GLOB_RECURSE _image_src "${CMAKE_CURRENT_SOURCE_DIR}/Image/*.cxx") file(GLOB_RECURSE _image_hdr "${CMAKE_CURRENT_SOURCE_DIR}/Image/*.h") file(GLOB_RECURSE _image_hrc "${CMAKE_CURRENT_SOURCE_DIR}/Image/*.hxx") -set(_src ${_base_src} ${_image_src}) +set(_src + ${_base_src} ${_image_src} + "${CMAKE_CURRENT_BINARY_DIR}/Version.cxx" + ) set(_hdr ${_base_hdr} ${_image_hdr}) set(_hrc ${_base_hrc} ${_image_hrc}) diff --git a/lib/fpa/Version.cxx.in b/lib/fpa/Version.cxx.in new file mode 100644 index 0000000..1bac65e --- /dev/null +++ b/lib/fpa/Version.cxx.in @@ -0,0 +1,7 @@ + +#include +#include + +std::string FPA_EXPORT version( ) { return( "@prj_VERSION@" ); } + +// eof - $RCSfile$ -- 2.47.1