1
0
mirror of https://git.tartarus.org/simon/putty.git synced 2025-01-09 17:38:00 +00:00
putty-source/cmake
Simon Tatham 5eee8ca648 Compatibility with older versions of cmake.
After this change, the cmake setup now works even on Debian stretch
(oldoldstable), which runs cmake 3.7.

In order to support a version that early I had to:

 - write a fallback implementation of 'add_compile_definitions' for
   older cmakes, which is easy, because add_compile_definitions(FOO)
   is basically just add_compile_options(-DFOO)

 - stop using list(TRANSFORM) and string(JOIN), of which I had one
   case each, and they were easily replaced with simple foreach loops

 - stop putting OBJECT libraries in the target_link_libraries command
   for executable targets, in favour of adding $<TARGET_OBJECTS:foo>
   to the main sources list for the same target. That matches what I
   do with library targets, so it's probably more sensible anyway.

I tried going back by another Debian release and getting this cmake
setup to work on jessie, but that runs CMake 3.0.1, and in _that_
version of cmake the target_sources command is missing, and I didn't
find any alternative way to add extra sources to a target after having
first declared it. Reorganising to cope with _that_ omission would be
too much upheaval without a very good reason.
2021-10-29 18:08:18 +01:00
..
platforms Fix paste error in comment. 2021-10-21 20:42:25 +01:00
cmake.h.in Don't #include <utmp.h> if it doesn't exist. 2021-05-13 18:40:47 +01:00
gitcommit.cmake gitcommit.cmake: stop needing TOPLEVEL_SOURCE_DIR. 2021-05-08 10:25:34 +01:00
gtk.cmake Replace mkfiles.pl with a CMake build system. 2021-04-17 13:53:02 +01:00
licence.cmake Replace mkfiles.pl with a CMake build system. 2021-04-17 13:53:02 +01:00
setup.cmake Compatibility with older versions of cmake. 2021-10-29 18:08:18 +01:00
toolchain-mingw.cmake Replace mkfiles.pl with a CMake build system. 2021-04-17 13:53:02 +01:00
toolchain-winegcc.cmake Replace mkfiles.pl with a CMake build system. 2021-04-17 13:53:02 +01:00
winegcc Replace mkfiles.pl with a CMake build system. 2021-04-17 13:53:02 +01:00