Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Source/Common/Platform: Explicitly include <cstdint>
GCC 15 will no longer include <cstdint> by default, resulting in build failures in projects that do not explicitly include it. Errors: Source/Common/Platform/NMR_EncryptionHeader.cpp: In member function ‘size_t NMR::CEncryptionHeader::readFrom(NMR::PImportStream)’: Source/Common/Platform/NMR_EncryptionHeader.cpp:35:52: error: ‘uint64_t’ was not declared in this scope 35 | if (header.Header.Length.length < (uint64_t) headerSize) | ^~~~~~~~ Source/Common/Platform/NMR_EncryptionHeader.cpp:12:1: note: ‘uint64_t’ is defined in header ‘<cstdint>’; this is probably fixable by adding ‘#include <cstdint>’ 11 | #include <cstring> +++ |+#include <cstdint> 12 | Source/Common/Platform/NMR_ImportStream_Unique_Memory.cpp: In member function ‘virtual const NMR::nfByte* NMR::CImportStream_Unique_Memory::getAt(NMR::nfUint64)’: Source/Common/Platform/NMR_ImportStream_Unique_Memory.cpp:128:35: error: ‘uint64_t’ was not declared in this scope 128 | if (nPosition >= (uint64_t) m_Buffer.size()) | ^~~~~~~~ Source/Common/Platform/NMR_ImportStream_Unique_Memory.cpp:37:1: note: ‘uint64_t’ is defined in header ‘<cstdint>’; this is probably fixable by adding ‘#include <cstdint>’ 36 | #include "Common/NMR_Exception_Windows.h" +++ |+#include <cstdint> 37 | Test results: Test project lib3mf/build Start 1: Test_CPP_Bindings 1/1 Test #1: Test_CPP_Bindings ................ Passed 0.39 sec 100% tests passed, 0 tests failed out of 1 Total Test time (real) = 0.39 sec Gentoo bug: https://bugs.gentoo.org/937423 See-also: https://gcc.gnu.org/pipermail/gcc-cvs/2024-August/407124.html Signed-off-by: Christopher Fore <[email protected]>
- Loading branch information