Skip to content
Snippets Groups Projects
Commit ba3aa72e authored by Guillaume Roguez's avatar Guillaume Roguez Committed by gerrit2
Browse files

fix configure.ac

Into the darwin OS detection the AC_EGREP_CPP macro is used.
This causes an bugged configure file issued and this one
prevents Linux platform to generate shared-library.

Following this link:
https://www.gnu.org/software/autoconf/manual/autoconf-2.69/html_node/AC_005fACT_005fIFELSE-vs-AC_005fTRY_005fACT.html

Using AC_EGREP_CPP is a bad way to test a C preprocessor.
This patch changes this call by AC_COMPILE_IFELSE + AC_LANG_PROGRAM calls:
- this is a better way to process
- this fix the linux shared build

Change-Id: I150666f2bc45a48d021110025f2d486a9750d333
Tuleap: #699
parent 207627be
Branches
Tags
No related merge requests found
...@@ -50,12 +50,12 @@ case "${host_os}" in ...@@ -50,12 +50,12 @@ case "${host_os}" in
;; ;;
darwin*) darwin*)
SYS=darwin SYS=darwin
AC_COMPILE_IFELSE([AC_LANG_PROGRAM(
AC_EGREP_CPP(yes, [[#import <TargetConditionals.h>
[#import <TargetConditionals.h> #if TARGET_OS_IPHONE == 0
#if TARGET_OS_IPHONE #error this is not an IPHONE
yes #endif
#endif], ]])],
[HAVE_IOS="1"], [HAVE_IOS="1"],
[HAVE_OSX="1"]) [HAVE_OSX="1"])
;; ;;
......
...@@ -75,6 +75,11 @@ libring_la_CFLAGS = \ ...@@ -75,6 +75,11 @@ libring_la_CFLAGS = \
libring_la_CXXFLAGS = @JSONCPP_CFLAGS@ libring_la_CXXFLAGS = @JSONCPP_CFLAGS@
if HAVE_LINUX
#needed to compile the .so
libring_la_CXXFLAGS += -fPIC
endif
libring_la_SOURCES = \ libring_la_SOURCES = \
buildinfo.cpp \ buildinfo.cpp \
conference.cpp \ conference.cpp \
...@@ -112,7 +117,7 @@ libring_la_SOURCES = \ ...@@ -112,7 +117,7 @@ libring_la_SOURCES = \
noncopyable.h \ noncopyable.h \
utf8_utils.h \ utf8_utils.h \
ring_types.h \ ring_types.h \
compiler_intrinsics.h \ intrin.h \
array_size.h \ array_size.h \
account_schema.h \ account_schema.h \
registration_states.h \ registration_states.h \
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment