diff options
author | Andrew Kaster <akaster@serenityos.org> | 2021-07-27 00:19:08 -0600 |
---|---|---|
committer | Linus Groh <mail@linusgroh.de> | 2021-07-29 21:46:25 +0100 |
commit | de2bf3f333eb85ffe49afcdd0321e03c1d1f7cb6 (patch) | |
tree | 1e9c7596950f94cae5e0e48809fe3b27ded9d4ba /Userland/Libraries/LibTest/CMakeLists.txt | |
parent | af9be6e093c571aa9afbbfc6276572bba0aa2ff4 (diff) | |
download | serenity-de2bf3f333eb85ffe49afcdd0321e03c1d1f7cb6.zip |
Meta/LibTest: Build object libraries for test main files
By using the power of object libraries and $<TARGET_OBJECTS> we can make
sure to only build TestMain.cpp and JavaScriptTestRunnerMain.cpp once.
Previously we built these cpp files into object files once for every
single test executable. This change reduces the number of total compile
jobs in a Serenity target build by around 100.
Diffstat (limited to 'Userland/Libraries/LibTest/CMakeLists.txt')
-rw-r--r-- | Userland/Libraries/LibTest/CMakeLists.txt | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/Userland/Libraries/LibTest/CMakeLists.txt b/Userland/Libraries/LibTest/CMakeLists.txt index ad5f2bb251..c5ba722218 100644 --- a/Userland/Libraries/LibTest/CMakeLists.txt +++ b/Userland/Libraries/LibTest/CMakeLists.txt @@ -7,3 +7,6 @@ set(SOURCES serenity_lib(LibTest test) target_link_libraries(LibTest LibC) + +add_library(LibTestMain OBJECT TestMain.cpp) +add_library(JavaScriptTestRunnerMain OBJECT JavaScriptTestRunnerMain.cpp) |