FindGTK2: Fix missing optional include dirs.
FindGTK2 was adding optional include directories to the interface include dirs regardless of whether or not they existed. This ensures that the directories only get added if they are actually found. This is particularly a problem on Solaris where the gtk2 libs and headers might exist but the FreeType2 headers might not.
This commit is contained in:
parent
75abb6da97
commit
cb8f0f7c81
|
@ -540,7 +540,11 @@ function(_GTK2_ADD_TARGET _var)
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
if(_${_var}_OPTIONAL_INCLUDES)
|
if(_${_var}_OPTIONAL_INCLUDES)
|
||||||
_GTK2_ADD_TARGET_INCLUDE_DIRS(${_var} ${_${_var}_OPTIONAL_INCLUDES})
|
foreach(_D ${_${_var}_OPTIONAL_INCLUDES})
|
||||||
|
if(_D)
|
||||||
|
_GTK2_ADD_TARGET_INCLUDE_DIRS(${_var} ${_D})
|
||||||
|
endif()
|
||||||
|
endforeach()
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
if(GTK2_USE_IMPORTED_TARGETS)
|
if(GTK2_USE_IMPORTED_TARGETS)
|
||||||
|
|
Loading…
Reference in New Issue