aboutsummaryrefslogtreecommitdiffstatshomepage
diff options
context:
space:
mode:
-rw-r--r--linden/doc/contributions.txt1
-rw-r--r--linden/indra/cmake/00-Common.cmake2
-rw-r--r--linden/indra/cmake/APR.cmake20
-rw-r--r--linden/indra/cmake/BerkeleyDB.cmake7
-rw-r--r--linden/indra/cmake/CopyWinLibs.cmake6
-rw-r--r--linden/indra/cmake/LLCommon.cmake21
-rwxr-xr-xlinden/indra/develop.py8
-rw-r--r--linden/indra/llcharacter/llcharacter.cpp1
-rw-r--r--linden/indra/llcommon/CMakeLists.txt23
-rw-r--r--linden/indra/llcommon/imageids.h48
-rw-r--r--linden/indra/llcommon/indra_constants.h10
-rw-r--r--linden/indra/llcommon/linden_common.h19
-rw-r--r--linden/indra/llcommon/llapp.cpp2
-rw-r--r--linden/indra/llcommon/llapp.h13
-rw-r--r--linden/indra/llcommon/llapr.h21
-rw-r--r--linden/indra/llcommon/llassettype.h2
-rw-r--r--linden/indra/llcommon/llbase32.h2
-rw-r--r--linden/indra/llcommon/llbase64.h2
-rw-r--r--linden/indra/llcommon/llcommon.h2
-rw-r--r--linden/indra/llcommon/llcrc.h2
-rw-r--r--linden/indra/llcommon/llcriticaldamp.h2
-rw-r--r--linden/indra/llcommon/llcursortypes.h2
-rw-r--r--linden/indra/llcommon/lldate.h6
-rw-r--r--linden/indra/llcommon/llerror.cpp2
-rw-r--r--linden/indra/llcommon/llerror.h6
-rw-r--r--linden/indra/llcommon/llerrorcontrol.h46
-rw-r--r--linden/indra/llcommon/llerrorthread.cpp1
-rw-r--r--linden/indra/llcommon/llerrorthread.h2
-rw-r--r--linden/indra/llcommon/llevent.h10
-rw-r--r--linden/indra/llcommon/llfasttimer.cpp1
-rw-r--r--linden/indra/llcommon/llfasttimer.h4
-rw-r--r--linden/indra/llcommon/llfile.h10
-rw-r--r--linden/indra/llcommon/llfindlocale.h4
-rw-r--r--linden/indra/llcommon/llfixedbuffer.h2
-rw-r--r--linden/indra/llcommon/llformat.h2
-rw-r--r--linden/indra/llcommon/llframetimer.h2
-rw-r--r--linden/indra/llcommon/llheartbeat.h2
-rw-r--r--linden/indra/llcommon/llliveappconfig.h2
-rw-r--r--linden/indra/llcommon/lllivefile.h2
-rw-r--r--linden/indra/llcommon/lllog.h2
-rw-r--r--linden/indra/llcommon/llmd5.cpp1
-rw-r--r--linden/indra/llcommon/llmd5.h2
-rw-r--r--linden/indra/llcommon/llmemory.cpp13
-rw-r--r--linden/indra/llcommon/llmemory.h10
-rw-r--r--linden/indra/llcommon/llmemorystream.h4
-rw-r--r--linden/indra/llcommon/llmemtype.h2
-rw-r--r--linden/indra/llcommon/llmetrics.h2
-rw-r--r--linden/indra/llcommon/llmortician.h2
-rw-r--r--linden/indra/llcommon/llpreprocessor.h62
-rw-r--r--linden/indra/llcommon/llprocesslauncher.h2
-rw-r--r--linden/indra/llcommon/llqueuedthread.cpp1
-rw-r--r--linden/indra/llcommon/llqueuedthread.h4
-rw-r--r--linden/indra/llcommon/llrand.h12
-rw-r--r--linden/indra/llcommon/llrun.h6
-rw-r--r--linden/indra/llcommon/llsd.cpp12
-rw-r--r--linden/indra/llcommon/llsd.h4
-rw-r--r--linden/indra/llcommon/llsdserialize.h18
-rw-r--r--linden/indra/llcommon/llsdserialize_xml.cpp2
-rw-r--r--linden/indra/llcommon/llsdutil.h22
-rw-r--r--linden/indra/llcommon/llsecondlifeurls.h8
-rw-r--r--linden/indra/llcommon/llsimplehash.h2
-rw-r--r--linden/indra/llcommon/llstat.h14
-rw-r--r--linden/indra/llcommon/llstreamtools.h36
-rw-r--r--linden/indra/llcommon/llstring.h106
-rw-r--r--linden/indra/llcommon/llstringtable.h8
-rw-r--r--linden/indra/llcommon/llsys.h18
-rw-r--r--linden/indra/llcommon/llthread.h12
-rw-r--r--linden/indra/llcommon/lltimer.cpp4
-rw-r--r--linden/indra/llcommon/lltimer.h29
-rw-r--r--linden/indra/llcommon/lluri.h4
-rw-r--r--linden/indra/llcommon/lluuid.h9
-rw-r--r--linden/indra/llcommon/llworkerthread.h4
-rw-r--r--linden/indra/llcommon/metaclass.h2
-rw-r--r--linden/indra/llcommon/metaproperty.h2
-rw-r--r--linden/indra/llcommon/reflective.h2
-rw-r--r--linden/indra/llcommon/timing.h2
-rw-r--r--linden/indra/llcommon/u64.h10
-rw-r--r--linden/indra/llinventory/llparcel.h2
-rw-r--r--linden/indra/llmath/lloctree.h6
-rw-r--r--linden/indra/llmath/lltreenode.h2
-rw-r--r--linden/indra/llmessage/CMakeLists.txt4
-rw-r--r--linden/indra/llmessage/llassetstorage.cpp12
-rw-r--r--linden/indra/llmessage/llassetstorage.h6
-rw-r--r--linden/indra/llmessage/llcurl.cpp4
-rw-r--r--linden/indra/llmessage/llcurl.h2
-rw-r--r--linden/indra/llmessage/llhttpassetstorage.cpp2
-rw-r--r--linden/indra/llmessage/llhttpassetstorage.h2
-rw-r--r--linden/indra/llmessage/llhttpnode.cpp18
-rw-r--r--linden/indra/llmessage/llhttpnode.h10
-rw-r--r--linden/indra/llmessage/llpumpio.cpp1
-rw-r--r--linden/indra/llmessage/llregionpresenceverifier.cpp1
-rw-r--r--linden/indra/llmessage/llsdappservices.cpp4
-rw-r--r--linden/indra/llmessage/llsdhttpserver.cpp4
-rw-r--r--linden/indra/llplugin/CMakeLists.txt4
-rw-r--r--linden/indra/llrender/llfontgl.cpp1
-rw-r--r--linden/indra/llrender/llgl.cpp2
-rw-r--r--linden/indra/llui/llfunctorregistry.cpp1
-rw-r--r--linden/indra/llvfs/lldir.cpp1
-rwxr-xr-xlinden/indra/llvfs/llpidlock.cpp3
-rwxr-xr-xlinden/indra/llvfs/llpidlock.h2
-rw-r--r--linden/indra/llvfs/llvfile.cpp1
-rw-r--r--linden/indra/llvfs/llvfs.cpp1
-rw-r--r--linden/indra/llwindow/CMakeLists.txt1
-rw-r--r--linden/indra/llwindow/lldxhardware.cpp1
-rw-r--r--linden/indra/llwindow/llwindowmacosx.h1
-rw-r--r--linden/indra/llwindow/llwindowsdl.cpp6
-rw-r--r--linden/indra/llwindow/llwindowsdl.h2
-rw-r--r--linden/indra/llwindow/llwindowwin32.cpp2
-rw-r--r--linden/indra/lscript/lscript_execute.h1
-rw-r--r--linden/indra/lscript/lscript_execute/llscriptresource.cpp1
-rw-r--r--linden/indra/media_plugins/base/CMakeLists.txt4
-rw-r--r--linden/indra/media_plugins/example/CMakeLists.txt4
-rw-r--r--linden/indra/media_plugins/gstreamer010/CMakeLists.txt12
-rwxr-xr-xlinden/indra/media_plugins/gstreamer010/llmediaimplgstreamertriviallogging.h26
-rwxr-xr-xlinden/indra/media_plugins/gstreamer010/media_plugin_gstreamer010.cpp2
-rw-r--r--linden/indra/media_plugins/webkit/CMakeLists.txt12
-rw-r--r--linden/indra/newview/CMakeLists.txt14
-rw-r--r--linden/indra/newview/emeraldboobutils.cpp1
-rw-r--r--linden/indra/newview/llagent.cpp4
-rw-r--r--linden/indra/newview/llappviewer.h2
-rw-r--r--linden/indra/newview/llfeaturemanager.cpp1
-rw-r--r--linden/indra/newview/llfloaterabout.cpp1
-rw-r--r--linden/indra/newview/llfloaterregioninfo.cpp6
-rw-r--r--linden/indra/newview/llfloaterregioninfo.h2
-rw-r--r--linden/indra/newview/llfolderview.h2
-rw-r--r--linden/indra/newview/llhomelocationresponder.cpp5
-rw-r--r--linden/indra/newview/llhomelocationresponder.h2
-rw-r--r--linden/indra/newview/llinventorybridge.h2
-rw-r--r--linden/indra/newview/llpanelinventory.cpp5
-rw-r--r--linden/indra/newview/llspatialpartition.cpp6
-rw-r--r--linden/indra/newview/llviewerassetstorage.h1
-rw-r--r--linden/indra/newview/llwatchdog.h3
-rwxr-xr-xlinden/indra/newview/viewer_manifest.py55
-rwxr-xr-xlinden/install.xml12
134 files changed, 579 insertions, 491 deletions
diff --git a/linden/doc/contributions.txt b/linden/doc/contributions.txt
index cd6544a..89d22ee 100644
--- a/linden/doc/contributions.txt
+++ b/linden/doc/contributions.txt
@@ -90,6 +90,7 @@ Aleric Inglewood
90 IMP-667 90 IMP-667
91 IMP-670 91 IMP-670
92 IMP-688 92 IMP-688
93 IMP-692
93Alissa Sabre 94Alissa Sabre
94 VWR-81 95 VWR-81
95 VWR-83 96 VWR-83
diff --git a/linden/indra/cmake/00-Common.cmake b/linden/indra/cmake/00-Common.cmake
index 4c04be9..c3aa9ea 100644
--- a/linden/indra/cmake/00-Common.cmake
+++ b/linden/indra/cmake/00-Common.cmake
@@ -210,7 +210,7 @@ if (LINUX OR DARWIN)
210 set(GCC_WARNINGS "${GCC_WARNINGS} -Werror") 210 set(GCC_WARNINGS "${GCC_WARNINGS} -Werror")
211 endif (NOT GCC_DISABLE_FATAL_WARNINGS) 211 endif (NOT GCC_DISABLE_FATAL_WARNINGS)
212 212
213 set(GCC_CXX_WARNINGS "${GCC_WARNINGS} -Wno-reorder -Wno-non-virtual-dtor") 213 set(GCC_CXX_WARNINGS "${GCC_WARNINGS} -Wno-reorder -Wno-non-virtual-dtor -Woverloaded-virtual")
214 214
215 set(CMAKE_C_FLAGS "${GCC_WARNINGS} ${CMAKE_C_FLAGS}") 215 set(CMAKE_C_FLAGS "${GCC_WARNINGS} ${CMAKE_C_FLAGS}")
216 set(CMAKE_CXX_FLAGS "${GCC_CXX_WARNINGS} ${CMAKE_CXX_FLAGS}") 216 set(CMAKE_CXX_FLAGS "${GCC_CXX_WARNINGS} ${CMAKE_CXX_FLAGS}")
diff --git a/linden/indra/cmake/APR.cmake b/linden/indra/cmake/APR.cmake
index e9f6411..d1f0898 100644
--- a/linden/indra/cmake/APR.cmake
+++ b/linden/indra/cmake/APR.cmake
@@ -14,27 +14,27 @@ else (STANDALONE)
14 use_prebuilt_binary(apr_suite) 14 use_prebuilt_binary(apr_suite)
15 if (WINDOWS) 15 if (WINDOWS)
16 set(APR_LIBRARIES 16 set(APR_LIBRARIES
17 debug ${ARCH_PREBUILT_DIRS_DEBUG}/apr-1.lib 17 debug ${ARCH_PREBUILT_DIRS_DEBUG}/libapr-1.lib
18 optimized ${ARCH_PREBUILT_DIRS_RELEASE}/apr-1.lib 18 optimized ${ARCH_PREBUILT_DIRS_RELEASE}/libapr-1.lib
19 ) 19 )
20 set(APRICONV_LIBRARIES 20 set(APRICONV_LIBRARIES
21 debug ${ARCH_PREBUILT_DIRS_DEBUG}/apriconv-1.lib 21 debug ${ARCH_PREBUILT_DIRS_DEBUG}/libapriconv-1.lib
22 optimized ${ARCH_PREBUILT_DIRS_RELEASE}/apriconv-1.lib 22 optimized ${ARCH_PREBUILT_DIRS_RELEASE}/libapriconv-1.lib
23 ) 23 )
24 # Doesn't need to link with iconv.dll 24 # Doesn't need to link with iconv.dll
25 set(APRICONV_LIBRARIES "") 25 set(APRICONV_LIBRARIES "")
26 set(APRUTIL_LIBRARIES 26 set(APRUTIL_LIBRARIES
27 debug ${ARCH_PREBUILT_DIRS_DEBUG}/aprutil-1.lib ${APRICONV_LIBRARIES} 27 debug ${ARCH_PREBUILT_DIRS_DEBUG}/libaprutil-1.lib ${APRICONV_LIBRARIES}
28 optimized ${ARCH_PREBUILT_DIRS_RELEASE}/aprutil-1.lib ${APRICONV_LIBRARIES} 28 optimized ${ARCH_PREBUILT_DIRS_RELEASE}/libaprutil-1.lib ${APRICONV_LIBRARIES}
29 ) 29 )
30 elseif (DARWIN) 30 elseif (DARWIN)
31 set(APR_LIBRARIES 31 set(APR_LIBRARIES
32 debug ${ARCH_PREBUILT_DIRS_DEBUG}/libapr-1.a 32 debug ${ARCH_PREBUILT_DIRS_DEBUG}/libapr-1.0.3.7.dylib
33 optimized ${ARCH_PREBUILT_DIRS_RELEASE}/libapr-1.a 33 optimized ${ARCH_PREBUILT_DIRS_RELEASE}/libapr-1.0.3.7.dylib
34 ) 34 )
35 set(APRUTIL_LIBRARIES 35 set(APRUTIL_LIBRARIES
36 debug ${ARCH_PREBUILT_DIRS_DEBUG}/libaprutil-1.a 36 debug ${ARCH_PREBUILT_DIRS_DEBUG}/libaprutil-1.0.3.8.dylib
37 optimized ${ARCH_PREBUILT_DIRS_RELEASE}/libaprutil-1.a 37 optimized ${ARCH_PREBUILT_DIRS_RELEASE}/libaprutil-1.0.3.8.dylib
38 ) 38 )
39 set(APRICONV_LIBRARIES iconv) 39 set(APRICONV_LIBRARIES iconv)
40 else (WINDOWS) 40 else (WINDOWS)
diff --git a/linden/indra/cmake/BerkeleyDB.cmake b/linden/indra/cmake/BerkeleyDB.cmake
index d98e791..de62763 100644
--- a/linden/indra/cmake/BerkeleyDB.cmake
+++ b/linden/indra/cmake/BerkeleyDB.cmake
@@ -6,6 +6,11 @@ set(DB_FIND_REQUIRED ON)
6if (STANDALONE) 6if (STANDALONE)
7 include(FindBerkeleyDB) 7 include(FindBerkeleyDB)
8else (STANDALONE) 8else (STANDALONE)
9 set(DB_LIBRARIES db-4.2) 9 if (LINUX)
10 # Need to add dependency pthread explicitely to support ld.gold.
11 set(DB_LIBRARIES db-4.2 pthread)
12 else (LINUX)
13 set(DB_LIBRARIES db-4.2)
14 endif (LINUX)
10 set(DB_INCLUDE_DIRS ${LIBS_PREBUILT_DIR}/include) 15 set(DB_INCLUDE_DIRS ${LIBS_PREBUILT_DIR}/include)
11endif (STANDALONE) 16endif (STANDALONE)
diff --git a/linden/indra/cmake/CopyWinLibs.cmake b/linden/indra/cmake/CopyWinLibs.cmake
index a091a31..f584689 100644
--- a/linden/indra/cmake/CopyWinLibs.cmake
+++ b/linden/indra/cmake/CopyWinLibs.cmake
@@ -29,6 +29,9 @@ set(debug_files
29 openal32.dll 29 openal32.dll
30 openjpegd.dll 30 openjpegd.dll
31 libhunspell.dll 31 libhunspell.dll
32 libapr-1.dll
33 libaprutil-1.dll
34 libapriconv-1.dll
32 ) 35 )
33 36
34copy_if_different( 37copy_if_different(
@@ -209,6 +212,9 @@ set(release_files
209 openal32.dll 212 openal32.dll
210 openjpeg.dll 213 openjpeg.dll
211 libhunspell.dll 214 libhunspell.dll
215 libapr-1.dll
216 libaprutil-1.dll
217 libapriconv-1.dll
212 ) 218 )
213 219
214copy_if_different( 220copy_if_different(
diff --git a/linden/indra/cmake/LLCommon.cmake b/linden/indra/cmake/LLCommon.cmake
index 9158e98..d87d3c0 100644
--- a/linden/indra/cmake/LLCommon.cmake
+++ b/linden/indra/cmake/LLCommon.cmake
@@ -7,20 +7,15 @@ include(ZLIB)
7 7
8set(LLCOMMON_INCLUDE_DIRS 8set(LLCOMMON_INCLUDE_DIRS
9 ${LIBS_OPEN_DIR}/llcommon 9 ${LIBS_OPEN_DIR}/llcommon
10 ${APRUTIL_INCLUDE_DIR}
11 ${APR_INCLUDE_DIR} 10 ${APR_INCLUDE_DIR}
12 ${Boost_INCLUDE_DIRS} 11 ${Boost_INCLUDE_DIRS}
13 ) 12 )
14 13
15# Files that need PIC code (pluginAPI) need to set REQUIRE_PIC on 64bit systems 14if (LINUX)
16# this will link against a llcommon built with Position Independent Code 15 # In order to support using ld.gold on linux, we need to explicitely
17# this is a requirment to link a static library (.a) to a DSO on 64 bit systems 16 # specify all libraries that llcommon uses.
18 17 # llcommon uses `clock_gettime' which is provided by librt on linux.
19if(REQUIRE_PIC) 18 set(LLCOMMON_LIBRARIES llcommon rt)
20 set(LLCOMMON_LIBRARIES llcommonPIC) 19else (LINUX)
21else(REQUIRE_PIC) 20 set(LLCOMMON_LIBRARIES llcommon)
22 set(LLCOMMON_LIBRARIES llcommon) 21endif (LINUX)
23endif(REQUIRE_PIC)
24
25#force clear the flag, files that need this must explicity set it themselves
26set(REQUIRE_PIC 0) \ No newline at end of file
diff --git a/linden/indra/develop.py b/linden/indra/develop.py
index 2ce9f91..e804374 100755
--- a/linden/indra/develop.py
+++ b/linden/indra/develop.py
@@ -76,6 +76,7 @@ class PlatformSetup(object):
76 build_type = build_types['relwithdebinfo'] 76 build_type = build_types['relwithdebinfo']
77 standalone = 'OFF' 77 standalone = 'OFF'
78 unattended = 'OFF' 78 unattended = 'OFF'
79 universal = 'OFF'
79 project_name = 'Imprudence' 80 project_name = 'Imprudence'
80 distcc = True 81 distcc = True
81 cmake_opts = [] 82 cmake_opts = []
@@ -404,7 +405,7 @@ class DarwinSetup(UnixSetup):
404 return 'darwin' 405 return 'darwin'
405 406
406 def arch(self): 407 def arch(self):
407 if self.unattended == 'ON': 408 if self.universal == 'ON':
408 return 'universal' 409 return 'universal'
409 else: 410 else:
410 return UnixSetup.arch(self) 411 return UnixSetup.arch(self)
@@ -417,10 +418,10 @@ class DarwinSetup(UnixSetup):
417 standalone=self.standalone, 418 standalone=self.standalone,
418 unattended=self.unattended, 419 unattended=self.unattended,
419 project_name=self.project_name, 420 project_name=self.project_name,
420 universal='', 421 universal=self.universal,
421 type=self.build_type.upper() 422 type=self.build_type.upper()
422 ) 423 )
423 if self.unattended == 'ON': 424 if self.universal == 'ON':
424 args['universal'] = '-DCMAKE_OSX_ARCHITECTURES:STRING=\'i386\'' 425 args['universal'] = '-DCMAKE_OSX_ARCHITECTURES:STRING=\'i386\''
425 #if simple: 426 #if simple:
426 # return 'cmake %(opts)s %(dir)r' % args 427 # return 'cmake %(opts)s %(dir)r' % args
@@ -696,6 +697,7 @@ Options:
696 --standalone build standalone, without Linden prebuild libraries 697 --standalone build standalone, without Linden prebuild libraries
697 --unattended build unattended, do not invoke any tools requiring 698 --unattended build unattended, do not invoke any tools requiring
698 a human response 699 a human response
700 --universal build a universal binary on Mac OS X (unsupported)
699 -t | --type=NAME build type ("Debug", "Release", or "RelWithDebInfo") 701 -t | --type=NAME build type ("Debug", "Release", or "RelWithDebInfo")
700 -N | --no-distcc disable use of distcc 702 -N | --no-distcc disable use of distcc
701 -G | --generator=NAME generator name 703 -G | --generator=NAME generator name
diff --git a/linden/indra/llcharacter/llcharacter.cpp b/linden/indra/llcharacter/llcharacter.cpp
index dcdfe07..46ac326 100644
--- a/linden/indra/llcharacter/llcharacter.cpp
+++ b/linden/indra/llcharacter/llcharacter.cpp
@@ -38,6 +38,7 @@
38 38
39#include "llcharacter.h" 39#include "llcharacter.h"
40#include "llstring.h" 40#include "llstring.h"
41#include "llfasttimer.h"
41 42
42#define SKEL_HEADER "Linden Skeleton 1.0" 43#define SKEL_HEADER "Linden Skeleton 1.0"
43 44
diff --git a/linden/indra/llcommon/CMakeLists.txt b/linden/indra/llcommon/CMakeLists.txt
index 7d001ae..5d590a9 100644
--- a/linden/indra/llcommon/CMakeLists.txt
+++ b/linden/indra/llcommon/CMakeLists.txt
@@ -4,6 +4,7 @@ project(llcommon)
4 4
5include(00-Common) 5include(00-Common)
6include(LLCommon) 6include(LLCommon)
7include(Linking)
7 8
8include_directories( 9include_directories(
9 ${EXPAT_INCLUDE_DIRS} 10 ${EXPAT_INCLUDE_DIRS}
@@ -192,31 +193,13 @@ set_source_files_properties(${llcommon_HEADER_FILES}
192 193
193list(APPEND llcommon_SOURCE_FILES ${llcommon_HEADER_FILES}) 194list(APPEND llcommon_SOURCE_FILES ${llcommon_HEADER_FILES})
194 195
195add_library (llcommon ${llcommon_SOURCE_FILES}) 196add_library (llcommon SHARED ${llcommon_SOURCE_FILES})
196target_link_libraries( 197target_link_libraries(
197 llcommon 198 llcommon
198 ${APRUTIL_LIBRARIES} 199 ${APRUTIL_LIBRARIES}
199 ${APR_LIBRARIES} 200 ${APR_LIBRARIES}
200 ${EXPAT_LIBRARIES} 201 ${EXPAT_LIBRARIES}
201 ${ZLIB_LIBRARIES} 202 ${ZLIB_LIBRARIES}
203 ${WINDOWS_LIBRARIES}
202 ) 204 )
203 205
204if(HAVE_64_BIT)
205 add_library (llcommonPIC ${llcommon_SOURCE_FILES})
206 add_dependencies(llcommonPIC prepare)
207
208 if(WINDOWS)
209 add_definitions(/FIXED:NO)
210 else(WINDOWS) # not windows therefore gcc LINUX and DARWIN
211 add_definitions(-fPIC)
212 endif(WINDOWS)
213
214 target_link_libraries(
215 llcommonPIC
216 ${APRUTIL_LIBRARIES}
217 ${APR_LIBRARIES}
218 ${EXPAT_LIBRARIES}
219 ${ZLIB_LIBRARIES}
220 )
221endif(HAVE_64_BIT)
222
diff --git a/linden/indra/llcommon/imageids.h b/linden/indra/llcommon/imageids.h
index 7bae496..dc726dc 100644
--- a/linden/indra/llcommon/imageids.h
+++ b/linden/indra/llcommon/imageids.h
@@ -41,35 +41,35 @@
41 41
42class LLUUID; 42class LLUUID;
43 43
44extern const LLUUID IMG_SMOKE; 44LL_COMMON_API extern const LLUUID IMG_SMOKE;
45 45
46extern const LLUUID IMG_DEFAULT; 46LL_COMMON_API extern const LLUUID IMG_DEFAULT;
47 47
48extern const LLUUID IMG_SUN; 48LL_COMMON_API extern const LLUUID IMG_SUN;
49extern const LLUUID IMG_MOON; 49LL_COMMON_API extern const LLUUID IMG_MOON;
50extern const LLUUID IMG_CLOUD_POOF; 50LL_COMMON_API extern const LLUUID IMG_CLOUD_POOF;
51extern const LLUUID IMG_SHOT; 51LL_COMMON_API extern const LLUUID IMG_SHOT;
52extern const LLUUID IMG_SPARK; 52LL_COMMON_API extern const LLUUID IMG_SPARK;
53extern const LLUUID IMG_FIRE; 53LL_COMMON_API extern const LLUUID IMG_FIRE;
54extern const LLUUID IMG_FACE_SELECT; 54LL_COMMON_API extern const LLUUID IMG_FACE_SELECT;
55extern const LLUUID IMG_DEFAULT_AVATAR; 55LL_COMMON_API extern const LLUUID IMG_DEFAULT_AVATAR;
56extern const LLUUID IMG_INVISIBLE; 56LL_COMMON_API extern const LLUUID IMG_INVISIBLE;
57 57
58extern const LLUUID IMG_EXPLOSION; 58LL_COMMON_API extern const LLUUID IMG_EXPLOSION;
59extern const LLUUID IMG_EXPLOSION_2; 59LL_COMMON_API extern const LLUUID IMG_EXPLOSION_2;
60extern const LLUUID IMG_EXPLOSION_3; 60LL_COMMON_API extern const LLUUID IMG_EXPLOSION_3;
61extern const LLUUID IMG_EXPLOSION_4; 61LL_COMMON_API extern const LLUUID IMG_EXPLOSION_4;
62extern const LLUUID IMG_SMOKE_POOF; 62LL_COMMON_API extern const LLUUID IMG_SMOKE_POOF;
63 63
64extern const LLUUID IMG_BIG_EXPLOSION_1; 64LL_COMMON_API extern const LLUUID IMG_BIG_EXPLOSION_1;
65extern const LLUUID IMG_BIG_EXPLOSION_2; 65LL_COMMON_API extern const LLUUID IMG_BIG_EXPLOSION_2;
66 66
67extern const LLUUID IMG_BLOOM1; 67LL_COMMON_API extern const LLUUID IMG_BLOOM1;
68extern const LLUUID TERRAIN_DIRT_DETAIL; 68LL_COMMON_API extern const LLUUID TERRAIN_DIRT_DETAIL;
69extern const LLUUID TERRAIN_GRASS_DETAIL; 69LL_COMMON_API extern const LLUUID TERRAIN_GRASS_DETAIL;
70extern const LLUUID TERRAIN_MOUNTAIN_DETAIL; 70LL_COMMON_API extern const LLUUID TERRAIN_MOUNTAIN_DETAIL;
71extern const LLUUID TERRAIN_ROCK_DETAIL; 71LL_COMMON_API extern const LLUUID TERRAIN_ROCK_DETAIL;
72 72
73extern const LLUUID DEFAULT_WATER_NORMAL; 73LL_COMMON_API extern const LLUUID DEFAULT_WATER_NORMAL;
74 74
75#endif 75#endif
diff --git a/linden/indra/llcommon/indra_constants.h b/linden/indra/llcommon/indra_constants.h
index 34d1538..279d280 100644
--- a/linden/indra/llcommon/indra_constants.h
+++ b/linden/indra/llcommon/indra_constants.h
@@ -263,15 +263,15 @@ const U8 GOD_LIKE = 1;
263const U8 GOD_NOT = 0; 263const U8 GOD_NOT = 0;
264 264
265// "agent id" for things that should be done to ALL agents 265// "agent id" for things that should be done to ALL agents
266extern const LLUUID LL_UUID_ALL_AGENTS; 266LL_COMMON_API extern const LLUUID LL_UUID_ALL_AGENTS;
267 267
268// inventory library owner 268// inventory library owner
269extern const LLUUID ALEXANDRIA_LINDEN_ID; 269LL_COMMON_API extern const LLUUID ALEXANDRIA_LINDEN_ID;
270 270
271extern const LLUUID GOVERNOR_LINDEN_ID; 271LL_COMMON_API extern const LLUUID GOVERNOR_LINDEN_ID;
272extern const LLUUID REALESTATE_LINDEN_ID; 272LL_COMMON_API extern const LLUUID REALESTATE_LINDEN_ID;
273// Maintenance's group id. 273// Maintenance's group id.
274extern const LLUUID MAINTENANCE_GROUP_ID; 274LL_COMMON_API extern const LLUUID MAINTENANCE_GROUP_ID;
275 275
276// Flags for kick message 276// Flags for kick message
277const U32 KICK_FLAGS_DEFAULT = 0x0; 277const U32 KICK_FLAGS_DEFAULT = 0x0;
diff --git a/linden/indra/llcommon/linden_common.h b/linden/indra/llcommon/linden_common.h
index 25dd629..bf844b9 100644
--- a/linden/indra/llcommon/linden_common.h
+++ b/linden/indra/llcommon/linden_common.h
@@ -51,16 +51,16 @@
51#include <cstdio> 51#include <cstdio>
52#include <cstdlib> 52#include <cstdlib>
53#include <ctime> 53#include <ctime>
54#include <iostream> 54#include <iosfwd>
55#include <fstream>
56 55
57// Work Microsoft compiler warnings 56// Work around Microsoft compiler warnings in STL headers
58#ifdef LL_WINDOWS 57#ifdef LL_WINDOWS
59#pragma warning (disable : 4702) // unreachable code 58#pragma warning (disable : 4702) // unreachable code
60#pragma warning (disable : 4244) // conversion from time_t to S32 59#pragma warning (disable : 4244) // conversion from time_t to S32
61#endif // LL_WINDOWS 60#endif // LL_WINDOWS
62 61
63#include <algorithm> 62// *TODO: Eliminate these, most library .cpp files don't need them.
63// Add them to llviewerprecompiledheaders.h if necessary.
64#include <list> 64#include <list>
65#include <map> 65#include <map>
66#include <vector> 66#include <vector>
@@ -76,18 +76,21 @@
76#pragma warning (disable : 4512) // assignment operator could not be generated 76#pragma warning (disable : 4512) // assignment operator could not be generated
77#pragma warning (disable : 4706) // assignment within conditional (even if((x = y)) ) 77#pragma warning (disable : 4706) // assignment within conditional (even if((x = y)) )
78#pragma warning (disable : 4265) // boost 1.36.0, non-virtual destructor in boost::exception_detail::* 78#pragma warning (disable : 4265) // boost 1.36.0, non-virtual destructor in boost::exception_detail::*
79
80// Reenable warnings we disabled above
81#pragma warning (3 : 4702) // unreachable code, we like level 3, not 4
82// moved msvc warnings to llpreprocessor.h *TODO - delete this comment after merge conflicts are unlikely -brad
79#endif // LL_WINDOWS 83#endif // LL_WINDOWS
80 84
81// Linden only libs in alpha-order other than stdtypes.h 85// Linden only libs in alpha-order other than stdtypes.h
86// *NOTE: Please keep includes here to a minimum, see above.
82#include "stdtypes.h" 87#include "stdtypes.h"
83#include "lldefs.h" 88#include "lldefs.h"
84#include "llerror.h" 89#include "llerror.h"
85#include "llextendedstatus.h" 90#include "llextendedstatus.h"
86#include "llfasttimer.h" 91// Don't do this, adds 15K lines of header code to every library file.
92//#include "llfasttimer.h"
87#include "llfile.h" 93#include "llfile.h"
88#include "llformat.h" 94#include "llformat.h"
89#include "llstring.h"
90#include "llsys.h"
91#include "lltimer.h"
92 95
93#endif 96#endif
diff --git a/linden/indra/llcommon/llapp.cpp b/linden/indra/llcommon/llapp.cpp
index 199315f..e269f59 100644
--- a/linden/indra/llcommon/llapp.cpp
+++ b/linden/indra/llcommon/llapp.cpp
@@ -420,7 +420,7 @@ void LLApp::incSigChildCount()
420int LLApp::getPid() 420int LLApp::getPid()
421{ 421{
422#if LL_WINDOWS 422#if LL_WINDOWS
423 return 0; 423 return GetCurrentProcessId();
424#else 424#else
425 return getpid(); 425 return getpid();
426#endif 426#endif
diff --git a/linden/indra/llcommon/llapp.h b/linden/indra/llcommon/llapp.h
index f8a593c..96112c9 100644
--- a/linden/indra/llcommon/llapp.h
+++ b/linden/indra/llcommon/llapp.h
@@ -34,14 +34,17 @@
34#define LL_LLAPP_H 34#define LL_LLAPP_H
35 35
36#include <map> 36#include <map>
37#include "llapr.h"
38#include "llrun.h" 37#include "llrun.h"
39#include "llsd.h" 38#include "llsd.h"
40 39
41// Forward declarations 40// Forward declarations
41template <typename Type> class LLAtomic32;
42typedef LLAtomic32<U32> LLAtomicU32;
42class LLErrorThread; 43class LLErrorThread;
43class LLApp; 44class LLLiveFile;
44 45#if LL_LINUX
46typedef struct siginfo siginfo_t;
47#endif
45 48
46typedef void (*LLAppErrorHandler)(); 49typedef void (*LLAppErrorHandler)();
47typedef void (*LLAppChildCallback)(int pid, bool exited, int status); 50typedef void (*LLAppChildCallback)(int pid, bool exited, int status);
@@ -62,7 +65,7 @@ public:
62}; 65};
63#endif 66#endif
64 67
65class LLApp 68class LL_COMMON_API LLApp
66{ 69{
67 friend class LLErrorThread; 70 friend class LLErrorThread;
68public: 71public:
@@ -189,8 +192,6 @@ public:
189#if !LL_WINDOWS 192#if !LL_WINDOWS
190 static U32 getSigChildCount(); 193 static U32 getSigChildCount();
191 static void incSigChildCount(); 194 static void incSigChildCount();
192#else
193#define getpid GetCurrentProcessId
194#endif 195#endif
195 static int getPid(); 196 static int getPid();
196 197
diff --git a/linden/indra/llcommon/llapr.h b/linden/indra/llcommon/llapr.h
index 7f770b0..2aed515 100644
--- a/linden/indra/llcommon/llapr.h
+++ b/linden/indra/llcommon/llapr.h
@@ -48,25 +48,24 @@
48#include "apr_atomic.h" 48#include "apr_atomic.h"
49#include "llstring.h" 49#include "llstring.h"
50 50
51extern apr_thread_mutex_t* gLogMutexp; 51extern LL_COMMON_API apr_thread_mutex_t* gLogMutexp;
52extern apr_thread_mutex_t* gCallStacksLogMutexp;
53 52
54/** 53/**
55 * @brief initialize the common apr constructs -- apr itself, the 54 * @brief initialize the common apr constructs -- apr itself, the
56 * global pool, and a mutex. 55 * global pool, and a mutex.
57 */ 56 */
58void ll_init_apr(); 57void LL_COMMON_API ll_init_apr();
59 58
60/** 59/**
61 * @brief Cleanup those common apr constructs. 60 * @brief Cleanup those common apr constructs.
62 */ 61 */
63void ll_cleanup_apr(); 62void LL_COMMON_API ll_cleanup_apr();
64 63
65// 64//
66//LL apr_pool 65//LL apr_pool
67//manage apr_pool_t, destroy allocated apr_pool in the destruction function. 66//manage apr_pool_t, destroy allocated apr_pool in the destruction function.
68// 67//
69class LLAPRPool 68class LL_COMMON_API LLAPRPool
70{ 69{
71public: 70public:
72 LLAPRPool(apr_pool_t *parent = NULL, apr_size_t size = 0, BOOL releasePoolFlag = TRUE) ; 71 LLAPRPool(apr_pool_t *parent = NULL, apr_size_t size = 0, BOOL releasePoolFlag = TRUE) ;
@@ -92,7 +91,7 @@ protected:
92//which clears memory automatically. 91//which clears memory automatically.
93//so it can not hold static data or data after memory is cleared 92//so it can not hold static data or data after memory is cleared
94// 93//
95class LLVolatileAPRPool : protected LLAPRPool 94class LL_COMMON_API LLVolatileAPRPool : protected LLAPRPool
96{ 95{
97public: 96public:
98 LLVolatileAPRPool(apr_pool_t *parent = NULL, apr_size_t size = 0, BOOL releasePoolFlag = TRUE); 97 LLVolatileAPRPool(apr_pool_t *parent = NULL, apr_size_t size = 0, BOOL releasePoolFlag = TRUE);
@@ -126,7 +125,7 @@ private:
126 * destructor handles the unlock. Instances of this class are 125 * destructor handles the unlock. Instances of this class are
127 * <b>not</b> thread safe. 126 * <b>not</b> thread safe.
128 */ 127 */
129class LLScopedLock : private boost::noncopyable 128class LL_COMMON_API LLScopedLock : private boost::noncopyable
130{ 129{
131public: 130public:
132 /** 131 /**
@@ -201,7 +200,7 @@ typedef LLAtomic32<S32> LLAtomicS32;
201// 2, a global pool. 200// 2, a global pool.
202// 201//
203 202
204class LLAPRFile : boost::noncopyable 203class LL_COMMON_API LLAPRFile : boost::noncopyable
205{ 204{
206 // make this non copyable since a copy closes the file 205 // make this non copyable since a copy closes the file
207private: 206private:
@@ -257,10 +256,10 @@ public:
257 * APR_SUCCESS. 256 * APR_SUCCESS.
258 * @return Returns <code>true</code> if status is an error condition. 257 * @return Returns <code>true</code> if status is an error condition.
259 */ 258 */
260bool ll_apr_warn_status(apr_status_t status); 259bool LL_COMMON_API ll_apr_warn_status(apr_status_t status);
261 260
262void ll_apr_assert_status(apr_status_t status); 261void LL_COMMON_API ll_apr_assert_status(apr_status_t status);
263 262
264extern "C" apr_pool_t* gAPRPoolp; // Global APR memory pool 263extern "C" LL_COMMON_API apr_pool_t* gAPRPoolp; // Global APR memory pool
265 264
266#endif // LL_LLAPR_H 265#endif // LL_LLAPR_H
diff --git a/linden/indra/llcommon/llassettype.h b/linden/indra/llcommon/llassettype.h
index 4077b8d..9f611ae 100644
--- a/linden/indra/llcommon/llassettype.h
+++ b/linden/indra/llcommon/llassettype.h
@@ -37,7 +37,7 @@
37 37
38#include "stdenums.h" // for EDragAndDropType 38#include "stdenums.h" // for EDragAndDropType
39 39
40class LLAssetType 40class LL_COMMON_API LLAssetType
41{ 41{
42public: 42public:
43 enum EType 43 enum EType
diff --git a/linden/indra/llcommon/llbase32.h b/linden/indra/llcommon/llbase32.h
index 63a93e1..47cd893 100644
--- a/linden/indra/llcommon/llbase32.h
+++ b/linden/indra/llcommon/llbase32.h
@@ -34,7 +34,7 @@
34#ifndef LLBASE32_H 34#ifndef LLBASE32_H
35#define LLBASE32_h 35#define LLBASE32_h
36 36
37class LLBase32 37class LL_COMMON_API LLBase32
38{ 38{
39public: 39public:
40 static std::string encode(const U8* input, size_t input_size); 40 static std::string encode(const U8* input, size_t input_size);
diff --git a/linden/indra/llcommon/llbase64.h b/linden/indra/llcommon/llbase64.h
index 58414bb..15b27a6 100644
--- a/linden/indra/llcommon/llbase64.h
+++ b/linden/indra/llcommon/llbase64.h
@@ -34,7 +34,7 @@
34#ifndef LLBASE64_H 34#ifndef LLBASE64_H
35#define LLBASE64_h 35#define LLBASE64_h
36 36
37class LLBase64 37class LL_COMMON_API LLBase64
38{ 38{
39public: 39public:
40 static std::string encode(const U8* input, size_t input_size); 40 static std::string encode(const U8* input, size_t input_size);
diff --git a/linden/indra/llcommon/llcommon.h b/linden/indra/llcommon/llcommon.h
index 5f77988..851d4ac 100644
--- a/linden/indra/llcommon/llcommon.h
+++ b/linden/indra/llcommon/llcommon.h
@@ -38,7 +38,7 @@
38#include "lltimer.h" 38#include "lltimer.h"
39#include "llfile.h" 39#include "llfile.h"
40 40
41class LLCommon 41class LL_COMMON_API LLCommon
42{ 42{
43public: 43public:
44 static void initClass(); 44 static void initClass();
diff --git a/linden/indra/llcommon/llcrc.h b/linden/indra/llcommon/llcrc.h
index 27fae7d..7436906 100644
--- a/linden/indra/llcommon/llcrc.h
+++ b/linden/indra/llcommon/llcrc.h
@@ -50,7 +50,7 @@
50// llinfos << "File crc: " << crc.getCRC() << llendl; 50// llinfos << "File crc: " << crc.getCRC() << llendl;
51//~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ 51//~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
52 52
53class LLCRC 53class LL_COMMON_API LLCRC
54{ 54{
55protected: 55protected:
56 U32 mCurrent; 56 U32 mCurrent;
diff --git a/linden/indra/llcommon/llcriticaldamp.h b/linden/indra/llcommon/llcriticaldamp.h
index ad98284..13e37d8 100644
--- a/linden/indra/llcommon/llcriticaldamp.h
+++ b/linden/indra/llcommon/llcriticaldamp.h
@@ -38,7 +38,7 @@
38 38
39#include "llframetimer.h" 39#include "llframetimer.h"
40 40
41class LLCriticalDamp 41class LL_COMMON_API LLCriticalDamp
42{ 42{
43public: 43public:
44 LLCriticalDamp(); 44 LLCriticalDamp();
diff --git a/linden/indra/llcommon/llcursortypes.h b/linden/indra/llcommon/llcursortypes.h
index bea7035..836ecc3 100644
--- a/linden/indra/llcommon/llcursortypes.h
+++ b/linden/indra/llcommon/llcursortypes.h
@@ -77,6 +77,6 @@ enum ECursorType {
77 UI_CURSOR_COUNT // Number of elements in this enum (NOT a cursor) 77 UI_CURSOR_COUNT // Number of elements in this enum (NOT a cursor)
78}; 78};
79 79
80ECursorType getCursorFromString(const std::string& cursor_string); 80LL_COMMON_API ECursorType getCursorFromString(const std::string& cursor_string);
81 81
82#endif // LL_LLCURSORTYPES_H 82#endif // LL_LLCURSORTYPES_H
diff --git a/linden/indra/llcommon/lldate.h b/linden/indra/llcommon/lldate.h
index 5e1a491..d27da79 100644
--- a/linden/indra/llcommon/lldate.h
+++ b/linden/indra/llcommon/lldate.h
@@ -46,7 +46,7 @@
46 * 46 *
47 * The date class represents a point in time after epoch - 1970-01-01. 47 * The date class represents a point in time after epoch - 1970-01-01.
48 */ 48 */
49class LLDate 49class LL_COMMON_API LLDate
50{ 50{
51public: 51public:
52 /** 52 /**
@@ -153,9 +153,9 @@ private:
153}; 153};
154 154
155// Helper function to stream out a date 155// Helper function to stream out a date
156std::ostream& operator<<(std::ostream& s, const LLDate& date); 156LL_COMMON_API std::ostream& operator<<(std::ostream& s, const LLDate& date);
157 157
158// Helper function to stream in a date 158// Helper function to stream in a date
159std::istream& operator>>(std::istream& s, LLDate& date); 159LL_COMMON_API std::istream& operator>>(std::istream& s, LLDate& date);
160 160
161#endif // LL_LLDATE_H 161#endif // LL_LLDATE_H
diff --git a/linden/indra/llcommon/llerror.cpp b/linden/indra/llcommon/llerror.cpp
index 30b61a9..edc570f 100644
--- a/linden/indra/llcommon/llerror.cpp
+++ b/linden/indra/llcommon/llerror.cpp
@@ -58,7 +58,9 @@
58#include "llsd.h" 58#include "llsd.h"
59#include "llsdserialize.h" 59#include "llsdserialize.h"
60#include "llstl.h" 60#include "llstl.h"
61#include "lltimer.h"
61 62
63extern apr_thread_mutex_t* gCallStacksLogMutexp;
62 64
63namespace { 65namespace {
64#if !LL_WINDOWS 66#if !LL_WINDOWS
diff --git a/linden/indra/llcommon/llerror.h b/linden/indra/llcommon/llerror.h
index 37e922d..5a4c644 100644
--- a/linden/indra/llcommon/llerror.h
+++ b/linden/indra/llcommon/llerror.h
@@ -131,7 +131,7 @@ namespace LLError
131 131
132 class CallSite; 132 class CallSite;
133 133
134 class Log 134 class LL_COMMON_API Log
135 { 135 {
136 public: 136 public:
137 static bool shouldLog(CallSite&); 137 static bool shouldLog(CallSite&);
@@ -140,7 +140,7 @@ namespace LLError
140 static void flush(std::ostringstream*, const CallSite&); 140 static void flush(std::ostringstream*, const CallSite&);
141 }; 141 };
142 142
143 class CallSite 143 class LL_COMMON_API CallSite
144 { 144 {
145 // Represents a specific place in the code where a message is logged 145 // Represents a specific place in the code where a message is logged
146 // This is public because it is used by the macros below. It is not 146 // This is public because it is used by the macros below. It is not
@@ -189,7 +189,7 @@ namespace LLError
189 //LLCallStacks is designed not to be thread-safe. 189 //LLCallStacks is designed not to be thread-safe.
190 //so try not to use it in multiple parallel threads at same time. 190 //so try not to use it in multiple parallel threads at same time.
191 //Used in a single thread at a time is fine. 191 //Used in a single thread at a time is fine.
192 class LLCallStacks 192 class LL_COMMON_API LLCallStacks
193 { 193 {
194 private: 194 private:
195 static char** sBuffer ; 195 static char** sBuffer ;
diff --git a/linden/indra/llcommon/llerrorcontrol.h b/linden/indra/llcommon/llerrorcontrol.h
index fae7547..54138b2 100644
--- a/linden/indra/llcommon/llerrorcontrol.h
+++ b/linden/indra/llcommon/llerrorcontrol.h
@@ -52,12 +52,12 @@ class LLSD;
52 52
53namespace LLError 53namespace LLError
54{ 54{
55 void initForServer(const std::string& identity); 55 LL_COMMON_API void initForServer(const std::string& identity);
56 // resets all logging settings to defaults needed by server processes 56 // resets all logging settings to defaults needed by server processes
57 // logs to stderr, syslog, and windows debug log 57 // logs to stderr, syslog, and windows debug log
58 // the identity string is used for in the syslog 58 // the identity string is used for in the syslog
59 59
60 void initForApplication(const std::string& dir); 60 LL_COMMON_API void initForApplication(const std::string& dir);
61 // resets all logging settings to defaults needed by applicaitons 61 // resets all logging settings to defaults needed by applicaitons
62 // logs to stderr and windows debug log 62 // logs to stderr and windows debug log
63 // sets up log configuration from the file logcontrol.xml in dir 63 // sets up log configuration from the file logcontrol.xml in dir
@@ -68,14 +68,14 @@ namespace LLError
68 Setting a level means log messages at that level or above. 68 Setting a level means log messages at that level or above.
69 */ 69 */
70 70
71 void setPrintLocation(bool); 71 LL_COMMON_API void setPrintLocation(bool);
72 void setDefaultLevel(LLError::ELevel); 72 LL_COMMON_API void setDefaultLevel(LLError::ELevel);
73 void setFunctionLevel(const std::string& function_name, LLError::ELevel); 73 LL_COMMON_API void setFunctionLevel(const std::string& function_name, LLError::ELevel);
74 void setClassLevel(const std::string& class_name, LLError::ELevel); 74 LL_COMMON_API void setClassLevel(const std::string& class_name, LLError::ELevel);
75 void setFileLevel(const std::string& file_name, LLError::ELevel); 75 LL_COMMON_API void setFileLevel(const std::string& file_name, LLError::ELevel);
76 void setTagLevel(const std::string& file_name, LLError::ELevel); 76 LL_COMMON_API void setTagLevel(const std::string& file_name, LLError::ELevel);
77 77
78 void configure(const LLSD&); 78 LL_COMMON_API void configure(const LLSD&);
79 // the LLSD can configure all of the settings 79 // the LLSD can configure all of the settings
80 // usually read automatically from the live errorlog.xml file 80 // usually read automatically from the live errorlog.xml file
81 81
@@ -85,25 +85,25 @@ namespace LLError
85 */ 85 */
86 86
87 typedef void(*FatalFunction)(const std::string& message); 87 typedef void(*FatalFunction)(const std::string& message);
88 void crashAndLoop(const std::string& message); 88 LL_COMMON_API void crashAndLoop(const std::string& message);
89 // Default fatal funtion: access null pointer and loops forever 89 // Default fatal funtion: access null pointer and loops forever
90 90
91 void setFatalFunction(FatalFunction); 91 LL_COMMON_API void setFatalFunction(FatalFunction);
92 // The fatal function will be called when an message of LEVEL_ERROR 92 // The fatal function will be called when an message of LEVEL_ERROR
93 // is logged. Note: supressing a LEVEL_ERROR message from being logged 93 // is logged. Note: supressing a LEVEL_ERROR message from being logged
94 // (by, for example, setting a class level to LEVEL_NONE), will keep 94 // (by, for example, setting a class level to LEVEL_NONE), will keep
95 // the that message from causing the fatal funciton to be invoked. 95 // the that message from causing the fatal funciton to be invoked.
96 96
97 typedef std::string (*TimeFunction)(); 97 typedef std::string (*TimeFunction)();
98 std::string utcTime(); 98 LL_COMMON_API std::string utcTime();
99 99
100 void setTimeFunction(TimeFunction); 100 LL_COMMON_API void setTimeFunction(TimeFunction);
101 // The function is use to return the current time, formatted for 101 // The function is use to return the current time, formatted for
102 // display by those error recorders that want the time included. 102 // display by those error recorders that want the time included.
103 103
104 104
105 105
106 class Recorder 106 class LL_COMMON_API Recorder
107 { 107 {
108 // An object that handles the actual output or error messages. 108 // An object that handles the actual output or error messages.
109 public: 109 public:
@@ -117,17 +117,17 @@ namespace LLError
117 // included in the text of the message 117 // included in the text of the message
118 }; 118 };
119 119
120 void addRecorder(Recorder*); 120 LL_COMMON_API void addRecorder(Recorder*);
121 void removeRecorder(Recorder*); 121 LL_COMMON_API void removeRecorder(Recorder*);
122 // each error message is passed to each recorder via recordMessage() 122 // each error message is passed to each recorder via recordMessage()
123 123
124 void logToFile(const std::string& filename); 124 LL_COMMON_API void logToFile(const std::string& filename);
125 void logToFixedBuffer(LLFixedBuffer*); 125 LL_COMMON_API void logToFixedBuffer(LLFixedBuffer*);
126 // Utilities to add recorders for logging to a file or a fixed buffer 126 // Utilities to add recorders for logging to a file or a fixed buffer
127 // A second call to the same function will remove the logger added 127 // A second call to the same function will remove the logger added
128 // with the first. 128 // with the first.
129 // Passing the empty string or NULL to just removes any prior. 129 // Passing the empty string or NULL to just removes any prior.
130 std::string logFileName(); 130 LL_COMMON_API std::string logFileName();
131 // returns name of current logging file, empty string if none 131 // returns name of current logging file, empty string if none
132 132
133 133
@@ -136,11 +136,11 @@ namespace LLError
136 */ 136 */
137 137
138 class Settings; 138 class Settings;
139 Settings* saveAndResetSettings(); 139 LL_COMMON_API Settings* saveAndResetSettings();
140 void restoreSettings(Settings *); 140 LL_COMMON_API void restoreSettings(Settings *);
141 141
142 std::string abbreviateFile(const std::string& filePath); 142 LL_COMMON_API std::string abbreviateFile(const std::string& filePath);
143 int shouldLogCallCount(); 143 LL_COMMON_API int shouldLogCallCount();
144 144
145}; 145};
146 146
diff --git a/linden/indra/llcommon/llerrorthread.cpp b/linden/indra/llcommon/llerrorthread.cpp
index 4c779c5..e2b106a 100644
--- a/linden/indra/llcommon/llerrorthread.cpp
+++ b/linden/indra/llcommon/llerrorthread.cpp
@@ -32,6 +32,7 @@
32#include "linden_common.h" 32#include "linden_common.h"
33#include "llerrorthread.h" 33#include "llerrorthread.h"
34#include "llapp.h" 34#include "llapp.h"
35#include "lltimer.h"
35 36
36LLErrorThread::LLErrorThread() 37LLErrorThread::LLErrorThread()
37 : LLThread("Error"), 38 : LLThread("Error"),
diff --git a/linden/indra/llcommon/llerrorthread.h b/linden/indra/llcommon/llerrorthread.h
index f1d6ffc..3121d29 100644
--- a/linden/indra/llcommon/llerrorthread.h
+++ b/linden/indra/llcommon/llerrorthread.h
@@ -35,7 +35,7 @@
35 35
36#include "llthread.h" 36#include "llthread.h"
37 37
38class LLErrorThread : public LLThread 38class LL_COMMON_API LLErrorThread : public LLThread
39{ 39{
40public: 40public:
41 LLErrorThread(); 41 LLErrorThread();
diff --git a/linden/indra/llcommon/llevent.h b/linden/indra/llcommon/llevent.h
index 60887a0..6b223a8 100644
--- a/linden/indra/llcommon/llevent.h
+++ b/linden/indra/llcommon/llevent.h
@@ -44,7 +44,7 @@ class LLEventDispatcher;
44class LLObservable; 44class LLObservable;
45 45
46// Abstract event. All events derive from LLEvent 46// Abstract event. All events derive from LLEvent
47class LLEvent : public LLThreadSafeRefCount 47class LL_COMMON_API LLEvent : public LLThreadSafeRefCount
48{ 48{
49protected: 49protected:
50 virtual ~LLEvent(); 50 virtual ~LLEvent();
@@ -72,7 +72,7 @@ private:
72}; 72};
73 73
74// Abstract listener. All listeners derive from LLEventListener 74// Abstract listener. All listeners derive from LLEventListener
75class LLEventListener : public LLThreadSafeRefCount 75class LL_COMMON_API LLEventListener : public LLThreadSafeRefCount
76{ 76{
77protected: 77protected:
78 virtual ~LLEventListener(); 78 virtual ~LLEventListener();
@@ -89,7 +89,7 @@ public:
89}; 89};
90 90
91// A listener which tracks references to it and cleans up when it's deallocated 91// A listener which tracks references to it and cleans up when it's deallocated
92class LLSimpleListener : public LLEventListener 92class LL_COMMON_API LLSimpleListener : public LLEventListener
93{ 93{
94public: 94public:
95 void clearDispatchers(); 95 void clearDispatchers();
@@ -114,7 +114,7 @@ struct LLListenerEntry
114// Base class for a dispatcher - an object which listens 114// Base class for a dispatcher - an object which listens
115// to events being fired and relays them to their 115// to events being fired and relays them to their
116// appropriate destinations. 116// appropriate destinations.
117class LLEventDispatcher : public LLThreadSafeRefCount 117class LL_COMMON_API LLEventDispatcher : public LLThreadSafeRefCount
118{ 118{
119protected: 119protected:
120 virtual ~LLEventDispatcher(); 120 virtual ~LLEventDispatcher();
@@ -157,7 +157,7 @@ private:
157// In order for this class to work properly, it needs 157// In order for this class to work properly, it needs
158// an instance of an LLEventDispatcher to route events to their 158// an instance of an LLEventDispatcher to route events to their
159// listeners. 159// listeners.
160class LLObservable 160class LL_COMMON_API LLObservable
161{ 161{
162public: 162public:
163 // Initialize with the default Dispatcher 163 // Initialize with the default Dispatcher
diff --git a/linden/indra/llcommon/llfasttimer.cpp b/linden/indra/llcommon/llfasttimer.cpp
index 4aa23bb..5f091d5 100644
--- a/linden/indra/llcommon/llfasttimer.cpp
+++ b/linden/indra/llcommon/llfasttimer.cpp
@@ -42,6 +42,7 @@
42#include <sched.h> 42#include <sched.h>
43#elif LL_DARWIN 43#elif LL_DARWIN
44#include <sys/time.h> 44#include <sys/time.h>
45#include "lltimer.h" // get_clock_count()
45#else 46#else
46#error "architecture not supported" 47#error "architecture not supported"
47#endif 48#endif
diff --git a/linden/indra/llcommon/llfasttimer.h b/linden/indra/llcommon/llfasttimer.h
index 8c1cf47..602a2f7 100644
--- a/linden/indra/llcommon/llfasttimer.h
+++ b/linden/indra/llcommon/llfasttimer.h
@@ -35,9 +35,9 @@
35 35
36#define FAST_TIMER_ON 1 36#define FAST_TIMER_ON 1
37 37
38U64 get_cpu_clock_count(); 38LL_COMMON_API U64 get_cpu_clock_count();
39 39
40class LLFastTimer 40class LL_COMMON_API LLFastTimer
41{ 41{
42public: 42public:
43 enum EFastTimerType 43 enum EFastTimerType
diff --git a/linden/indra/llcommon/llfile.h b/linden/indra/llcommon/llfile.h
index c6092f7..ee37605 100644
--- a/linden/indra/llcommon/llfile.h
+++ b/linden/indra/llcommon/llfile.h
@@ -70,7 +70,7 @@ typedef struct stat llstat;
70 70
71#include "llstring.h" // safe char* -> std::string conversion 71#include "llstring.h" // safe char* -> std::string conversion
72 72
73class LLFile 73class LL_COMMON_API LLFile
74{ 74{
75public: 75public:
76 // All these functions take UTF8 path/filenames. 76 // All these functions take UTF8 path/filenames.
@@ -95,7 +95,7 @@ public:
95 95
96#if USE_LLFILESTREAMS 96#if USE_LLFILESTREAMS
97 97
98class llifstream : public std::basic_istream < char , std::char_traits < char > > 98class LL_COMMON_API llifstream : public std::basic_istream < char , std::char_traits < char > >
99{ 99{
100 // input stream associated with a C stream 100 // input stream associated with a C stream
101public: 101public:
@@ -136,7 +136,7 @@ private:
136}; 136};
137 137
138 138
139class llofstream : public std::basic_ostream< char , std::char_traits < char > > 139class LL_COMMON_API llofstream : public std::basic_ostream< char , std::char_traits < char > >
140{ 140{
141public: 141public:
142 typedef std::basic_ostream< char , std::char_traits < char > > _Myt; 142 typedef std::basic_ostream< char , std::char_traits < char > > _Myt;
@@ -185,7 +185,7 @@ private:
185//#define llifstream std::ifstream 185//#define llifstream std::ifstream
186//#define llofstream std::ofstream 186//#define llofstream std::ofstream
187 187
188class llifstream : public std::ifstream 188class LL_COMMON_API llifstream : public std::ifstream
189{ 189{
190public: 190public:
191 llifstream() : std::ifstream() 191 llifstream() : std::ifstream()
@@ -203,7 +203,7 @@ public:
203}; 203};
204 204
205 205
206class llofstream : public std::ofstream 206class LL_COMMON_API llofstream : public std::ofstream
207{ 207{
208public: 208public:
209 llofstream() : std::ofstream() 209 llofstream() : std::ofstream()
diff --git a/linden/indra/llcommon/llfindlocale.h b/linden/indra/llcommon/llfindlocale.h
index f17c774..b812a06 100644
--- a/linden/indra/llcommon/llfindlocale.h
+++ b/linden/indra/llcommon/llfindlocale.h
@@ -59,8 +59,8 @@ typedef enum {
59/* This allocates/fills in a FL_Locale structure with pointers to 59/* This allocates/fills in a FL_Locale structure with pointers to
60 strings (which should be treated as static), or NULL for inappropriate / 60 strings (which should be treated as static), or NULL for inappropriate /
61 undetected fields. */ 61 undetected fields. */
62FL_Success FL_FindLocale(FL_Locale **locale, FL_Domain domain); 62LL_COMMON_API FL_Success FL_FindLocale(FL_Locale **locale, FL_Domain domain);
63/* This should be used to free the struct written by FL_FindLocale */ 63/* This should be used to free the struct written by FL_FindLocale */
64void FL_FreeLocale(FL_Locale **locale); 64LL_COMMON_API void FL_FreeLocale(FL_Locale **locale);
65 65
66#endif /*__findlocale_h_*/ 66#endif /*__findlocale_h_*/
diff --git a/linden/indra/llcommon/llfixedbuffer.h b/linden/indra/llcommon/llfixedbuffer.h
index 992a024..51d0701 100644
--- a/linden/indra/llcommon/llfixedbuffer.h
+++ b/linden/indra/llcommon/llfixedbuffer.h
@@ -41,7 +41,7 @@
41 41
42// Fixed size buffer for console output and other things. 42// Fixed size buffer for console output and other things.
43 43
44class LLFixedBuffer 44class LL_COMMON_API LLFixedBuffer
45{ 45{
46public: 46public:
47 LLFixedBuffer(const U32 max_lines = 20); 47 LLFixedBuffer(const U32 max_lines = 20);
diff --git a/linden/indra/llcommon/llformat.h b/linden/indra/llcommon/llformat.h
index 44c62d9..ad30d4f 100644
--- a/linden/indra/llcommon/llformat.h
+++ b/linden/indra/llcommon/llformat.h
@@ -40,6 +40,6 @@
40// *NOTE: buffer limited to 1024, (but vsnprintf prevents overrun) 40// *NOTE: buffer limited to 1024, (but vsnprintf prevents overrun)
41// should perhaps be replaced with boost::format. 41// should perhaps be replaced with boost::format.
42 42
43std::string llformat(const char *fmt, ...); 43LL_COMMON_API std::string llformat(const char *fmt, ...);
44 44
45#endif // LL_LLFORMAT_H 45#endif // LL_LLFORMAT_H
diff --git a/linden/indra/llcommon/llframetimer.h b/linden/indra/llcommon/llframetimer.h
index 8f51272..f4775a9 100644
--- a/linden/indra/llcommon/llframetimer.h
+++ b/linden/indra/llcommon/llframetimer.h
@@ -43,7 +43,7 @@
43#include "lltimer.h" 43#include "lltimer.h"
44#include "timing.h" 44#include "timing.h"
45 45
46class LLFrameTimer 46class LL_COMMON_API LLFrameTimer
47{ 47{
48public: 48public:
49 LLFrameTimer() : mStartTime( sFrameTime ), mExpiry(0), mStarted(TRUE) {} 49 LLFrameTimer() : mStartTime( sFrameTime ), mExpiry(0), mStarted(TRUE) {}
diff --git a/linden/indra/llcommon/llheartbeat.h b/linden/indra/llcommon/llheartbeat.h
index fecb5b1..6f70269 100644
--- a/linden/indra/llcommon/llheartbeat.h
+++ b/linden/indra/llcommon/llheartbeat.h
@@ -40,7 +40,7 @@
40// Note: Win32 does not support the heartbeat/smackdown system; 40// Note: Win32 does not support the heartbeat/smackdown system;
41// heartbeat-delivery turns into a no-op there. 41// heartbeat-delivery turns into a no-op there.
42 42
43class LLHeartbeat 43class LL_COMMON_API LLHeartbeat
44{ 44{
45public: 45public:
46 // secs_between_heartbeat: after a heartbeat is successfully delivered, 46 // secs_between_heartbeat: after a heartbeat is successfully delivered,
diff --git a/linden/indra/llcommon/llliveappconfig.h b/linden/indra/llcommon/llliveappconfig.h
index 55d84a4..3251a7c 100644
--- a/linden/indra/llcommon/llliveappconfig.h
+++ b/linden/indra/llcommon/llliveappconfig.h
@@ -37,7 +37,7 @@
37 37
38class LLApp; 38class LLApp;
39 39
40class LLLiveAppConfig : public LLLiveFile 40class LL_COMMON_API LLLiveAppConfig : public LLLiveFile
41{ 41{
42public: 42public:
43 // To use this, instantiate a LLLiveAppConfig object inside your main loop. 43 // To use this, instantiate a LLLiveAppConfig object inside your main loop.
diff --git a/linden/indra/llcommon/lllivefile.h b/linden/indra/llcommon/lllivefile.h
index fddf006..72f16fd 100644
--- a/linden/indra/llcommon/lllivefile.h
+++ b/linden/indra/llcommon/lllivefile.h
@@ -36,7 +36,7 @@
36const F32 configFileRefreshRate = 5.0; // seconds 36const F32 configFileRefreshRate = 5.0; // seconds
37 37
38 38
39class LLLiveFile 39class LL_COMMON_API LLLiveFile
40{ 40{
41public: 41public:
42 LLLiveFile(const std::string &filename, const F32 refresh_period = 5.f); 42 LLLiveFile(const std::string &filename, const F32 refresh_period = 5.f);
diff --git a/linden/indra/llcommon/lllog.h b/linden/indra/llcommon/lllog.h
index 7ac6c8a..4b6777b 100644
--- a/linden/indra/llcommon/lllog.h
+++ b/linden/indra/llcommon/lllog.h
@@ -41,7 +41,7 @@ class LLLogImpl;
41class LLApp; 41class LLApp;
42class LLSD; 42class LLSD;
43 43
44class LLLog 44class LL_COMMON_API LLLog
45{ 45{
46public: 46public:
47 LLLog(LLApp* app); 47 LLLog(LLApp* app);
diff --git a/linden/indra/llcommon/llmd5.cpp b/linden/indra/llcommon/llmd5.cpp
index 14b4f9f..887979b 100644
--- a/linden/indra/llcommon/llmd5.cpp
+++ b/linden/indra/llcommon/llmd5.cpp
@@ -83,6 +83,7 @@ documentation and/or software.
83#include "llmd5.h" 83#include "llmd5.h"
84 84
85#include <cassert> 85#include <cassert>
86#include <iostream>
86 87
87// how many bytes to grab at a time when checking files 88// how many bytes to grab at a time when checking files
88const int LLMD5::BLOCK_LEN = 4096; 89const int LLMD5::BLOCK_LEN = 4096;
diff --git a/linden/indra/llcommon/llmd5.h b/linden/indra/llcommon/llmd5.h
index d8bca03..df9d732 100644
--- a/linden/indra/llcommon/llmd5.h
+++ b/linden/indra/llcommon/llmd5.h
@@ -80,7 +80,7 @@ const int MD5RAW_BYTES = 16;
80const int MD5HEX_STR_SIZE = 33; // char hex[MD5HEX_STR_SIZE]; with null 80const int MD5HEX_STR_SIZE = 33; // char hex[MD5HEX_STR_SIZE]; with null
81const int MD5HEX_STR_BYTES = 32; // message system fixed size 81const int MD5HEX_STR_BYTES = 32; // message system fixed size
82 82
83class LLMD5 { 83class LL_COMMON_API LLMD5 {
84// first, some types: 84// first, some types:
85 typedef unsigned int uint4; // assumes integer is 4 words long 85 typedef unsigned int uint4; // assumes integer is 4 words long
86 typedef unsigned short int uint2; // assumes short integer is 2 words long 86 typedef unsigned short int uint2; // assumes short integer is 2 words long
diff --git a/linden/indra/llcommon/llmemory.cpp b/linden/indra/llcommon/llmemory.cpp
index a6de3d2..74004b0 100644
--- a/linden/indra/llcommon/llmemory.cpp
+++ b/linden/indra/llcommon/llmemory.cpp
@@ -283,6 +283,11 @@ LLRefCount::LLRefCount() :
283{ 283{
284} 284}
285 285
286LLRefCount::LLRefCount(const LLRefCount& other)
287: mRef(0)
288{
289}
290
286LLRefCount::~LLRefCount() 291LLRefCount::~LLRefCount()
287{ 292{
288 if (mRef != 0) 293 if (mRef != 0)
@@ -290,7 +295,13 @@ LLRefCount::~LLRefCount()
290 llerrs << "deleting non-zero reference" << llendl; 295 llerrs << "deleting non-zero reference" << llendl;
291 } 296 }
292} 297}
293 298
299LLRefCount& LLRefCount::operator=(const LLRefCount&)
300{
301 // do nothing, since ref count is specific to *this* reference
302 return *this;
303}
304
294//---------------------------------------------------------------------------- 305//----------------------------------------------------------------------------
295 306
296#if defined(LL_WINDOWS) 307#if defined(LL_WINDOWS)
diff --git a/linden/indra/llcommon/llmemory.h b/linden/indra/llcommon/llmemory.h
index b5c0711..9aa4b85 100644
--- a/linden/indra/llcommon/llmemory.h
+++ b/linden/indra/llcommon/llmemory.h
@@ -45,7 +45,7 @@ const U32 LLREFCOUNT_SENTINEL_VALUE = 0xAAAAAAAA;
45 45
46//---------------------------------------------------------------------------- 46//----------------------------------------------------------------------------
47 47
48class LLMemory 48class LL_COMMON_API LLMemory
49{ 49{
50public: 50public:
51 static void initClass(); 51 static void initClass();
@@ -68,12 +68,12 @@ private:
68 68
69//---------------------------------------------------------------------------- 69//----------------------------------------------------------------------------
70 70
71class LLRefCount 71class LL_COMMON_API LLRefCount
72{ 72{
73protected: 73protected:
74 LLRefCount(const LLRefCount&); // not implemented 74 LLRefCount(const LLRefCount&);
75private: 75private:
76 LLRefCount&operator=(const LLRefCount&); // not implemented 76 LLRefCount&operator=(const LLRefCount&);
77 77
78protected: 78protected:
79 virtual ~LLRefCount(); // use unref() 79 virtual ~LLRefCount(); // use unref()
@@ -467,6 +467,6 @@ private:
467 467
468// Return the resident set size of the current process, in bytes. 468// Return the resident set size of the current process, in bytes.
469// Return value is zero if not known. 469// Return value is zero if not known.
470U64 getCurrentRSS(); 470LL_COMMON_API U64 getCurrentRSS();
471 471
472#endif 472#endif
diff --git a/linden/indra/llcommon/llmemorystream.h b/linden/indra/llcommon/llmemorystream.h
index f348632..fa0f5d2 100644
--- a/linden/indra/llcommon/llmemorystream.h
+++ b/linden/indra/llcommon/llmemorystream.h
@@ -52,7 +52,7 @@
52 * be careful to always pass in a valid memory location that exists 52 * be careful to always pass in a valid memory location that exists
53 * for at least as long as this streambuf. 53 * for at least as long as this streambuf.
54 */ 54 */
55class LLMemoryStreamBuf : public std::streambuf 55class LL_COMMON_API LLMemoryStreamBuf : public std::streambuf
56{ 56{
57public: 57public:
58 LLMemoryStreamBuf(const U8* start, S32 length); 58 LLMemoryStreamBuf(const U8* start, S32 length);
@@ -74,7 +74,7 @@ protected:
74 * be careful to always pass in a valid memory location that exists 74 * be careful to always pass in a valid memory location that exists
75 * for at least as long as this streambuf. 75 * for at least as long as this streambuf.
76 */ 76 */
77class LLMemoryStream : public std::istream 77class LL_COMMON_API LLMemoryStream : public std::istream
78{ 78{
79public: 79public:
80 LLMemoryStream(const U8* start, S32 length); 80 LLMemoryStream(const U8* start, S32 length);
diff --git a/linden/indra/llcommon/llmemtype.h b/linden/indra/llcommon/llmemtype.h
index a9ebc20..d4cc67e 100644
--- a/linden/indra/llcommon/llmemtype.h
+++ b/linden/indra/llcommon/llmemtype.h
@@ -57,7 +57,7 @@ static void operator delete(void* p) { ll_release(p); }
57 57
58//---------------------------------------------------------------------------- 58//----------------------------------------------------------------------------
59 59
60class LLMemType 60class LL_COMMON_API LLMemType
61{ 61{
62public: 62public:
63 // Also update sTypeDesc in llmemory.cpp 63 // Also update sTypeDesc in llmemory.cpp
diff --git a/linden/indra/llcommon/llmetrics.h b/linden/indra/llcommon/llmetrics.h
index 1d91e8c..f6f49eb 100644
--- a/linden/indra/llcommon/llmetrics.h
+++ b/linden/indra/llcommon/llmetrics.h
@@ -38,7 +38,7 @@
38class LLMetricsImpl; 38class LLMetricsImpl;
39class LLSD; 39class LLSD;
40 40
41class LLMetrics 41class LL_COMMON_API LLMetrics
42{ 42{
43public: 43public:
44 LLMetrics(); 44 LLMetrics();
diff --git a/linden/indra/llcommon/llmortician.h b/linden/indra/llcommon/llmortician.h
index 247632f..55a101a 100644
--- a/linden/indra/llcommon/llmortician.h
+++ b/linden/indra/llcommon/llmortician.h
@@ -35,7 +35,7 @@
35 35
36#include "stdtypes.h" 36#include "stdtypes.h"
37 37
38class LLMortician 38class LL_COMMON_API LLMortician
39{ 39{
40public: 40public:
41 LLMortician() { mIsDead = FALSE; } 41 LLMortician() { mIsDead = FALSE; }
diff --git a/linden/indra/llcommon/llpreprocessor.h b/linden/indra/llcommon/llpreprocessor.h
index 2e4fd47..6886e3a 100644
--- a/linden/indra/llcommon/llpreprocessor.h
+++ b/linden/indra/llcommon/llpreprocessor.h
@@ -92,47 +92,63 @@
92 92
93#endif 93#endif
94 94
95
96// Deal with the differeneces on Windows 95// Deal with the differeneces on Windows
97#if LL_MSVC
98namespace snprintf_hack
99{
100 int snprintf(char *str, size_t size, const char *format, ...);
101}
102
103// #define snprintf safe_snprintf /* Flawfinder: ignore */
104using snprintf_hack::snprintf;
105#endif // LL_MSVC
106
107// Static linking with apr on windows needs to be declared.
108#ifdef LL_WINDOWS
109#ifndef APR_DECLARE_STATIC
110#define APR_DECLARE_STATIC // For APR on Windows
111#endif
112#ifndef APU_DECLARE_STATIC
113#define APU_DECLARE_STATIC // For APR util on Windows
114#endif
115#endif
116
117#if defined(LL_WINDOWS) 96#if defined(LL_WINDOWS)
118#define BOOST_REGEX_NO_LIB 1 97#define BOOST_REGEX_NO_LIB 1
119#define CURL_STATICLIB 1 98#define CURL_STATICLIB 1
120#define XML_STATIC 99#define XML_STATIC
121#endif // LL_WINDOWS 100#endif // LL_WINDOWS
122 101
123
124// Deal with VC6 problems 102// Deal with VC6 problems
125#if LL_MSVC 103#if LL_MSVC
126#pragma warning( 3 : 4701 ) // "local variable used without being initialized" Treat this as level 3, not level 4. 104#pragma warning( 3 : 4701 ) // "local variable used without being initialized" Treat this as level 3, not level 4.
127#pragma warning( 3 : 4702 ) // "unreachable code" Treat this as level 3, not level 4. 105#pragma warning( 3 : 4702 ) // "unreachable code" Treat this as level 3, not level 4.
128#pragma warning( 3 : 4189 ) // "local variable initialized but not referenced" Treat this as level 3, not level 4. 106#pragma warning( 3 : 4189 ) // "local variable initialized but not referenced" Treat this as level 3, not level 4.
129//#pragma warning( 3 : 4018 ) // "signed/unsigned mismatch" Treat this as level 3, not level 4. 107//#pragma warning( 3 : 4018 ) // "signed/unsigned mismatch" Treat this as level 3, not level 4.
108#pragma warning( 3 : 4263 ) // 'function' : member function does not override any base class virtual member function
109#pragma warning( 3 : 4264 ) // "'virtual_function' : no override available for virtual member function from base 'class'; function is hidden"
130#pragma warning( 3 : 4265 ) // "class has virtual functions, but destructor is not virtual" 110#pragma warning( 3 : 4265 ) // "class has virtual functions, but destructor is not virtual"
131#pragma warning( disable : 4786 ) // silly MS warning deep inside their <map> include file 111//#pragma warning( disable : 4265 ) // boost 1.36.0, non-virtual destructor in boost::exception_detail::*
112#pragma warning( 3 : 4266 ) // 'function' : no override available for virtual member function from base 'type'; function is hidden
113#pragma warning (disable : 4180) // qualifier applied to function type has no meaning; ignored
132#pragma warning( disable : 4284 ) // silly MS warning deep inside their <map> include file 114#pragma warning( disable : 4284 ) // silly MS warning deep inside their <map> include file
133#pragma warning( disable : 4503 ) // 'decorated name length exceeded, name was truncated'. Does not seem to affect compilation. 115#pragma warning( disable : 4503 ) // 'decorated name length exceeded, name was truncated'. Does not seem to affect compilation.
134#pragma warning( disable : 4800 ) // 'BOOL' : forcing value to bool 'true' or 'false' (performance warning) 116#pragma warning( disable : 4800 ) // 'BOOL' : forcing value to bool 'true' or 'false' (performance warning)
135#pragma warning( disable : 4996 ) // warning: deprecated 117#pragma warning( disable : 4996 ) // warning: deprecated
118
119// Linker optimization with "extern template" generates these warnings
120#pragma warning( disable : 4231 ) // nonstandard extension used : 'extern' before template explicit instantiation
121#pragma warning( disable : 4506 ) // no definition for inline function
122
123// level 4 warnings that we need to disable:
124#pragma warning (disable : 4100) // unreferenced formal parameter
125#pragma warning (disable : 4127) // conditional expression is constant (e.g. while(1) )
126#pragma warning (disable : 4244) // possible loss of data on conversions
127#pragma warning (disable : 4396) // the inline specifier cannot be used when a friend declaration refers to a specialization of a function template
128#pragma warning (disable : 4512) // assignment operator could not be generated
129#pragma warning (disable : 4706) // assignment within conditional (even if((x = y)) )
130
131#pragma warning (disable : 4251) // member needs to have dll-interface to be used by clients of class
132#pragma warning (disable : 4275) // non dll-interface class used as base for dll-interface class
136#endif // LL_MSVC 133#endif // LL_MSVC
137 134
135#if LL_WINDOWS
136#define LL_DLLEXPORT __declspec(dllexport)
137#define LL_DLLIMPORT __declspec(dllimport)
138#elif LL_LINUX
139#define LL_DLLEXPORT __attribute__ ((visibility("default")))
140#define LL_DLLIMPORT
141#else
142#define LL_DLLEXPORT
143#define LL_DLLIMPORT
144#endif // LL_WINDOWS
145
146#ifdef llcommon_EXPORTS
147// Compiling llcommon (shared)
148#define LL_COMMON_API LL_DLLEXPORT
149#else // llcommon_EXPORTS
150// Using llcommon (shared)
151#define LL_COMMON_API LL_DLLIMPORT
152#endif // llcommon_EXPORTS
153
138#endif // not LL_LINDEN_PREPROCESSOR_H 154#endif // not LL_LINDEN_PREPROCESSOR_H
diff --git a/linden/indra/llcommon/llprocesslauncher.h b/linden/indra/llcommon/llprocesslauncher.h
index 9cdb0f6..b72be27 100644
--- a/linden/indra/llcommon/llprocesslauncher.h
+++ b/linden/indra/llcommon/llprocesslauncher.h
@@ -43,7 +43,7 @@
43 It also keeps track of whether the process is still running, and can kill it if required. 43 It also keeps track of whether the process is still running, and can kill it if required.
44*/ 44*/
45 45
46class LLProcessLauncher 46class LL_COMMON_API LLProcessLauncher
47{ 47{
48 LOG_CLASS(LLProcessLauncher); 48 LOG_CLASS(LLProcessLauncher);
49public: 49public:
diff --git a/linden/indra/llcommon/llqueuedthread.cpp b/linden/indra/llcommon/llqueuedthread.cpp
index caf4c2a..bee95be 100644
--- a/linden/indra/llcommon/llqueuedthread.cpp
+++ b/linden/indra/llcommon/llqueuedthread.cpp
@@ -32,6 +32,7 @@
32#include "linden_common.h" 32#include "linden_common.h"
33#include "llqueuedthread.h" 33#include "llqueuedthread.h"
34#include "llstl.h" 34#include "llstl.h"
35#include "lltimer.h"
35 36
36//============================================================================ 37//============================================================================
37 38
diff --git a/linden/indra/llcommon/llqueuedthread.h b/linden/indra/llcommon/llqueuedthread.h
index aa7c6e4..e0e0f1b 100644
--- a/linden/indra/llcommon/llqueuedthread.h
+++ b/linden/indra/llcommon/llqueuedthread.h
@@ -47,7 +47,7 @@
47// Note: ~LLQueuedThread is O(N) N=# of queued threads, assumed to be small 47// Note: ~LLQueuedThread is O(N) N=# of queued threads, assumed to be small
48// It is assumed that LLQueuedThreads are rarely created/destroyed. 48// It is assumed that LLQueuedThreads are rarely created/destroyed.
49 49
50class LLQueuedThread : public LLThread 50class LL_COMMON_API LLQueuedThread : public LLThread
51{ 51{
52 //------------------------------------------------------------------------ 52 //------------------------------------------------------------------------
53public: 53public:
@@ -80,7 +80,7 @@ public:
80 //------------------------------------------------------------------------ 80 //------------------------------------------------------------------------
81public: 81public:
82 82
83 class QueuedRequest : public LLSimpleHashEntry<handle_t> 83 class LL_COMMON_API QueuedRequest : public LLSimpleHashEntry<handle_t>
84 { 84 {
85 friend class LLQueuedThread; 85 friend class LLQueuedThread;
86 86
diff --git a/linden/indra/llcommon/llrand.h b/linden/indra/llcommon/llrand.h
index d12597b..73ea179 100644
--- a/linden/indra/llcommon/llrand.h
+++ b/linden/indra/llcommon/llrand.h
@@ -65,32 +65,32 @@
65/** 65/**
66 *@brief Generate a float from [0, RAND_MAX). 66 *@brief Generate a float from [0, RAND_MAX).
67 */ 67 */
68S32 ll_rand(); 68LL_COMMON_API S32 ll_rand();
69 69
70/** 70/**
71 *@brief Generate a float from [0, val) or (val, 0]. 71 *@brief Generate a float from [0, val) or (val, 0].
72 */ 72 */
73S32 ll_rand(S32 val); 73LL_COMMON_API S32 ll_rand(S32 val);
74 74
75/** 75/**
76 *@brief Generate a float from [0, 1.0). 76 *@brief Generate a float from [0, 1.0).
77 */ 77 */
78F32 ll_frand(); 78LL_COMMON_API F32 ll_frand();
79 79
80/** 80/**
81 *@brief Generate a float from [0, val) or (val, 0]. 81 *@brief Generate a float from [0, val) or (val, 0].
82 */ 82 */
83F32 ll_frand(F32 val); 83LL_COMMON_API F32 ll_frand(F32 val);
84 84
85/** 85/**
86 *@brief Generate a double from [0, 1.0). 86 *@brief Generate a double from [0, 1.0).
87 */ 87 */
88F64 ll_drand(); 88LL_COMMON_API F64 ll_drand();
89 89
90/** 90/**
91 *@brief Generate a double from [0, val) or (val, 0]. 91 *@brief Generate a double from [0, val) or (val, 0].
92 */ 92 */
93F64 ll_drand(F64 val); 93LL_COMMON_API F64 ll_drand(F64 val);
94 94
95/** 95/**
96 * @brief typedefs for good boost lagged fibonacci. 96 * @brief typedefs for good boost lagged fibonacci.
diff --git a/linden/indra/llcommon/llrun.h b/linden/indra/llcommon/llrun.h
index 77b23d9..0f8d51d 100644
--- a/linden/indra/llcommon/llrun.h
+++ b/linden/indra/llcommon/llrun.h
@@ -38,6 +38,8 @@
38#include <vector> 38#include <vector>
39#include <boost/shared_ptr.hpp> 39#include <boost/shared_ptr.hpp>
40 40
41#include "llpreprocessor.h"
42
41class LLRunnable; 43class LLRunnable;
42 44
43/** 45/**
@@ -48,7 +50,7 @@ class LLRunnable;
48 * which are scheduled to run on a repeating or one time basis. 50 * which are scheduled to run on a repeating or one time basis.
49 * @see LLRunnable 51 * @see LLRunnable
50 */ 52 */
51class LLRunner 53class LL_COMMON_API LLRunner
52{ 54{
53public: 55public:
54 /** 56 /**
@@ -149,7 +151,7 @@ protected:
149 * something useful. 151 * something useful.
150 * @see LLRunner 152 * @see LLRunner
151 */ 153 */
152class LLRunnable 154class LL_COMMON_API LLRunnable
153{ 155{
154public: 156public:
155 LLRunnable(); 157 LLRunnable();
diff --git a/linden/indra/llcommon/llsd.cpp b/linden/indra/llcommon/llsd.cpp
index 2cc94c2..be40bb6 100644
--- a/linden/indra/llcommon/llsd.cpp
+++ b/linden/indra/llcommon/llsd.cpp
@@ -75,7 +75,7 @@ protected:
75 ///< This constructor is used for static objects and causes the 75 ///< This constructor is used for static objects and causes the
76 // suppresses adjusting the debugging counters when they are 76 // suppresses adjusting the debugging counters when they are
77 // finally initialized. 77 // finally initialized.
78 78
79 virtual ~Impl(); 79 virtual ~Impl();
80 80
81 bool shared() const { return mUseCount > 1; } 81 bool shared() const { return mUseCount > 1; }
@@ -162,6 +162,7 @@ namespace
162 162
163 virtual LLSD::Type type() const { return T; } 163 virtual LLSD::Type type() const { return T; }
164 164
165 using LLSD::Impl::assign;
165 virtual void assign(LLSD::Impl*& var, DataRef value) { 166 virtual void assign(LLSD::Impl*& var, DataRef value) {
166 if (shared()) 167 if (shared())
167 { 168 {
@@ -348,6 +349,10 @@ namespace
348 349
349 virtual LLSD::Boolean asBoolean() const { return !mData.empty(); } 350 virtual LLSD::Boolean asBoolean() const { return !mData.empty(); }
350 351
352 using LLSD::Impl::get; // Unhiding get(LLSD::Integer)
353 using LLSD::Impl::erase; // Unhiding erase(LLSD::Integer)
354 using LLSD::Impl::ref; // Unhiding ref(LLSD::Integer)
355
351 virtual bool has(const LLSD::String&) const; 356 virtual bool has(const LLSD::String&) const;
352 virtual LLSD get(const LLSD::String&) const; 357 virtual LLSD get(const LLSD::String&) const;
353 LLSD& insert(const LLSD::String& k, const LLSD& v); 358 LLSD& insert(const LLSD::String& k, const LLSD& v);
@@ -440,6 +445,11 @@ namespace
440 virtual LLSD::Boolean asBoolean() const { return !mData.empty(); } 445 virtual LLSD::Boolean asBoolean() const { return !mData.empty(); }
441 446
442 virtual int size() const; 447 virtual int size() const;
448
449 using LLSD::Impl::get; // Unhiding get(LLSD::Integer)
450 using LLSD::Impl::erase; // Unhiding erase(LLSD::Integer)
451 using LLSD::Impl::ref; // Unhiding ref(LLSD::Integer)
452
443 virtual LLSD get(LLSD::Integer) const; 453 virtual LLSD get(LLSD::Integer) const;
444 void set(LLSD::Integer, const LLSD&); 454 void set(LLSD::Integer, const LLSD&);
445 LLSD& insert(LLSD::Integer, const LLSD&); 455 LLSD& insert(LLSD::Integer, const LLSD&);
diff --git a/linden/indra/llcommon/llsd.h b/linden/indra/llcommon/llsd.h
index d2845a3..552bb57 100644
--- a/linden/indra/llcommon/llsd.h
+++ b/linden/indra/llcommon/llsd.h
@@ -89,7 +89,7 @@
89 @nosubgrouping 89 @nosubgrouping
90*/ 90*/
91 91
92class LLSD 92class LL_COMMON_API LLSD
93{ 93{
94public: 94public:
95 LLSD(); ///< initially Undefined 95 LLSD(); ///< initially Undefined
@@ -387,7 +387,7 @@ struct llsd_select_string : public std::unary_function<LLSD, LLSD::String>
387 } 387 }
388}; 388};
389 389
390std::ostream& operator<<(std::ostream& s, const LLSD& llsd); 390LL_COMMON_API std::ostream& operator<<(std::ostream& s, const LLSD& llsd);
391 391
392/** QUESTIONS & TO DOS 392/** QUESTIONS & TO DOS
393 - Would Binary be more convenient as usigned char* buffer semantics? 393 - Would Binary be more convenient as usigned char* buffer semantics?
diff --git a/linden/indra/llcommon/llsdserialize.h b/linden/indra/llcommon/llsdserialize.h
index f7cd91b..a01b6dc 100644
--- a/linden/indra/llcommon/llsdserialize.h
+++ b/linden/indra/llcommon/llsdserialize.h
@@ -43,7 +43,7 @@
43 * @class LLSDParser 43 * @class LLSDParser
44 * @brief Abstract base class for LLSD parsers. 44 * @brief Abstract base class for LLSD parsers.
45 */ 45 */
46class LLSDParser : public LLRefCount 46class LL_COMMON_API LLSDParser : public LLRefCount
47{ 47{
48protected: 48protected:
49 /** 49 /**
@@ -220,7 +220,7 @@ protected:
220 * @class LLSDNotationParser 220 * @class LLSDNotationParser
221 * @brief Parser which handles the original notation format for LLSD. 221 * @brief Parser which handles the original notation format for LLSD.
222 */ 222 */
223class LLSDNotationParser : public LLSDParser 223class LL_COMMON_API LLSDNotationParser : public LLSDParser
224{ 224{
225protected: 225protected:
226 /** 226 /**
@@ -293,7 +293,7 @@ private:
293 * @class LLSDXMLParser 293 * @class LLSDXMLParser
294 * @brief Parser which handles XML format LLSD. 294 * @brief Parser which handles XML format LLSD.
295 */ 295 */
296class LLSDXMLParser : public LLSDParser 296class LL_COMMON_API LLSDXMLParser : public LLSDParser
297{ 297{
298protected: 298protected:
299 /** 299 /**
@@ -341,7 +341,7 @@ private:
341 * @class LLSDBinaryParser 341 * @class LLSDBinaryParser
342 * @brief Parser which handles binary formatted LLSD. 342 * @brief Parser which handles binary formatted LLSD.
343 */ 343 */
344class LLSDBinaryParser : public LLSDParser 344class LL_COMMON_API LLSDBinaryParser : public LLSDParser
345{ 345{
346protected: 346protected:
347 /** 347 /**
@@ -406,7 +406,7 @@ private:
406 * @class LLSDFormatter 406 * @class LLSDFormatter
407 * @brief Abstract base class for formatting LLSD. 407 * @brief Abstract base class for formatting LLSD.
408 */ 408 */
409class LLSDFormatter : public LLRefCount 409class LL_COMMON_API LLSDFormatter : public LLRefCount
410{ 410{
411protected: 411protected:
412 /** 412 /**
@@ -478,7 +478,7 @@ protected:
478 * @class LLSDNotationFormatter 478 * @class LLSDNotationFormatter
479 * @brief Formatter which outputs the original notation format for LLSD. 479 * @brief Formatter which outputs the original notation format for LLSD.
480 */ 480 */
481class LLSDNotationFormatter : public LLSDFormatter 481class LL_COMMON_API LLSDNotationFormatter : public LLSDFormatter
482{ 482{
483protected: 483protected:
484 /** 484 /**
@@ -519,7 +519,7 @@ public:
519 * @class LLSDXMLFormatter 519 * @class LLSDXMLFormatter
520 * @brief Formatter which outputs the LLSD as XML. 520 * @brief Formatter which outputs the LLSD as XML.
521 */ 521 */
522class LLSDXMLFormatter : public LLSDFormatter 522class LL_COMMON_API LLSDXMLFormatter : public LLSDFormatter
523{ 523{
524protected: 524protected:
525 /** 525 /**
@@ -587,7 +587,7 @@ protected:
587 * Map: '{' + 4 byte integer size every(key + value) + '}'<br> 587 * Map: '{' + 4 byte integer size every(key + value) + '}'<br>
588 * map keys are serialized as 'k' + 4 byte integer size + string 588 * map keys are serialized as 'k' + 4 byte integer size + string
589 */ 589 */
590class LLSDBinaryFormatter : public LLSDFormatter 590class LL_COMMON_API LLSDBinaryFormatter : public LLSDFormatter
591{ 591{
592protected: 592protected:
593 /** 593 /**
@@ -676,7 +676,7 @@ typedef LLSDOStreamer<LLSDXMLFormatter> LLSDXMLStreamer;
676 * @class LLSDSerialize 676 * @class LLSDSerialize
677 * @brief Serializer / deserializer for the various LLSD formats 677 * @brief Serializer / deserializer for the various LLSD formats
678 */ 678 */
679class LLSDSerialize 679class LL_COMMON_API LLSDSerialize
680{ 680{
681public: 681public:
682 enum ELLSD_Serialize 682 enum ELLSD_Serialize
diff --git a/linden/indra/llcommon/llsdserialize_xml.cpp b/linden/indra/llcommon/llsdserialize_xml.cpp
index c12ca35..33206b4 100644
--- a/linden/indra/llcommon/llsdserialize_xml.cpp
+++ b/linden/indra/llcommon/llsdserialize_xml.cpp
@@ -562,7 +562,7 @@ void LLSDXMLParser::Impl::parsePart(const char* buf, int len)
562 562
563#ifdef XML_PARSER_PERFORMANCE_TESTS 563#ifdef XML_PARSER_PERFORMANCE_TESTS
564 564
565extern U64 totalTime(); 565extern LL_COMMON_API U64 totalTime();
566U64 readElementTime = 0; 566U64 readElementTime = 0;
567U64 startElementTime = 0; 567U64 startElementTime = 0;
568U64 endElementTime = 0; 568U64 endElementTime = 0;
diff --git a/linden/indra/llcommon/llsdutil.h b/linden/indra/llcommon/llsdutil.h
index b67ad52..4740a30 100644
--- a/linden/indra/llcommon/llsdutil.h
+++ b/linden/indra/llcommon/llsdutil.h
@@ -68,28 +68,28 @@ LLSD ll_sd_from_color4(const LLColor4& c);
68LLColor4 ll_color4_from_sd(const LLSD& sd); 68LLColor4 ll_color4_from_sd(const LLSD& sd);
69 69
70// U32 70// U32
71LLSD ll_sd_from_U32(const U32); 71LL_COMMON_API LLSD ll_sd_from_U32(const U32);
72U32 ll_U32_from_sd(const LLSD& sd); 72LL_COMMON_API U32 ll_U32_from_sd(const LLSD& sd);
73 73
74// U64 74// U64
75LLSD ll_sd_from_U64(const U64); 75LL_COMMON_API LLSD ll_sd_from_U64(const U64);
76U64 ll_U64_from_sd(const LLSD& sd); 76LL_COMMON_API U64 ll_U64_from_sd(const LLSD& sd);
77 77
78// IP Address 78// IP Address
79LLSD ll_sd_from_ipaddr(const U32); 79LL_COMMON_API LLSD ll_sd_from_ipaddr(const U32);
80U32 ll_ipaddr_from_sd(const LLSD& sd); 80LL_COMMON_API U32 ll_ipaddr_from_sd(const LLSD& sd);
81 81
82// Binary to string 82// Binary to string
83LLSD ll_string_from_binary(const LLSD& sd); 83LL_COMMON_API LLSD ll_string_from_binary(const LLSD& sd);
84 84
85//String to binary 85//String to binary
86LLSD ll_binary_from_string(const LLSD& sd); 86LL_COMMON_API LLSD ll_binary_from_string(const LLSD& sd);
87 87
88// Serializes sd to static buffer and returns pointer, useful for gdb debugging. 88// Serializes sd to static buffer and returns pointer, useful for gdb debugging.
89char* ll_print_sd(const LLSD& sd); 89LL_COMMON_API char* ll_print_sd(const LLSD& sd);
90 90
91// Serializes sd to static buffer and returns pointer, using "pretty printing" mode. 91// Serializes sd to static buffer and returns pointer, using "pretty printing" mode.
92char* ll_pretty_print_sd(const LLSD& sd); 92LL_COMMON_API char* ll_pretty_print_sd(const LLSD& sd);
93 93
94//compares the structure of an LLSD to a template LLSD and stores the 94//compares the structure of an LLSD to a template LLSD and stores the
95//"valid" values in a 3rd LLSD. Default values 95//"valid" values in a 3rd LLSD. Default values
@@ -98,7 +98,7 @@ char* ll_pretty_print_sd(const LLSD& sd);
98//Returns false if the test is of same type but values differ in type 98//Returns false if the test is of same type but values differ in type
99//Otherwise, returns true 99//Otherwise, returns true
100 100
101BOOL compare_llsd_with_template( 101LL_COMMON_API BOOL compare_llsd_with_template(
102 const LLSD& llsd_to_test, 102 const LLSD& llsd_to_test,
103 const LLSD& template_llsd, 103 const LLSD& template_llsd,
104 LLSD& resultant_llsd); 104 LLSD& resultant_llsd);
diff --git a/linden/indra/llcommon/llsecondlifeurls.h b/linden/indra/llcommon/llsecondlifeurls.h
index 9c64b57..e3932d0 100644
--- a/linden/indra/llcommon/llsecondlifeurls.h
+++ b/linden/indra/llcommon/llsecondlifeurls.h
@@ -34,14 +34,14 @@
34#define LL_LLSECONDLIFEURLS_H 34#define LL_LLSECONDLIFEURLS_H
35 35
36 36
37extern const std::string AUCTION_URL; 37LL_COMMON_API extern const std::string AUCTION_URL;
38 38
39extern const std::string EVENTS_URL; 39LL_COMMON_API extern const std::string EVENTS_URL;
40 40
41// Currency page 41// Currency page
42extern const std::string BUY_CURRENCY_URL; 42LL_COMMON_API extern const std::string BUY_CURRENCY_URL;
43 43
44// Release Notes Redirect URL for Server and Viewer 44// Release Notes Redirect URL for Server and Viewer
45extern const std::string RELEASE_NOTES_BASE_URL; 45LL_COMMON_API extern const std::string RELEASE_NOTES_BASE_URL;
46 46
47#endif 47#endif
diff --git a/linden/indra/llcommon/llsimplehash.h b/linden/indra/llcommon/llsimplehash.h
index 0ba2a30..5df93b6 100644
--- a/linden/indra/llcommon/llsimplehash.h
+++ b/linden/indra/llcommon/llsimplehash.h
@@ -64,7 +64,7 @@ public:
64}; 64};
65 65
66template <typename HASH_KEY_TYPE, int TABLE_SIZE> 66template <typename HASH_KEY_TYPE, int TABLE_SIZE>
67class LLSimpleHash 67class LL_COMMON_API LLSimpleHash
68{ 68{
69public: 69public:
70 LLSimpleHash() 70 LLSimpleHash()
diff --git a/linden/indra/llcommon/llstat.h b/linden/indra/llcommon/llstat.h
index 66521a3..951091b 100644
--- a/linden/indra/llcommon/llstat.h
+++ b/linden/indra/llcommon/llstat.h
@@ -52,7 +52,7 @@ class LLSD;
52// amounts of time with very low memory cost. 52// amounts of time with very low memory cost.
53// 53//
54 54
55class LLStatAccum 55class LL_COMMON_API LLStatAccum
56{ 56{
57protected: 57protected:
58 LLStatAccum(bool use_frame_timer); 58 LLStatAccum(bool use_frame_timer);
@@ -109,7 +109,7 @@ public:
109 F64 mLastSampleValue; 109 F64 mLastSampleValue;
110}; 110};
111 111
112class LLStatMeasure : public LLStatAccum 112class LL_COMMON_API LLStatMeasure : public LLStatAccum
113 // gathers statistics about things that are measured 113 // gathers statistics about things that are measured
114 // ex.: tempature, time dilation 114 // ex.: tempature, time dilation
115{ 115{
@@ -124,7 +124,7 @@ public:
124}; 124};
125 125
126 126
127class LLStatRate : public LLStatAccum 127class LL_COMMON_API LLStatRate : public LLStatAccum
128 // gathers statistics about things that can be counted over time 128 // gathers statistics about things that can be counted over time
129 // ex.: LSL instructions executed, messages sent, simulator frames completed 129 // ex.: LSL instructions executed, messages sent, simulator frames completed
130 // renders it in terms of rate of thing per second 130 // renders it in terms of rate of thing per second
@@ -140,7 +140,7 @@ public:
140}; 140};
141 141
142 142
143class LLStatTime : public LLStatAccum 143class LL_COMMON_API LLStatTime : public LLStatAccum
144 // gathers statistics about time spent in a block of code 144 // gathers statistics about time spent in a block of code
145 // measure average duration per second in the block 145 // measure average duration per second in the block
146{ 146{
@@ -171,7 +171,7 @@ private:
171 171
172 172
173// Use this class on the stack to record statistics about an area of code 173// Use this class on the stack to record statistics about an area of code
174class LLPerfBlock 174class LL_COMMON_API LLPerfBlock
175{ 175{
176public: 176public:
177 struct StatEntry 177 struct StatEntry
@@ -213,7 +213,7 @@ private:
213 213
214// ---------------------------------------------------------------------------- 214// ----------------------------------------------------------------------------
215 215
216class LLPerfStats 216class LL_COMMON_API LLPerfStats
217{ 217{
218public: 218public:
219 LLPerfStats(const std::string& process_name = "unknown", S32 process_pid = 0); 219 LLPerfStats(const std::string& process_name = "unknown", S32 process_pid = 0);
@@ -249,7 +249,7 @@ private:
249}; 249};
250 250
251// ---------------------------------------------------------------------------- 251// ----------------------------------------------------------------------------
252class LLStat 252class LL_COMMON_API LLStat
253{ 253{
254public: 254public:
255 LLStat(const U32 num_bins = 32, BOOL use_frame_timer = FALSE); 255 LLStat(const U32 num_bins = 32, BOOL use_frame_timer = FALSE);
diff --git a/linden/indra/llcommon/llstreamtools.h b/linden/indra/llcommon/llstreamtools.h
index a6dc4d5..371fac5 100644
--- a/linden/indra/llcommon/llstreamtools.h
+++ b/linden/indra/llcommon/llstreamtools.h
@@ -39,23 +39,23 @@
39// unless specifed otherwise these all return input_stream.good() 39// unless specifed otherwise these all return input_stream.good()
40 40
41// skips spaces and tabs 41// skips spaces and tabs
42bool skip_whitespace(std::istream& input_stream); 42LL_COMMON_API bool skip_whitespace(std::istream& input_stream);
43 43
44// skips whitespace and newlines 44// skips whitespace and newlines
45bool skip_emptyspace(std::istream& input_stream); 45LL_COMMON_API bool skip_emptyspace(std::istream& input_stream);
46 46
47// skips emptyspace and lines that start with a # 47// skips emptyspace and lines that start with a #
48bool skip_comments_and_emptyspace(std::istream& input_stream); 48LL_COMMON_API bool skip_comments_and_emptyspace(std::istream& input_stream);
49 49
50// skips to character after next newline 50// skips to character after next newline
51bool skip_line(std::istream& input_stream); 51LL_COMMON_API bool skip_line(std::istream& input_stream);
52 52
53// skips to beginning of next non-emptyspace 53// skips to beginning of next non-emptyspace
54bool skip_to_next_word(std::istream& input_stream); 54LL_COMMON_API bool skip_to_next_word(std::istream& input_stream);
55 55
56// skips to character after the end of next keyword 56// skips to character after the end of next keyword
57// a 'keyword' is defined as the first word on a line 57// a 'keyword' is defined as the first word on a line
58bool skip_to_end_of_next_keyword(const char* keyword, std::istream& input_stream); 58LL_COMMON_API bool skip_to_end_of_next_keyword(const char* keyword, std::istream& input_stream);
59 59
60// skip_to_start_of_next_keyword() is disabled -- might tickle corruption bug 60// skip_to_start_of_next_keyword() is disabled -- might tickle corruption bug
61// in windows iostream 61// in windows iostream
@@ -65,14 +65,14 @@ bool skip_to_end_of_next_keyword(const char* keyword, std::istream& input_stream
65 65
66// characters are pulled out of input_stream and appended to output_string 66// characters are pulled out of input_stream and appended to output_string
67// returns result of input_stream.good() after characters are pulled 67// returns result of input_stream.good() after characters are pulled
68bool get_word(std::string& output_string, std::istream& input_stream); 68LL_COMMON_API bool get_word(std::string& output_string, std::istream& input_stream);
69bool get_line(std::string& output_string, std::istream& input_stream); 69LL_COMMON_API bool get_line(std::string& output_string, std::istream& input_stream);
70 70
71// characters are pulled out of input_stream (up to a max of 'n') 71// characters are pulled out of input_stream (up to a max of 'n')
72// and appended to output_string 72// and appended to output_string
73// returns result of input_stream.good() after characters are pulled 73// returns result of input_stream.good() after characters are pulled
74bool get_word(std::string& output_string, std::istream& input_stream, int n); 74LL_COMMON_API bool get_word(std::string& output_string, std::istream& input_stream, int n);
75bool get_line(std::string& output_string, std::istream& input_stream, int n); 75LL_COMMON_API bool get_line(std::string& output_string, std::istream& input_stream, int n);
76 76
77// unget_line() is disabled -- might tickle corruption bug in windows iostream 77// unget_line() is disabled -- might tickle corruption bug in windows iostream
78//// backs up the input_stream by line_size + 1 characters 78//// backs up the input_stream by line_size + 1 characters
@@ -82,28 +82,28 @@ bool get_line(std::string& output_string, std::istream& input_stream, int n);
82 82
83// removes the last char in 'line' if it matches 'c' 83// removes the last char in 'line' if it matches 'c'
84// returns true if removed last char 84// returns true if removed last char
85bool remove_last_char(char c, std::string& line); 85LL_COMMON_API bool remove_last_char(char c, std::string& line);
86 86
87// replaces escaped characters with the correct characters from left to right 87// replaces escaped characters with the correct characters from left to right
88// "\\" ---> '\\' 88// "\\" ---> '\\'
89// "\n" ---> '\n' 89// "\n" ---> '\n'
90void unescape_string(std::string& line); 90LL_COMMON_API void unescape_string(std::string& line);
91 91
92// replaces unescaped characters with expanded equivalents from left to right 92// replaces unescaped characters with expanded equivalents from left to right
93// '\\' ---> "\\" 93// '\\' ---> "\\"
94// '\n' ---> "\n" 94// '\n' ---> "\n"
95void escape_string(std::string& line); 95LL_COMMON_API void escape_string(std::string& line);
96 96
97// replaces each '\n' character with ' ' 97// replaces each '\n' character with ' '
98void replace_newlines_with_whitespace(std::string& line); 98LL_COMMON_API void replace_newlines_with_whitespace(std::string& line);
99 99
100// erases any double-quote characters in line 100// erases any double-quote characters in line
101void remove_double_quotes(std::string& line); 101LL_COMMON_API void remove_double_quotes(std::string& line);
102 102
103// the 'keyword' is defined as the first word on a line 103// the 'keyword' is defined as the first word on a line
104// the 'value' is everything after the keyword on the same line 104// the 'value' is everything after the keyword on the same line
105// starting at the first non-whitespace and ending right before the newline 105// starting at the first non-whitespace and ending right before the newline
106void get_keyword_and_value(std::string& keyword, 106LL_COMMON_API void get_keyword_and_value(std::string& keyword,
107 std::string& value, 107 std::string& value,
108 const std::string& line); 108 const std::string& line);
109 109
@@ -111,13 +111,13 @@ void get_keyword_and_value(std::string& keyword,
111// read anymore or until we hit the count. Some istream 111// read anymore or until we hit the count. Some istream
112// implimentations have a max that they will read. 112// implimentations have a max that they will read.
113// Returns the number of bytes read. 113// Returns the number of bytes read.
114std::streamsize fullread( 114LL_COMMON_API std::streamsize fullread(
115 std::istream& istr, 115 std::istream& istr,
116 char* buf, 116 char* buf,
117 std::streamsize requested); 117 std::streamsize requested);
118 118
119 119
120std::istream& operator>>(std::istream& str, const char *tocheck); 120LL_COMMON_API std::istream& operator>>(std::istream& str, const char *tocheck);
121 121
122#endif 122#endif
123 123
diff --git a/linden/indra/llcommon/llstring.h b/linden/indra/llcommon/llstring.h
index bab89b1..ae5d84c 100644
--- a/linden/indra/llcommon/llstring.h
+++ b/linden/indra/llcommon/llstring.h
@@ -34,12 +34,13 @@
34#define LL_LLSTRING_H 34#define LL_LLSTRING_H
35 35
36#include <string> 36#include <string>
37#include <cstdio>
38#include <algorithm>
37 39
38#if LL_LINUX || LL_SOLARIS 40#if LL_LINUX || LL_SOLARIS
39#include <wctype.h> 41#include <wctype.h>
40#include <wchar.h> 42#include <wchar.h>
41#endif 43#endif
42#include "linden_common.h"
43 44
44#include <string.h> 45#include <string.h>
45 46
@@ -144,7 +145,7 @@ struct char_traits<U16>
144}; 145};
145#endif 146#endif
146 147
147class LLStringOps 148class LL_COMMON_API LLStringOps
148{ 149{
149public: 150public:
150 static char toUpper(char elem) { return toupper((unsigned char)elem); } 151 static char toUpper(char elem) { return toupper((unsigned char)elem); }
@@ -179,8 +180,8 @@ public:
179 * @brief Return a string constructed from in without crashing if the 180 * @brief Return a string constructed from in without crashing if the
180 * pointer is NULL. 181 * pointer is NULL.
181 */ 182 */
182std::string ll_safe_string(const char* in); 183std::string LL_COMMON_API ll_safe_string(const char* in);
183std::string ll_safe_string(const char* in, S32 maxlen); 184std::string LL_COMMON_API ll_safe_string(const char* in, S32 maxlen);
184 185
185 186
186// Allowing assignments from non-strings into format_map_t is apparently 187// Allowing assignments from non-strings into format_map_t is apparently
@@ -236,7 +237,8 @@ public:
236 static void replaceTabsWithSpaces( std::basic_string<T>& string, size_type spaces_per_tab ); 237 static void replaceTabsWithSpaces( std::basic_string<T>& string, size_type spaces_per_tab );
237 static void replaceNonstandardASCII( std::basic_string<T>& string, T replacement ); 238 static void replaceNonstandardASCII( std::basic_string<T>& string, T replacement );
238 static void replaceChar( std::basic_string<T>& string, T target, T replacement ); 239 static void replaceChar( std::basic_string<T>& string, T target, T replacement );
239 240 static void replaceString( std::basic_string<T>& string, std::basic_string<T> target, std::basic_string<T> replacement );
241
240 static BOOL containsNonprintable(const std::basic_string<T>& string); 242 static BOOL containsNonprintable(const std::basic_string<T>& string);
241 static void stripNonprintable(std::basic_string<T>& string); 243 static void stripNonprintable(std::basic_string<T>& string);
242 244
@@ -349,7 +351,7 @@ inline std::string chop_tail_copy(
349 * @brief This translates a nybble stored as a hex value from 0-f back 351 * @brief This translates a nybble stored as a hex value from 0-f back
350 * to a nybble in the low order bits of the return byte. 352 * to a nybble in the low order bits of the return byte.
351 */ 353 */
352U8 hex_as_nybble(char hex); 354LL_COMMON_API U8 hex_as_nybble(char hex);
353 355
354/** 356/**
355 * @brief read the contents of a file into a string. 357 * @brief read the contents of a file into a string.
@@ -360,7 +362,7 @@ U8 hex_as_nybble(char hex);
360 * @param filename The full name of the file to read. 362 * @param filename The full name of the file to read.
361 * @return Returns true on success. If false, str is unmodified. 363 * @return Returns true on success. If false, str is unmodified.
362 */ 364 */
363bool _read_file_into_string(std::string& str, const std::string& filename); 365LL_COMMON_API bool _read_file_into_string(std::string& str, const std::string& filename);
364 366
365/** 367/**
366 * Unicode support 368 * Unicode support
@@ -369,52 +371,52 @@ bool _read_file_into_string(std::string& str, const std::string& filename);
369// Make the incoming string a utf8 string. Replaces any unknown glyph 371// Make the incoming string a utf8 string. Replaces any unknown glyph
370// with the UNKOWN_CHARACTER. Once any unknown glph is found, the rest 372// with the UNKOWN_CHARACTER. Once any unknown glph is found, the rest
371// of the data may not be recovered. 373// of the data may not be recovered.
372std::string rawstr_to_utf8(const std::string& raw); 374LL_COMMON_API std::string rawstr_to_utf8(const std::string& raw);
373 375
374// 376//
375// We should never use UTF16 except when communicating with Win32! 377// We should never use UTF16 except when communicating with Win32!
376// 378//
377typedef std::basic_string<U16> llutf16string; 379typedef std::basic_string<U16> llutf16string;
378 380
379LLWString utf16str_to_wstring(const llutf16string &utf16str, S32 len); 381LL_COMMON_API LLWString utf16str_to_wstring(const llutf16string &utf16str, S32 len);
380LLWString utf16str_to_wstring(const llutf16string &utf16str); 382LL_COMMON_API LLWString utf16str_to_wstring(const llutf16string &utf16str);
381 383
382llutf16string wstring_to_utf16str(const LLWString &utf32str, S32 len); 384LL_COMMON_API llutf16string wstring_to_utf16str(const LLWString &utf32str, S32 len);
383llutf16string wstring_to_utf16str(const LLWString &utf32str); 385LL_COMMON_API llutf16string wstring_to_utf16str(const LLWString &utf32str);
384 386
385llutf16string utf8str_to_utf16str ( const std::string& utf8str, S32 len); 387LL_COMMON_API llutf16string utf8str_to_utf16str ( const std::string& utf8str, S32 len);
386llutf16string utf8str_to_utf16str ( const std::string& utf8str ); 388LL_COMMON_API llutf16string utf8str_to_utf16str ( const std::string& utf8str );
387 389
388LLWString utf8str_to_wstring(const std::string &utf8str, S32 len); 390LL_COMMON_API LLWString utf8str_to_wstring(const std::string &utf8str, S32 len);
389LLWString utf8str_to_wstring(const std::string &utf8str); 391LL_COMMON_API LLWString utf8str_to_wstring(const std::string &utf8str);
390// Same function, better name. JC 392// Same function, better name. JC
391inline LLWString utf8string_to_wstring(const std::string& utf8_string) { return utf8str_to_wstring(utf8_string); } 393inline LLWString utf8string_to_wstring(const std::string& utf8_string) { return utf8str_to_wstring(utf8_string); }
392 394
393// 395//
394S32 wchar_to_utf8chars(llwchar inchar, char* outchars); 396LL_COMMON_API S32 wchar_to_utf8chars(llwchar inchar, char* outchars);
395 397
396std::string wstring_to_utf8str(const LLWString &utf32str, S32 len); 398LL_COMMON_API std::string wstring_to_utf8str(const LLWString &utf32str, S32 len);
397std::string wstring_to_utf8str(const LLWString &utf32str); 399LL_COMMON_API std::string wstring_to_utf8str(const LLWString &utf32str);
398 400
399std::string utf16str_to_utf8str(const llutf16string &utf16str, S32 len); 401LL_COMMON_API std::string utf16str_to_utf8str(const llutf16string &utf16str, S32 len);
400std::string utf16str_to_utf8str(const llutf16string &utf16str); 402LL_COMMON_API std::string utf16str_to_utf8str(const llutf16string &utf16str);
401 403
402// Length of this UTF32 string in bytes when transformed to UTF8 404// Length of this UTF32 string in bytes when transformed to UTF8
403S32 wstring_utf8_length(const LLWString& wstr); 405LL_COMMON_API S32 wstring_utf8_length(const LLWString& wstr);
404 406
405// Length in bytes of this wide char in a UTF8 string 407// Length in bytes of this wide char in a UTF8 string
406S32 wchar_utf8_length(const llwchar wc); 408LL_COMMON_API S32 wchar_utf8_length(const llwchar wc);
407 409
408std::string utf8str_tolower(const std::string& utf8str); 410LL_COMMON_API std::string utf8str_tolower(const std::string& utf8str);
409 411
410// Length in llwchar (UTF-32) of the first len units (16 bits) of the given UTF-16 string. 412// Length in llwchar (UTF-32) of the first len units (16 bits) of the given UTF-16 string.
411S32 utf16str_wstring_length(const llutf16string &utf16str, S32 len); 413LL_COMMON_API S32 utf16str_wstring_length(const llutf16string &utf16str, S32 len);
412 414
413// Length in utf16string (UTF-16) of wlen wchars beginning at woffset. 415// Length in utf16string (UTF-16) of wlen wchars beginning at woffset.
414S32 wstring_utf16_length(const LLWString & wstr, S32 woffset, S32 wlen); 416LL_COMMON_API S32 wstring_utf16_length(const LLWString & wstr, S32 woffset, S32 wlen);
415 417
416// Length in wstring (i.e., llwchar count) of a part of a wstring specified by utf16 length (i.e., utf16 units.) 418// Length in wstring (i.e., llwchar count) of a part of a wstring specified by utf16 length (i.e., utf16 units.)
417S32 wstring_wstring_length_from_utf16_length(const LLWString & wstr, S32 woffset, S32 utf16_length, BOOL *unaligned = NULL); 419LL_COMMON_API S32 wstring_wstring_length_from_utf16_length(const LLWString & wstr, S32 woffset, S32 utf16_length, BOOL *unaligned = NULL);
418 420
419/** 421/**
420 * @brief Properly truncate a utf8 string to a maximum byte count. 422 * @brief Properly truncate a utf8 string to a maximum byte count.
@@ -426,11 +428,11 @@ S32 wstring_wstring_length_from_utf16_length(const LLWString & wstr, S32 woffset
426 * @param max_len The maximum number of bytes in the return value. 428 * @param max_len The maximum number of bytes in the return value.
427 * @return Returns a valid utf8 string with byte count <= max_len. 429 * @return Returns a valid utf8 string with byte count <= max_len.
428 */ 430 */
429std::string utf8str_truncate(const std::string& utf8str, const S32 max_len); 431LL_COMMON_API std::string utf8str_truncate(const std::string& utf8str, const S32 max_len);
430 432
431std::string utf8str_trim(const std::string& utf8str); 433LL_COMMON_API std::string utf8str_trim(const std::string& utf8str);
432 434
433S32 utf8str_compare_insensitive( 435LL_COMMON_API S32 utf8str_compare_insensitive(
434 const std::string& lhs, 436 const std::string& lhs,
435 const std::string& rhs); 437 const std::string& rhs);
436 438
@@ -441,17 +443,17 @@ S32 utf8str_compare_insensitive(
441 * @param target_char The wchar to be replaced 443 * @param target_char The wchar to be replaced
442 * @param replace_char The wchar which is written on replace 444 * @param replace_char The wchar which is written on replace
443 */ 445 */
444std::string utf8str_substChar( 446LL_COMMON_API std::string utf8str_substChar(
445 const std::string& utf8str, 447 const std::string& utf8str,
446 const llwchar target_char, 448 const llwchar target_char,
447 const llwchar replace_char); 449 const llwchar replace_char);
448 450
449std::string utf8str_makeASCII(const std::string& utf8str); 451LL_COMMON_API std::string utf8str_makeASCII(const std::string& utf8str);
450 452
451// Hack - used for evil notecards. 453// Hack - used for evil notecards.
452std::string mbcsstring_makeASCII(const std::string& str); 454LL_COMMON_API std::string mbcsstring_makeASCII(const std::string& str);
453 455
454std::string utf8str_removeCRLF(const std::string& utf8str); 456LL_COMMON_API std::string utf8str_removeCRLF(const std::string& utf8str);
455 457
456 458
457#if LL_WINDOWS 459#if LL_WINDOWS
@@ -476,14 +478,21 @@ std::string utf8str_removeCRLF(const std::string& utf8str);
476 * formatted string. 478 * formatted string.
477 * 479 *
478 */ 480 */
479int safe_snprintf(char* str, size_t size, const char* format, ...); 481
482// Deal with the differeneces on Windows
483namespace snprintf_hack
484{
485 LL_COMMON_API int snprintf(char *str, size_t size, const char *format, ...);
486}
487
488using snprintf_hack::snprintf;
480 489
481/** 490/**
482 * @brief Convert a wide string to std::string 491 * @brief Convert a wide string to std::string
483 * 492 *
484 * This replaces the unsafe W2A macro from ATL. 493 * This replaces the unsafe W2A macro from ATL.
485 */ 494 */
486std::string ll_convert_wide_to_string(const wchar_t* in); 495LL_COMMON_API std::string ll_convert_wide_to_string(const wchar_t* in);
487 496
488//@} 497//@}
489#endif // LL_WINDOWS 498#endif // LL_WINDOWS
@@ -506,7 +515,7 @@ namespace LLStringFn
506 * with zero non-printable characters. 515 * with zero non-printable characters.
507 * @param The replacement character. use LL_UNKNOWN_CHAR if unsure. 516 * @param The replacement character. use LL_UNKNOWN_CHAR if unsure.
508 */ 517 */
509 void replace_nonprintable_in_ascii( 518 LL_COMMON_API void replace_nonprintable_in_ascii(
510 std::basic_string<char>& string, 519 std::basic_string<char>& string,
511 char replacement); 520 char replacement);
512 521
@@ -520,7 +529,7 @@ namespace LLStringFn
520 * with zero non-printable characters and zero pipe characters. 529 * with zero non-printable characters and zero pipe characters.
521 * @param The replacement character. use LL_UNKNOWN_CHAR if unsure. 530 * @param The replacement character. use LL_UNKNOWN_CHAR if unsure.
522 */ 531 */
523 void replace_nonprintable_and_pipe_in_ascii(std::basic_string<char>& str, 532 LL_COMMON_API void replace_nonprintable_and_pipe_in_ascii(std::basic_string<char>& str,
524 char replacement); 533 char replacement);
525 534
526 535
@@ -529,7 +538,7 @@ namespace LLStringFn
529 * Returns a copy of the string with those characters removed. 538 * Returns a copy of the string with those characters removed.
530 * Works with US ASCII and UTF-8 encoded strings. JC 539 * Works with US ASCII and UTF-8 encoded strings. JC
531 */ 540 */
532 std::string strip_invalid_xml(const std::string& input); 541 LL_COMMON_API std::string strip_invalid_xml(const std::string& input);
533 542
534 543
535 /** 544 /**
@@ -540,7 +549,7 @@ namespace LLStringFn
540 * with zero non-printable characters. 549 * with zero non-printable characters.
541 * @param The replacement character. use LL_UNKNOWN_CHAR if unsure. 550 * @param The replacement character. use LL_UNKNOWN_CHAR if unsure.
542 */ 551 */
543 void replace_ascii_controlchars( 552 LL_COMMON_API void replace_ascii_controlchars(
544 std::basic_string<char>& string, 553 std::basic_string<char>& string,
545 char replacement); 554 char replacement);
546} 555}
@@ -901,11 +910,22 @@ template<class T>
901void LLStringUtilBase<T>::replaceChar( std::basic_string<T>& string, T target, T replacement ) 910void LLStringUtilBase<T>::replaceChar( std::basic_string<T>& string, T target, T replacement )
902{ 911{
903 size_type found_pos = 0; 912 size_type found_pos = 0;
904 for (found_pos = string.find(target, found_pos); 913 while( (found_pos = string.find(target, found_pos)) != std::basic_string<T>::npos )
905 found_pos != std::basic_string<T>::npos;
906 found_pos = string.find(target, found_pos))
907 { 914 {
908 string[found_pos] = replacement; 915 string[found_pos] = replacement;
916 found_pos++; // avoid infinite defeat if target == replacement
917 }
918}
919
920//static
921template<class T>
922void LLStringUtilBase<T>::replaceString( std::basic_string<T>& string, std::basic_string<T> target, std::basic_string<T> replacement )
923{
924 size_type found_pos = 0;
925 while( (found_pos = string.find(target, found_pos)) != std::basic_string<T>::npos )
926 {
927 string.replace( found_pos, target.length(), replacement );
928 found_pos += replacement.length(); // avoid infinite defeat if replacement contains target
909 } 929 }
910} 930}
911 931
diff --git a/linden/indra/llcommon/llstringtable.h b/linden/indra/llcommon/llstringtable.h
index 4492063..b13b016 100644
--- a/linden/indra/llcommon/llstringtable.h
+++ b/linden/indra/llcommon/llstringtable.h
@@ -56,7 +56,7 @@
56 56
57const U32 MAX_STRINGS_LENGTH = 256; 57const U32 MAX_STRINGS_LENGTH = 256;
58 58
59class LLStringTableEntry 59class LL_COMMON_API LLStringTableEntry
60{ 60{
61public: 61public:
62 LLStringTableEntry(const char *str) 62 LLStringTableEntry(const char *str)
@@ -81,7 +81,7 @@ public:
81 S32 mCount; 81 S32 mCount;
82}; 82};
83 83
84class LLStringTable 84class LL_COMMON_API LLStringTable
85{ 85{
86public: 86public:
87 LLStringTable(int tablesize); 87 LLStringTable(int tablesize);
@@ -115,7 +115,7 @@ public:
115#endif 115#endif
116}; 116};
117 117
118extern LLStringTable gStringTable; 118extern LL_COMMON_API LLStringTable gStringTable;
119 119
120//============================================================================ 120//============================================================================
121 121
@@ -125,7 +125,7 @@ extern LLStringTable gStringTable;
125 125
126typedef const std::string* LLStdStringHandle; 126typedef const std::string* LLStdStringHandle;
127 127
128class LLStdStringTable 128class LL_COMMON_API LLStdStringTable
129{ 129{
130public: 130public:
131 LLStdStringTable(S32 tablesize = 0) 131 LLStdStringTable(S32 tablesize = 0)
diff --git a/linden/indra/llcommon/llsys.h b/linden/indra/llcommon/llsys.h
index 03f48ca..d5575b2 100644
--- a/linden/indra/llcommon/llsys.h
+++ b/linden/indra/llcommon/llsys.h
@@ -45,7 +45,7 @@
45#include <iosfwd> 45#include <iosfwd>
46#include <string> 46#include <string>
47 47
48class LLOSInfo 48class LL_COMMON_API LLOSInfo
49{ 49{
50public: 50public:
51 LLOSInfo(); 51 LLOSInfo();
@@ -70,7 +70,7 @@ private:
70}; 70};
71 71
72 72
73class LLCPUInfo 73class LL_COMMON_API LLCPUInfo
74{ 74{
75public: 75public:
76 LLCPUInfo(); 76 LLCPUInfo();
@@ -99,7 +99,7 @@ private:
99// 99//
100// CLASS LLMemoryInfo 100// CLASS LLMemoryInfo
101 101
102class LLMemoryInfo 102class LL_COMMON_API LLMemoryInfo
103 103
104/*! @brief Class to query the memory subsystem 104/*! @brief Class to query the memory subsystem
105 105
@@ -123,15 +123,15 @@ public:
123}; 123};
124 124
125 125
126std::ostream& operator<<(std::ostream& s, const LLOSInfo& info); 126LL_COMMON_API std::ostream& operator<<(std::ostream& s, const LLOSInfo& info);
127std::ostream& operator<<(std::ostream& s, const LLCPUInfo& info); 127LL_COMMON_API std::ostream& operator<<(std::ostream& s, const LLCPUInfo& info);
128std::ostream& operator<<(std::ostream& s, const LLMemoryInfo& info); 128LL_COMMON_API std::ostream& operator<<(std::ostream& s, const LLMemoryInfo& info);
129 129
130// gunzip srcfile into dstfile. Returns FALSE on error. 130// gunzip srcfile into dstfile. Returns FALSE on error.
131BOOL gunzip_file(const std::string& srcfile, const std::string& dstfile); 131LL_COMMON_API BOOL gunzip_file(const std::string& srcfile, const std::string& dstfile);
132// gzip srcfile into dstfile. Returns FALSE on error. 132// gzip srcfile into dstfile. Returns FALSE on error.
133BOOL gzip_file(const std::string& srcfile, const std::string& dstfile); 133LL_COMMON_API BOOL gzip_file(const std::string& srcfile, const std::string& dstfile);
134 134
135extern LLCPUInfo gSysCPU; 135LL_COMMON_API extern LLCPUInfo gSysCPU;
136 136
137#endif // LL_LLSYS_H 137#endif // LL_LLSYS_H
diff --git a/linden/indra/llcommon/llthread.h b/linden/indra/llcommon/llthread.h
index ed76a3b..98d64ef 100644
--- a/linden/indra/llcommon/llthread.h
+++ b/linden/indra/llcommon/llthread.h
@@ -43,7 +43,7 @@ class LLThread;
43class LLMutex; 43class LLMutex;
44class LLCondition; 44class LLCondition;
45 45
46class LLThread 46class LL_COMMON_API LLThread
47{ 47{
48public: 48public:
49 typedef enum e_thread_status 49 typedef enum e_thread_status
@@ -125,7 +125,7 @@ protected:
125 125
126//============================================================================ 126//============================================================================
127 127
128class LLMutex 128class LL_COMMON_API LLMutex
129{ 129{
130public: 130public:
131 LLMutex(apr_pool_t *apr_poolp); // NULL pool constructs a new pool for the mutex 131 LLMutex(apr_pool_t *apr_poolp); // NULL pool constructs a new pool for the mutex
@@ -145,7 +145,7 @@ protected:
145}; 145};
146 146
147// Actually a condition/mutex pair (since each condition needs to be associated with a mutex). 147// Actually a condition/mutex pair (since each condition needs to be associated with a mutex).
148class LLCondition : public LLMutex 148class LL_COMMON_API LLCondition : public LLMutex
149{ 149{
150public: 150public:
151 LLCondition(apr_pool_t *apr_poolp); // Defaults to global pool, could use the thread pool as well. 151 LLCondition(apr_pool_t *apr_poolp); // Defaults to global pool, could use the thread pool as well.
@@ -159,7 +159,7 @@ protected:
159 apr_thread_cond_t *mAPRCondp; 159 apr_thread_cond_t *mAPRCondp;
160}; 160};
161 161
162class LLMutexLock 162class LL_COMMON_API LLMutexLock
163{ 163{
164public: 164public:
165 LLMutexLock(LLMutex* mutex) 165 LLMutexLock(LLMutex* mutex)
@@ -192,7 +192,7 @@ void LLThread::unlockData()
192 192
193// see llmemory.h for LLPointer<> definition 193// see llmemory.h for LLPointer<> definition
194 194
195class LLThreadSafeRefCount 195class LL_COMMON_API LLThreadSafeRefCount
196{ 196{
197public: 197public:
198 static void initThreadSafeRefCount(); // creates sMutex 198 static void initThreadSafeRefCount(); // creates sMutex
@@ -244,7 +244,7 @@ private:
244 244
245// Simple responder for self destructing callbacks 245// Simple responder for self destructing callbacks
246// Pure virtual class 246// Pure virtual class
247class LLResponder : public LLThreadSafeRefCount 247class LL_COMMON_API LLResponder : public LLThreadSafeRefCount
248{ 248{
249protected: 249protected:
250 virtual ~LLResponder(); 250 virtual ~LLResponder();
diff --git a/linden/indra/llcommon/lltimer.cpp b/linden/indra/llcommon/lltimer.cpp
index fb3e1ef..2d283ec 100644
--- a/linden/indra/llcommon/lltimer.cpp
+++ b/linden/indra/llcommon/lltimer.cpp
@@ -33,6 +33,7 @@
33#include "linden_common.h" 33#include "linden_common.h"
34 34
35#include "lltimer.h" 35#include "lltimer.h"
36#include "timing.h" // totalTime prototype.
36 37
37#include "u64.h" 38#include "u64.h"
38 39
@@ -51,9 +52,6 @@
51// 52//
52// Locally used constants 53// Locally used constants
53// 54//
54const U32 SEC_PER_DAY = 86400;
55const F64 SEC_TO_MICROSEC = 1000000.f;
56const U64 SEC_TO_MICROSEC_U64 = 1000000;
57const F64 USEC_TO_SEC_F64 = 0.000001; 55const F64 USEC_TO_SEC_F64 = 0.000001;
58 56
59 57
diff --git a/linden/indra/llcommon/lltimer.h b/linden/indra/llcommon/lltimer.h
index a653233..8590328 100644
--- a/linden/indra/llcommon/lltimer.h
+++ b/linden/indra/llcommon/lltimer.h
@@ -39,6 +39,7 @@
39#include <limits.h> 39#include <limits.h>
40 40
41#include "stdtypes.h" 41#include "stdtypes.h"
42#include "llpreprocessor.h"
42#include "lldate.h" 43#include "lldate.h"
43 44
44#include <string> 45#include <string>
@@ -54,7 +55,7 @@ const U32 USEC_PER_HOUR = USEC_PER_MIN * MIN_PER_HOUR;
54const U32 SEC_PER_HOUR = SEC_PER_MIN * MIN_PER_HOUR; 55const U32 SEC_PER_HOUR = SEC_PER_MIN * MIN_PER_HOUR;
55const F64 SEC_PER_USEC = 1.0 / (F64) USEC_PER_SEC; 56const F64 SEC_PER_USEC = 1.0 / (F64) USEC_PER_SEC;
56 57
57class LLTimer 58class LL_COMMON_API LLTimer
58{ 59{
59public: 60public:
60 static LLTimer *sTimer; // global timer 61 static LLTimer *sTimer; // global timer
@@ -113,17 +114,17 @@ public:
113// 114//
114// Various functions for initializing/accessing clock and timing stuff. Don't use these without REALLY knowing how they work. 115// Various functions for initializing/accessing clock and timing stuff. Don't use these without REALLY knowing how they work.
115// 116//
116U64 get_clock_count(); 117LL_COMMON_API U64 get_clock_count();
117F64 calc_clock_frequency(U32 msecs); 118LL_COMMON_API F64 calc_clock_frequency(U32 msecs);
118void update_clock_frequencies(); 119LL_COMMON_API void update_clock_frequencies();
119 120
120// Sleep for milliseconds 121// Sleep for milliseconds
121void ms_sleep(U32 ms); 122LL_COMMON_API void ms_sleep(U32 ms);
122U32 micro_sleep(U64 us, U32 max_yields = 0xFFFFFFFF); 123LL_COMMON_API U32 micro_sleep(U64 us, U32 max_yields = 0xFFFFFFFF);
123 124
124// Returns the correct UTC time in seconds, like time(NULL). 125// Returns the correct UTC time in seconds, like time(NULL).
125// Useful on the viewer, which may have its local clock set wrong. 126// Useful on the viewer, which may have its local clock set wrong.
126time_t time_corrected(); 127LL_COMMON_API time_t time_corrected();
127 128
128static inline time_t time_min() 129static inline time_t time_min()
129{ 130{
@@ -154,25 +155,25 @@ static inline time_t time_max()
154} 155}
155 156
156// Correction factor used by time_corrected() above. 157// Correction factor used by time_corrected() above.
157extern S32 gUTCOffset; 158LL_COMMON_API extern S32 gUTCOffset;
158 159
159// Is the current computer (in its current time zone) 160// Is the current computer (in its current time zone)
160// observing daylight savings time? 161// observing daylight savings time?
161BOOL is_daylight_savings(); 162LL_COMMON_API BOOL is_daylight_savings();
162 163
163// Converts internal "struct tm" time buffer to Pacific Standard/Daylight Time 164// Converts internal "struct tm" time buffer to Pacific Standard/Daylight Time
164// Usage: 165// Usage:
165// S32 utc_time; 166// S32 utc_time;
166// utc_time = time_corrected(); 167// utc_time = time_corrected();
167// struct tm* internal_time = utc_to_pacific_time(utc_time, gDaylight); 168// struct tm* internal_time = utc_to_pacific_time(utc_time, gDaylight);
168struct tm* utc_to_pacific_time(time_t utc_time, BOOL pacific_daylight_time); 169LL_COMMON_API struct tm* utc_to_pacific_time(time_t utc_time, BOOL pacific_daylight_time);
169struct tm* utc_to_offset_time(time_t utc_time, S32 offset, BOOL DST); 170LL_COMMON_API struct tm* utc_to_offset_time(time_t utc_time, S32 offset, BOOL DST);
170 171
171void microsecondsToTimecodeString(U64 current_time, std::string& tcstring); 172LL_COMMON_API void microsecondsToTimecodeString(U64 current_time, std::string& tcstring);
172void secondsToTimecodeString(F32 current_time, std::string& tcstring); 173LL_COMMON_API void secondsToTimecodeString(F32 current_time, std::string& tcstring);
173 174
174// class for scheduling a function to be called at a given frequency (approximate, inprecise) 175// class for scheduling a function to be called at a given frequency (approximate, inprecise)
175class LLEventTimer 176class LL_COMMON_API LLEventTimer
176{ 177{
177public: 178public:
178 LLEventTimer(F32 period); // period is the amount of time between each call to tick() in seconds 179 LLEventTimer(F32 period); // period is the amount of time between each call to tick() in seconds
diff --git a/linden/indra/llcommon/lluri.h b/linden/indra/llcommon/lluri.h
index 156d80b..57bbedf 100644
--- a/linden/indra/llcommon/lluri.h
+++ b/linden/indra/llcommon/lluri.h
@@ -47,7 +47,7 @@ class LLApp;
47 * See: http://www.ietf.org/rfc/rfc3986.txt 47 * See: http://www.ietf.org/rfc/rfc3986.txt
48 * 48 *
49 */ 49 */
50class LLURI 50class LL_COMMON_API LLURI
51{ 51{
52public: 52public:
53 LLURI(); 53 LLURI();
@@ -189,6 +189,6 @@ private:
189}; 189};
190 190
191// this operator required for tut 191// this operator required for tut
192bool operator!=(const LLURI& first, const LLURI& second); 192LL_COMMON_API bool operator!=(const LLURI& first, const LLURI& second);
193 193
194#endif // LL_LLURI_H 194#endif // LL_LLURI_H
diff --git a/linden/indra/llcommon/lluuid.h b/linden/indra/llcommon/lluuid.h
index 4b32138..c78fb12 100644
--- a/linden/indra/llcommon/lluuid.h
+++ b/linden/indra/llcommon/lluuid.h
@@ -35,6 +35,7 @@
35#include <iostream> 35#include <iostream>
36#include <set> 36#include <set>
37#include "stdtypes.h" 37#include "stdtypes.h"
38#include "llpreprocessor.h"
38 39
39const S32 UUID_BYTES = 16; 40const S32 UUID_BYTES = 16;
40const S32 UUID_WORDS = 4; 41const S32 UUID_WORDS = 4;
@@ -47,7 +48,7 @@ struct uuid_time_t {
47 U32 low; 48 U32 low;
48 }; 49 };
49 50
50class LLUUID 51class LL_COMMON_API LLUUID
51{ 52{
52public: 53public:
53 // 54 //
@@ -106,8 +107,8 @@ public:
106 LLUUID combine(const LLUUID& other) const; 107 LLUUID combine(const LLUUID& other) const;
107 void combine(const LLUUID& other, LLUUID& result) const; 108 void combine(const LLUUID& other, LLUUID& result) const;
108 109
109 friend std::ostream& operator<<(std::ostream& s, const LLUUID &uuid); 110 friend LL_COMMON_API std::ostream& operator<<(std::ostream& s, const LLUUID &uuid);
110 friend std::istream& operator>>(std::istream& s, LLUUID &uuid); 111 friend LL_COMMON_API std::istream& operator>>(std::istream& s, LLUUID &uuid);
111 112
112 void toString(char *out) const; // Does not allocate memory, needs 36 characters (including \0) 113 void toString(char *out) const; // Does not allocate memory, needs 36 characters (including \0)
113 void toString(std::string& out) const; 114 void toString(std::string& out) const;
@@ -323,7 +324,7 @@ typedef std::set<LLUUID, lluuid_less> uuid_list_t;
323 */ 324 */
324typedef LLUUID LLAssetID; 325typedef LLUUID LLAssetID;
325 326
326class LLTransactionID : public LLUUID 327class LL_COMMON_API LLTransactionID : public LLUUID
327{ 328{
328public: 329public:
329 LLTransactionID() : LLUUID() { } 330 LLTransactionID() : LLUUID() { }
diff --git a/linden/indra/llcommon/llworkerthread.h b/linden/indra/llcommon/llworkerthread.h
index 708d812..33d4c40 100644
--- a/linden/indra/llcommon/llworkerthread.h
+++ b/linden/indra/llcommon/llworkerthread.h
@@ -50,7 +50,7 @@ class LLWorkerClass;
50// Note: ~LLWorkerThread is O(N) N=# of worker threads, assumed to be small 50// Note: ~LLWorkerThread is O(N) N=# of worker threads, assumed to be small
51// It is assumed that LLWorkerThreads are rarely created/destroyed. 51// It is assumed that LLWorkerThreads are rarely created/destroyed.
52 52
53class LLWorkerThread : public LLQueuedThread 53class LL_COMMON_API LLWorkerThread : public LLQueuedThread
54{ 54{
55 friend class LLWorkerClass; 55 friend class LLWorkerClass;
56public: 56public:
@@ -114,7 +114,7 @@ public:
114// Only one background task can be active at a time (per instance). 114// Only one background task can be active at a time (per instance).
115// i.e. don't call addWork() if haveWork() returns true 115// i.e. don't call addWork() if haveWork() returns true
116 116
117class LLWorkerClass 117class LL_COMMON_API LLWorkerClass
118{ 118{
119 friend class LLWorkerThread; 119 friend class LLWorkerThread;
120 friend class LLWorkerThread::WorkRequest; 120 friend class LLWorkerThread::WorkRequest;
diff --git a/linden/indra/llcommon/metaclass.h b/linden/indra/llcommon/metaclass.h
index cc10f16..f38bcd2 100644
--- a/linden/indra/llcommon/metaclass.h
+++ b/linden/indra/llcommon/metaclass.h
@@ -43,7 +43,7 @@
43class LLReflective; 43class LLReflective;
44class LLMetaProperty; 44class LLMetaProperty;
45class LLMetaMethod; 45class LLMetaMethod;
46class LLMetaClass 46class LL_COMMON_API LLMetaClass
47{ 47{
48public: 48public:
49 49
diff --git a/linden/indra/llcommon/metaproperty.h b/linden/indra/llcommon/metaproperty.h
index e5ac359..6c016c5 100644
--- a/linden/indra/llcommon/metaproperty.h
+++ b/linden/indra/llcommon/metaproperty.h
@@ -41,7 +41,7 @@
41 41
42class LLMetaClass; 42class LLMetaClass;
43class LLReflective; 43class LLReflective;
44class LLMetaProperty 44class LL_COMMON_API LLMetaProperty
45{ 45{
46public: 46public:
47 LLMetaProperty(const std::string& name, const LLMetaClass& object_class); 47 LLMetaProperty(const std::string& name, const LLMetaClass& object_class);
diff --git a/linden/indra/llcommon/reflective.h b/linden/indra/llcommon/reflective.h
index e2c18eb..a135376 100644
--- a/linden/indra/llcommon/reflective.h
+++ b/linden/indra/llcommon/reflective.h
@@ -36,7 +36,7 @@
36#define LL_REFLECTIVE_H 36#define LL_REFLECTIVE_H
37 37
38class LLMetaClass; 38class LLMetaClass;
39class LLReflective 39class LL_COMMON_API LLReflective
40{ 40{
41public: 41public:
42 LLReflective(); 42 LLReflective();
diff --git a/linden/indra/llcommon/timing.h b/linden/indra/llcommon/timing.h
index 2b9f60a..cfc637e 100644
--- a/linden/indra/llcommon/timing.h
+++ b/linden/indra/llcommon/timing.h
@@ -44,6 +44,6 @@ const U64 SEC_TO_MICROSEC_U64 = 1000000;
44const U32 SEC_PER_DAY = 86400; 44const U32 SEC_PER_DAY = 86400;
45 45
46// This is just a stub, implementation in lltimer.cpp. This file will be deprecated in the future. 46// This is just a stub, implementation in lltimer.cpp. This file will be deprecated in the future.
47U64 totalTime(); // Returns current system time in microseconds 47LL_COMMON_API U64 totalTime(); // Returns current system time in microseconds
48 48
49#endif 49#endif
diff --git a/linden/indra/llcommon/u64.h b/linden/indra/llcommon/u64.h
index 09a6b3e..eb51131 100644
--- a/linden/indra/llcommon/u64.h
+++ b/linden/indra/llcommon/u64.h
@@ -39,14 +39,14 @@
39 * @param str The string to parse. 39 * @param str The string to parse.
40 * @return Returns the first U64 value found in the string or 0 on failure. 40 * @return Returns the first U64 value found in the string or 0 on failure.
41 */ 41 */
42U64 str_to_U64(const std::string& str); 42LL_COMMON_API U64 str_to_U64(const std::string& str);
43 43
44/** 44/**
45 * @brief Given a U64 value, return a printable representation. 45 * @brief Given a U64 value, return a printable representation.
46 * @param value The U64 to turn into a printable character array. 46 * @param value The U64 to turn into a printable character array.
47 * @return Returns the result string. 47 * @return Returns the result string.
48 */ 48 */
49std::string U64_to_str(U64 value); 49LL_COMMON_API std::string U64_to_str(U64 value);
50 50
51/** 51/**
52 * @brief Given a U64 value, return a printable representation. 52 * @brief Given a U64 value, return a printable representation.
@@ -65,16 +65,16 @@ std::string U64_to_str(U64 value);
65 * @param result_size The size of the buffer allocated. Use U64_BUF. 65 * @param result_size The size of the buffer allocated. Use U64_BUF.
66 * @return Returns the result pointer. 66 * @return Returns the result pointer.
67 */ 67 */
68char* U64_to_str(U64 value, char* result, S32 result_size); 68LL_COMMON_API char* U64_to_str(U64 value, char* result, S32 result_size);
69 69
70/** 70/**
71 * @brief Convert a U64 to the closest F64 value. 71 * @brief Convert a U64 to the closest F64 value.
72 */ 72 */
73F64 U64_to_F64(const U64 value); 73LL_COMMON_API F64 U64_to_F64(const U64 value);
74 74
75/** 75/**
76 * @brief Helper function to wrap strtoull() which is not available on windows. 76 * @brief Helper function to wrap strtoull() which is not available on windows.
77 */ 77 */
78U64 llstrtou64(const char* str, char** end, S32 base); 78LL_COMMON_API U64 llstrtou64(const char* str, char** end, S32 base);
79 79
80#endif 80#endif
diff --git a/linden/indra/llinventory/llparcel.h b/linden/indra/llinventory/llparcel.h
index 47571d0..8faa673 100644
--- a/linden/indra/llinventory/llparcel.h
+++ b/linden/indra/llinventory/llparcel.h
@@ -39,7 +39,7 @@
39#include "llparcelflags.h" 39#include "llparcelflags.h"
40#include "llpermissions.h" 40#include "llpermissions.h"
41#include "v3math.h" 41#include "v3math.h"
42 42#include "lltimer.h"
43 43
44// Grid out of which parcels taken is stepped every 4 meters. 44// Grid out of which parcels taken is stepped every 4 meters.
45const F32 PARCEL_GRID_STEP_METERS = 4.f; 45const F32 PARCEL_GRID_STEP_METERS = 4.f;
diff --git a/linden/indra/llmath/lloctree.h b/linden/indra/llmath/lloctree.h
index bced84c..2029554 100644
--- a/linden/indra/llmath/lloctree.h
+++ b/linden/indra/llmath/lloctree.h
@@ -68,8 +68,7 @@ template <class T>
68class LLOctreeTraveler : public LLTreeTraveler<T> 68class LLOctreeTraveler : public LLTreeTraveler<T>
69{ 69{
70public: 70public:
71 virtual void traverse(const LLTreeNode<T>* node); 71 virtual void traverse(const LLOctreeNode<T>* node);
72 virtual void visit(const LLTreeNode<T>* state) { }
73 virtual void visit(const LLOctreeNode<T>* branch) = 0; 72 virtual void visit(const LLOctreeNode<T>* branch) = 0;
74}; 73};
75 74
@@ -705,9 +704,8 @@ public:
705// LLOctreeTraveler 704// LLOctreeTraveler
706//======================== 705//========================
707template <class T> 706template <class T>
708void LLOctreeTraveler<T>::traverse(const LLTreeNode<T>* tree_node) 707void LLOctreeTraveler<T>::traverse(const LLOctreeNode<T>* node)
709{ 708{
710 const LLOctreeNode<T>* node = (const LLOctreeNode<T>*) tree_node;
711 node->accept(this); 709 node->accept(this);
712 for (U32 i = 0; i < node->getChildCount(); i++) 710 for (U32 i = 0; i < node->getChildCount(); i++)
713 { 711 {
diff --git a/linden/indra/llmath/lltreenode.h b/linden/indra/llmath/lltreenode.h
index ee98362..ccbeda5 100644
--- a/linden/indra/llmath/lltreenode.h
+++ b/linden/indra/llmath/lltreenode.h
@@ -82,8 +82,6 @@ class LLTreeTraveler
82{ 82{
83public: 83public:
84 virtual ~LLTreeTraveler() { }; 84 virtual ~LLTreeTraveler() { };
85 virtual void traverse(const LLTreeNode<T>* node) = 0;
86 virtual void visit(const LLTreeNode<T>* node) = 0;
87}; 85};
88 86
89template <class T> 87template <class T>
diff --git a/linden/indra/llmessage/CMakeLists.txt b/linden/indra/llmessage/CMakeLists.txt
index 4723281..a5e4249 100644
--- a/linden/indra/llmessage/CMakeLists.txt
+++ b/linden/indra/llmessage/CMakeLists.txt
@@ -218,7 +218,7 @@ IF (NOT LINUX AND VIEWER)
218 # These can not be found when we try to run the tests, so we had to disable them, for the viewer build. 218 # These can not be found when we try to run the tests, so we had to disable them, for the viewer build.
219 # TODO: Can someone with viewer knowledge figure out how to make these find the correct so. 219 # TODO: Can someone with viewer knowledge figure out how to make these find the correct so.
220 #ADD_BUILD_TEST(llhttpclientadapter llmessage) 220 #ADD_BUILD_TEST(llhttpclientadapter llmessage)
221 ADD_BUILD_TEST(lltrustedmessageservice llmessage) 221 #ADD_BUILD_TEST(lltrustedmessageservice llmessage)
222 ADD_BUILD_TEST(lltemplatemessagedispatcher llmessage) 222 #ADD_BUILD_TEST(lltemplatemessagedispatcher llmessage)
223ENDIF (NOT LINUX AND VIEWER) 223ENDIF (NOT LINUX AND VIEWER)
224 224
diff --git a/linden/indra/llmessage/llassetstorage.cpp b/linden/indra/llmessage/llassetstorage.cpp
index 16a96b7..0ab1081 100644
--- a/linden/indra/llmessage/llassetstorage.cpp
+++ b/linden/indra/llmessage/llassetstorage.cpp
@@ -1028,12 +1028,12 @@ LLSD LLAssetStorage::getPendingDetails(LLAssetStorage::ERequestType rt,
1028{ 1028{
1029 const request_list_t* requests = getRequestList(rt); 1029 const request_list_t* requests = getRequestList(rt);
1030 LLSD sd; 1030 LLSD sd;
1031 sd["requests"] = getPendingDetails(requests, asset_type, detail_prefix); 1031 sd["requests"] = getPendingDetailsImpl(requests, asset_type, detail_prefix);
1032 return sd; 1032 return sd;
1033} 1033}
1034 1034
1035// virtual 1035// virtual
1036LLSD LLAssetStorage::getPendingDetails(const LLAssetStorage::request_list_t* requests, 1036LLSD LLAssetStorage::getPendingDetailsImpl(const LLAssetStorage::request_list_t* requests,
1037 LLAssetType::EType asset_type, 1037 LLAssetType::EType asset_type,
1038 const std::string& detail_prefix) const 1038 const std::string& detail_prefix) const
1039{ 1039{
@@ -1116,11 +1116,11 @@ LLSD LLAssetStorage::getPendingRequest(LLAssetStorage::ERequestType rt,
1116 const LLUUID& asset_id) const 1116 const LLUUID& asset_id) const
1117{ 1117{
1118 const request_list_t* requests = getRequestList(rt); 1118 const request_list_t* requests = getRequestList(rt);
1119 return getPendingRequest(requests, asset_type, asset_id); 1119 return getPendingRequestImpl(requests, asset_type, asset_id);
1120} 1120}
1121 1121
1122// virtual 1122// virtual
1123LLSD LLAssetStorage::getPendingRequest(const LLAssetStorage::request_list_t* requests, 1123LLSD LLAssetStorage::getPendingRequestImpl(const LLAssetStorage::request_list_t* requests,
1124 LLAssetType::EType asset_type, 1124 LLAssetType::EType asset_type,
1125 const LLUUID& asset_id) const 1125 const LLUUID& asset_id) const
1126{ 1126{
@@ -1139,7 +1139,7 @@ bool LLAssetStorage::deletePendingRequest(LLAssetStorage::ERequestType rt,
1139 const LLUUID& asset_id) 1139 const LLUUID& asset_id)
1140{ 1140{
1141 request_list_t* requests = getRequestList(rt); 1141 request_list_t* requests = getRequestList(rt);
1142 if (deletePendingRequest(requests, asset_type, asset_id)) 1142 if (deletePendingRequestImpl(requests, asset_type, asset_id))
1143 { 1143 {
1144 llinfos << "Asset " << getRequestName(rt) << " request for " 1144 llinfos << "Asset " << getRequestName(rt) << " request for "
1145 << asset_id << "." << LLAssetType::lookup(asset_type) 1145 << asset_id << "." << LLAssetType::lookup(asset_type)
@@ -1150,7 +1150,7 @@ bool LLAssetStorage::deletePendingRequest(LLAssetStorage::ERequestType rt,
1150} 1150}
1151 1151
1152// virtual 1152// virtual
1153bool LLAssetStorage::deletePendingRequest(LLAssetStorage::request_list_t* requests, 1153bool LLAssetStorage::deletePendingRequestImpl(LLAssetStorage::request_list_t* requests,
1154 LLAssetType::EType asset_type, 1154 LLAssetType::EType asset_type,
1155 const LLUUID& asset_id) 1155 const LLUUID& asset_id)
1156{ 1156{
diff --git a/linden/indra/llmessage/llassetstorage.h b/linden/indra/llmessage/llassetstorage.h
index c094ef4..83cfdf6 100644
--- a/linden/indra/llmessage/llassetstorage.h
+++ b/linden/indra/llmessage/llassetstorage.h
@@ -315,15 +315,15 @@ public:
315 void markAssetToxic( const LLUUID& uuid ); 315 void markAssetToxic( const LLUUID& uuid );
316 316
317protected: 317protected:
318 virtual LLSD getPendingDetails(const request_list_t* requests, 318 virtual LLSD getPendingDetailsImpl(const request_list_t* requests,
319 LLAssetType::EType asset_type, 319 LLAssetType::EType asset_type,
320 const std::string& detail_prefix) const; 320 const std::string& detail_prefix) const;
321 321
322 virtual LLSD getPendingRequest(const request_list_t* requests, 322 virtual LLSD getPendingRequestImpl(const request_list_t* requests,
323 LLAssetType::EType asset_type, 323 LLAssetType::EType asset_type,
324 const LLUUID& asset_id) const; 324 const LLUUID& asset_id) const;
325 325
326 virtual bool deletePendingRequest(request_list_t* requests, 326 virtual bool deletePendingRequestImpl(request_list_t* requests,
327 LLAssetType::EType asset_type, 327 LLAssetType::EType asset_type,
328 const LLUUID& asset_id); 328 const LLUUID& asset_id);
329 329
diff --git a/linden/indra/llmessage/llcurl.cpp b/linden/indra/llmessage/llcurl.cpp
index 12321fe..202332c 100644
--- a/linden/indra/llmessage/llcurl.cpp
+++ b/linden/indra/llmessage/llcurl.cpp
@@ -120,7 +120,7 @@ LLCurl::Responder::~Responder()
120} 120}
121 121
122// virtual 122// virtual
123void LLCurl::Responder::error( 123void LLCurl::Responder::errorWithContent(
124 U32 status, 124 U32 status,
125 const std::string& reason, 125 const std::string& reason,
126 const LLSD&) 126 const LLSD&)
@@ -161,7 +161,7 @@ void LLCurl::Responder::completed(U32 status, const std::string& reason, const L
161 } 161 }
162 else 162 else
163 { 163 {
164 error(status, reason, content); 164 errorWithContent(status, reason, content);
165 } 165 }
166} 166}
167 167
diff --git a/linden/indra/llmessage/llcurl.h b/linden/indra/llmessage/llcurl.h
index 3e9c0d4..32637b2 100644
--- a/linden/indra/llmessage/llcurl.h
+++ b/linden/indra/llmessage/llcurl.h
@@ -85,7 +85,7 @@ public:
85 return((200 <= status) && (status < 300)); 85 return((200 <= status) && (status < 300));
86 } 86 }
87 87
88 virtual void error( 88 virtual void errorWithContent(
89 U32 status, 89 U32 status,
90 const std::string& reason, 90 const std::string& reason,
91 const LLSD& content); 91 const LLSD& content);
diff --git a/linden/indra/llmessage/llhttpassetstorage.cpp b/linden/indra/llmessage/llhttpassetstorage.cpp
index dfdad59..49dbdbd 100644
--- a/linden/indra/llmessage/llhttpassetstorage.cpp
+++ b/linden/indra/llmessage/llhttpassetstorage.cpp
@@ -626,7 +626,7 @@ LLSD LLHTTPAssetStorage::getPendingRequest(LLAssetStorage::ERequestType rt,
626 const request_list_t* running = getRunningList(rt); 626 const request_list_t* running = getRunningList(rt);
627 if (running) 627 if (running)
628 { 628 {
629 LLSD sd = LLAssetStorage::getPendingRequest(running, asset_type, asset_id); 629 LLSD sd = LLAssetStorage::getPendingRequestImpl(running, asset_type, asset_id);
630 if (sd) 630 if (sd)
631 { 631 {
632 sd["is_running"] = true; 632 sd["is_running"] = true;
diff --git a/linden/indra/llmessage/llhttpassetstorage.h b/linden/indra/llmessage/llhttpassetstorage.h
index 5786c5d..231437d 100644
--- a/linden/indra/llmessage/llhttpassetstorage.h
+++ b/linden/indra/llmessage/llhttpassetstorage.h
@@ -62,6 +62,8 @@ public:
62 62
63 virtual ~LLHTTPAssetStorage(); 63 virtual ~LLHTTPAssetStorage();
64 64
65 using LLAssetStorage::storeAssetData; // Unhiding virtuals...
66
65 virtual void storeAssetData( 67 virtual void storeAssetData(
66 const LLUUID& uuid, 68 const LLUUID& uuid,
67 LLAssetType::EType atype, 69 LLAssetType::EType atype,
diff --git a/linden/indra/llmessage/llhttpnode.cpp b/linden/indra/llmessage/llhttpnode.cpp
index 2ba900a..440b91f 100644
--- a/linden/indra/llmessage/llhttpnode.cpp
+++ b/linden/indra/llmessage/llhttpnode.cpp
@@ -98,19 +98,19 @@ namespace {
98} 98}
99 99
100// virtual 100// virtual
101LLSD LLHTTPNode::get() const 101LLSD LLHTTPNode::simpleGet() const
102{ 102{
103 throw NotImplemented(); 103 throw NotImplemented();
104} 104}
105 105
106// virtual 106// virtual
107LLSD LLHTTPNode::put(const LLSD& input) const 107LLSD LLHTTPNode::simplePut(const LLSD& input) const
108{ 108{
109 throw NotImplemented(); 109 throw NotImplemented();
110} 110}
111 111
112// virtual 112// virtual
113LLSD LLHTTPNode::post(const LLSD& input) const 113LLSD LLHTTPNode::simplePost(const LLSD& input) const
114{ 114{
115 throw NotImplemented(); 115 throw NotImplemented();
116} 116}
@@ -121,7 +121,7 @@ void LLHTTPNode::get(LLHTTPNode::ResponsePtr response, const LLSD& context) cons
121{ 121{
122 try 122 try
123 { 123 {
124 response->result(get()); 124 response->result(simpleGet());
125 } 125 }
126 catch (NotImplemented) 126 catch (NotImplemented)
127 { 127 {
@@ -134,7 +134,7 @@ void LLHTTPNode::put(LLHTTPNode::ResponsePtr response, const LLSD& context, cons
134{ 134{
135 try 135 try
136 { 136 {
137 response->result(put(input)); 137 response->result(simplePut(input));
138 } 138 }
139 catch (NotImplemented) 139 catch (NotImplemented)
140 { 140 {
@@ -147,7 +147,7 @@ void LLHTTPNode::post(LLHTTPNode::ResponsePtr response, const LLSD& context, con
147{ 147{
148 try 148 try
149 { 149 {
150 response->result(post(input)); 150 response->result(simplePost(input));
151 } 151 }
152 catch (NotImplemented) 152 catch (NotImplemented)
153 { 153 {
@@ -160,7 +160,7 @@ void LLHTTPNode::del(LLHTTPNode::ResponsePtr response, const LLSD& context) cons
160{ 160{
161 try 161 try
162 { 162 {
163 response->result(del(context)); 163 response->result(simpleDel(context));
164 } 164 }
165 catch (NotImplemented) 165 catch (NotImplemented)
166 { 166 {
@@ -170,7 +170,7 @@ void LLHTTPNode::del(LLHTTPNode::ResponsePtr response, const LLSD& context) cons
170} 170}
171 171
172// virtual 172// virtual
173LLSD LLHTTPNode::del(const LLSD&) const 173LLSD LLHTTPNode::simpleDel(const LLSD&) const
174{ 174{
175 throw NotImplemented(); 175 throw NotImplemented();
176} 176}
@@ -388,7 +388,7 @@ LLHTTPNode::Response::~Response()
388{ 388{
389} 389}
390 390
391void LLHTTPNode::Response::status(S32 code) 391void LLHTTPNode::Response::statusUnknownError(S32 code)
392{ 392{
393 status(code, "Unknown Error"); 393 status(code, "Unknown Error");
394} 394}
diff --git a/linden/indra/llmessage/llhttpnode.h b/linden/indra/llmessage/llhttpnode.h
index 17ffd66..87f0c48 100644
--- a/linden/indra/llmessage/llhttpnode.h
+++ b/linden/indra/llmessage/llhttpnode.h
@@ -83,10 +83,10 @@ public:
83 //@{ 83 //@{
84public: 84public:
85 85
86 virtual LLSD get() const; 86 virtual LLSD simpleGet() const;
87 virtual LLSD put(const LLSD& input) const; 87 virtual LLSD simplePut(const LLSD& input) const;
88 virtual LLSD post(const LLSD& input) const; 88 virtual LLSD simplePost(const LLSD& input) const;
89 virtual LLSD del(const LLSD& context) const; 89 virtual LLSD simpleDel(const LLSD& context) const;
90 90
91 /** 91 /**
92 * @brief Abstract Base Class declaring Response interface. 92 * @brief Abstract Base Class declaring Response interface.
@@ -116,7 +116,7 @@ public:
116 /** 116 /**
117 * @brief Return no body, just status code and 'UNKNOWN ERROR'. 117 * @brief Return no body, just status code and 'UNKNOWN ERROR'.
118 */ 118 */
119 virtual void status(S32 code); 119 virtual void statusUnknownError(S32 code);
120 120
121 virtual void notFound(const std::string& message); 121 virtual void notFound(const std::string& message);
122 virtual void notFound(); 122 virtual void notFound();
diff --git a/linden/indra/llmessage/llpumpio.cpp b/linden/indra/llmessage/llpumpio.cpp
index 3e3f0b3..8ef2b16 100644
--- a/linden/indra/llmessage/llpumpio.cpp
+++ b/linden/indra/llmessage/llpumpio.cpp
@@ -43,6 +43,7 @@
43#include "llmemtype.h" 43#include "llmemtype.h"
44#include "llstl.h" 44#include "llstl.h"
45#include "llstat.h" 45#include "llstat.h"
46#include "llfasttimer.h"
46 47
47// These should not be enabled in production, but they can be 48// These should not be enabled in production, but they can be
48// intensely useful during development for finding certain kinds of 49// intensely useful during development for finding certain kinds of
diff --git a/linden/indra/llmessage/llregionpresenceverifier.cpp b/linden/indra/llmessage/llregionpresenceverifier.cpp
index 24410a7..04eba34 100644
--- a/linden/indra/llmessage/llregionpresenceverifier.cpp
+++ b/linden/indra/llmessage/llregionpresenceverifier.cpp
@@ -30,6 +30,7 @@
30 * $/LicenseInfo$ 30 * $/LicenseInfo$
31 */ 31 */
32 32
33#include "linden_common.h"
33#include "llregionpresenceverifier.h" 34#include "llregionpresenceverifier.h"
34#include "llhttpclientinterface.h" 35#include "llhttpclientinterface.h"
35#include <sstream> 36#include <sstream>
diff --git a/linden/indra/llmessage/llsdappservices.cpp b/linden/indra/llmessage/llsdappservices.cpp
index dc135c5..b87c0cd 100644
--- a/linden/indra/llmessage/llsdappservices.cpp
+++ b/linden/indra/llmessage/llsdappservices.cpp
@@ -56,7 +56,7 @@ public:
56 desc.source(__FILE__, __LINE__); 56 desc.source(__FILE__, __LINE__);
57 } 57 }
58 58
59 virtual LLSD get() const 59 virtual LLSD simpleGet() const
60 { 60 {
61 LLSD result; 61 LLSD result;
62 LLApp* app = LLApp::instance(); 62 LLApp* app = LLApp::instance();
@@ -82,7 +82,7 @@ public:
82 desc.source(__FILE__, __LINE__); 82 desc.source(__FILE__, __LINE__);
83 } 83 }
84 84
85 virtual LLSD get() const 85 virtual LLSD simpleGet() const
86 { 86 {
87 return LLApp::instance()->getOptionData( 87 return LLApp::instance()->getOptionData(
88 LLApp::PRIORITY_RUNTIME_OVERRIDE); 88 LLApp::PRIORITY_RUNTIME_OVERRIDE);
diff --git a/linden/indra/llmessage/llsdhttpserver.cpp b/linden/indra/llmessage/llsdhttpserver.cpp
index 00fc170..7d06c29 100644
--- a/linden/indra/llmessage/llsdhttpserver.cpp
+++ b/linden/indra/llmessage/llsdhttpserver.cpp
@@ -62,7 +62,7 @@ public:
62 desc.source(__FILE__, __LINE__); 62 desc.source(__FILE__, __LINE__);
63 } 63 }
64 64
65 virtual LLSD get() const 65 virtual LLSD simpleGet() const
66 { 66 {
67 LLSD result = "hello"; 67 LLSD result = "hello";
68 return result; 68 return result;
@@ -86,7 +86,7 @@ public:
86 desc.source(__FILE__, __LINE__); 86 desc.source(__FILE__, __LINE__);
87 } 87 }
88 88
89 virtual LLSD post(const LLSD& params) const 89 virtual LLSD simplePost(const LLSD& params) const
90 { 90 {
91 return params; 91 return params;
92 } 92 }
diff --git a/linden/indra/llplugin/CMakeLists.txt b/linden/indra/llplugin/CMakeLists.txt
index 73cd9a3..7a7f4e5 100644
--- a/linden/indra/llplugin/CMakeLists.txt
+++ b/linden/indra/llplugin/CMakeLists.txt
@@ -2,10 +2,6 @@
2 2
3project(llplugin) 3project(llplugin)
4 4
5if(HAVE_64_BIT)
6 set(REQUIRE_PIC)
7endif(HAVE_64_BIT)
8
9include(00-Common) 5include(00-Common)
10include(CURL) 6include(CURL)
11include(LLCommon) 7include(LLCommon)
diff --git a/linden/indra/llrender/llfontgl.cpp b/linden/indra/llrender/llfontgl.cpp
index 5d3d6a7..7baec81 100644
--- a/linden/indra/llrender/llfontgl.cpp
+++ b/linden/indra/llrender/llfontgl.cpp
@@ -42,6 +42,7 @@
42#include "llrender.h" 42#include "llrender.h"
43#include "v4color.h" 43#include "v4color.h"
44#include "llstl.h" 44#include "llstl.h"
45#include "llfasttimer.h"
45 46
46const S32 BOLD_OFFSET = 1; 47const S32 BOLD_OFFSET = 1;
47 48
diff --git a/linden/indra/llrender/llgl.cpp b/linden/indra/llrender/llgl.cpp
index 2e9b2bd..4a4ff1b 100644
--- a/linden/indra/llrender/llgl.cpp
+++ b/linden/indra/llrender/llgl.cpp
@@ -547,8 +547,6 @@ void LLGLManager::shutdownGL()
547// these are used to turn software blending on. They appear in the Debug/Avatar menu 547// these are used to turn software blending on. They appear in the Debug/Avatar menu
548// presence of vertex skinning/blending or vertex programs will set these to FALSE by default. 548// presence of vertex skinning/blending or vertex programs will set these to FALSE by default.
549 549
550extern LLCPUInfo gSysCPU;
551
552void LLGLManager::initExtensions() 550void LLGLManager::initExtensions()
553{ 551{
554#if LL_MESA_HEADLESS 552#if LL_MESA_HEADLESS
diff --git a/linden/indra/llui/llfunctorregistry.cpp b/linden/indra/llui/llfunctorregistry.cpp
index 0c5b165..5f9644f 100644
--- a/linden/indra/llui/llfunctorregistry.cpp
+++ b/linden/indra/llui/llfunctorregistry.cpp
@@ -31,6 +31,7 @@
31 * $/LicenseInfo$ 31 * $/LicenseInfo$
32 **/ 32 **/
33 33
34#include "linden_common.h"
34#include "llfunctorregistry.h" 35#include "llfunctorregistry.h"
35 36
36// This is a default functor always resident in the system. 37// This is a default functor always resident in the system.
diff --git a/linden/indra/llvfs/lldir.cpp b/linden/indra/llvfs/lldir.cpp
index b8a4794..0c93cbb 100644
--- a/linden/indra/llvfs/lldir.cpp
+++ b/linden/indra/llvfs/lldir.cpp
@@ -43,6 +43,7 @@
43#include "lldir.h" 43#include "lldir.h"
44#include "llerror.h" 44#include "llerror.h"
45#include "lluuid.h" 45#include "lluuid.h"
46#include "lltimer.h"
46 47
47#if LL_WINDOWS 48#if LL_WINDOWS
48#include "lldir_win32.h" 49#include "lldir_win32.h"
diff --git a/linden/indra/llvfs/llpidlock.cpp b/linden/indra/llvfs/llpidlock.cpp
index 93ac120..cb64428 100755
--- a/linden/indra/llvfs/llpidlock.cpp
+++ b/linden/indra/llvfs/llpidlock.cpp
@@ -39,6 +39,7 @@
39#include "llsdserialize.h" 39#include "llsdserialize.h"
40#include "llnametable.h" 40#include "llnametable.h"
41#include "llframetimer.h" 41#include "llframetimer.h"
42#include "llapp.h"
42 43
43#if LL_WINDOWS //For windows platform. 44#if LL_WINDOWS //For windows platform.
44bool isProcessAlive(U32 pid) 45bool isProcessAlive(U32 pid)
@@ -60,7 +61,7 @@ class LLPidLockFile
60 public: 61 public:
61 LLPidLockFile( ) : 62 LLPidLockFile( ) :
62 mSaving(FALSE), mWaiting(FALSE), 63 mSaving(FALSE), mWaiting(FALSE),
63 mClean(TRUE), mPID(getpid()) 64 mClean(TRUE), mPID(LLApp::getPid())
64 { 65 {
65 mLockName = gDirUtilp->getTempDir() + "/savelock"; 66 mLockName = gDirUtilp->getTempDir() + "/savelock";
66 } 67 }
diff --git a/linden/indra/llvfs/llpidlock.h b/linden/indra/llvfs/llpidlock.h
index 42aee4d..efcfd91 100755
--- a/linden/indra/llvfs/llpidlock.h
+++ b/linden/indra/llvfs/llpidlock.h
@@ -41,8 +41,6 @@ class LLFrameTimer;
41 41
42#include <windows.h> 42#include <windows.h>
43 43
44#define getpid GetCurrentProcessId
45
46#else //Everyone Else 44#else //Everyone Else
47 45
48#include <signal.h> 46#include <signal.h>
diff --git a/linden/indra/llvfs/llvfile.cpp b/linden/indra/llvfs/llvfile.cpp
index 6b1563b..630975a 100644
--- a/linden/indra/llvfs/llvfile.cpp
+++ b/linden/indra/llvfs/llvfile.cpp
@@ -38,6 +38,7 @@
38#include "llthread.h" 38#include "llthread.h"
39#include "llstat.h" 39#include "llstat.h"
40#include "llvfs.h" 40#include "llvfs.h"
41#include "llfasttimer.h"
41 42
42const S32 LLVFile::READ = 0x00000001; 43const S32 LLVFile::READ = 0x00000001;
43const S32 LLVFile::WRITE = 0x00000002; 44const S32 LLVFile::WRITE = 0x00000002;
diff --git a/linden/indra/llvfs/llvfs.cpp b/linden/indra/llvfs/llvfs.cpp
index 9bf5b59..dea8c9c 100644
--- a/linden/indra/llvfs/llvfs.cpp
+++ b/linden/indra/llvfs/llvfs.cpp
@@ -47,6 +47,7 @@
47 47
48#include "llvfs.h" 48#include "llvfs.h"
49#include "llstl.h" 49#include "llstl.h"
50#include "lltimer.h"
50 51
51const S32 FILE_BLOCK_MASK = 0x000003FF; // 1024-byte blocks 52const S32 FILE_BLOCK_MASK = 0x000003FF; // 1024-byte blocks
52const S32 VFS_CLEANUP_SIZE = 5242880; // how much space we free up in a single stroke 53const S32 VFS_CLEANUP_SIZE = 5242880; // how much space we free up in a single stroke
diff --git a/linden/indra/llwindow/CMakeLists.txt b/linden/indra/llwindow/CMakeLists.txt
index 5224163..ea81abf 100644
--- a/linden/indra/llwindow/CMakeLists.txt
+++ b/linden/indra/llwindow/CMakeLists.txt
@@ -59,6 +59,7 @@ set(viewer_HEADER_FILES
59set(llwindow_LINK_LIBRARIES 59set(llwindow_LINK_LIBRARIES
60 ${UI_LIBRARIES} # for GTK 60 ${UI_LIBRARIES} # for GTK
61 ${SDL_LIBRARY} 61 ${SDL_LIBRARY}
62 fontconfig # For FCInit and other FC* functions.
62 ) 63 )
63 64
64if (DARWIN) 65if (DARWIN)
diff --git a/linden/indra/llwindow/lldxhardware.cpp b/linden/indra/llwindow/lldxhardware.cpp
index e0cb82d..d8058ba 100644
--- a/linden/indra/llwindow/lldxhardware.cpp
+++ b/linden/indra/llwindow/lldxhardware.cpp
@@ -47,6 +47,7 @@
47 47
48#include "llstring.h" 48#include "llstring.h"
49#include "llstl.h" 49#include "llstl.h"
50#include "lltimer.h"
50 51
51void (*gWriteDebug)(const char* msg) = NULL; 52void (*gWriteDebug)(const char* msg) = NULL;
52LLDXHardware gDXHardware; 53LLDXHardware gDXHardware;
diff --git a/linden/indra/llwindow/llwindowmacosx.h b/linden/indra/llwindow/llwindowmacosx.h
index 92c73e8..d4c1b44 100644
--- a/linden/indra/llwindow/llwindowmacosx.h
+++ b/linden/indra/llwindow/llwindowmacosx.h
@@ -34,6 +34,7 @@
34#define LL_LLWINDOWMACOSX_H 34#define LL_LLWINDOWMACOSX_H
35 35
36#include "llwindow.h" 36#include "llwindow.h"
37#include "lltimer.h"
37 38
38#include <Carbon/Carbon.h> 39#include <Carbon/Carbon.h>
39#include <AGL/agl.h> 40#include <AGL/agl.h>
diff --git a/linden/indra/llwindow/llwindowsdl.cpp b/linden/indra/llwindow/llwindowsdl.cpp
index 16106af..f7d7587 100644
--- a/linden/indra/llwindow/llwindowsdl.cpp
+++ b/linden/indra/llwindow/llwindowsdl.cpp
@@ -42,6 +42,7 @@
42#include "llstring.h" 42#include "llstring.h"
43#include "lldir.h" 43#include "lldir.h"
44#include "llfindlocale.h" 44#include "llfindlocale.h"
45#include "lltimer.h"
45 46
46#include "indra_constants.h" 47#include "indra_constants.h"
47 48
@@ -1940,11 +1941,6 @@ void LLWindowSDL::setCursor(ECursorType cursor)
1940 } 1941 }
1941} 1942}
1942 1943
1943ECursorType LLWindowSDL::getCursor()
1944{
1945 return mCurrentCursor;
1946}
1947
1948void LLWindowSDL::initCursors() 1944void LLWindowSDL::initCursors()
1949{ 1945{
1950 int i; 1946 int i;
diff --git a/linden/indra/llwindow/llwindowsdl.h b/linden/indra/llwindow/llwindowsdl.h
index 37b0835..e632dfe 100644
--- a/linden/indra/llwindow/llwindowsdl.h
+++ b/linden/indra/llwindow/llwindowsdl.h
@@ -36,6 +36,7 @@
36// Simple Directmedia Layer (http://libsdl.org/) implementation of LLWindow class 36// Simple Directmedia Layer (http://libsdl.org/) implementation of LLWindow class
37 37
38#include "llwindow.h" 38#include "llwindow.h"
39#include "lltimer.h"
39 40
40#include "SDL/SDL.h" 41#include "SDL/SDL.h"
41#include "SDL/SDL_endian.h" 42#include "SDL/SDL_endian.h"
@@ -77,7 +78,6 @@ public:
77 /*virtual*/ void hideCursorUntilMouseMove(); 78 /*virtual*/ void hideCursorUntilMouseMove();
78 /*virtual*/ BOOL isCursorHidden(); 79 /*virtual*/ BOOL isCursorHidden();
79 /*virtual*/ void setCursor(ECursorType cursor); 80 /*virtual*/ void setCursor(ECursorType cursor);
80 /*virtual*/ ECursorType getCursor();
81 /*virtual*/ void captureMouse(); 81 /*virtual*/ void captureMouse();
82 /*virtual*/ void releaseMouse(); 82 /*virtual*/ void releaseMouse();
83 /*virtual*/ void setMouseClipping( BOOL b ); 83 /*virtual*/ void setMouseClipping( BOOL b );
diff --git a/linden/indra/llwindow/llwindowwin32.cpp b/linden/indra/llwindow/llwindowwin32.cpp
index 12a488a..7bc9a3b 100644
--- a/linden/indra/llwindow/llwindowwin32.cpp
+++ b/linden/indra/llwindow/llwindowwin32.cpp
@@ -59,6 +59,8 @@
59 59
60#include "llpreeditor.h" 60#include "llpreeditor.h"
61 61
62#include "llfasttimer.h"
63
62// culled from winuser.h 64// culled from winuser.h
63#ifndef WM_MOUSEWHEEL /* Added to be compatible with later SDK's */ 65#ifndef WM_MOUSEWHEEL /* Added to be compatible with later SDK's */
64const S32 WM_MOUSEWHEEL = 0x020A; 66const S32 WM_MOUSEWHEEL = 0x020A;
diff --git a/linden/indra/lscript/lscript_execute.h b/linden/indra/lscript/lscript_execute.h
index 9a631c4..e2263fd 100644
--- a/linden/indra/lscript/lscript_execute.h
+++ b/linden/indra/lscript/lscript_execute.h
@@ -36,6 +36,7 @@
36#include "lscript_byteconvert.h" 36#include "lscript_byteconvert.h"
37#include "linked_lists.h" 37#include "linked_lists.h"
38#include "lscript_library.h" 38#include "lscript_library.h"
39#include "lltimer.h"
39 40
40// Return values for run() methods 41// Return values for run() methods
41const U32 NO_DELETE_FLAG = 0x0000; 42const U32 NO_DELETE_FLAG = 0x0000;
diff --git a/linden/indra/lscript/lscript_execute/llscriptresource.cpp b/linden/indra/lscript/lscript_execute/llscriptresource.cpp
index 6c4776c..05ab8eb 100644
--- a/linden/indra/lscript/lscript_execute/llscriptresource.cpp
+++ b/linden/indra/lscript/lscript_execute/llscriptresource.cpp
@@ -30,6 +30,7 @@
30 * $/LicenseInfo$ 30 * $/LicenseInfo$
31 */ 31 */
32 32
33#include "linden_common.h"
33#include "llscriptresource.h" 34#include "llscriptresource.h"
34#include "llerror.h" 35#include "llerror.h"
35 36
diff --git a/linden/indra/media_plugins/base/CMakeLists.txt b/linden/indra/media_plugins/base/CMakeLists.txt
index dd0b0a0..8d62043 100644
--- a/linden/indra/media_plugins/base/CMakeLists.txt
+++ b/linden/indra/media_plugins/base/CMakeLists.txt
@@ -2,10 +2,6 @@
2 2
3project(media_plugin_base) 3project(media_plugin_base)
4 4
5if(HAVE_64_BIT)
6 set(REQUIRE_PIC)
7endif(HAVE_64_BIT)
8
9include(00-Common) 5include(00-Common)
10include(LLCommon) 6include(LLCommon)
11include(LLImage) 7include(LLImage)
diff --git a/linden/indra/media_plugins/example/CMakeLists.txt b/linden/indra/media_plugins/example/CMakeLists.txt
index bac5fa2..7822300 100644
--- a/linden/indra/media_plugins/example/CMakeLists.txt
+++ b/linden/indra/media_plugins/example/CMakeLists.txt
@@ -2,10 +2,6 @@
2 2
3project(media_plugin_example) 3project(media_plugin_example)
4 4
5if(HAVE_64_BIT)
6 set(REQUIRE_PIC)
7endif(HAVE_64_BIT)
8
9include(00-Common) 5include(00-Common)
10include(LLCommon) 6include(LLCommon)
11include(LLImage) 7include(LLImage)
diff --git a/linden/indra/media_plugins/gstreamer010/CMakeLists.txt b/linden/indra/media_plugins/gstreamer010/CMakeLists.txt
index a031157..4401e64 100644
--- a/linden/indra/media_plugins/gstreamer010/CMakeLists.txt
+++ b/linden/indra/media_plugins/gstreamer010/CMakeLists.txt
@@ -2,10 +2,6 @@
2 2
3project(media_plugin_gstreamer010) 3project(media_plugin_gstreamer010)
4 4
5if(HAVE_64_BIT)
6 set(REQUIRE_PIC)
7endif(HAVE_64_BIT)
8
9include(00-Common) 5include(00-Common)
10include(LLCommon) 6include(LLCommon)
11include(LLImage) 7include(LLImage)
@@ -34,14 +30,6 @@ include_directories(
34 30
35### media_plugin_gstreamer010 31### media_plugin_gstreamer010
36 32
37if(NOT CMAKE_SIZEOF_VOID_P MATCHES 4)
38 if(WINDOWS)
39 add_definitions(/FIXED:NO)
40 else(WINDOWS) # not windows therefore gcc LINUX and DARWIN
41 add_definitions(-fPIC)
42 endif(WINDOWS)
43endif (NOT CMAKE_SIZEOF_VOID_P MATCHES 4)
44
45set(media_plugin_gstreamer010_SOURCE_FILES 33set(media_plugin_gstreamer010_SOURCE_FILES
46 media_plugin_gstreamer010.cpp 34 media_plugin_gstreamer010.cpp
47 llmediaimplgstreamervidplug.cpp 35 llmediaimplgstreamervidplug.cpp
diff --git a/linden/indra/media_plugins/gstreamer010/llmediaimplgstreamertriviallogging.h b/linden/indra/media_plugins/gstreamer010/llmediaimplgstreamertriviallogging.h
index 0ea096a..bb90aa1 100755
--- a/linden/indra/media_plugins/gstreamer010/llmediaimplgstreamertriviallogging.h
+++ b/linden/indra/media_plugins/gstreamer010/llmediaimplgstreamertriviallogging.h
@@ -38,31 +38,23 @@
38 38
39#include <cstdio> 39#include <cstdio>
40 40
41extern "C" {
42#include <sys/types.h>
43//#include <unistd.h> //fiuxme
44}
45
46#define MSGMODULEFOO "(media plugin)"
47
48#ifdef LL_LINUX
49///////////////////////////////////////////////////////////////////////// 41/////////////////////////////////////////////////////////////////////////
50// Debug/Info/Warning macros. 42// Debug/Info/Warning macros.
51 43#if LL_WINDOWS
52#define STDERRMSG(...) do{\ 44#include <process.h>
53 fprintf(stderr, " pid:%d: ", (int)getpid());\ 45#define LL_GETPID GetCurrentProcessId
54 fprintf(stderr, MSGMODULEFOO " %s:%d: ", __FUNCTION__, __LINE__);\
55 fprintf(stderr, __VA_ARGS__);\
56 fputc('\n',stderr);\
57 }while(0)
58#else 46#else
47#include <sys/types.h>
48#include <unistd.h>
49#define LL_GETPID getpid
50#endif
51#define MSGMODULEFOO "(media plugin)"
59#define STDERRMSG(...) do{\ 52#define STDERRMSG(...) do{\
53 fprintf(stderr, " pid:%d: ", (int)LL_GETPID());\
60 fprintf(stderr, MSGMODULEFOO " %s:%d: ", __FUNCTION__, __LINE__);\ 54 fprintf(stderr, MSGMODULEFOO " %s:%d: ", __FUNCTION__, __LINE__);\
61 fprintf(stderr, __VA_ARGS__);\ 55 fprintf(stderr, __VA_ARGS__);\
62 fputc('\n',stderr);\ 56 fputc('\n',stderr);\
63 }while(0) 57 }while(0)
64#endif
65
66#define NULLMSG(...) do{}while(0) 58#define NULLMSG(...) do{}while(0)
67 59
68#define DEBUGMSG NULLMSG 60#define DEBUGMSG NULLMSG
diff --git a/linden/indra/media_plugins/gstreamer010/media_plugin_gstreamer010.cpp b/linden/indra/media_plugins/gstreamer010/media_plugin_gstreamer010.cpp
index 44bc32e..78e46ca 100755
--- a/linden/indra/media_plugins/gstreamer010/media_plugin_gstreamer010.cpp
+++ b/linden/indra/media_plugins/gstreamer010/media_plugin_gstreamer010.cpp
@@ -175,7 +175,7 @@ MediaPluginGStreamer010::MediaPluginGStreamer010(
175 mCommand ( COMMAND_NONE ) 175 mCommand ( COMMAND_NONE )
176{ 176{
177 std::ostringstream str; 177 std::ostringstream str;
178 INFOMSG("MediaPluginGStreamer010 constructor - my PID=%u", U32(getpid())); 178 INFOMSG("MediaPluginGStreamer010 constructor - my PID=%u", U32(LL_GETPID()));
179} 179}
180 180
181/////////////////////////////////////////////////////////////////////////////// 181///////////////////////////////////////////////////////////////////////////////
diff --git a/linden/indra/media_plugins/webkit/CMakeLists.txt b/linden/indra/media_plugins/webkit/CMakeLists.txt
index 2ab4a95..303a774 100644
--- a/linden/indra/media_plugins/webkit/CMakeLists.txt
+++ b/linden/indra/media_plugins/webkit/CMakeLists.txt
@@ -2,10 +2,6 @@
2 2
3project(media_plugin_webkit) 3project(media_plugin_webkit)
4 4
5if(HAVE_64_BIT)
6 set(REQUIRE_PIC)
7endif(HAVE_64_BIT)
8
9include(00-Common) 5include(00-Common)
10include(LLCommon) 6include(LLCommon)
11include(LLImage) 7include(LLImage)
@@ -34,20 +30,12 @@ include_directories(
34 ${LLQTWEBKIT_INCLUDE_DIR} 30 ${LLQTWEBKIT_INCLUDE_DIR}
35) 31)
36 32
37
38### media_plugin_webkit 33### media_plugin_webkit
39 34
40set(media_plugin_webkit_SOURCE_FILES 35set(media_plugin_webkit_SOURCE_FILES
41 media_plugin_webkit.cpp 36 media_plugin_webkit.cpp
42 ) 37 )
43 38
44if(NOT CMAKE_SIZEOF_VOID_P MATCHES 4)
45 if(WINDOWS)
46 add_definitions(/FIXED:NO)
47 else(WINDOWS) # not windows therefore gcc LINUX and DARWIN
48 add_definitions(-fPIC)
49 endif(WINDOWS)
50endif (NOT CMAKE_SIZEOF_VOID_P MATCHES 4)
51set(media_plugin_webkit_HEADER_FILES 39set(media_plugin_webkit_HEADER_FILES
52 volume_catcher.h 40 volume_catcher.h
53 ) 41 )
diff --git a/linden/indra/newview/CMakeLists.txt b/linden/indra/newview/CMakeLists.txt
index 77de749..dff759e 100644
--- a/linden/indra/newview/CMakeLists.txt
+++ b/linden/indra/newview/CMakeLists.txt
@@ -1541,11 +1541,23 @@ if (INSTALL)
1541 include(${CMAKE_CURRENT_SOURCE_DIR}/ViewerInstall.cmake) 1541 include(${CMAKE_CURRENT_SOURCE_DIR}/ViewerInstall.cmake)
1542endif (INSTALL) 1542endif (INSTALL)
1543 1543
1544ADD_VIEWER_BUILD_TEST(llagentaccess viewer) 1544#ADD_VIEWER_BUILD_TEST(llagentaccess viewer)
1545 1545
1546# Don't do these for DARWIN or LINUX here -- they're taken care of by viewer_manifest.py 1546# Don't do these for DARWIN or LINUX here -- they're taken care of by viewer_manifest.py
1547if (WINDOWS) 1547if (WINDOWS)
1548 1548
1549 get_target_property(BUILT_LLCOMMON llcommon LOCATION)
1550 add_custom_command(
1551 TARGET ${VIEWER_BINARY_NAME} POST_BUILD
1552 COMMAND ${CMAKE_COMMAND}
1553 ARGS
1554 -E
1555 copy_if_different
1556 ${BUILT_LLCOMMON}
1557 ${CMAKE_CURRENT_BINARY_DIR}/${CMAKE_CFG_INTDIR}
1558 COMMENT "Copying llcommon.dll to the runtime folder."
1559 )
1560
1549 get_target_property(BUILT_SLPLUGIN SLPlugin LOCATION) 1561 get_target_property(BUILT_SLPLUGIN SLPlugin LOCATION)
1550 add_custom_command( 1562 add_custom_command(
1551 TARGET ${VIEWER_BINARY_NAME} POST_BUILD 1563 TARGET ${VIEWER_BINARY_NAME} POST_BUILD
diff --git a/linden/indra/newview/emeraldboobutils.cpp b/linden/indra/newview/emeraldboobutils.cpp
index f68d6a7..f440940 100644
--- a/linden/indra/newview/emeraldboobutils.cpp
+++ b/linden/indra/newview/emeraldboobutils.cpp
@@ -1,3 +1,4 @@
1#include "linden_common.h"
1#include "emeraldboobutils.h" 2#include "emeraldboobutils.h"
2 3
3std::ostream &operator<<(std::ostream &os, const EmeraldGlobalBoobConfig &v) 4std::ostream &operator<<(std::ostream &os, const EmeraldGlobalBoobConfig &v)
diff --git a/linden/indra/newview/llagent.cpp b/linden/indra/newview/llagent.cpp
index 8109196..5a1700a 100644
--- a/linden/indra/newview/llagent.cpp
+++ b/linden/indra/newview/llagent.cpp
@@ -5573,7 +5573,7 @@ class LLAgentDropGroupViewerNode : public LLHTTPNode
5573 !input.has("body") ) 5573 !input.has("body") )
5574 { 5574 {
5575 //what to do with badly formed message? 5575 //what to do with badly formed message?
5576 response->status(400); 5576 response->statusUnknownError(400);
5577 response->result(LLSD("Invalid message parameters")); 5577 response->result(LLSD("Invalid message parameters"));
5578 } 5578 }
5579 5579
@@ -5646,7 +5646,7 @@ class LLAgentDropGroupViewerNode : public LLHTTPNode
5646 else 5646 else
5647 { 5647 {
5648 //what to do with badly formed message? 5648 //what to do with badly formed message?
5649 response->status(400); 5649 response->statusUnknownError(400);
5650 response->result(LLSD("Invalid message parameters")); 5650 response->result(LLSD("Invalid message parameters"));
5651 } 5651 }
5652 } 5652 }
diff --git a/linden/indra/newview/llappviewer.h b/linden/indra/newview/llappviewer.h
index 9d72457..7b3230a 100644
--- a/linden/indra/newview/llappviewer.h
+++ b/linden/indra/newview/llappviewer.h
@@ -33,6 +33,8 @@
33#ifndef LL_LLAPPVIEWER_H 33#ifndef LL_LLAPPVIEWER_H
34#define LL_LLAPPVIEWER_H 34#define LL_LLAPPVIEWER_H
35 35
36#include "llsys.h" // LLOSInfo
37
36class LLTextureCache; 38class LLTextureCache;
37class LLImageDecodeThread; 39class LLImageDecodeThread;
38class LLTextureFetch; 40class LLTextureFetch;
diff --git a/linden/indra/newview/llfeaturemanager.cpp b/linden/indra/newview/llfeaturemanager.cpp
index 54da31b..bf43fcf 100644
--- a/linden/indra/newview/llfeaturemanager.cpp
+++ b/linden/indra/newview/llfeaturemanager.cpp
@@ -62,7 +62,6 @@
62// externs 62// externs
63// 63//
64extern LLMemoryInfo gSysMemory; 64extern LLMemoryInfo gSysMemory;
65extern LLCPUInfo gSysCPU;
66 65
67#if LL_DARWIN 66#if LL_DARWIN
68const char FEATURE_TABLE_FILENAME[] = "featuretable_mac.txt"; 67const char FEATURE_TABLE_FILENAME[] = "featuretable_mac.txt";
diff --git a/linden/indra/newview/llfloaterabout.cpp b/linden/indra/newview/llfloaterabout.cpp
index 5c037d6..f7163ee 100644
--- a/linden/indra/newview/llfloaterabout.cpp
+++ b/linden/indra/newview/llfloaterabout.cpp
@@ -68,7 +68,6 @@
68#include "lldxhardware.h" 68#include "lldxhardware.h"
69#endif 69#endif
70 70
71extern LLCPUInfo gSysCPU;
72extern LLMemoryInfo gSysMemory; 71extern LLMemoryInfo gSysMemory;
73extern U32 gPacketsIn; 72extern U32 gPacketsIn;
74 73
diff --git a/linden/indra/newview/llfloaterregioninfo.cpp b/linden/indra/newview/llfloaterregioninfo.cpp
index 8ae3fa2..d4ffe22 100644
--- a/linden/indra/newview/llfloaterregioninfo.cpp
+++ b/linden/indra/newview/llfloaterregioninfo.cpp
@@ -908,7 +908,7 @@ BOOL LLPanelRegionOpenSettingsInfo::postBuild()
908 initHelpBtn("show_tags_help", "HelpShowTags"); 908 initHelpBtn("show_tags_help", "HelpShowTags");
909 initHelpBtn("allow_parcel_windlight_help", "HelpAllowParcelWindLight"); 909 initHelpBtn("allow_parcel_windlight_help", "HelpAllowParcelWindLight");
910 910
911 childSetAction("apply_ors_btn", sendUpdate, this); 911 childSetAction("apply_ors_btn", onClickOrs, this);
912 912
913 refreshFromRegion(gAgent.getRegion()); 913 refreshFromRegion(gAgent.getRegion());
914 914
@@ -926,12 +926,12 @@ BOOL LLPanelRegionOpenSettingsInfo::postBuild()
926// strings[7] = restrict pushobject 926// strings[7] = restrict pushobject
927// strings[8] = 'Y' - allow parcel subdivide, 'N' - not 927// strings[8] = 'Y' - allow parcel subdivide, 'N' - not
928// strings[9] = 'Y' - block parcel search, 'N' - allow 928// strings[9] = 'Y' - block parcel search, 'N' - allow
929void LLPanelRegionOpenSettingsInfo::sendUpdate(void* userdata) 929void LLPanelRegionOpenSettingsInfo::onClickOrs(void* userdata)
930{ 930{
931 LLPanelRegionOpenSettingsInfo* self; 931 LLPanelRegionOpenSettingsInfo* self;
932 self = (LLPanelRegionOpenSettingsInfo*)userdata; 932 self = (LLPanelRegionOpenSettingsInfo*)userdata;
933 933
934 llinfos << "LLPanelRegionOpenSettingsInfo::sendUpdate()" << llendl; 934 llinfos << "LLPanelRegionOpenSettingsInfo::onClickOrs()" << llendl;
935 935
936 LLSD body; 936 LLSD body;
937 std::string url = gAgent.getRegion()->getCapability("DispatchOpenRegionSettings"); 937 std::string url = gAgent.getRegion()->getCapability("DispatchOpenRegionSettings");
diff --git a/linden/indra/newview/llfloaterregioninfo.h b/linden/indra/newview/llfloaterregioninfo.h
index ee01c7c..ae0c993 100644
--- a/linden/indra/newview/llfloaterregioninfo.h
+++ b/linden/indra/newview/llfloaterregioninfo.h
@@ -188,7 +188,7 @@ public:
188 virtual BOOL postBuild(); 188 virtual BOOL postBuild();
189 189
190protected: 190protected:
191 static void sendUpdate(void* userdata); 191 static void onClickOrs(void* userdata);
192}; 192};
193 193
194///////////////////////////////////////////////////////////////////////////// 194/////////////////////////////////////////////////////////////////////////////
diff --git a/linden/indra/newview/llfolderview.h b/linden/indra/newview/llfolderview.h
index 9fad72e..40da669 100644
--- a/linden/indra/newview/llfolderview.h
+++ b/linden/indra/newview/llfolderview.h
@@ -97,7 +97,7 @@ public:
97 virtual void move( LLFolderViewEventListener* parent_listener ) = 0; 97 virtual void move( LLFolderViewEventListener* parent_listener ) = 0;
98 virtual BOOL isItemCopyable() const = 0; 98 virtual BOOL isItemCopyable() const = 0;
99 virtual BOOL copyToClipboard() const = 0; 99 virtual BOOL copyToClipboard() const = 0;
100 virtual void cutToClipboard() = 0; 100 virtual BOOL cutToClipboard() const = 0;
101 virtual BOOL isClipboardPasteable() const = 0; 101 virtual BOOL isClipboardPasteable() const = 0;
102 virtual void pasteFromClipboard() = 0; 102 virtual void pasteFromClipboard() = 0;
103 virtual void buildContextMenu(LLMenuGL& menu, U32 flags) = 0; 103 virtual void buildContextMenu(LLMenuGL& menu, U32 flags) = 0;
diff --git a/linden/indra/newview/llhomelocationresponder.cpp b/linden/indra/newview/llhomelocationresponder.cpp
index e609237..c00d8e7 100644
--- a/linden/indra/newview/llhomelocationresponder.cpp
+++ b/linden/indra/newview/llhomelocationresponder.cpp
@@ -105,7 +105,8 @@ void LLHomeLocationResponder::result( const LLSD& content )
105 } 105 }
106} 106}
107 107
108void LLHomeLocationResponder::error( const LLSD& content ) 108void LLHomeLocationResponder::error( U32 status, const std::string& reason )
109{ 109{
110 llinfos << "received error(" << ll_pretty_print_sd( content ) << ")" << llendl; 110 llinfos << "received error(" << reason << ")" << llendl;
111} 111}
112
diff --git a/linden/indra/newview/llhomelocationresponder.h b/linden/indra/newview/llhomelocationresponder.h
index 1e222cd..3a1d8eb 100644
--- a/linden/indra/newview/llhomelocationresponder.h
+++ b/linden/indra/newview/llhomelocationresponder.h
@@ -42,7 +42,7 @@
42class LLHomeLocationResponder : public LLHTTPClient::Responder 42class LLHomeLocationResponder : public LLHTTPClient::Responder
43{ 43{
44 virtual void result( const LLSD& content ); 44 virtual void result( const LLSD& content );
45 virtual void error( const LLSD& content ); 45 virtual void error( U32 status, const std::string& reason );
46}; 46};
47 47
48#endif 48#endif
diff --git a/linden/indra/newview/llinventorybridge.h b/linden/indra/newview/llinventorybridge.h
index 2004678..5a53aa5 100644
--- a/linden/indra/newview/llinventorybridge.h
+++ b/linden/indra/newview/llinventorybridge.h
@@ -221,7 +221,7 @@ public:
221 virtual void move(LLFolderViewEventListener* new_parent_bridge) {} 221 virtual void move(LLFolderViewEventListener* new_parent_bridge) {}
222 virtual BOOL isItemCopyable() const { return FALSE; } 222 virtual BOOL isItemCopyable() const { return FALSE; }
223 virtual BOOL copyToClipboard() const { return FALSE; } 223 virtual BOOL copyToClipboard() const { return FALSE; }
224 virtual void cutToClipboard() {} 224 virtual BOOL cutToClipboard() const { return FALSE; }
225 virtual BOOL isClipboardPasteable() const; 225 virtual BOOL isClipboardPasteable() const;
226 virtual void pasteFromClipboard() {} 226 virtual void pasteFromClipboard() {}
227 void getClipboardEntries(bool show_asset_id, std::vector<std::string> &items, 227 void getClipboardEntries(bool show_asset_id, std::vector<std::string> &items,
diff --git a/linden/indra/newview/llpanelinventory.cpp b/linden/indra/newview/llpanelinventory.cpp
index 9cd2759..277ab15 100644
--- a/linden/indra/newview/llpanelinventory.cpp
+++ b/linden/indra/newview/llpanelinventory.cpp
@@ -145,7 +145,7 @@ public:
145 virtual void move(LLFolderViewEventListener* parent_listener); 145 virtual void move(LLFolderViewEventListener* parent_listener);
146 virtual BOOL isItemCopyable() const; 146 virtual BOOL isItemCopyable() const;
147 virtual BOOL copyToClipboard() const; 147 virtual BOOL copyToClipboard() const;
148 virtual void cutToClipboard(); 148 virtual BOOL cutToClipboard() const;
149 virtual BOOL isClipboardPasteable() const; 149 virtual BOOL isClipboardPasteable() const;
150 virtual void pasteFromClipboard(); 150 virtual void pasteFromClipboard();
151 virtual void buildContextMenu(LLMenuGL& menu, U32 flags); 151 virtual void buildContextMenu(LLMenuGL& menu, U32 flags);
@@ -594,8 +594,9 @@ BOOL LLTaskInvFVBridge::copyToClipboard() const
594 return FALSE; 594 return FALSE;
595} 595}
596 596
597void LLTaskInvFVBridge::cutToClipboard() 597BOOL LLTaskInvFVBridge::cutToClipboard() const
598{ 598{
599 return FALSE;
599} 600}
600 601
601BOOL LLTaskInvFVBridge::isClipboardPasteable() const 602BOOL LLTaskInvFVBridge::isClipboardPasteable() const
diff --git a/linden/indra/newview/llspatialpartition.cpp b/linden/indra/newview/llspatialpartition.cpp
index c1d5ff3..d9fa5b5 100644
--- a/linden/indra/newview/llspatialpartition.cpp
+++ b/linden/indra/newview/llspatialpartition.cpp
@@ -826,7 +826,7 @@ class LLSpatialSetStateDiff : public LLSpatialSetState
826public: 826public:
827 LLSpatialSetStateDiff(U32 state) : LLSpatialSetState(state) { } 827 LLSpatialSetStateDiff(U32 state) : LLSpatialSetState(state) { }
828 828
829 virtual void traverse(const LLSpatialGroup::TreeNode* n) 829 virtual void traverse(const LLSpatialGroup::OctreeNode* n)
830 { 830 {
831 LLSpatialGroup* group = (LLSpatialGroup*) n->getListener(0); 831 LLSpatialGroup* group = (LLSpatialGroup*) n->getListener(0);
832 832
@@ -885,7 +885,7 @@ class LLSpatialClearStateDiff : public LLSpatialClearState
885public: 885public:
886 LLSpatialClearStateDiff(U32 state) : LLSpatialClearState(state) { } 886 LLSpatialClearStateDiff(U32 state) : LLSpatialClearState(state) { }
887 887
888 virtual void traverse(const LLSpatialGroup::TreeNode* n) 888 virtual void traverse(const LLSpatialGroup::OctreeNode* n)
889 { 889 {
890 LLSpatialGroup* group = (LLSpatialGroup*) n->getListener(0); 890 LLSpatialGroup* group = (LLSpatialGroup*) n->getListener(0);
891 891
@@ -1519,7 +1519,7 @@ public:
1519 return false; 1519 return false;
1520 } 1520 }
1521 1521
1522 virtual void traverse(const LLSpatialGroup::TreeNode* n) 1522 virtual void traverse(const LLSpatialGroup::OctreeNode* n)
1523 { 1523 {
1524 LLSpatialGroup* group = (LLSpatialGroup*) n->getListener(0); 1524 LLSpatialGroup* group = (LLSpatialGroup*) n->getListener(0);
1525 1525
diff --git a/linden/indra/newview/llviewerassetstorage.h b/linden/indra/newview/llviewerassetstorage.h
index 15c11c7..512b590 100644
--- a/linden/indra/newview/llviewerassetstorage.h
+++ b/linden/indra/newview/llviewerassetstorage.h
@@ -47,6 +47,7 @@ public:
47 LLViewerAssetStorage(LLMessageSystem *msg, LLXferManager *xfer, 47 LLViewerAssetStorage(LLMessageSystem *msg, LLXferManager *xfer,
48 LLVFS *vfs); 48 LLVFS *vfs);
49 49
50 using LLAssetStorage::storeAssetData;
50 virtual void storeAssetData( 51 virtual void storeAssetData(
51 const LLTransactionID& tid, 52 const LLTransactionID& tid,
52 LLAssetType::EType atype, 53 LLAssetType::EType atype,
diff --git a/linden/indra/newview/llwatchdog.h b/linden/indra/newview/llwatchdog.h
index ed7d5bd..1a10e33 100644
--- a/linden/indra/newview/llwatchdog.h
+++ b/linden/indra/newview/llwatchdog.h
@@ -64,9 +64,10 @@ public:
64 64
65 /* virtual */ bool isAlive() const; 65 /* virtual */ bool isAlive() const;
66 /* virtual */ void reset(); 66 /* virtual */ void reset();
67 /* virtual */ void start(const std::string& state); 67 /* virtual */ void start() { start(""); };
68 /* virtual */ void stop(); 68 /* virtual */ void stop();
69 69
70 void start(const std::string& state);
70 void setTimeout(F32 d); 71 void setTimeout(F32 d);
71 void ping(const std::string& state); 72 void ping(const std::string& state);
72 const std::string& getState() {return mPingState; } 73 const std::string& getState() {return mPingState; }
diff --git a/linden/indra/newview/viewer_manifest.py b/linden/indra/newview/viewer_manifest.py
index cc22748..f9c34d6 100755
--- a/linden/indra/newview/viewer_manifest.py
+++ b/linden/indra/newview/viewer_manifest.py
@@ -230,7 +230,7 @@ class WindowsManifest(ViewerManifest):
230 self.path("LICENSE-libraries.txt") 230 self.path("LICENSE-libraries.txt")
231 self.end_prefix("../..") 231 self.end_prefix("../..")
232 232
233 233
234 self.path("imprudence.url") 234 self.path("imprudence.url")
235 235
236 # Plugin host application 236 # Plugin host application
@@ -252,6 +252,14 @@ class WindowsManifest(ViewerManifest):
252 self.path("libhunspell.dll") 252 self.path("libhunspell.dll")
253 self.end_prefix() 253 self.end_prefix()
254 254
255 # Get llcommon and deps.
256 if self.prefix(src=self.args['configuration'], dst=""):
257 self.path('libapr-1.dll')
258 self.path('libaprutil-1.dll')
259 self.path('libapriconv-1.dll')
260 self.path('llcommon.dll')
261 self.end_prefix()
262
255 # For textures 263 # For textures
256 if self.prefix(src="../../libraries/i686-win32/lib/release", dst=""): 264 if self.prefix(src="../../libraries/i686-win32/lib/release", dst=""):
257 self.path("openjpeg.dll") 265 self.path("openjpeg.dll")
@@ -731,14 +739,51 @@ class DarwinManifest(ViewerManifest):
731 self.path("vivox-runtime/universal-darwin/SLVoice", "SLVoice") 739 self.path("vivox-runtime/universal-darwin/SLVoice", "SLVoice")
732 #self.path("vivox-runtime/universal-darwin/SLVoiceAgent.app", "SLVoiceAgent.app") 740 #self.path("vivox-runtime/universal-darwin/SLVoiceAgent.app", "SLVoiceAgent.app")
733 741
742 libdir = "../../libraries/universal-darwin/lib_release"
743 dylibs = {}
744
745 #for lib in "llkdu", "llcommon":
746 for lib in "llcommon":
747 libfile = "lib%s.dylib" % lib
748 try:
749 self.path(self.find_existing_file(os.path.join(os.pardir,
750 lib,
751 self.args['configuration'],
752 libfile),
753 os.path.join(libdir, libfile)),
754 dst=libfile)
755 except RuntimeError:
756 print "Skipping %s" % libfile
757 dylibs[lib] = False
758 else:
759 dylibs[lib] = True
760
761 for libfile in ("libapr-1.0.3.7.dylib",
762 "libaprutil-1.0.3.8.dylib",
763 "libexpat.0.5.0.dylib"):
764 self.path(os.path.join(libdir, libfile), libfile)
765
734 #libfmodwrapper.dylib 766 #libfmodwrapper.dylib
735 #self.path(self.args['configuration'] + "/libfmodwrapper.dylib", "libfmodwrapper.dylib") 767 #self.path(self.args['configuration'] + "/libfmodwrapper.dylib", "libfmodwrapper.dylib")
736 768
737 # our apps 769 # our apps
738# self.path("../mac_crash_logger/" + self.args['configuration'] + "/mac-crash-logger.app", "mac-crash-logger.app") 770# self.path("../mac_crash_logger/" + self.args['configuration'] + "/mac-crash-logger.app", "mac-crash-logger.app")
739 self.path("../mac_updater/" + self.args['configuration'] + "/mac-updater.app", "mac-updater.app") 771 self.path("../mac_updater/" + self.args['configuration'] + "/mac-updater.app", "mac-updater.app")
740 772
741 # plugin launcher 773 # our apps dependencies on shared libs
774 mac_crash_logger_res_path = self.dst_path_of("mac-crash-logger.app/Contents/Resources")
775 mac_updater_res_path = self.dst_path_of("mac-updater.app/Contents/Resources")
776 for libfile in ("libllcommon.dylib",
777 "libapr-1.0.3.7.dylib",
778 "libaprutil-1.0.3.8.dylib",
779 "libexpat.0.5.0.dylib"):
780 target_lib = os.path.join('../../..', libfile)
781 self.run_command("ln -sf %(target)r %(link)r" %
782 {'target': target_lib,
783 'link' : os.path.join(mac_crash_logger_res_path, libfile)}
784 )
785
786 # plugin launcher
742 self.path("../llplugin/slplugin/" + self.args['configuration'] + "/SLPlugin", "SLPlugin") 787 self.path("../llplugin/slplugin/" + self.args['configuration'] + "/SLPlugin", "SLPlugin")
743 788
744 # plugins 789 # plugins
@@ -952,6 +997,8 @@ class Linux_i686Manifest(LinuxManifest):
952 else: 997 else:
953 self.path("imprudence-stripped","bin/do-not-directly-run-imprudence-bin") 998 self.path("imprudence-stripped","bin/do-not-directly-run-imprudence-bin")
954 999
1000 self.path("../llcommon/libllcommon.so", "lib/libllcommon.so")
1001
955 if (not self.standalone()) and self.prefix("../../libraries/i686-linux/lib_release_client", dst="lib"): 1002 if (not self.standalone()) and self.prefix("../../libraries/i686-linux/lib_release_client", dst="lib"):
956 self.path("libapr-1.so.0") 1003 self.path("libapr-1.so.0")
957 self.path("libaprutil-1.so.0") 1004 self.path("libaprutil-1.so.0")
@@ -1072,6 +1119,8 @@ class Linux_x86_64Manifest(LinuxManifest):
1072 self.path("imprudence-stripped","bin/do-not-directly-run-imprudence-bin") 1119 self.path("imprudence-stripped","bin/do-not-directly-run-imprudence-bin")
1073# self.path("../linux_crash_logger/linux-crash-logger-stripped","linux-crash-logger.bin") 1120# self.path("../linux_crash_logger/linux-crash-logger-stripped","linux-crash-logger.bin")
1074 1121
1122 self.path("../llcommon/libllcommon.so", "lib64/libllcommon.so")
1123
1075 self.path("linux_tools/launch_url.sh","launch_url.sh") 1124 self.path("linux_tools/launch_url.sh","launch_url.sh")
1076 if self.prefix("res-sdl"): 1125 if self.prefix("res-sdl"):
1077 self.path("*") 1126 self.path("*")
diff --git a/linden/install.xml b/linden/install.xml
index 88b6ef3..1df31e2 100755
--- a/linden/install.xml
+++ b/linden/install.xml
@@ -99,9 +99,9 @@
99 <key>darwin</key> 99 <key>darwin</key>
100 <map> 100 <map>
101 <key>md5sum</key> 101 <key>md5sum</key>
102 <string>abd07d760cdc7d23da3b861f34b09c92</string> 102 <string>115d8ac44a91efdb173e9b3e478c46b6</string>
103 <key>url</key> 103 <key>url</key>
104 <uri>http://s3.amazonaws.com/viewer-source-downloads/install_pkgs/apr_suite-1.2.8-darwin-20080812.tar.bz2</uri> 104 <uri>http://s3.amazonaws.com/viewer-source-downloads/install_pkgs/apr_suite-1.3.7-darwin-20090805.tar.bz2</uri>
105 </map> 105 </map>
106 <key>linux</key> 106 <key>linux</key>
107 <map> 107 <map>
@@ -120,9 +120,9 @@
120 <key>windows</key> 120 <key>windows</key>
121 <map> 121 <map>
122 <key>md5sum</key> 122 <key>md5sum</key>
123 <string>b9d23a69a25fdeed96dcc3bf696b6514</string> 123 <string>a02619c1e30a3db02d3883bf1ad7a1e6</string>
124 <key>url</key> 124 <key>url</key>
125 <uri>http://s3.amazonaws.com/viewer-source-downloads/install_pkgs/apr_suite-1.2.12-windows-20080806.tar.bz2</uri> 125 <uri>http://s3.amazonaws.com/viewer-source-downloads/install_pkgs/apr_suite-1.3.8-windows-20090911.tar.bz2</uri>
126 </map> 126 </map>
127 </map> 127 </map>
128 </map> 128 </map>
@@ -354,9 +354,9 @@
354 <key>darwin</key> 354 <key>darwin</key>
355 <map> 355 <map>
356 <key>md5sum</key> 356 <key>md5sum</key>
357 <string>9c5603e328e9f543e0a599d6b25be973</string> 357 <string>c457a0a041ac4946265889a503d26c3d</string>
358 <key>url</key> 358 <key>url</key>
359 <uri>http://s3.amazonaws.com/viewer-source-downloads/install_pkgs/expat-1.95.8-darwin-20080812.tar.bz2</uri> 359 <uri>http://s3.amazonaws.com/viewer-source-downloads/install_pkgs/expat-1.95.8-darwin-20090805.tar.bz2</uri>
360 </map> 360 </map>
361 <key>linux</key> 361 <key>linux</key>
362 <map> 362 <map>