* avoid as much code and linker information as possible
[olsrd.git] / make / Makefile.osx
index fa94083..69ff7e7 100644 (file)
@@ -2,8 +2,12 @@
 # MAC OSX SPECIFIC CONFIGURATION
 #
 
-INSTALL_PREFIX ?=
-LIBDIR =       $(INSTALL_PREFIX)/usr/lib
+# don't strip executables and bundles for now until we figure out the proper way
+# to do it (flags).
+STRIP = \#
+
+DESTDIR ?=
+LIBDIR =       $(DESTDIR)/usr/lib
 
 SRCS +=                $(wildcard src/bsd/*.c) $(wildcard src/unix/*.c)
 HDRS +=                $(wildcard src/bsd/*.h) $(wildcard src/unix/*.h)
@@ -12,13 +16,17 @@ DEFINES =   -D__MacOSX__
 LIBS =         
 
 PLUGIN_FULLNAME ?= $(PLUGIN_NAME).so.$(PLUGIN_VER)
-INSTALL_LIB =  install -m 755 $(PLUGIN_FULLNAME) $(LIBDIR)/$(PLUGIN_FULLNAME); \
-               /sbin/ldconfig
+INSTALL_LIB =  install -m 755 $(PLUGIN_FULLNAME) $(LIBDIR)/$(PLUGIN_FULLNAME)
 
 ifdef OLSRD_PLUGIN
-CFLAGS +=      -fPIC
-LDFLAGS +=     -fPIC
+LDFLAGS = -bundle -flat_namespace -undefined suppress
+else
+LDFLAGS = -dynamic
 endif
-               
+
 OS_LIB_PTHREAD =
 OS_LIB_DYNLOAD =
+
+# Local Variables:
+# mode: makefile
+# End: