From 0d1a2e09bcd1a194b9403aa7ba5e9f3d88b46f62 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Lo=C3=AFc=20Siret?= <loic.siret@savoirfairelinux.com>
Date: Wed, 5 Oct 2016 10:26:53 -0400
Subject: [PATCH] compilation: force sharedLib for OSX

OSX need Shared Library to compile the daemon. This patch ensure
that we didn't disable them on compilation.

Change-Id: Iedc37da7980599f2011e9501df0e4b087a0d7d0f
---
 scripts/install.sh | 11 +++++++++--
 1 file changed, 9 insertions(+), 2 deletions(-)

diff --git a/scripts/install.sh b/scripts/install.sh
index 4d2e0bc0..5e5ee81b 100755
--- a/scripts/install.sh
+++ b/scripts/install.sh
@@ -1,6 +1,7 @@
 #!/usr/bin/env bash
 
 # Build and install to a local prefix under this repository.
+export OSTYPE
 
 # Flags:
 
@@ -64,10 +65,16 @@ cd native
 make
 cd "${DAEMON}"
 ./autogen.sh
+
+#keep shared Lib on MAC OSX
+if [[ "$OSTYPE" != "darwin"* ]]; then
+    sharedLib="--disable-shared"
+fi
+
 if $global; then
-  ./configure --disable-shared $CONFIGURE_FLAGS
+  ./configure $sharedLib $CONFIGURE_FLAGS
 else
-  ./configure --disable-shared $CONFIGURE_FLAGS --prefix="${INSTALL}/daemon"
+  ./configure $sharedLib $CONFIGURE_FLAGS --prefix="${INSTALL}/daemon"
 fi
 make -j${proc}
 make_install $global
-- 
GitLab