mirror of https://github.com/openXC7/prjxray.git
lib/memory_mapped_file.cc used POSIX open/fstat/mmap, which does not exist under mingw-w64, blocking a native Windows build of the prjxray tools. Add an #ifdef _WIN32 branch using CreateFileA/CreateFileMappingA/MapViewOfFile; the POSIX path is byte-for-byte unchanged. One behavioural note: a zero-length file cannot be mapped on Windows, so that case returns an object with nullptr data and zero size to preserve the "file exists" contract of InitWithFile. |
||
|---|---|---|
| .. | ||
| include/prjxray | ||
| test_data | ||
| xilinx | ||
| CMakeLists.txt | ||
| big_endian_span_test.cc | ||
| bit_ops_test.cc | ||
| database.cc | ||
| memory_mapped_file.cc | ||
| memory_mapped_file_test.cc | ||
| segbits_file_reader.cc | ||
| segbits_file_reader_test.cc | ||