If CMAKE_MODULE_PATH is empty before appending
'${CMAKE_CURRENT_SOURCE_DIR}/cmake' to it (CMakeLists.txt:27),
CONFIGURE_FILE (CMakeLists.txt:182) works as intended.
However, when CMAKE_MODULE_PATH is not empty, e.g., because of
further tool-chain settings, CONFIGURE_FILE fails with:
CMake Error: File <SOME-OTHER-PATH>;<POCO-SRC-PATH>/cmake/cmake_uninstall.cmake.in does not exist.
| CMake Error at CMakeLists.txt:182 (CONFIGURE_FILE):
| configure_file Problem configuring file
This commit addresses this problem by only using
'${CMAKE_CURRENT_SOURCE_DIR}/cmake' in CONFIGURE_FILE.
The problem was discovered in the meta-ros layer project
(http://github.com/bmwcarit/meta-ros) when creating a libpoco
bitbake recipe, which uses poco's cmake installation scripts.
Signed-off-by: Lukas Bulwahn <lukas.bulwahn@oss.bmw-carit.de>
CMAKE_DEBUG_POSTFIX is already build-type specific and only applied
in case of "Debug" builds. The build-type is correctly inferred from
either CMAKE_BUILD_TYPE for MAkefile based generators or the selected
build type in the Visual Studio IDE. This fix allows to switch the
build type in Visual Studio and have Poco compile/link correctly.
By convention CMake project files are placed on a folder called "cmake" and then called from the build system by appending the CMAKE_MODULE_PATH variable
for CMake build system
.
It is strongly recomended to use out-of-source build to preserve
original Poco makefiles.
http://www.cmake.org/Wiki/CMake_FAQ#Out-of-source_build_trees
I have tested unix makefile generating and Eclipse CDT4 generating.
Supported are static/dynamic and debug/release targets.
On now only core libs are included: CppUnit, Foundation,
Data, Data/SQLite, Util, Net and XML. But autodetection
of OpenSSL, MySQL and ODBC is working OK already.
CPack and CTest nor library install still doesn't work, only building.
This is only the start.