xbmc / peripheral.joystick

Kodi joystick support (drivers and button maps)
GNU General Public License v2.0
24 stars 46 forks source link

[cmake] sync FindUDEV.cmake from Kodi master #280

Closed garbear closed 1 year ago

garbear commented 1 year ago

Description

Currently, peripheral.joystick fails to build on Jenkins for Linux and FreeBSD. It's likely due to an old Findudev.cmake file. @lrusak has synced the CMake module with Kodi. I'm PRing to test and see if this fixes the problem.

Motivation and context

Reported here: https://github.com/xbmc/peripheral.joystick/pull/251

How has this been tested?

Included in 2023-07-17 test builds: https://github.com/garbear/xbmc/releases

Before:

--   No package 'libudev' found
CMake Error at /home/jenkins/workspace/LINUX-AARCH64-GLES/tools/depends/xbmc-depends/x86_64-linux-gnu-native/share/cmake-3.26/Modules/FindPackageHandleStandardArgs.cmake:230 (message):
  Could NOT find udev (missing: UDEV_LIBRARY UDEV_INCLUDE_DIR)
Call Stack (most recent call first):
  /home/jenkins/workspace/LINUX-AARCH64-GLES/tools/depends/xbmc-depends/x86_64-linux-gnu-native/share/cmake-3.26/Modules/FindPackageHandleStandardArgs.cmake:600 (_FPHSA_FAILURE_MESSAGE)
  cmake/Findudev.cmake:63 (find_package_handle_standard_args)
  CMakeLists.txt:203 (find_package)

-- Configuring incomplete, errors occurred!
make[1]: *** [Makefile:1515: peripheral.joystick] Error 2

After:

Success: https://jenkins.kodi.tv/view/Linux/job/LINUX/59413/

19:45:55 [100%] Built target peripheral.joystick
garbear commented 1 year ago

@lrusak I was able to get Jenkins to build successfully by adding libudev to depends/. I used the upstream Kodi master version (and we grab it directly from the mirrors). PR looks good?