From aafefa7592ac0e34d1adc5a795bfba88c292ab78 Mon Sep 17 00:00:00 2001 From: Austin Seipp Date: Sat, 16 Jul 2011 00:49:35 -0500 Subject: [PATCH] Fix build on OS X; ld needs 'install_name', not 'soname' --- configure | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/configure b/configure index 79c1c3c..0cb0aea 100755 --- a/configure +++ b/configure @@ -357,7 +357,12 @@ if test "$COMPILER" = "suncc"; then PTHREAD_CFLAGS="-mt -lpthread" elif test "$COMPILER" = "gcc"; then LD=$CC - LDFLAGS="-shared -fPIC -Wl,-soname,libck.so.$VERSION_MAJOR $LDFLAGS" + if test "$SYSTEM" = "darwin"; then + CC_WL_OPT="-install_name" + else + CC_WL_OPT="-soname" + fi + LDFLAGS="-shared -fPIC -Wl,$CC_WL_OPT,libck.so.$VERSION_MAJOR $LDFLAGS" CFLAGS="-D_XOPEN_SOURCE=600 -D_BSD_SOURCE -std=gnu99 -pedantic -Wall -W -Wundef -Wendif-labels -Wshadow -Wpointer-arith -Wbad-function-cast -Wcast-align -Wwrite-strings -Wstrict-prototypes -Wmissing-prototypes -Wnested-externs -Winline -Wdisabled-optimization -fstrict-aliasing -O2 -pipe -Wno-parentheses $CFLAGS" PTHREAD_CFLAGS="-pthread" else