fix Visual Studio build
The change to use an extern version variable in 24d83a12
produces a
linker error with Visual Studio due to the `version.c` source file being
compiled as C instead of C++.
Rename:
`version.c` -> `version.cpp`
`version_c.h` -> `version_cpp.h`
And update all references accordingly.
Signed-off-by: Rafael Kitover <rkitover@gmail.com>
This commit is contained in:
parent
24d83a1262
commit
3e22d17fb2
|
@ -809,7 +809,7 @@ set(
|
|||
src/sdl/expr.cpp
|
||||
src/sdl/exprNode.cpp
|
||||
src/sdl/expr-lex.cpp
|
||||
src/common/version.c
|
||||
src/common/version.cpp
|
||||
)
|
||||
|
||||
set(
|
||||
|
@ -819,7 +819,7 @@ set(
|
|||
src/sdl/inputSDL.h
|
||||
src/sdl/expr.cpp.h
|
||||
src/sdl/exprNode.h
|
||||
src/common/version_c.h
|
||||
src/common/version_cpp.h
|
||||
)
|
||||
|
||||
set(
|
||||
|
|
|
@ -1,6 +0,0 @@
|
|||
#include "version_c.h"
|
||||
#include "version.h"
|
||||
|
||||
const char* vba_name_and_subversion = VBA_NAME_AND_SUBVERSION;
|
||||
|
||||
const char* vbam_version = VERSION;
|
|
@ -0,0 +1,6 @@
|
|||
#include "version_cpp.h"
|
||||
#include "version.h"
|
||||
|
||||
const char* const vba_name_and_subversion = VBA_NAME_AND_SUBVERSION;
|
||||
|
||||
const char* const vbam_version = VBAM_VERSION;
|
|
@ -1,8 +0,0 @@
|
|||
#ifndef VBAM_VERSION_C_H
|
||||
#define VBAM_VERSION_C_H
|
||||
|
||||
extern const char* vba_name_and_subversion;
|
||||
|
||||
extern const char* vbam_version;
|
||||
|
||||
#endif /* VBAM_VERSION_C_H */
|
|
@ -0,0 +1,8 @@
|
|||
#ifndef VBAM_VERSION_CPP_H
|
||||
#define VBAM_VERSION_CPP_H
|
||||
|
||||
extern const char* const vba_name_and_subversion;
|
||||
|
||||
extern const char* const vbam_version;
|
||||
|
||||
#endif /* VBAM_VERSION_CPP_H */
|
|
@ -41,7 +41,7 @@
|
|||
|
||||
#include <time.h>
|
||||
|
||||
#include "../common/version_c.h"
|
||||
#include "../common/version_cpp.h"
|
||||
|
||||
#include "SDL.h"
|
||||
|
||||
|
|
|
@ -45,9 +45,9 @@
|
|||
#define VBA_NAME_AND_VERSION VBA_NAME " " VBA_VERSION_STRING
|
||||
#define VBA_NAME_AND_SUBVERSION VBA_NAME_AND_VERSION VBA_SUBVERSION_STRING
|
||||
|
||||
#define VERSION VBA_CURRENT_VERSION VBA_SUBVERSION_STRING
|
||||
#define VBAM_VERSION VBA_CURRENT_VERSION VBA_SUBVERSION_STRING
|
||||
|
||||
#define VER_FILEVERSION_STR VERSION
|
||||
#define VER_FILEVERSION_STR VBAM_VERSION
|
||||
#define VER_FILEVERSION @WIN_VERSION@
|
||||
|
||||
#endif /* VBAM_VERSION_H */
|
||||
|
|
|
@ -668,7 +668,7 @@ set(
|
|||
cmd-evtable.h
|
||||
# icon File
|
||||
xrc/vbam.xpm
|
||||
../common/version.c
|
||||
../common/version.cpp
|
||||
)
|
||||
|
||||
if(APPLE)
|
||||
|
@ -694,7 +694,7 @@ set(
|
|||
../sdl/text.h
|
||||
# from external source with minor modifications
|
||||
widgets/wx/checkedlistctrl.h
|
||||
../common/version_c.h
|
||||
../common/version_cpp.h
|
||||
)
|
||||
|
||||
set(
|
||||
|
|
|
@ -10,7 +10,7 @@
|
|||
#include <wx/wfstream.h>
|
||||
#include <wx/msgdlg.h>
|
||||
|
||||
#include "../common/version_c.h"
|
||||
#include "../common/version_cpp.h"
|
||||
#include "../common/ConfigManager.h"
|
||||
#include "../gb/gbPrinter.h"
|
||||
#include "../gba/agbprint.h"
|
||||
|
@ -2723,8 +2723,6 @@ EVT_HANDLER(Translate, "Translations")
|
|||
wxLaunchDefaultBrowser(wxT("http://www.transifex.com/projects/p/vba-m"));
|
||||
}
|
||||
|
||||
#include "../common/version_c.h"
|
||||
|
||||
// was About
|
||||
EVT_HANDLER(wxID_ABOUT, "About...")
|
||||
{
|
||||
|
|
|
@ -5,7 +5,7 @@
|
|||
#include <wx/dcbuffer.h>
|
||||
#include <SDL_joystick.h>
|
||||
|
||||
#include "../common/version_c.h"
|
||||
#include "../common/version_cpp.h"
|
||||
#include "../common/ConfigManager.h"
|
||||
#include "../common/Patch.h"
|
||||
#include "../gb/gbPrinter.h"
|
||||
|
|
Loading…
Reference in New Issue