Fix X11 lib detection

LT1AB
Ryan Burns 2020-01-08 12:08:23 -08:00
parent 46fef17f39
commit aa140d5f79
1 changed files with 4 additions and 1 deletions

View File

@ -2,12 +2,15 @@ find_package(X11)
if(X11_FOUND)
set(X11_X11_FOUND TRUE)
foreach(component
X11
Xmu
Xt
)
if(X11_${Xmu}_FOUND AND NOT TARGET X11::${component})
if(X11_${component}_FOUND AND NOT TARGET X11::${component})
add_library(X11::${component} IMPORTED INTERFACE)
target_include_directories(X11::${component} SYSTEM
INTERFACE ${X11_${component}_INCLUDE_PATH})