mirror of
https://git.tartarus.org/simon/putty.git
synced 2025-07-01 03:22:48 -05:00
Fix pre-GTK3 build failures in puttyapp / ptermapp.
These alternate frontends using the GtkApplication class don't work before GTK3, because the GtkApplication class didn't exist. In the old mkfiles.pl system, the simplest way to prevent a build failure was to just compile them anyway but make them reduce to a stub main(). But now, with the new library-based code organisation, library search order issues mean that these applications won't build at all. Happily, with cmake, it's also easy to simply omit these binaries from the build completely depending on our GTK version.
This commit is contained in:
@ -12,6 +12,9 @@ macro(try_pkg_config_gtk VER PACKAGENAME)
|
||||
(PUTTY_GTK_VERSION STREQUAL ANY OR PUTTY_GTK_VERSION STREQUAL ${VER}))
|
||||
find_package(PkgConfig)
|
||||
pkg_check_modules(GTK ${PACKAGENAME})
|
||||
if(GTK_FOUND)
|
||||
set(GTK_VERSION ${VER})
|
||||
endif()
|
||||
endif()
|
||||
endmacro()
|
||||
try_pkg_config_gtk(3 gtk+-3.0)
|
||||
|
Reference in New Issue
Block a user