Describe the bug
When attempting to compile moss-transcribe.cpp on a fresh environment using a modern compiler (GCC 16.1.0 via MinGW/Ninja on Windows), the compilation fails at src/model_loader.cpp due to an unhandled template argument and undeclared types (int32_t). Modern GCC versions are much stricter with implicit header inclusions and no longer automatically pull in <cstdint> through other standard library files.
Error Log
[path/to/project]/src/config.hpp:21:17: error: 'int32_t' was not declared in this scope
21 | std::vector<int32_t> digit_token_ids; // 10 ids for "0".."9"
| ^~~~~~~
[path/to/project]/src/config.hpp:4:1: note: 'int32_t' is defined in header '<cstdint>'; this is probably fixable by adding '#include <cstdint>'
Environment
- OS: Windows 11
- Compiler: GCC 16.1.0 (MinGW-W64)
- Build System: CMake + Ninja
Steps to Reproduce
- Clone the repository recursively.
- Configure the build:
cmake -B build -G "Ninja" -DMT_BUILD_TESTS=ON
- Run the build step:
cmake --build build -j
Suggested Fix
Explicitly include <cstdint> inside src/config.hpp. Adding #include <cstdint> right below #include <vector> fixes the compilation error entirely, allowing the project to compile and run tests successfully.
Describe the bug
When attempting to compile
moss-transcribe.cppon a fresh environment using a modern compiler (GCC 16.1.0 via MinGW/Ninja on Windows), the compilation fails atsrc/model_loader.cppdue to an unhandled template argument and undeclared types (int32_t). Modern GCC versions are much stricter with implicit header inclusions and no longer automatically pull in<cstdint>through other standard library files.Error Log
Environment
Steps to Reproduce
cmake -B build -G "Ninja" -DMT_BUILD_TESTS=ONcmake --build build -jSuggested Fix
Explicitly include
<cstdint>insidesrc/config.hpp. Adding#include <cstdint>right below#include <vector>fixes the compilation error entirely, allowing the project to compile and run tests successfully.