Avoid conflicts with multiple versions of udev by first trying the library that is linked with the executable, if any, and then picking the one that is in the build environment.

This fixes joystick detection for applications using the Steam Linux Runtime
This commit is contained in:
Sam Lantinga 2016-11-29 05:34:20 -08:00
parent 070b6b0d93
commit 1e59d959f0
7 changed files with 41 additions and 3 deletions

10
configure vendored
View file

@ -21578,6 +21578,16 @@ fi
$as_echo "#define HAVE_LIBUDEV_H 1" >>confdefs.h
udev_lib=`find_lib "libudev.so.*" "" | sed 's/.*\/\(.*\)/\1/; q'`
if test x$udev_lib != x; then
echo "-- dynamic udev -> $udev_lib"
cat >>confdefs.h <<_ACEOF
#define SDL_UDEV_DYNAMIC "$udev_lib"
_ACEOF
fi
fi
fi
}