diff --git a/cpu/CpuIntegration.h b/cpu/CpuIntegration.h index d4a51c5..c5a933b 100644 --- a/cpu/CpuIntegration.h +++ b/cpu/CpuIntegration.h @@ -1,6 +1,12 @@ #ifndef CpuIntegration_H #define CpuIntegration_H +#include + +#ifdef __cplusplus +extern "C" { +#endif + typedef enum { M68000 = 0, M68010 = 1, @@ -41,4 +47,8 @@ extern void cpuIntegrationHardReset(void); extern void cpuIntegrationStartup(void); extern void cpuIntegrationShutdown(void); +#ifdef __cplusplus +} +#endif + #endif diff --git a/cpu/CpuModule.h b/cpu/CpuModule.h index 3b04da8..b6d1681 100644 --- a/cpu/CpuModule.h +++ b/cpu/CpuModule.h @@ -1,6 +1,11 @@ #ifndef CpuModule_H #define CpuModule_H +#ifdef __cplusplus +extern "C" { +#endif + + // This header file defines the internal interfaces of the CPU module. #define CPU_INSTRUCTION_LOGGING @@ -90,4 +95,8 @@ extern void cpuSetModel(ULO major, ULO minor); extern ULO cpuGetModelMajor(void); extern ULO cpuGetModelMinor(void); +#ifdef __cplusplus +} +#endif + #endif \ No newline at end of file diff --git a/cpu/CpuModule_Disassembler.h b/cpu/CpuModule_Disassembler.h index 5dc77f3..d2a0004 100644 --- a/cpu/CpuModule_Disassembler.h +++ b/cpu/CpuModule_Disassembler.h @@ -1,6 +1,10 @@ #ifndef CPUMODULE_DISASSEMBLER_H #define CPUMODULE_DISASSEMBLER_H +#ifdef __cplusplus +extern "C" { +#endif + extern ULO cpuDisOpcode(ULO disasm_pc, STR *saddress, STR *sdata, STR *sinstruction, STR *soperands); extern ULO cpuDisIllegal(ULO prc, ULO opc, STR *sdata, STR *sinstruction, STR *soperands); @@ -94,4 +98,8 @@ extern ULO cpuDisUnpk(ULO prc, ULO opc, STR *sdata, STR *sinstruction, STR *sope extern ULO cpuDisCallm(ULO prc, ULO opc, STR *sdata, STR *sinstruction, STR *soperands); extern ULO cpuDisRtm(ULO prc, ULO opc, STR *sdata, STR *sinstruction, STR *soperands); +#ifdef __cplusplus +} +#endif + #endif diff --git a/cpu/CpuModule_Internal.h b/cpu/CpuModule_Internal.h index 3fab76f..b7bf858 100644 --- a/cpu/CpuModule_Internal.h +++ b/cpu/CpuModule_Internal.h @@ -1,6 +1,10 @@ #ifndef CpuModule_Internal_H #define CpuModule_Internal_H +#ifdef __cplusplus +extern "C" { +#endif + // This header file defines the internal interfaces of the CPU module. extern void cpuMakeOpcodeTableForModel(void); extern void cpuCreateMulTimeTables(void); @@ -196,5 +200,9 @@ static BOOLE cpuIsZeroB(UBY v) {return v == 0;} static BOOLE cpuIsZeroW(UWO v) {return v == 0;} static BOOLE cpuIsZeroL(ULO v) {return v == 0;} +#ifdef __cplusplus +} +#endif + #endif \ No newline at end of file diff --git a/cpu/defs.h b/cpu/defs.h index ce67e95..3c55584 100644 --- a/cpu/defs.h +++ b/cpu/defs.h @@ -5,6 +5,10 @@ #include #include +#ifdef __cplusplus +extern "C" { +#endif + /* Maximum values for memory, don't change */ #define CHIPMEM 0x200000 @@ -69,4 +73,8 @@ typedef void (*buseventfunc)(void); #define FELLOWLONGVERSION "WinFellow Amiga Emulator alpha v0.5.0 - CVS" #define FELLOWNUMERICVERSION "0.5.0.0" +#ifdef __cplusplus +} +#endif + #endif diff --git a/cpu/fmem.h b/cpu/fmem.h index e5b9702..49bc927 100644 --- a/cpu/fmem.h +++ b/cpu/fmem.h @@ -1,6 +1,10 @@ #ifndef FMEM_H #define FMEM_H +#ifdef __cplusplus +extern "C" { +#endif + /* Memory access functions */ extern UBY memoryReadByte(ULO address); @@ -149,4 +153,8 @@ extern ULO potgor; extern ULO memory_fault_address; extern BOOLE memory_fault_read; +#ifdef __cplusplus +} +#endif + #endif