From 3d2078c37278c1fe1c8e04eca7d5428feefc5353 Mon Sep 17 00:00:00 2001 From: Sven Almgren Date: Wed, 14 Mar 2012 11:59:13 +0100 Subject: [PATCH 1/5] Added new variable to specify base of boost library (BOOST_PREFIX) --- Makefile | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/Makefile b/Makefile index e004eb30be..dbc9ce2b08 100644 --- a/Makefile +++ b/Makefile @@ -30,8 +30,9 @@ objects = network_utilities.o sha1.o base64.o md5.o uri.o hybi_header.o data.o -BOOST_LIB_PATH ?= /usr/local/lib -BOOST_INCLUDE_PATH ?= /usr/local/include +BOOST_PREFIX ?= /usr/local +BOOST_LIB_PATH ?= $(BOOST_PREFIX)/lib +BOOST_INCLUDE_PATH ?= $(BOOST_PREFIX)/include libs = -L$(BOOST_LIB_PATH) -lboost_system -lboost_date_time -lboost_regex -lboost_random -lboost_program_options -lboost_thread From f9d21d80b618f0b0c309a45c6aaad8923b4919e2 Mon Sep 17 00:00:00 2001 From: Sven Almgren Date: Wed, 14 Mar 2012 12:09:04 +0100 Subject: [PATCH 2/5] Make sure lib-directory exists before copying files on install --- Makefile | 2 ++ 1 file changed, 2 insertions(+) diff --git a/Makefile b/Makefile index dbc9ce2b08..7bc384f8b3 100644 --- a/Makefile +++ b/Makefile @@ -170,6 +170,7 @@ $(objdir)/%.o: $(srcdir)/%.cpp ifeq ($(SHARED),1) install: banner install_headers $(lib_target) @echo "Install shared library" + mkdir -p $(inst_path) cp -f ./$(lib_target) $(inst_path) cd $(inst_path) ; \ ln -sf $(lib_target) $(libname_shared_major_version) ; \ @@ -181,6 +182,7 @@ install: banner install_headers $(lib_target) else install: banner install_headers $(lib_target) @echo "Install static library" + mkdir -p $(inst_path) cp -f ./$(lib_target) $(inst_path) @echo "Install static library: Done." endif From b985f5aa4b423354dbcffa07f76dd3f37eca210a Mon Sep 17 00:00:00 2001 From: Sven Almgren Date: Wed, 14 Mar 2012 12:31:58 +0100 Subject: [PATCH 3/5] Fixed if-statement for running ldconfig on newer Ubuntu --- Makefile | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/Makefile b/Makefile index 7bc384f8b3..fd7239faf7 100644 --- a/Makefile +++ b/Makefile @@ -175,9 +175,9 @@ install: banner install_headers $(lib_target) cd $(inst_path) ; \ ln -sf $(lib_target) $(libname_shared_major_version) ; \ ln -sf $(libname_shared_major_version) $(libname_shared) - ifneq ($(OS),Darwin) - ldconfig - endif + if test "$(OS)" != "Darwin" ; then \ + ldconfig ; \ + fi @echo "Install shared library: Done." else install: banner install_headers $(lib_target) From 5b9cab14ffc71f46ba7f30db7a748956ce009130 Mon Sep 17 00:00:00 2001 From: Sven Almgren Date: Wed, 14 Mar 2012 12:33:51 +0100 Subject: [PATCH 4/5] Removed quotes from SHARED and BUILD_TYPE defaults --- Makefile | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Makefile b/Makefile index fd7239faf7..366ab84610 100644 --- a/Makefile +++ b/Makefile @@ -75,8 +75,8 @@ srcdir ?= src CXX ?= c++ AR ?= ar PIC ?= PIC -BUILD_TYPE ?= "default" -SHARED ?= "1" +BUILD_TYPE ?= default +SHARED ?= 1 # Internal Variables From 6d206c0e9fb8f0e288bec16db82bcda129af936d Mon Sep 17 00:00:00 2001 From: Sven Almgren Date: Wed, 14 Mar 2012 12:36:46 +0100 Subject: [PATCH 5/5] Hide generated shared SO files --- .gitignore | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.gitignore b/.gitignore index 1e6f1faab8..4ea8142d22 100644 --- a/.gitignore +++ b/.gitignore @@ -10,6 +10,8 @@ *.o *.so +*.so.? +*.so.?.?.? *.a *.dylib