Rename CMake target from loot to libloot

On Windows using "loot" causes a name collisions with LOOT itself:

- for the MSVC project name, it clashes with LOOT's own project,
  despite the difference in case. This means that you can't build LOOT
  in Visual Studio when using FetchContent to handle the libloot
  dependency (running CMake on the CLI works though).
- for the PDB file, LOOT has LOOT.pdb and libloot has loot.pdb, which
  appear to be the same due to file paths being case-insensitive. This
  makes it more difficult to debug LOOT with the relevant debug info
  loaded.

Renaming the CMake target adds a "lib" prefix to the Visual Studio
project name and the artifact filenames:

- loot.vcxproj* -> libloot.vcxproj*
- loot.dll -> libloot.dll
- loot.lib -> libloot.lib
- loot.pdb -> libloot.pdb

The Linux build artifact filenames are unchanged, as they already had
the "lib" prefix.
This commit is contained in:
Oliver Hamlet
2026-01-02 13:16:46 +00:00
parent ee4188f917
commit c322e27e1e
2 changed files with 24 additions and 22 deletions
+1 -1
View File
@@ -76,7 +76,7 @@ endif()
# Build API tests.
add_executable(libloot_tests ${LIBLOOT_INTERFACE_TESTS_ALL_SOURCES})
target_link_libraries(libloot_tests PRIVATE loot GTest::gtest_main)
target_link_libraries(libloot_tests PRIVATE libloot GTest::gtest_main)
enable_testing()
gtest_discover_tests(libloot_tests DISCOVERY_TIMEOUT 10)