OICSensorBoard: install example and improve configuration 65/5365/11
authorPhilippe Coval <philippe.coval@osg.samsung.com>
Fri, 22 Jan 2016 15:37:04 +0000 (16:37 +0100)
committerJon A. Cruz <jon@joncruz.org>
Mon, 11 Jul 2016 20:37:50 +0000 (20:37 +0000)
Origin: https://gerrit.iotivity.org/gerrit/#/c/4743/
Change-Id: I7b434e45226d78dc4b69a8b9296b6d9d77d89189
Signed-off-by: Philippe Coval <philippe.coval@osg.samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/5365
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Ziran Sun <ziran.sun@samsung.com>
Reviewed-by: Mats Wichmann <mats@osg.samsung.com>
Reviewed-by: Jon A. Cruz <jon@joncruz.org>
examples/OICSensorBoard/Makefile

index 2e7acb5..21c9068 100644 (file)
@@ -1,3 +1,5 @@
+default: all
+
 #Set the two variables below for the client build.
 CLIENTARCH?=x86
 BUILDTYPE?=release
@@ -11,6 +13,17 @@ CXXFLAGS=-I../../resource/include -I../../resource/c_common -I../../resource/csd
 
 LDFLAGS=-L../../out/linux/$(CLIENTARCH)/$(BUILDTYPE) -loc -loctbstack -loc_logger
 
+install_dir?=${DESTDIR}/usr/lib/iotivity/examples/OICSensorBoard
+
+exes?=client
+ifneq ($(SDKTARGETSYSROOT),)
+exes+=server
+endif
+
+
+all: client
+       @echo "server depends on mraa"
+
 client: client.o
        g++ -o client client.o $(LDFLAGS)
 
@@ -32,3 +45,7 @@ server: server.o observer.o
 
 clean:
        rm -rf server client *.o
+
+install: ${exes}
+       install -d ${install_dir}
+       install $^ ${install_dir}