diff options
author | Jay Threeth | 2011-04-23 12:52:06 -0700 |
---|---|---|
committer | Jay Threeth | 2011-04-23 12:52:06 -0700 |
commit | dcff75d6da80bab3defbe66f49b379ac91cf48dd (patch) | |
tree | 1e5c96e0fb826b1f0306c9b00615f6910e344374 | |
parent | Merge branch 'exp' of github.com:onefang/meta-impy into libotr (diff) | |
download | meta-impy-dcff75d6da80bab3defbe66f49b379ac91cf48dd.zip meta-impy-dcff75d6da80bab3defbe66f49b379ac91cf48dd.tar.gz meta-impy-dcff75d6da80bab3defbe66f49b379ac91cf48dd.tar.bz2 meta-impy-dcff75d6da80bab3defbe66f49b379ac91cf48dd.tar.xz |
Build libotr, and static link it, libgpg-error and libgcrypt into the exe (on linux)
-rw-r--r-- | linden/indra/CMakeLists.txt | 14 | ||||
-rw-r--r-- | linden/indra/newview/CMakeLists.txt | 22 | ||||
-rwxr-xr-x | linden/indra/newview/viewer_manifest.py | 12 |
3 files changed, 42 insertions, 6 deletions
diff --git a/linden/indra/CMakeLists.txt b/linden/indra/CMakeLists.txt index 5ef5d2c..2085ea1 100644 --- a/linden/indra/CMakeLists.txt +++ b/linden/indra/CMakeLists.txt | |||
@@ -35,6 +35,20 @@ file(MAKE_DIRECTORY ${CMAKE_BINARY_DIR}/temp) | |||
35 | file(WRITE ${CMAKE_BINARY_DIR}/temp/sentinel_installed "0") | 35 | file(WRITE ${CMAKE_BINARY_DIR}/temp/sentinel_installed "0") |
36 | add_subdirectory(cmake) | 36 | add_subdirectory(cmake) |
37 | 37 | ||
38 | # [$PLOTR$] | ||
39 | if (WINDOWS) | ||
40 | add_subdirectory(${LIBS_OPEN_PREFIX}gpg.vs) | ||
41 | add_subdirectory(${LIBS_OPEN_PREFIX}libgcrypt) | ||
42 | add_subdirectory(${LIBS_OPEN_PREFIX}libgpg-error) | ||
43 | endif (WINDOWS) | ||
44 | |||
45 | # if ON will cause linux to link in static OTR like windows does | ||
46 | # if off will use the systems libotr.so but won't be fully compatible with windows version | ||
47 | set(STATIC_LIBOTR_ETC 1) | ||
48 | |||
49 | add_subdirectory(${LIBS_OPEN_PREFIX}libotr) | ||
50 | # [/$PLOTR$] | ||
51 | |||
38 | add_subdirectory(${LIBS_OPEN_PREFIX}llaudio) | 52 | add_subdirectory(${LIBS_OPEN_PREFIX}llaudio) |
39 | add_subdirectory(${LIBS_OPEN_PREFIX}llcharacter) | 53 | add_subdirectory(${LIBS_OPEN_PREFIX}llcharacter) |
40 | add_subdirectory(${LIBS_OPEN_PREFIX}llcommon) | 54 | add_subdirectory(${LIBS_OPEN_PREFIX}llcommon) |
diff --git a/linden/indra/newview/CMakeLists.txt b/linden/indra/newview/CMakeLists.txt index 299164d..6d6e8c9 100644 --- a/linden/indra/newview/CMakeLists.txt +++ b/linden/indra/newview/CMakeLists.txt | |||
@@ -45,10 +45,13 @@ endif (WINDOWS) | |||
45 | # [$PLOTR$] | 45 | # [$PLOTR$] |
46 | include(libgcrypt) | 46 | include(libgcrypt) |
47 | include(libgpg-error) | 47 | include(libgpg-error) |
48 | include(libotr) | ||
49 | 48 | ||
50 | if (DARWIN OR LINUX) | 49 | if (DARWIN OR LINUX) |
50 | if (STATIC_LIBOTR_ETC) | ||
51 | include(libotr) # to build libotr from source and statically link in libgcrypt and libgpg-error | ||
52 | else (STATIC_LIBOTR_ETC) | ||
51 | include(libotrb) | 53 | include(libotrb) |
54 | endif (STATIC_LIBOTR_ETC) | ||
52 | endif (DARWIN OR LINUX) | 55 | endif (DARWIN OR LINUX) |
53 | # [/$PLOTR$] | 56 | # [/$PLOTR$] |
54 | 57 | ||
@@ -1059,9 +1062,19 @@ if (LINUX) | |||
1059 | LIST(APPEND viewer_SOURCE_FILES llappviewerlinux.cpp) | 1062 | LIST(APPEND viewer_SOURCE_FILES llappviewerlinux.cpp) |
1060 | SET(CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} -Wl,--as-needed") | 1063 | SET(CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} -Wl,--as-needed") |
1061 | 1064 | ||
1065 | # [$PLOTR$] | ||
1066 | if (STATIC_LIBOTR_ETC) # defined in .../linden/indra/CMakeLists.txt | ||
1062 | set(viewer_LIBRARIES | 1067 | set(viewer_LIBRARIES |
1063 | Xinerama | 1068 | Xinerama |
1069 | gpg-error | ||
1070 | gcrypt # to build libotr from source and statically link in libgcrypt and libgpg-error | ||
1064 | ) | 1071 | ) |
1072 | else (STATIC_LIBOTR_ETC) # below for dynamically linked, unmodified libotr | ||
1073 | set(viewer_LIBRARIES | ||
1074 | Xinerama | ||
1075 | ) | ||
1076 | endif (STATIC_LIBOTR_ETC) | ||
1077 | # [/$PLOTR$] | ||
1065 | endif (LINUX) | 1078 | endif (LINUX) |
1066 | 1079 | ||
1067 | if (WINDOWS) | 1080 | if (WINDOWS) |
@@ -1424,8 +1437,13 @@ if (WINDOWS) | |||
1424 | ${LIBOTR_LIBRARIES} | 1437 | ${LIBOTR_LIBRARIES} |
1425 | ) | 1438 | ) |
1426 | else (WINDOWS) | 1439 | else (WINDOWS) |
1440 | if (STATIC_LIBOTR_ETC) | ||
1441 | set(otr_link_libs ${LIBOTR_LIBRARIES} | ||
1442 | ) # statically linked libotr, built from source | ||
1443 | else (STATIC_LIBOTR_ETC) | ||
1427 | set(otr_link_libs ${OTR_LIBRARY} | 1444 | set(otr_link_libs ${OTR_LIBRARY} |
1428 | ) | 1445 | ) |
1446 | endif (STATIC_LIBOTR_ETC) | ||
1429 | endif (WINDOWS) | 1447 | endif (WINDOWS) |
1430 | # [/$PLOTR$] | 1448 | # [/$PLOTR$] |
1431 | 1449 | ||
diff --git a/linden/indra/newview/viewer_manifest.py b/linden/indra/newview/viewer_manifest.py index 0008e45..719c34e 100755 --- a/linden/indra/newview/viewer_manifest.py +++ b/linden/indra/newview/viewer_manifest.py | |||
@@ -1118,8 +1118,10 @@ class Linux_i686Manifest(LinuxManifest): | |||
1118 | 1118 | ||
1119 | #self.end_prefix("gstreamer-plugins") | 1119 | #self.end_prefix("gstreamer-plugins") |
1120 | 1120 | ||
1121 | self.path("libotr.so.2.2.0") | 1121 | # [$PLOTR$] these two are not needed when STATIC_LIBOTR_ETC is on in .../linden/indra/CMakeLists.txt |
1122 | self.path("libotr.so.2") | 1122 | # self.path("libotr.so.2.2.0") |
1123 | # self.path("libotr.so.2") | ||
1124 | # [/$PLOTR$] | ||
1123 | self.end_prefix("lib") | 1125 | self.end_prefix("lib") |
1124 | 1126 | ||
1125 | # Vivox runtimes and libs | 1127 | # Vivox runtimes and libs |
@@ -1252,8 +1254,10 @@ class Linux_x86_64Manifest(LinuxManifest): | |||
1252 | #self.path("libgstwavparse.so") | 1254 | #self.path("libgstwavparse.so") |
1253 | 1255 | ||
1254 | #self.end_prefix("gstreamer-plugins") | 1256 | #self.end_prefix("gstreamer-plugins") |
1255 | self.path("libotr.so.2.2.0") | 1257 | # [$PLOTR$] these two are not needed when STATIC_LIBOTR_ETC is on in .../linden/indra/CMakeLists.txt |
1256 | self.path("libotr.so.2") | 1258 | # self.path("libotr.so.2.2.0") |
1259 | # self.path("libotr.so.2") | ||
1260 | # [/$PLOTR$] | ||
1257 | self.end_prefix("lib64") | 1261 | self.end_prefix("lib64") |
1258 | 1262 | ||
1259 | 1263 | ||