FindGTK2: Populate GTK2_DEFINITIONS before searching for libraries
This commit is contained in:
parent
8d7b070410
commit
fab6c2deb0
|
@ -449,6 +449,20 @@ if(GTK2_FIND_VERSION)
|
||||||
endif()
|
endif()
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
|
#
|
||||||
|
# On MSVC, according to https://wiki.gnome.org/gtkmm/MSWindows, the /vd2 flag needs to be
|
||||||
|
# passed to the compiler in order to use gtkmm
|
||||||
|
#
|
||||||
|
if(MSVC)
|
||||||
|
foreach(_GTK2_component ${GTK2_FIND_COMPONENTS})
|
||||||
|
if(_GTK2_component STREQUAL "gtkmm")
|
||||||
|
set(GTK2_DEFINITIONS "/vd2")
|
||||||
|
elseif(_GTK2_component STREQUAL "glademm")
|
||||||
|
set(GTK2_DEFINITIONS "/vd2")
|
||||||
|
endif()
|
||||||
|
endforeach()
|
||||||
|
endif()
|
||||||
|
|
||||||
#
|
#
|
||||||
# Find all components
|
# Find all components
|
||||||
#
|
#
|
||||||
|
@ -565,20 +579,6 @@ if(NOT GTK2_FIND_VERSION AND GTK2_GTK_INCLUDE_DIR)
|
||||||
set(GTK2_VERSION ${GTK2_MAJOR_VERSION}.${GTK2_MINOR_VERSION}.${GTK2_PATCH_VERSION})
|
set(GTK2_VERSION ${GTK2_MAJOR_VERSION}.${GTK2_MINOR_VERSION}.${GTK2_PATCH_VERSION})
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
#
|
|
||||||
# On MSVC, according to https://wiki.gnome.org/gtkmm/MSWindows, the /vd2 flag needs to be
|
|
||||||
# passed to the compiler in order to use gtkmm
|
|
||||||
#
|
|
||||||
if(MSVC)
|
|
||||||
foreach(_GTK2_component ${GTK2_FIND_COMPONENTS})
|
|
||||||
if(_GTK2_component STREQUAL "gtkmm")
|
|
||||||
set(GTK2_DEFINITIONS "/vd2")
|
|
||||||
elseif(_GTK2_component STREQUAL "glademm")
|
|
||||||
set(GTK2_DEFINITIONS "/vd2")
|
|
||||||
endif()
|
|
||||||
endforeach()
|
|
||||||
endif()
|
|
||||||
|
|
||||||
#
|
#
|
||||||
# Try to enforce components
|
# Try to enforce components
|
||||||
#
|
#
|
||||||
|
|
Loading…
Reference in New Issue