clients: Include and link against math lib for new multi-resource
authorStefan Schmidt <s.schmidt@samsung.com>
Mon, 23 Sep 2013 10:25:29 +0000 (11:25 +0100)
committerKristian Høgsberg <krh@bitplanet.net>
Mon, 23 Sep 2013 17:10:48 +0000 (10:10 -0700)
Linking failed with missing ceil() here. Making sure that we include
the header and add the missing -lm.

Signed-off-by: Stefan Schmidt <s.schmidt@samsung.com>
clients/Makefile.am
clients/multi-resource.c

index d4bee2a..4f9dc48 100644 (file)
@@ -51,7 +51,7 @@ weston_multi_resource_SOURCES = multi-resource.c      \
        ../shared/os-compatibility.c                    \
        ../shared/os-compatibility.h
 weston_multi_resource_CPPFLAGS = $(SIMPLE_CLIENT_CFLAGS)
-weston_multi_resource_LDADD = $(SIMPLE_CLIENT_LIBS)
+weston_multi_resource_LDADD = $(SIMPLE_CLIENT_LIBS) -lm
 endif
 
 if BUILD_SIMPLE_EGL_CLIENTS
index 1c2e5c9..6f93618 100644 (file)
@@ -35,6 +35,7 @@
 #include <time.h>
 #include <sys/poll.h>
 #include <float.h>
+#include <math.h>
 
 #include <wayland-client.h>
 #include "../shared/os-compatibility.h"