Bochs/bochs-testing/plugin-test/test7-win32dll/main.h
Bryce Denney d52e44afdb - test7-win32dll began life as an exact copy of test6-ltdlopen. This
revision is exactly the same as the present versin from test6-ltdlopen.
- added: Makefile.in README main.cc main.h module1.cc module2.cc
2002-10-14 20:34:13 +00:00

26 lines
646 B
C

#if defined(WIN32) || defined(__CYGWIN__)
# ifdef MAIN_DLL_EXPORT
# ifdef DLL_EXPORT
# warning I will export DLL symbols for MODULE1
# define MAINAPI(type) __declspec(dllexport) type
# endif
# else
# warning I will import DLL symbols for MODULE1
# define MAINAPI(type) __declspec(dllimport) type
# endif
#endif
#ifndef MAINAPI
# warning No DLL import/export is needed
# define MAINAPI(type) type
#endif
typedef void (*modload_func)(void);
MAINAPI(extern const char *) version_string;
MAINAPI(extern int) register_module (const char *name);
extern "C" {
// this prevents C++ name mangling
void module_init ();
};