Update MSVC2008 project files.

Fix compiler errors.
This commit is contained in:
spacy51 2008-03-08 13:59:23 +00:00
parent 3cd080a1c3
commit 1c529a52e7
10 changed files with 451 additions and 712 deletions

View File

@ -2,72 +2,25 @@ Microsoft Visual Studio Solution File, Format Version 10.00
# Visual Studio 2008
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "VisualBoyAdvance", "VBA2008.vcproj", "{6D4C5EC8-933F-4C05-A1BF-498E658576DF}"
ProjectSection(ProjectDependencies) = postProject
{DB5C12E9-BCD3-4517-8708-475C0D1D88CE} = {DB5C12E9-BCD3-4517-8708-475C0D1D88CE}
{96E945F7-0377-48DA-A5F8-1C192DE9F25F} = {96E945F7-0377-48DA-A5F8-1C192DE9F25F}
{B938FBD9-C7F9-4BF7-8C27-68865D1FA092} = {B938FBD9-C7F9-4BF7-8C27-68865D1FA092}
{7AEC599C-7C82-4F00-AA60-411E0A359CB0} = {7AEC599C-7C82-4F00-AA60-411E0A359CB0}
EndProjectSection
EndProject
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "zlib", "..\dependencies\zlib\zlib2008.vcproj", "{B938FBD9-C7F9-4BF7-8C27-68865D1FA092}"
EndProject
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "libpng", "..\dependencies\libpng\libpng2008.vcproj", "{96E945F7-0377-48DA-A5F8-1C192DE9F25F}"
ProjectSection(ProjectDependencies) = postProject
{B938FBD9-C7F9-4BF7-8C27-68865D1FA092} = {B938FBD9-C7F9-4BF7-8C27-68865D1FA092}
EndProjectSection
EndProject
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "File_Extractor", "..\dependencies\File_Extractor-0.4.2\File_Extractor2008.vcproj", "{7AEC599C-7C82-4F00-AA60-411E0A359CB0}"
ProjectSection(ProjectDependencies) = postProject
{B938FBD9-C7F9-4BF7-8C27-68865D1FA092} = {B938FBD9-C7F9-4BF7-8C27-68865D1FA092}
EndProjectSection
EndProject
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "cximage", "..\dependencies\cximage\cximage2008.vcproj", "{DB5C12E9-BCD3-4517-8708-475C0D1D88CE}"
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "File_Extractor", "..\dependencies\File_Extractor-0.4.3\File_Extractor2008.vcproj", "{7AEC599C-7C82-4F00-AA60-411E0A359CB0}"
EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
Debug|Win32 = Debug|Win32
Debug|x64 = Debug|x64
Release|Win32 = Release|Win32
Release|x64 = Release|x64
EndGlobalSection
GlobalSection(ProjectConfigurationPlatforms) = postSolution
{6D4C5EC8-933F-4C05-A1BF-498E658576DF}.Debug|Win32.ActiveCfg = Debug|Win32
{6D4C5EC8-933F-4C05-A1BF-498E658576DF}.Debug|Win32.Build.0 = Debug|Win32
{6D4C5EC8-933F-4C05-A1BF-498E658576DF}.Debug|x64.ActiveCfg = Debug|x64
{6D4C5EC8-933F-4C05-A1BF-498E658576DF}.Debug|x64.Build.0 = Debug|x64
{6D4C5EC8-933F-4C05-A1BF-498E658576DF}.Release|Win32.ActiveCfg = Release|Win32
{6D4C5EC8-933F-4C05-A1BF-498E658576DF}.Release|Win32.Build.0 = Release|Win32
{6D4C5EC8-933F-4C05-A1BF-498E658576DF}.Release|x64.ActiveCfg = Release|x64
{6D4C5EC8-933F-4C05-A1BF-498E658576DF}.Release|x64.Build.0 = Release|x64
{B938FBD9-C7F9-4BF7-8C27-68865D1FA092}.Debug|Win32.ActiveCfg = Debug|Win32
{B938FBD9-C7F9-4BF7-8C27-68865D1FA092}.Debug|Win32.Build.0 = Debug|Win32
{B938FBD9-C7F9-4BF7-8C27-68865D1FA092}.Debug|x64.ActiveCfg = Debug|x64
{B938FBD9-C7F9-4BF7-8C27-68865D1FA092}.Debug|x64.Build.0 = Debug|x64
{B938FBD9-C7F9-4BF7-8C27-68865D1FA092}.Release|Win32.ActiveCfg = Release|Win32
{B938FBD9-C7F9-4BF7-8C27-68865D1FA092}.Release|Win32.Build.0 = Release|Win32
{B938FBD9-C7F9-4BF7-8C27-68865D1FA092}.Release|x64.ActiveCfg = Release|x64
{B938FBD9-C7F9-4BF7-8C27-68865D1FA092}.Release|x64.Build.0 = Release|x64
{96E945F7-0377-48DA-A5F8-1C192DE9F25F}.Debug|Win32.ActiveCfg = Debug|Win32
{96E945F7-0377-48DA-A5F8-1C192DE9F25F}.Debug|Win32.Build.0 = Debug|Win32
{96E945F7-0377-48DA-A5F8-1C192DE9F25F}.Debug|x64.ActiveCfg = Debug|x64
{96E945F7-0377-48DA-A5F8-1C192DE9F25F}.Debug|x64.Build.0 = Debug|x64
{96E945F7-0377-48DA-A5F8-1C192DE9F25F}.Release|Win32.ActiveCfg = Release|Win32
{96E945F7-0377-48DA-A5F8-1C192DE9F25F}.Release|Win32.Build.0 = Release|Win32
{96E945F7-0377-48DA-A5F8-1C192DE9F25F}.Release|x64.ActiveCfg = Release|x64
{96E945F7-0377-48DA-A5F8-1C192DE9F25F}.Release|x64.Build.0 = Release|x64
{7AEC599C-7C82-4F00-AA60-411E0A359CB0}.Debug|Win32.ActiveCfg = Debug|Win32
{7AEC599C-7C82-4F00-AA60-411E0A359CB0}.Debug|Win32.Build.0 = Debug|Win32
{7AEC599C-7C82-4F00-AA60-411E0A359CB0}.Debug|x64.ActiveCfg = Debug|x64
{7AEC599C-7C82-4F00-AA60-411E0A359CB0}.Debug|x64.Build.0 = Debug|x64
{7AEC599C-7C82-4F00-AA60-411E0A359CB0}.Release|Win32.ActiveCfg = Release|Win32
{7AEC599C-7C82-4F00-AA60-411E0A359CB0}.Release|Win32.Build.0 = Release|Win32
{7AEC599C-7C82-4F00-AA60-411E0A359CB0}.Release|x64.ActiveCfg = Release|x64
{7AEC599C-7C82-4F00-AA60-411E0A359CB0}.Release|x64.Build.0 = Release|x64
{DB5C12E9-BCD3-4517-8708-475C0D1D88CE}.Debug|Win32.ActiveCfg = Debug|Win32
{DB5C12E9-BCD3-4517-8708-475C0D1D88CE}.Debug|Win32.Build.0 = Debug|Win32
{DB5C12E9-BCD3-4517-8708-475C0D1D88CE}.Debug|x64.ActiveCfg = Debug|Win32
{DB5C12E9-BCD3-4517-8708-475C0D1D88CE}.Release|Win32.ActiveCfg = Release|Win32
{DB5C12E9-BCD3-4517-8708-475C0D1D88CE}.Release|Win32.Build.0 = Release|Win32
{DB5C12E9-BCD3-4517-8708-475C0D1D88CE}.Release|x64.ActiveCfg = Release|Win32
EndGlobalSection
GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE

File diff suppressed because it is too large Load Diff

View File

@ -23,3 +23,24 @@ NASM: http://nasm.sourceforge.net
DirectX SDK: http://msdn2.microsoft.com/en-us/xna/aa937788.aspx
OpenAL SDK: http://openal.org/downloads.html
OpenGL files: http://www.opengl.org/registry/
zlib: http://zlib.net/
libpng: http://libpng.org/pub/png/libpng.html
#################################
# Visual C++ 2008 project files #
#################################
There are two solution files for Visual C++ 2008:
The Windows MFC GUI version project files are located in the root of the vba-m sources (VBA2008.sln).
In order to compile it, you have to compile zlib and libpng first and set your compiler's INCLUDE and LIB path accordantly.
If you also need Microsoft's DirectX SDK.
If you want to enable OpenAL sound output, install the OpenAL SDK. If you do not want it, #define NO_OAL.
Some pixel filters come with assembler code compatible to the NASM syntax. Extract NASM somewhere and add it to your PATH environment variable. All .asm files should be handled with the "nasm.rules" build rules file.
The new Qt GUI version can be found in /project/vc2008.
It uses the qmake file in /project/qmake and can be compiled with the Visual C++ 2008 Express Edition.
Qt has to be compiled with the Microsoft compiler first, in order to use it.
The dependencies folder is not yet necessary.

168
nasm.rules Normal file
View File

@ -0,0 +1,168 @@
<?xml version="1.0" encoding="utf-8"?>
<VisualStudioToolFile
Name="Netwide Assembler"
Version="8,00"
>
<Rules>
<CustomBuildRule
Name="NASM"
DisplayName="Netwide Assembler"
CommandLine="nasm.exe [AllOptions] [AdditionalOptions] -- [inputs]"
Outputs="[$ObjectFileName]"
FileExtensions="*.asm"
ExecutionDescription="Assembling..."
>
<Properties>
<StringProperty
Name="ObjectFileName"
DisplayName="Object File Name"
Description="Specifies the name of the output object file. (-o [file])"
Switch="-o &quot;[value]&quot;"
DefaultValue="$(IntDir)\$(InputName).obj"
/>
<EnumProperty
Name="Optimization"
DisplayName="Branch Offset Optimization"
Description="Optimize branch offsets. (-O[digit])"
>
<Values>
<EnumValue
Value="0"
Switch="-O0"
DisplayName="Do not optimize (-O0)"
/>
<EnumValue
Value="1"
Switch="-O1"
DisplayName="Optimize (-O1)"
/>
</Values>
</EnumProperty>
<StringProperty
Name="IncludePath"
DisplayName="Include Path"
Description="Adds a pathname to the include file path. (-I[path])"
Switch="-I&quot;[value]&quot;"
Delimited="true"
/>
<EnumProperty
Name="ObjectFileFormat"
DisplayName="Object File Format"
Description="Set the object file format. (-f [format])"
DefaultValue="8"
>
<Values>
<EnumValue
Value="0"
Switch="-f bin"
DisplayName="Flat-form binary files (e.g. DOS .COM, .SYS)"
/>
<EnumValue
Value="1"
Switch="-f aout"
DisplayName="Linux a.out object files"
/>
<EnumValue
Value="2"
Switch="-f aoutb"
DisplayName="NetBSD/FreeBSD a.out object files"
/>
<EnumValue
Value="3"
Switch="-f coff"
DisplayName="COFF (i386) object files (e.g. DJGPP for DOS)"
/>
<EnumValue
Value="4"
Switch="-f elf32"
DisplayName="ELF32 (i386) object files (e.g. Linux)"
/>
<EnumValue
Value="5"
Switch="-f elf64"
DisplayName="ELF64 (x86_64) object files (e.g. Linux)"
/>
<EnumValue
Value="6"
Switch="-f as86"
DisplayName="Linux as86 (bin86 version 0.3) object files"
/>
<EnumValue
Value="7"
Switch="-f obj"
DisplayName="MS-DOS 16-bit/32-bit OMF object files"
/>
<EnumValue
Value="8"
Switch="-f win32"
DisplayName="Microsoft Win32 (i386) object files"
/>
<EnumValue
Value="9"
Switch="-f win64"
DisplayName="Microsoft Win64 (x86-64) object files"
/>
<EnumValue
Value="10"
Switch="-f rdf"
DisplayName="Relocatable Dynamic Object File Format v2.0"
/>
<EnumValue
Value="11"
Switch="-f ieee"
DisplayName="IEEE-695 (LADsoft variant) object file format"
/>
<EnumValue
Value="12"
Switch="-f macho"
DisplayName="NeXTstep/OpenStep/Rhapsody/Darwin/MacOS X object files"
/>
</Values>
</EnumProperty>
<EnumProperty
Name="ErrorReportingFormat"
DisplayName="Error Reporting Format"
Description="Specifies error reporting format. (-X[format])"
DefaultValue="1"
>
<Values>
<EnumValue
Value="0"
Switch="-Xgnu"
DisplayName="GNU"
/>
<EnumValue
Value="1"
Switch="-Xvc"
DisplayName="Microsoft Visual C++"
/>
</Values>
</EnumProperty>
<BooleanProperty
Name="TreatWarningsAsErrors"
DisplayName="Treat Warnings As Errors"
Description="Returns an error code if warnings are generated. (-w+error)"
Switch="-w+error"
/>
<BooleanProperty
Name="DisableOrphanLabelsWarning"
DisplayName="Disable Orphan Labels Warning"
Description="Disable warning when labels alone on lines without trailing &apos;:&apos; are found. (-w-orphan-labels)"
Switch="-w-orphan-labels"
/>
<StringProperty
Name="PreprocessorDefinitions"
DisplayName="Preprocessor Definitions"
Description="Defines a text macro with the given name. (-D[symbol][=value])"
Switch="-D[value]"
/>
<BooleanProperty
Name="GenerateDebugInfo"
DisplayName="Generate Debug Info"
Description="Generate debug information in selected format. (-g)"
Switch="-g"
/>
</Properties>
</CustomBuildRule>
</Rules>
</VisualStudioToolFile>

View File

@ -444,8 +444,6 @@ void MainWnd::OnClose()
{
emulating = false;
CWnd::OnClose();
delete this;
}
bool MainWnd::FileRun()
@ -767,7 +765,7 @@ void MainWnd::OnSizing(UINT fwSide, LPRECT pRect)
0 );
MENUBARINFO mbi;
mbi.cbSize = sizeof(MENUBARINFO);
this->GetMenuBarInfo( OBJID_MENU, 0, &mbi );
GetMenuBarInfo( this->GetSafeHwnd(), OBJID_MENU, 0, &mbi );
const LONG menuHeight = mbi.rcBar.bottom - mbi.rcBar.top + 1;
// +1 because of that white line, wherever it comes from
const LONG width = size.right - size.left;

View File

@ -26,6 +26,8 @@
// MainWnd.h : header file
//
#include "stdafx.h"
/////////////////////////////////////////////////////////////////////////////
// MainWnd window

View File

@ -36,14 +36,14 @@
#include "BIOSDialog.h"
#include "../System.h"
#include "../agbprint.h"
#include "../GBA.h"
#include "../agb/agbprint.h"
#include "../agb/GBA.h"
#include "../Globals.h"
#include "../Sound.h"
#include "../gb/GB.h"
#include "../gb/gbGlobals.h"
#include "../gb/gbPrinter.h"
#include "../Link.h"
#include "../dmg/GB.h"
#include "../dmg/gbGlobals.h"
#include "../dmg/gbPrinter.h"
#include "../agb/GBALink.h"
#include <tchar.h>
extern int emulating;

View File

@ -261,7 +261,7 @@ bool OpenGLDisplay::initialize()
case VIDEO_640x480:
case VIDEO_800x600:
case VIDEO_1024x768:
case VIDEO_1280x960:
case VIDEO_1280x1024:
case VIDEO_OTHER:
{
if( theApp.fullScreenStretch ) {

View File

@ -1909,7 +1909,7 @@ void VBA::updateWindowSize(int value)
// content of old seperate 'winCheckMenuBarInfo' function:
MENUBARINFO info;
info.cbSize = sizeof(MENUBARINFO);
theApp.m_pMainWnd->GetMenuBarInfo(OBJID_MENU, 0, &info);
GetMenuBarInfo( theApp.m_pMainWnd->GetSafeHwnd(), OBJID_MENU, 0, &info );
int menuHeight = GetSystemMetrics(SM_CYMENU); // includes white line
if((info.rcBar.bottom - info.rcBar.top) > menuHeight)
{

View File

@ -1,7 +1,7 @@
// -*- C++ -*-
// VisualBoyAdvance - Nintendo Gameboy/GameboyAdvance (TM) emulator.
// Copyright (C) 1999-2003 Forgotten
// Copyright (C) 2004 Forgotten and the VBA development team
// Copyright (C) 2007-2008 VBA-M development team
// This program is free software; you can redistribute it and/or modify
// it under the terms of the GNU General Public License as published by
@ -17,26 +17,18 @@
// along with this program; if not, write to the Free Software Foundation,
// Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
// stdafx.h : include file for standard system include files,
// or project specific include files that are used frequently, but
// are changed infrequently
//
#if !defined(AFX_STDAFX_H__A7126ECB_A234_4116_A7D0_BE50547E87F8__INCLUDED_)
#define AFX_STDAFX_H__A7126ECB_A234_4116_A7D0_BE50547E87F8__INCLUDED_
#if _MSC_VER > 1000
#pragma once
#endif // _MSC_VER > 1000
// Exclude rarely-used stuff from Windows headers like
// Cryptography, DDE, RPC, Shell, and Windows Sockets
#define WIN32_LEAN_AND_MEAN
// Insert your headers here
//#define WIN32_LEAN_AND_MEAN // Exclude rarely-used stuff from Windows headers
// Target for Windows 2000
#define WINVER 0x0500
#define _WIN32_WINNT 0x0500
// Target for Windows 2000 (Required by GetMenuBar and other functions)
#define NTDDI_VERSION NTDDI_WIN2K // new
#define _WIN32_WINNT 0x0500 // old
//#define WINVER 0x0500
// Enable STRICT type checking
#define STRICT
@ -44,10 +36,3 @@
#include <afxcmn.h>
#include <afxdlgs.h>
#include "VBA.h"
// TODO: reference additional headers your program requires here
//{{AFX_INSERT_LOCATION}}
// Microsoft Visual C++ will insert additional declarations immediately before the previous line.
#endif // !defined(AFX_STDAFX_H__A7126ECB_A234_4116_A7D0_BE50547E87F8__INCLUDED_)