From e7d3879df43ae17b539fff555c4761c00259eef3 Mon Sep 17 00:00:00 2001 From: Peter Thorson Date: Sat, 10 Dec 2011 11:34:58 -0600 Subject: [PATCH] fixes stress client makefile --- examples/stress_client/Makefile | 11 +++++++---- examples/stress_client/stress_client.cpp | 2 +- 2 files changed, 8 insertions(+), 5 deletions(-) diff --git a/examples/stress_client/Makefile b/examples/stress_client/Makefile index 3809c3a0a1..76f4b1777d 100644 --- a/examples/stress_client/Makefile +++ b/examples/stress_client/Makefile @@ -1,13 +1,16 @@ -CFLAGS = -O2 -LDFLAGS = +BOOST_LIB_PATH ?= /usr/local/lib +BOOST_INCLUDE_PATH ?= /usr/local/include + +CFLAGS = -O2 -I$(BOOST_INCLUDE_PATH) +LDFLAGS = -L$(BOOST_LIB_PATH) CXX ?= c++ SHARED ?= "1" ifeq ($(SHARED), 1) - LDFLAGS := $(LDFLAGS) -lboost_system -lboost_thread -lwebsocketpp + LDFLAGS := $(LDFLAGS) -lboost_system -lboost_thread -lcrypto -lssl -lwebsocketpp else - LDFLAGS := $(LDFLAGS) -lboost_system -lboost_thread -lboost_date_time -lboost_regex -lboost_random -lboost_program_options ../../libwebsocketpp.a + LDFLAGS := $(LDFLAGS) $(BOOST_LIB_PATH)/libboost_system.a $(BOOST_LIB_PATH)/libboost_date_time.a $(BOOST_LIB_PATH)/libboost_regex.a -lcrypto -lssl ../../libwebsocketpp.a endif stress_client: stress_client.o diff --git a/examples/stress_client/stress_client.cpp b/examples/stress_client/stress_client.cpp index 91a1fbcdd1..5b568a5c8a 100644 --- a/examples/stress_client/stress_client.cpp +++ b/examples/stress_client/stress_client.cpp @@ -114,7 +114,7 @@ int main(int argc, char* argv[]) { } else if (result == EPERM) { std::cout << "Failed. This server will be limited to " << old_size << " concurrent connections. Error code: Insufficient permissions. Try running process as root. system max: " << old_max << std::endl; } else { - std::cout << "Failed. This server will be limited to " << old_size << " concurrent connections. Error code: " << errno << " system max: " old_max << std::endl; + std::cout << "Failed. This server will be limited to " << old_size << " concurrent connections. Error code: " << errno << " system max: " << old_max << std::endl; } } }