From d1609c2afe0e91c8a38b000545ed8137e49dc184 Mon Sep 17 00:00:00 2001 From: Stefan Schmidt Date: Wed, 13 Jan 2016 17:03:36 +0100 Subject: [PATCH] ecore_drm: make sure we include math.h and link against libm for floor() When we introduced the usage of floor() in ecore_drm_evdev.c we forgot to include math.h for it as well as linking against libm. This caused linking failures on some systems while it still worked on others. Better fix it for good. Original patch by aerodynamik. ref T2953 --- configure.ac | 2 ++ src/lib/ecore_drm/ecore_drm_evdev.c | 1 + 2 files changed, 3 insertions(+) diff --git a/configure.ac b/configure.ac index 0ee5a4c576..facdb5f3c3 100644 --- a/configure.ac +++ b/configure.ac @@ -3472,6 +3472,8 @@ EFL_INTERNAL_DEPEND_PKG([ECORE_DRM], [eina]) EFL_DEPEND_PKG([ECORE_DRM], [DRM], [libdrm >= 2.4 xkbcommon >= 0.3.0 gbm]) EFL_DEPEND_PKG([ECORE_DRM], [LIBINPUT], [libinput >= 0.6.0]) +EFL_ADD_LIBS([ECORE_DRM], [-lm]) + # API change from 0.7 to 0.8. So we define this to support both for now. PKG_CHECK_EXISTS([libinput >= 0.8.0], [have_libinput_new="yes"], diff --git a/src/lib/ecore_drm/ecore_drm_evdev.c b/src/lib/ecore_drm/ecore_drm_evdev.c index 1f21dd6b76..b2c2b994ec 100644 --- a/src/lib/ecore_drm/ecore_drm_evdev.c +++ b/src/lib/ecore_drm/ecore_drm_evdev.c @@ -4,6 +4,7 @@ #include "ecore_drm_private.h" #include +#include static void _device_modifiers_update(Ecore_Drm_Evdev *edev);