summaryrefslogtreecommitdiff
path: root/indra
diff options
context:
space:
mode:
authorRye <rye@alchemyviewer.org>2025-10-23 09:15:38 -0400
committerRye <rye@alchemyviewer.org>2025-10-27 04:59:15 -0400
commit37f89080ba5ce1ddd7848d2029794a5f5aabb7be (patch)
treecba155b6872e4ad40d010c10d59d72c578073360 /indra
parentf33eb2c2d4715607c8821f5d694e94a3b9663826 (diff)
Introduce global precompiled header to accelerate build
Signed-off-by: Rye <rye@alchemyviewer.org>
Diffstat (limited to 'indra')
-rw-r--r--indra/CMakeLists.txt3
-rw-r--r--indra/cmake/LLAddBuildTest.cmake14
-rw-r--r--indra/llappearance/CMakeLists.txt8
-rw-r--r--indra/llappearanceutility/CMakeLists.txt8
-rw-r--r--indra/llaudio/CMakeLists.txt4
-rw-r--r--indra/llcharacter/CMakeLists.txt4
-rw-r--r--indra/llcommon/CMakeLists.txt28
-rw-r--r--indra/llcommon/llsd.cpp5
-rw-r--r--indra/llcommon/llsdjson.cpp1
-rw-r--r--indra/llcorehttp/CMakeLists.txt8
-rw-r--r--indra/llcrashlogger/CMakeLists.txt4
-rw-r--r--indra/llfilesystem/CMakeLists.txt11
-rw-r--r--indra/llimage/CMakeLists.txt4
-rw-r--r--indra/llimagej2coj/CMakeLists.txt3
-rw-r--r--indra/llinventory/CMakeLists.txt4
-rw-r--r--indra/llmath/CMakeLists.txt8
-rw-r--r--indra/llmeshoptimizer/CMakeLists.txt4
-rw-r--r--indra/llmessage/CMakeLists.txt4
-rw-r--r--indra/llphysicsextensionsos/CMakeLists.txt4
-rw-r--r--indra/llplugin/CMakeLists.txt5
-rw-r--r--indra/llplugin/slplugin/CMakeLists.txt10
-rw-r--r--indra/llprecompiled/CMakeLists.txt53
-rw-r--r--indra/llprecompiled/cmake_dummy.cpp24
-rw-r--r--indra/llprimitive/CMakeLists.txt4
-rw-r--r--indra/llrender/CMakeLists.txt7
-rw-r--r--indra/llui/CMakeLists.txt4
-rw-r--r--indra/llwindow/CMakeLists.txt15
-rw-r--r--indra/llxml/CMakeLists.txt3
28 files changed, 241 insertions, 13 deletions
diff --git a/indra/CMakeLists.txt b/indra/CMakeLists.txt
index 571465c707..a7f0ab0486 100644
--- a/indra/CMakeLists.txt
+++ b/indra/CMakeLists.txt
@@ -58,6 +58,9 @@ endif (NOT CMAKE_BUILD_TYPE)
add_subdirectory(cmake)
+if (USE_PRECOMPILED_HEADERS)
+ add_subdirectory(${LIBS_OPEN_PREFIX}llprecompiled)
+endif ()
add_subdirectory(${LIBS_OPEN_PREFIX}llaudio)
add_subdirectory(${LIBS_OPEN_PREFIX}llappearance)
add_subdirectory(${LIBS_OPEN_PREFIX}llcharacter)
diff --git a/indra/cmake/LLAddBuildTest.cmake b/indra/cmake/LLAddBuildTest.cmake
index 83725ffd1b..4959051617 100644
--- a/indra/cmake/LLAddBuildTest.cmake
+++ b/indra/cmake/LLAddBuildTest.cmake
@@ -100,6 +100,10 @@ MACRO(LL_ADD_PROJECT_UNIT_TESTS project sources)
)
endif(DARWIN)
+ if (USE_PRECOMPILED_HEADERS)
+ target_precompile_headers(PROJECT_${project}_TEST_${name} REUSE_FROM llprecompiled)
+ endif ()
+
#
# Per-codefile additional / external project dep and lib dep property extraction
#
@@ -122,7 +126,9 @@ MACRO(LL_ADD_PROJECT_UNIT_TESTS project sources)
set_target_properties(PROJECT_${project}_TEST_${name}
PROPERTIES
COMPILE_FLAGS "${${name}_test_additional_CFLAGS}"
- COMPILE_DEFINITIONS "LL_TEST=${name};LL_TEST_${name}")
+ COMPILE_DEFINITIONS "LL_TEST=${name};LL_TEST_${name}"
+ FOLDER "Tests"
+ )
if(LL_TEST_VERBOSE)
message("LL_ADD_PROJECT_UNIT_TESTS ${name}_test_additional_CFLAGS ${${name}_test_additional_CFLAGS}")
endif()
@@ -217,6 +223,7 @@ FUNCTION(LL_ADD_INTEGRATION_TEST
PROPERTIES
RUNTIME_OUTPUT_DIRECTORY "${EXE_STAGING_DIR}"
COMPILE_DEFINITIONS "LL_TEST=${testname};LL_TEST_${testname}"
+ FOLDER "Tests"
)
# The following was copied to llcorehttp/CMakeLists.txt's texture_load target.
@@ -246,6 +253,11 @@ FUNCTION(LL_ADD_INTEGRATION_TEST
target_link_libraries(INTEGRATION_TEST_${testname} ${libraries})
target_include_directories (INTEGRATION_TEST_${testname} PRIVATE ${LIBS_OPEN_DIR}/test )
+ if (USE_PRECOMPILED_HEADERS)
+ target_include_directories (INTEGRATION_TEST_${testname} PRIVATE ${LIBS_OPEN_DIR}/llmath )
+ target_precompile_headers(INTEGRATION_TEST_${testname} REUSE_FROM llprecompiled)
+ endif ()
+
# Create the test running command
set(test_command ${ARGN})
set(TEST_EXE $<TARGET_FILE:INTEGRATION_TEST_${testname}>)
diff --git a/indra/llappearance/CMakeLists.txt b/indra/llappearance/CMakeLists.txt
index 40a1036597..5b6d68fa37 100644
--- a/indra/llappearance/CMakeLists.txt
+++ b/indra/llappearance/CMakeLists.txt
@@ -69,6 +69,10 @@ target_link_libraries(llappearance
)
target_include_directories( llappearance INTERFACE ${CMAKE_CURRENT_SOURCE_DIR})
+if (USE_PRECOMPILED_HEADERS)
+ target_precompile_headers(llappearance REUSE_FROM llprecompiled)
+endif ()
+
if (BUILD_HEADLESS)
add_library (llappearanceheadless ${llappearance_SOURCE_FILES})
target_include_directories( llappearanceheadless INTERFACE ${CMAKE_CURRENT_SOURCE_DIR})
@@ -85,4 +89,8 @@ if (BUILD_HEADLESS)
llcorehttp
llcommon
)
+
+ if (USE_PRECOMPILED_HEADERS)
+ target_precompile_headers(llappearanceheadless REUSE_FROM llprecompiled)
+ endif ()
endif (BUILD_HEADLESS)
diff --git a/indra/llappearanceutility/CMakeLists.txt b/indra/llappearanceutility/CMakeLists.txt
index 1d4e5309ba..53b5ce1cbe 100644
--- a/indra/llappearanceutility/CMakeLists.txt
+++ b/indra/llappearanceutility/CMakeLists.txt
@@ -63,6 +63,10 @@ target_link_libraries(appearance-utility-bin
llxml
)
+if (USE_PRECOMPILED_HEADERS)
+ target_precompile_headers(appearance-utility-bin REUSE_FROM llprecompiled)
+endif ()
+
if (BUILD_HEADLESS)
add_executable(appearance-utility-headless-bin ${appearance_utility_SOURCE_FILES})
@@ -74,5 +78,9 @@ if (BUILD_HEADLESS)
llrenderheadless
llxml
)
+
+ if (USE_PRECOMPILED_HEADERS)
+ target_precompile_headers(appearance-utility-headless-bin REUSE_FROM llprecompiled)
+ endif ()
endif (BUILD_HEADLESS)
diff --git a/indra/llaudio/CMakeLists.txt b/indra/llaudio/CMakeLists.txt
index 9278d3c488..18e29fb194 100644
--- a/indra/llaudio/CMakeLists.txt
+++ b/indra/llaudio/CMakeLists.txt
@@ -54,3 +54,7 @@ endif()
if( TARGET ll::fmodstudio )
target_link_libraries( llaudio ll::fmodstudio )
endif()
+
+if (USE_PRECOMPILED_HEADERS)
+ target_precompile_headers(llaudio REUSE_FROM llprecompiled)
+endif ()
diff --git a/indra/llcharacter/CMakeLists.txt b/indra/llcharacter/CMakeLists.txt
index bc45eb474a..1f019e6aef 100644
--- a/indra/llcharacter/CMakeLists.txt
+++ b/indra/llcharacter/CMakeLists.txt
@@ -70,3 +70,7 @@ target_link_libraries(
llfilesystem
llxml
)
+
+if (USE_PRECOMPILED_HEADERS)
+ target_precompile_headers(llcharacter REUSE_FROM llprecompiled)
+endif ()
diff --git a/indra/llcommon/CMakeLists.txt b/indra/llcommon/CMakeLists.txt
index 2de9deea70..c3b892b204 100644
--- a/indra/llcommon/CMakeLists.txt
+++ b/indra/llcommon/CMakeLists.txt
@@ -68,7 +68,7 @@ set(llcommon_SOURCE_FILES
llmetricperformancetester.cpp
llmortician.cpp
llmutex.cpp
- llptrto.cpp
+ llptrto.cpp
llpredicate.cpp
llprocess.cpp
llprocessor.cpp
@@ -108,7 +108,7 @@ set(llcommon_SOURCE_FILES
workqueue.cpp
StackWalker.cpp
)
-
+
set(llcommon_HEADER_FILES
CMakeLists.txt
@@ -255,14 +255,28 @@ set(llcommon_HEADER_FILES
workqueue.h
StackWalker.h
)
-
+
if (DARWIN)
list(APPEND llcommon_HEADER_FILES llsys_objc.h)
list(APPEND llcommon_SOURCE_FILES llsys_objc.mm)
+
+ set_source_files_properties(
+ llsys_objc.mm
+ PROPERTIES
+ SKIP_PRECOMPILE_HEADERS TRUE
+ )
endif (DARWIN)
if (USE_TRACY)
list(APPEND llcommon_SOURCE_FILES llprofiler.cpp)
+
+ # Skip precompiled headers on these files due to special compilation needs
+ set_source_files_properties(
+ llfasttimer.cpp
+ llprofiler.cpp
+ PROPERTIES
+ SKIP_PRECOMPILE_HEADERS TRUE
+ )
endif ()
list(APPEND llcommon_SOURCE_FILES ${llcommon_HEADER_FILES})
@@ -280,8 +294,12 @@ target_link_libraries(
ll::sse2neon
)
-target_include_directories(llcommon INTERFACE ${CMAKE_CURRENT_SOURCE_DIR})
-target_include_directories(llcommon PRIVATE ${CMAKE_CURRENT_SOURCE_DIR})
+target_include_directories(llcommon PUBLIC ${CMAKE_CURRENT_SOURCE_DIR})
+target_include_directories(llcommon PRIVATE ${CMAKE_SOURCE_DIR}/llmath)
+
+if (USE_PRECOMPILED_HEADERS)
+ target_precompile_headers(llcommon REUSE_FROM llprecompiled)
+endif ()
add_dependencies(llcommon stage_third_party_libs)
diff --git a/indra/llcommon/llsd.cpp b/indra/llcommon/llsd.cpp
index 77fe545c3f..ea6d6a308a 100644
--- a/indra/llcommon/llsd.cpp
+++ b/indra/llcommon/llsd.cpp
@@ -32,7 +32,6 @@
#include "llbase64.h"
#include "llerror.h"
-#include "../llmath/llmath.h"
#include "llformat.h"
#include "llsdserialize.h"
#include "stringize.h"
@@ -291,10 +290,10 @@ namespace
};
LLSD::Boolean ImplReal::asBoolean() const
- { return !llisnan(mValue) && mValue != 0.0; }
+ { return !std::isnan(mValue) && mValue != 0.0; }
LLSD::Integer ImplReal::asInteger() const
- { return !llisnan(mValue) ? (LLSD::Integer)mValue : 0; }
+ { return !std::isnan(mValue) ? (LLSD::Integer)mValue : 0; }
LLSD::String ImplReal::asString() const
{ return llformat("%lg", mValue); }
diff --git a/indra/llcommon/llsdjson.cpp b/indra/llcommon/llsdjson.cpp
index 655869a704..542a3c26e3 100644
--- a/indra/llcommon/llsdjson.cpp
+++ b/indra/llcommon/llsdjson.cpp
@@ -33,7 +33,6 @@
#include "llsdutil.h"
#include "llerror.h"
-#include "../llmath/llmath.h"
#include <boost/json/src.hpp>
diff --git a/indra/llcorehttp/CMakeLists.txt b/indra/llcorehttp/CMakeLists.txt
index 05b788a433..46503a8a4b 100644
--- a/indra/llcorehttp/CMakeLists.txt
+++ b/indra/llcorehttp/CMakeLists.txt
@@ -81,6 +81,7 @@ list(APPEND llcorehttp_SOURCE_FILES ${llcorehttp_HEADER_FILES})
add_library (llcorehttp ${llcorehttp_SOURCE_FILES})
target_link_libraries(
llcorehttp
+ llmath
llcommon
ll::libcurl
ll::openssl
@@ -92,6 +93,10 @@ target_include_directories( llcorehttp INTERFACE ${CMAKE_CURRENT_SOURCE_DIR})
# lead to circular dependencies (or in case of cmake, the first project declaring it's dependencies wins)
target_include_directories( llcorehttp PRIVATE ${CMAKE_CURRENT_SOURCE_DIR}/../llmessage)
+if (USE_PRECOMPILED_HEADERS)
+ target_precompile_headers(llcorehttp REUSE_FROM llprecompiled)
+endif ()
+
# tests
set(LLCOREHTTP_TESTS ON CACHE BOOL
"Build and run llcorehttp integration tests specifically")
@@ -131,7 +136,7 @@ if (LL_TESTS AND LLCOREHTTP_TESTS)
${PYTHON_EXECUTABLE}
"${CMAKE_CURRENT_SOURCE_DIR}/tests/test_llcorehttp_peer.py"
)
-
+
#
# Example Programs
#
@@ -151,6 +156,7 @@ if (LL_TESTS AND LLCOREHTTP_TESTS)
set_target_properties(http_texture_load
PROPERTIES
RUNTIME_OUTPUT_DIRECTORY "${EXE_STAGING_DIR}"
+ FOLDER "Tests"
)
if (WINDOWS)
diff --git a/indra/llcrashlogger/CMakeLists.txt b/indra/llcrashlogger/CMakeLists.txt
index 6ac73c0d32..7a1c3eef54 100644
--- a/indra/llcrashlogger/CMakeLists.txt
+++ b/indra/llcrashlogger/CMakeLists.txt
@@ -21,3 +21,7 @@ list(APPEND llcrashlogger_SOURCE_FILES ${llcrashlogger_HEADER_FILES})
add_library(llcrashlogger ${llcrashlogger_SOURCE_FILES})
target_link_libraries( llcrashlogger llcommon llmessage llcorehttp llxml llfilesystem )
+
+if (USE_PRECOMPILED_HEADERS)
+ target_precompile_headers(llcrashlogger REUSE_FROM llprecompiled)
+endif ()
diff --git a/indra/llfilesystem/CMakeLists.txt b/indra/llfilesystem/CMakeLists.txt
index 9f24f75eab..a552e4bdbc 100644
--- a/indra/llfilesystem/CMakeLists.txt
+++ b/indra/llfilesystem/CMakeLists.txt
@@ -28,6 +28,12 @@ if (DARWIN)
LIST(APPEND llfilesystem_SOURCE_FILES lldir_utils_objc.h)
LIST(APPEND llfilesystem_SOURCE_FILES lldir_mac.cpp)
LIST(APPEND llfilesystem_HEADER_FILES lldir_mac.h)
+
+ set_source_files_properties(
+ lldir_utils_objc.mm
+ PROPERTIES
+ SKIP_PRECOMPILE_HEADERS TRUE
+ )
endif (DARWIN)
if (LINUX)
@@ -52,10 +58,15 @@ list(APPEND llfilesystem_SOURCE_FILES ${llfilesystem_HEADER_FILES})
add_library (llfilesystem ${llfilesystem_SOURCE_FILES})
target_link_libraries(llfilesystem
+ llmath
llcommon
)
target_include_directories( llfilesystem INTERFACE ${CMAKE_CURRENT_SOURCE_DIR})
+if (USE_PRECOMPILED_HEADERS)
+ target_precompile_headers(llfilesystem REUSE_FROM llprecompiled)
+endif ()
+
# Add tests
if (LL_TESTS)
include(LLAddBuildTest)
diff --git a/indra/llimage/CMakeLists.txt b/indra/llimage/CMakeLists.txt
index cc75c463bc..a81808343f 100644
--- a/indra/llimage/CMakeLists.txt
+++ b/indra/llimage/CMakeLists.txt
@@ -63,6 +63,10 @@ target_link_libraries(llimage
ll::libjpeg
)
+if (USE_PRECOMPILED_HEADERS)
+ target_precompile_headers(llimage REUSE_FROM llprecompiled)
+endif ()
+
# Add tests
if (LL_TESTS)
SET(llimage_TEST_SOURCE_FILES
diff --git a/indra/llimagej2coj/CMakeLists.txt b/indra/llimagej2coj/CMakeLists.txt
index 93e85668dd..b7ef696b20 100644
--- a/indra/llimagej2coj/CMakeLists.txt
+++ b/indra/llimagej2coj/CMakeLists.txt
@@ -27,3 +27,6 @@ target_link_libraries( llimagej2coj
ll::openjpeg
)
+if (USE_PRECOMPILED_HEADERS)
+ target_precompile_headers(llimagej2coj REUSE_FROM llprecompiled)
+endif ()
diff --git a/indra/llinventory/CMakeLists.txt b/indra/llinventory/CMakeLists.txt
index 93a586759f..22966bc55b 100644
--- a/indra/llinventory/CMakeLists.txt
+++ b/indra/llinventory/CMakeLists.txt
@@ -59,6 +59,10 @@ add_library (llinventory ${llinventory_SOURCE_FILES})
target_link_libraries( llinventory llcommon llmath llmessage llxml )
target_include_directories( llinventory INTERFACE ${CMAKE_CURRENT_SOURCE_DIR})
+if (USE_PRECOMPILED_HEADERS)
+ target_precompile_headers(llinventory REUSE_FROM llprecompiled)
+endif ()
+
#add unit tests
if (LL_TESTS)
INCLUDE(LLAddBuildTest)
diff --git a/indra/llmath/CMakeLists.txt b/indra/llmath/CMakeLists.txt
index bd860adc31..fb57e5db11 100644
--- a/indra/llmath/CMakeLists.txt
+++ b/indra/llmath/CMakeLists.txt
@@ -99,10 +99,14 @@ set(llmath_HEADER_FILES
list(APPEND llmath_SOURCE_FILES ${llmath_HEADER_FILES})
-add_library (llmath ${llmath_SOURCE_FILES})
+add_library(llmath ${llmath_SOURCE_FILES})
target_link_libraries(llmath llcommon llmeshoptimizer ll::sse2neon)
-target_include_directories( llmath INTERFACE ${CMAKE_CURRENT_SOURCE_DIR})
+target_include_directories(llmath INTERFACE ${CMAKE_CURRENT_SOURCE_DIR})
+
+if (USE_PRECOMPILED_HEADERS)
+ target_precompile_headers(llmath REUSE_FROM llprecompiled)
+endif ()
# Add tests
if (LL_TESTS)
diff --git a/indra/llmeshoptimizer/CMakeLists.txt b/indra/llmeshoptimizer/CMakeLists.txt
index dfac44c296..5b1ab9d8e4 100644
--- a/indra/llmeshoptimizer/CMakeLists.txt
+++ b/indra/llmeshoptimizer/CMakeLists.txt
@@ -30,5 +30,9 @@ target_link_libraries(llmeshoptimizer
llmath
ll::meshoptimizer)
+if (USE_PRECOMPILED_HEADERS)
+ target_precompile_headers(llmeshoptimizer REUSE_FROM llprecompiled)
+endif ()
+
# Add tests
diff --git a/indra/llmessage/CMakeLists.txt b/indra/llmessage/CMakeLists.txt
index b2757a7306..46f28abc9c 100644
--- a/indra/llmessage/CMakeLists.txt
+++ b/indra/llmessage/CMakeLists.txt
@@ -194,6 +194,10 @@ target_link_libraries(
)
target_include_directories( llmessage INTERFACE ${CMAKE_CURRENT_SOURCE_DIR})
+if (USE_PRECOMPILED_HEADERS)
+ target_precompile_headers(llmessage REUSE_FROM llprecompiled)
+endif ()
+
# tests
if (LL_TESTS)
SET(llmessage_TEST_SOURCE_FILES
diff --git a/indra/llphysicsextensionsos/CMakeLists.txt b/indra/llphysicsextensionsos/CMakeLists.txt
index c04115ef26..ff1b703dc7 100644
--- a/indra/llphysicsextensionsos/CMakeLists.txt
+++ b/indra/llphysicsextensionsos/CMakeLists.txt
@@ -43,5 +43,9 @@ if(WINDOWS)
target_compile_options(llphysicsextensionsos PRIVATE /bigobj)
endif()
+if (USE_PRECOMPILED_HEADERS)
+ target_precompile_headers(llphysicsextensionsos REUSE_FROM llprecompiled)
+endif ()
+
# Add tests
diff --git a/indra/llplugin/CMakeLists.txt b/indra/llplugin/CMakeLists.txt
index e008a4093e..f67975365a 100644
--- a/indra/llplugin/CMakeLists.txt
+++ b/indra/llplugin/CMakeLists.txt
@@ -36,5 +36,10 @@ list(APPEND llplugin_SOURCE_FILES ${llplugin_HEADER_FILES})
add_library (llplugin ${llplugin_SOURCE_FILES})
target_include_directories( llplugin INTERFACE ${CMAKE_CURRENT_SOURCE_DIR})
target_link_libraries( llplugin llcommon llmath llmessage llxml )
+
+if (USE_PRECOMPILED_HEADERS)
+ target_precompile_headers(llplugin REUSE_FROM llprecompiled)
+endif ()
+
add_subdirectory(slplugin)
diff --git a/indra/llplugin/slplugin/CMakeLists.txt b/indra/llplugin/slplugin/CMakeLists.txt
index 4df3e306cb..f746160ada 100644
--- a/indra/llplugin/slplugin/CMakeLists.txt
+++ b/indra/llplugin/slplugin/CMakeLists.txt
@@ -18,6 +18,12 @@ if (DARWIN)
list(APPEND SLPlugin_HEADER_FILES
slplugin-objc.h
)
+
+ set_source_files_properties(
+ slplugin-objc.mm
+ PROPERTIES
+ SKIP_PRECOMPILE_HEADERS TRUE
+ )
endif (DARWIN)
if (SLPlugin_HEADER_FILES)
@@ -37,6 +43,10 @@ target_link_libraries(SLPlugin
ll::pluginlibraries
)
+if (USE_PRECOMPILED_HEADERS)
+ target_precompile_headers(SLPlugin REUSE_FROM llprecompiled)
+endif ()
+
if (WINDOWS)
set_target_properties(SLPlugin
PROPERTIES
diff --git a/indra/llprecompiled/CMakeLists.txt b/indra/llprecompiled/CMakeLists.txt
new file mode 100644
index 0000000000..ea230f4a98
--- /dev/null
+++ b/indra/llprecompiled/CMakeLists.txt
@@ -0,0 +1,53 @@
+# -*- cmake -*-
+
+project(llprecompiled)
+
+include(00-Common)
+include(APR)
+include(bugsplat)
+include(Linking)
+include(Boost)
+include(LLSharedLibs)
+include(ZLIBNG)
+include(Tracy)
+include(EXPAT)
+include(SSE2NEON)
+
+set(llprecompiled_SOURCE_FILES
+ cmake_dummy.cpp
+ )
+
+add_library (llprecompiled ${llprecompiled_SOURCE_FILES})
+
+target_include_directories(llprecompiled PRIVATE
+ ${CMAKE_SOURCE_DIR}/${LIBS_OPEN_PREFIX}llmath
+ )
+
+target_link_libraries(llprecompiled
+ llcommon
+ ll::apr
+ ll::expat
+ ll::zlib-ng
+ ll::boost
+ ll::oslibraries
+ ll::tracy
+ ll::sse2neon
+ )
+
+target_precompile_headers(llprecompiled PRIVATE
+ [["linden_common.h"]]
+ [["llwin32headers.h"]]
+ [["llprofiler.h"]]
+ [["llmath.h"]]
+ <boost/bind.hpp>
+ <boost/fiber/fiber.hpp>
+ <boost/fiber/fss.hpp>
+ <boost/fiber/future/promise.hpp>
+ <boost/fiber/future/future.hpp>
+ <boost/function.hpp>
+ <boost/function_types/function_arity.hpp>
+ <boost/iterator/transform_iterator.hpp>
+ <boost/iterator/indirect_iterator.hpp>
+ <boost/range/iterator_range.hpp>
+ <boost/signals2.hpp>
+ )
diff --git a/indra/llprecompiled/cmake_dummy.cpp b/indra/llprecompiled/cmake_dummy.cpp
new file mode 100644
index 0000000000..21a47a9b14
--- /dev/null
+++ b/indra/llprecompiled/cmake_dummy.cpp
@@ -0,0 +1,24 @@
+/**
+ * @file cmake_dummy.cpp
+ *
+ * $LicenseInfo:firstyear=2008&license=viewerlgpl$
+ * Second Life Viewer Source Code
+ * Copyright (C) 2010, Linden Research, Inc.
+ *
+ * This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Lesser General Public
+ * License as published by the Free Software Foundation;
+ * version 2.1 of the License only.
+ *
+ * This library is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this library; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ *
+ * Linden Research, Inc., 945 Battery Street, San Francisco, CA 94111 USA
+ * $/LicenseInfo$
+ */
diff --git a/indra/llprimitive/CMakeLists.txt b/indra/llprimitive/CMakeLists.txt
index ff0cad58d6..f05be03034 100644
--- a/indra/llprimitive/CMakeLists.txt
+++ b/indra/llprimitive/CMakeLists.txt
@@ -79,6 +79,10 @@ else()
)
endif ()
+if (USE_PRECOMPILED_HEADERS)
+ target_precompile_headers(llprimitive REUSE_FROM llprecompiled)
+endif ()
+
#add unit tests
if (LL_TESTS)
INCLUDE(LLAddBuildTest)
diff --git a/indra/llrender/CMakeLists.txt b/indra/llrender/CMakeLists.txt
index d0ae2d6b93..77af0693f3 100644
--- a/indra/llrender/CMakeLists.txt
+++ b/indra/llrender/CMakeLists.txt
@@ -86,6 +86,10 @@ if (BUILD_HEADLESS)
ll::freetype
OpenGL::GL
)
+
+ if (USE_PRECOMPILED_HEADERS)
+ target_precompile_headers(llrenderheadless REUSE_FROM llprecompiled)
+ endif()
endif (BUILD_HEADLESS)
add_library (llrender ${llrender_SOURCE_FILES})
@@ -104,3 +108,6 @@ target_link_libraries(llrender
OpenGL::GL
)
+if (USE_PRECOMPILED_HEADERS)
+ target_precompile_headers(llrender REUSE_FROM llprecompiled)
+endif ()
diff --git a/indra/llui/CMakeLists.txt b/indra/llui/CMakeLists.txt
index 908e94b24c..b543a12281 100644
--- a/indra/llui/CMakeLists.txt
+++ b/indra/llui/CMakeLists.txt
@@ -272,6 +272,10 @@ target_link_libraries(llui
llcommon
)
+if (USE_PRECOMPILED_HEADERS)
+ target_precompile_headers(llui REUSE_FROM llprecompiled)
+endif ()
+
# Add tests
if(LL_TESTS)
include(LLAddBuildTest)
diff --git a/indra/llwindow/CMakeLists.txt b/indra/llwindow/CMakeLists.txt
index fe45df4021..1f846de35d 100644
--- a/indra/llwindow/CMakeLists.txt
+++ b/indra/llwindow/CMakeLists.txt
@@ -101,6 +101,13 @@ if (DARWIN)
PROPERTIES
COMPILE_FLAGS "-fpascal-strings"
)
+
+ set_source_files_properties(
+ llwindowmacosx-objc.mm
+ llopenglview-objc.mm
+ PROPERTIES
+ SKIP_PRECOMPILE_HEADERS TRUE
+ )
endif (DARWIN)
@@ -170,6 +177,10 @@ if (BUILD_HEADLESS)
dl
)
target_include_directories(llwindowheadless INTERFACE ${CMAKE_CURRENT_SOURCE_DIR})
+
+ if (USE_PRECOMPILED_HEADERS)
+ target_precompile_headers(llwindowheadless REUSE_FROM llprecompiled)
+ endif ()
endif (BUILD_HEADLESS)
if (llwindow_HEADER_FILES)
@@ -190,6 +201,10 @@ if (USE_SDL_WINDOW)
target_compile_definitions( llwindow PUBLIC LL_SDL_WINDOW=1 )
endif()
+if (USE_PRECOMPILED_HEADERS)
+ target_precompile_headers(llwindow REUSE_FROM llprecompiled)
+endif ()
+
if (DARWIN)
target_link_libraries(llwindow ${CARBON_LIBRARY})
endif (DARWIN)
diff --git a/indra/llxml/CMakeLists.txt b/indra/llxml/CMakeLists.txt
index 508c2b919b..bc79e2ef19 100644
--- a/indra/llxml/CMakeLists.txt
+++ b/indra/llxml/CMakeLists.txt
@@ -34,6 +34,9 @@ target_link_libraries( llxml
)
target_include_directories( llxml INTERFACE ${CMAKE_CURRENT_SOURCE_DIR})
+if (USE_PRECOMPILED_HEADERS)
+ target_precompile_headers(llxml REUSE_FROM llprecompiled)
+endif ()
# tests