Commit Graph

215 Commits (b285e2f85fdae1f28359a67484908de40661a563)

Author SHA1 Message Date
AnyOldName3 26be98966f Modernise Boost CMake stuff
Resolves https://gitlab.com/OpenMW/openmw/-/issues/8100

Also removes some old crud.
Hopefully the old crud is all:
* Handled automatically by CMake now we're using the modern approach.
* A hack-fix for a problem caused by not using the modern approach.
* Massively outdated so no longer necessary.

If it turns out this makes CI fail, I'll tweak things as necessary.

Changes that might not be wanted include:
* Getting rid of our BOOST_STATIC CMake option. In cases where the CMake config doesn't make the one correct choice from the build environment (i.e. because there's a choice) the CMake config exposes the option already.
  However, we were forcing this on for Windows, so that might matter.
  It seems to default to static on my machine even though I thought I read something suggesting otherwise, so we'll see how things go with that.
  If we eventually put CMake in charge of installing dependency DLLs this will be a moot point as we won't need to care.
* Bumping the minimum version of Boost to 1.70.0, as that's the first with working CMake config.
  It's from 2019, so plausibly there are distros too scared to use a library from five years ago as it can't legally drink in the US (although it could in limited quantities with parental supervision in the UK, as long as it's just something inconsequential like a single sip of beer).
4 months ago
elsid 5c3ae3d94c
Make loading and saving script record more robust
* Check the header presence before using it.
* Write the header based on the actual content.
6 months ago
elsid 4571a8b88a
Remove unused SCHD type 6 months ago
elsid 01166b1f26
Split ESM headers 8 months ago
Evil Eye 5a0aed3a78 Use more decomposition, string_view, and implicit sizes in ESM code 9 months ago
elsid 5859fd464c
Add option to disable precompiled headers
To be able to use ccache.

Also fix compilation errors appeared due to absence of precompiled
headers.
10 months ago
Andrei Kortunov 737d3b499b Use move semantics for tools 11 months ago
Evil Eye e63933efa6 Use NAM9 for stack count 1 year ago
Evil Eye 3e101ab409 Add a variadic getHNOT 1 year ago
Evil Eye 88731f864e Add imports 1 year ago
Evil Eye dbf9d42cc5 Remove sized reads from essimporter 1 year ago
Andrei Kortunov 6f68df9ac2 Avoid redundant copies 1 year ago
Evil Eye dc781bad5d Use fixed size unsigned ints for inventory offsets 1 year ago
Andrei Kortunov d3d7a663c6 Move some objects instead of copying 1 year ago
Andrei Kortunov d8ec78d732 Fix some Coverity warnings 1 year ago
psi29a a6d6e16d48 Merge branch 'readsize' into 'master'
Disallow implicitly sized reads of ESM structs

See merge request OpenMW/openmw!3100
1 year ago
Mads Buvik Sandvei 364f2a98e9 Use refnum instead of slot for items during spellcast 1 year ago
Evil Eye 45ba05c0ed Disallow implicitly sized reads of ESM structs 1 year ago
AnyOldName3 34fcfb63cf Eliminate redundant version checks 1 year ago
Evil Eye 6b7e7acd16 Replace a number of incorrect index types 2 years ago
Evil Eye e01a3076dd Use std::array in NpcStats 2 years ago
Evil Eye 9214ffb50b Replace some empty constructors and destructors with default 2 years ago
florent.teppe d782d37ee2 Make sure Vec2iRefId is trivially copyable on GCC 11.3
std::pair<int, int> isn't trivially copyable on some compilers
so a specific struct is defined, it's an int pair, but it should be recognised by GCC 11.3 as trivially copyable

Vec2iRefId => ESM3ExteriorCellRefId

more explcit name and use mX,mY instead of pair
renamed files and enum
2 years ago
florent.teppe f99e65843a Removes most cellId.hpp include, simplifies id generation for cells. 2 years ago
florent.teppe c2182c2fcc Get Rid of ESM::CellId almost everywhere
it was a competing concept from using RefIds for cell.
There is almost no point to it now, except to load older data.
2 years ago
florent.teppe c39dd576f8 Gets rid of most ESM::CellId 2 years ago
florent.teppe 1bbf4a3acf fixes teleport to exterior cells.
fixes linux compile

fix compile bis
2 years ago
Evil Eye 54d6fb29c2 Don't store a save's cell name as a RefID 2 years ago
elsid 1857d8a68c
Use target_compile_options to add --coverage 2 years ago
elsid cc066efa11
Fix identation in CMakeLists.txt 2 years ago
elsid 6d261d38dd
Add functions to read and write ESM::RefId and use them
To be later changed with another implementation.
2 years ago
elsid 80e6d6cbe3
Support variable size strings in ESM3 2 years ago
elsid 080700f8fe
Name all custom ESM format versions and add tests 2 years ago
florent.teppe 3780033837 Reverts Cell name to a string 2 years ago
elsid c173348cbe
Use default initializers for ESM::RefNum members
Instead of unset function that is removed now and assignments all over the code.
2 years ago
florent.teppe 2c30575b3b CellName is now a RefId, makes more sense that way. 2 years ago
florent.teppe 0f3499f504 Renamed string => Id, makes more sense considering the new underlying type
Fixes unnecessary copies, and issues with case sensitive comparisons.

fixed modification that wasn't necessary

Fixed type mismatch, and unecessary copy
2 years ago
florent.teppe b61d5d8123 Some RefId == ESM::RefId::StringRefId('constString') still existed 2 years ago
florent.teppe 65cdd489fb create a specific esm reader function for RefID to avoid allocation for string and then again for RefId
Fixed some types

removed useless header

applied clang format

fixed compile tests

fixed clang tidy, and closer to logic before this MR

Removed hardcoded refids

unless there is a returned value we don't use static RefIds
can use == between RefId and hardcoded string

Fix clang format

Fixed a few instances where std::string was used, when only const std::string& was needed

removed unused variable
2 years ago
fteppe 62d8fe3fc2 changed a few hardcoded refIds used in mutliple places to be defined only once in a variable 2 years ago
fteppe 20da0892ef openMW_test_suite compiles and runs
Slowly moving through the open-cs errors

Good progress in openCS

Very good progress on openCS

Getting closer with openCS

OpenCS compiles and runs! Didn't have time to test it all though

ix openMW

everything compiles on windows??

Fix gcc

Fix Clang
2 years ago
elsid 843753da14
Remove unused includes 2 years ago
clang-format-bot ddb0522bbf
Apply clang-format to code base 2 years ago
elsid 4698a4cd2d
Use raw string literals to format command usage messages 2 years ago
elsid 6ae15f08e0
Avoid chained operator() calls to prevent formatting issues 2 years ago
Project579 c226b35f1f Fix some remaining encoding errors due to std::filesystem transition. 2 years ago
Project579 199bf233e8 essimporter: Don't use "std::string" to store paths. 2 years ago
Project579 4e428dee12 Update some settings that accept paths by "std::string" to accept them as "std::filesystem::path" instead. 2 years ago
AnyOldName3 4e8e2e1c60 Eliminate &thing[0] pattern 2 years ago
elsid 73f885db0e
Cleanup includes 2 years ago