aboutsummaryrefslogtreecommitdiff
path: root/libs/installer_fomod_plus/CMakeLists.txt
diff options
context:
space:
mode:
authorSulfurNitride <SulfurNitride@users.noreply.github.com>2026-02-14 02:45:12 -0600
committerSulfurNitride <SulfurNitride@users.noreply.github.com>2026-02-14 02:45:25 -0600
commit817e8f5cd26739c69d930d21cd9dc4c0b6e4984e (patch)
tree52aed11d6751bb7d20b06acf197d56fac113203d /libs/installer_fomod_plus/CMakeLists.txt
parent51a9f8f197727f00896e5de44569b098923527dd (diff)
Add FUSE external mapping support, BG3/Oblivion Remastered fixes, fomod-plus and NaK integration
FUSE VFS now deploys non-data-dir mod mappings (Paks, OBSE, UE4SS, etc.) via real symlinks and injects file-level data-dir mappings (plugins.txt, loadorder.txt) into the VFS tree. Fixes game launches for Oblivion Remastered (Root Builder path resolution, script extender support) and BG3 (Wine prefix documents directory, file mapper symlinks on Linux). Vendors mo2-fomod-plus plugin and NaK crate for FOMOD installer and game finder/runtime support. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Diffstat (limited to 'libs/installer_fomod_plus/CMakeLists.txt')
-rw-r--r--libs/installer_fomod_plus/CMakeLists.txt36
1 files changed, 36 insertions, 0 deletions
diff --git a/libs/installer_fomod_plus/CMakeLists.txt b/libs/installer_fomod_plus/CMakeLists.txt
new file mode 100644
index 0000000..3367145
--- /dev/null
+++ b/libs/installer_fomod_plus/CMakeLists.txt
@@ -0,0 +1,36 @@
+# mo2-fomod-plus — vendored from github.com/aglowinthefield/mo2-fomod-plus
+# Commit: da6c07ed4bbe235759910c14c2450e1bfe8fe25e (2026-01-27)
+#
+# Pure C++20 FOMOD installer replacement (no .NET dependency).
+# 3 plugin targets: installer, scanner, patch wizard.
+
+include(FetchContent)
+
+# Force pugixml to build as a static library so plugins don't need libpugixml.so at runtime.
+# (The global BUILD_SHARED_LIBS is ON for MO2's own archive lib, which would make pugixml shared.)
+set(BUILD_SHARED_LIBS_SAVED ${BUILD_SHARED_LIBS})
+set(BUILD_SHARED_LIBS OFF CACHE BOOL "" FORCE)
+
+# Compatibility: sub-CMakeLists call mo2_install_target but Fluorine defines mo2_install_plugin
+if (NOT COMMAND mo2_install_target AND COMMAND mo2_install_plugin)
+ function(mo2_install_target target)
+ mo2_install_plugin(${target})
+ endfunction()
+endif ()
+
+# Compute include dirs from existing targets for sub-CMakeLists that reference these variables
+get_target_property(MO2_UIBASE_INCLUDE_DIRS mo2::uibase INTERFACE_INCLUDE_DIRECTORIES)
+foreach(dir ${MO2_UIBASE_INCLUDE_DIRS})
+ list(APPEND MO2_UIBASE_INCLUDE_DIRS "${dir}/uibase" "${dir}/uibase/game_features")
+endforeach()
+get_target_property(MO2_ARCHIVE_INCLUDE_DIRS mo2::archive INTERFACE_INCLUDE_DIRECTORIES)
+foreach(dir ${MO2_ARCHIVE_INCLUDE_DIRS})
+ list(APPEND MO2_ARCHIVE_INCLUDE_DIRS "${dir}/archive")
+endforeach()
+
+add_subdirectory(installer)
+add_subdirectory(scanner)
+add_subdirectory(patchwizard)
+
+# Restore BUILD_SHARED_LIBS so subsequent targets aren't affected.
+set(BUILD_SHARED_LIBS ${BUILD_SHARED_LIBS_SAVED} CACHE BOOL "" FORCE)