Fix Linux build

This commit is contained in:
Tillmann Karras 2016-07-30 23:58:02 +01:00
parent 1252bd653d
commit 61eddbd1fa
3 changed files with 4 additions and 3 deletions

View file

@ -11,6 +11,7 @@
#include "common/string_util.h"
#else
#include <cstdlib>
#include <cstring>
#include <sys/mman.h>
#endif

View file

@ -82,7 +82,7 @@ static CPUCaps Detect() {
caps.vendor = CPUVendor::OTHER;
// Set reasonable default brand string even if brand string not available
strcpy_s(caps.cpu_string, sizeof(caps.cpu_string), caps.brand_string);
strncpy(caps.cpu_string, caps.brand_string, sizeof(caps.cpu_string));
// Detect family and other miscellaneous features
if (max_std_fn >= 1) {

View file

@ -231,12 +231,12 @@ void FuzzJitThumb(const size_t instruction_count, const size_t instructions_to_e
printf("\nInterp Write Records:\n");
for (auto& record : interp_write_records) {
printf("%zu [%x] = %llx\n", record.size, record.address, record.data);
printf("%zu [%x] = %" PRIu64 "\n", record.size, record.address, record.data);
}
printf("\nJIT Write Records:\n");
for (auto& record : jit_write_records) {
printf("%zu [%x] = %llx\n", record.size, record.address, record.data);
printf("%zu [%x] = %" PRIu64 "\n", record.size, record.address, record.data);
}
Dynarmic::IR::Block ir_block = Dynarmic::Arm::Translate({0, true, false, 0}, MemoryRead32);