Skip to content

Instantly share code, notes, and snippets.

@dakcarto
Created November 11, 2013 20:33
Show Gist options
  • Save dakcarto/7419882 to your computer and use it in GitHub Desktop.
Save dakcarto/7419882 to your computer and use it in GitHub Desktop.
Fix to statically link internal custom dependencies, instead of creating .dylibs
diff --git a/third_party/Makefile.in b/third_party/Makefile.in
index ec56ad0..20cddc6 100644
--- a/third_party/Makefile.in
+++ b/third_party/Makefile.in
@@ -265,15 +265,15 @@ AM_CPPFLAGS = -I$(top_srcdir)/third_party/zlib-1.2.3/contrib \
-I$(top_srcdir)/third_party/googletest-r108 \
-I$(top_srcdir)/third_party/googletest-r108/include
-lib_LTLIBRARIES = libminizip.la liburiparser.la
-noinst_LTLIBRARIES = libgtest.la
+lib_LTLIBRARIES =
+noinst_LTLIBRARIES = libgtest.la libminizip.la liburiparser.la
libminizip_la_SOURCES = \
zlib-1.2.3/contrib/minizip/unzip.c \
zlib-1.2.3/contrib/minizip/ioapi.c \
zlib-1.2.3/contrib/minizip/iomem_simple.c \
zlib-1.2.3/contrib/minizip/zip.c
-libminizip_la_LDFLAGS = -lz
+libminizip_la_LDFLAGS = -static -lz
liburiparser_la_SOURCES = \
$(uriparser)/lib/UriCommon.c \
$(uriparser)/lib/UriCommon.h \
@@ -294,7 +294,7 @@ liburiparser_la_SOURCES = \
$(uriparser)/lib/UriResolve.c \
$(uriparser)/lib/UriShorten.c
-liburiparser_la_LDFLAGS = -version-info 1:5:0
+liburiparser_la_LDFLAGS = -static -version-info 1:5:0
boost_root = boost_1_34_1
boost = $(boost_root)/boost
boostinc = $(includedir)/kml/third_party/$(boost)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment