readdir_r() has been deprecated in glibc-2.24, so trying to compile libdrm against those headers will give a deprecation warning.
Should be fixed with commit bb45ce4e3ac751315bfd7fbfd9e1425bf515ec0d Author: John Stultz <john.stultz@linaro.org> Date: Tue Mar 20 17:48:23 2018 +0000 libdrm: Use readdir instead of readdir_r to avoid build warnings
Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.