From 717618595087e3b5a73def1f0690d599df2a95ae Mon Sep 17 00:00:00 2001 From: lotodore Date: Sat, 30 Oct 2010 17:27:56 +0000 Subject: [PATCH] Allow use of boost libs which are located in /opt/boost by setting PREFIX (for header and lib). --- chatcleaner.pro | 7 ++++++- pokerth_db.pro | 5 +++++ pokerth_game.pro | 2 ++ pokerth_lib.pro | 7 ++++++- pokerth_server.pro | 3 ++- 5 files changed, 21 insertions(+), 3 deletions(-) diff --git a/chatcleaner.pro b/chatcleaner.pro index 72f94f21..c98bbc34 100644 --- a/chatcleaner.pro +++ b/chatcleaner.pro @@ -52,7 +52,12 @@ win32 { debug:LIBPATH += debug/lib release:LIBPATH += release/lib } -mac { +!win32{ + ##### My release static build options + #QMAKE_CXXFLAGS += -ffunction-sections -fdata-sections + INCLUDEPATH += $${PREFIX}/include +} +mac { # make it universal CONFIG += x86 CONFIG -= ppc diff --git a/pokerth_db.pro b/pokerth_db.pro index 98cfd7a4..d3f5629d 100644 --- a/pokerth_db.pro +++ b/pokerth_db.pro @@ -1,5 +1,9 @@ # QMake pro-file for PokerTH db library +isEmpty( PREFIX ){ + PREFIX =/usr +} + TEMPLATE = lib CODECFORSRC = UTF-8 @@ -44,6 +48,7 @@ win32{ !win32{ ##### My release static build options #QMAKE_CXXFLAGS += -ffunction-sections -fdata-sections + INCLUDEPATH += $${PREFIX}/include } mac{ diff --git a/pokerth_game.pro b/pokerth_game.pro index 0c41f17d..c1f18617 100644 --- a/pokerth_game.pro +++ b/pokerth_game.pro @@ -372,6 +372,8 @@ unix:!mac { # QMAKE_CXXFLAGS += -ffunction-sections -fdata-sections # QMAKE_LFLAGS += -Wl,--gc-sections LIBPATH += lib + LIBPATH += $${PREFIX}/lib + INCLUDEPATH += $${PREFIX}/include LIB_DIRS = $${PREFIX}/lib \ $${PREFIX}/lib64 BOOST_FS = boost_filesystem \ diff --git a/pokerth_lib.pro b/pokerth_lib.pro index c102495b..d70c5938 100644 --- a/pokerth_lib.pro +++ b/pokerth_lib.pro @@ -1,5 +1,9 @@ # QMake pro-file for PokerTH common library +isEmpty( PREFIX ){ + PREFIX =/usr +} + TEMPLATE = lib CODECFORSRC = UTF-8 @@ -220,13 +224,14 @@ official_server{ win32{ DEFINES += CURL_STATICLIB - DEFINES += _WIN32_WINNT=0x0501 + DEFINES += _WIN32_WINNT=0x0501 DEPENDPATH += src/net/win32/ src/core/win32 INCLUDEPATH += ../boost/ ../GnuTLS/include ../gsasl/include ../curl/include ../zlib ../openssl/include } !win32{ ##### My release static build options #QMAKE_CXXFLAGS += -ffunction-sections -fdata-sections + INCLUDEPATH += $${PREFIX}/include } mac{ diff --git a/pokerth_server.pro b/pokerth_server.pro index 61e9aaa5..4da3efdc 100644 --- a/pokerth_server.pro +++ b/pokerth_server.pro @@ -193,7 +193,8 @@ unix : !mac { #QMAKE_LFLAGS += -Wl,--gc-sections LIBPATH += lib - + LIBPATH += $${PREFIX}/lib + INCLUDEPATH += $${PREFIX}/include LIB_DIRS = $${PREFIX}/lib $${PREFIX}/lib64 BOOST_FS = boost_filesystem boost_filesystem-mt BOOST_THREAD = boost_thread boost_thread-mt