cmake: find libudev library so it gets priority

This commit is contained in:
Anonymous Maarten committed 2022-11-25 21:37:42 +01:00
1 parent a2611edcf3
commit 660cec69b1
3 files changed
+16 -1

No files matched your search

+13
View File
@@ -1294,3 +1294,16 @@ macro(CheckKMSDRM)
endif()
endif()
endmacro()
macro(CheckLibUDev)
if(SDL_LIBUDEV)
check_include_file("libudev.h" have_libudev_header)
if(have_libudev_header)
set(HAVE_LIBUDEV_H TRUE)
FindLibraryAndSONAME(udev)
if(UDEV_LIB_SONAME)
set(SDL_UDEV_DYNAMIC "\"${UDEV_LIB_SONAME}\"")
endif()
endif()
endif()
endmacro()