shuffles magic mush...... trunk MSVC2010 buildfix

This commit is contained in:
squall-leonhart 2012-01-20 22:03:27 +00:00
parent 113f7c1f81
commit 2908c33111
66 changed files with 27425 additions and 27377 deletions

View File

@ -192,18 +192,17 @@ SET(SRC_FEX
fex/7z_C/7zBuf.c fex/7z_C/7zBuf.c
fex/7z_C/7zCrc.c fex/7z_C/7zCrc.c
fex/7z_C/7zCrcOpt.c fex/7z_C/7zCrcOpt.c
fex/7z_C/7zDecode.c fex/7z_C/7zDec.c
fex/7z_C/7zExtract.c
fex/7z_C/7zHeader.c
fex/7z_C/7zIn.c fex/7z_C/7zIn.c
fex/7z_C/7zItem.c
fex/7z_C/7zStream.c fex/7z_C/7zStream.c
fex/7z_C/Bcj2.c fex/7z_C/Bcj2.c
fex/7z_C/Bra.c
fex/7z_C/Bra86.c fex/7z_C/Bra86.c
fex/7z_C/Bra.c
fex/7z_C/CpuArch.c fex/7z_C/CpuArch.c
fex/7z_C/LzmaDec.c
fex/7z_C/Lzma2Dec.c fex/7z_C/Lzma2Dec.c
fex/7z_C/LzmaDec.c
fex/7z_C/Ppmd7.c
fex/7z_C/Ppmd7Dec.c
fex/fex/Binary_Extractor.cpp fex/fex/Binary_Extractor.cpp
fex/fex/blargg_common.cpp fex/fex/blargg_common.cpp
fex/fex/blargg_errors.cpp fex/fex/blargg_errors.cpp

View File

@ -74,7 +74,7 @@ static void MyCPUID(UInt32 function, UInt32 *a, UInt32 *b, UInt32 *c, UInt32 *d)
// Mac cross-compile compiler: // Mac cross-compile compiler:
// can't find register in class 'BREG' while reloading 'asm' // can't find register in class 'BREG' while reloading 'asm'
// so use class 'r' and register var binding // so use class 'r' register var binding
register _b asm("%bx"); register _b asm("%bx");
__asm__ __volatile__ ( __asm__ __volatile__ (
"cpuid" "cpuid"

View File

@ -165,22 +165,7 @@ static void LzmaDec_UpdateWithUncompressed(CLzmaDec *p, const Byte *src, SizeT s
p->processedPos += (UInt32)size; p->processedPos += (UInt32)size;
} }
static void LzmaDec_InitDicAndState(CLzmaDec *p, Bool initDic, Bool initState);
void LzmaDec_InitDicAndState(CLzmaDec *p, Bool initDic, Bool initState)
{
p->needFlush = 1;
p->remainLen = 0;
p->tempBufSize = 0;
if (initDic)
{
p->processedPos = 0;
p->checkDicSize = 0;
p->needInitState = 1;
}
if (initState)
p->needInitState = 1;
}
SRes Lzma2Dec_DecodeToDic(CLzma2Dec *p, SizeT dicLimit, SRes Lzma2Dec_DecodeToDic(CLzma2Dec *p, SizeT dicLimit,
const Byte *src, SizeT *srcLen, ELzmaFinishMode finishMode, ELzmaStatus *status) const Byte *src, SizeT *srcLen, ELzmaFinishMode finishMode, ELzmaStatus *status)

View File

@ -682,7 +682,6 @@ static void LzmaDec_InitRc(CLzmaDec *p, const Byte *data)
p->needFlush = 0; p->needFlush = 0;
} }
static
void LzmaDec_InitDicAndState(CLzmaDec *p, Bool initDic, Bool initState) void LzmaDec_InitDicAndState(CLzmaDec *p, Bool initDic, Bool initState)
{ {
p->needFlush = 1; p->needFlush = 1;

View File

@ -1,4 +1,4 @@
LZMA SDK 4.65 LZMA SDK 9.20
------------- -------------
LZMA SDK provides the documentation, samples, header files, libraries, LZMA SDK provides the documentation, samples, header files, libraries,
@ -20,6 +20,10 @@ LICENSE
LZMA SDK is written and placed in the public domain by Igor Pavlov. LZMA SDK is written and placed in the public domain by Igor Pavlov.
Some code in LZMA SDK is based on public domain code from another developers:
1) PPMd var.H (2001): Dmitry Shkarin
2) SHA-256: Wei Dai (Crypto++ library)
LZMA SDK Contents LZMA SDK Contents
----------------- -----------------
@ -33,7 +37,7 @@ LZMA SDK includes:
UNIX/Linux version UNIX/Linux version
------------------ ------------------
To compile C++ version of file->file LZMA encoding, go to directory To compile C++ version of file->file LZMA encoding, go to directory
C++/7zip/Compress/LZMA_Alone CPP/7zip/Bundles/LzmaCon
and call make to recompile it: and call make to recompile it:
make -f makefile.gcc clean all make -f makefile.gcc clean all
@ -49,6 +53,7 @@ lzma.txt - LZMA SDK description (this file)
7zC.txt - 7z ANSI-C Decoder description 7zC.txt - 7z ANSI-C Decoder description
methods.txt - Compression method IDs for .7z methods.txt - Compression method IDs for .7z
lzma.exe - Compiled file->file LZMA encoder/decoder for Windows lzma.exe - Compiled file->file LZMA encoder/decoder for Windows
7zr.exe - 7-Zip with 7z/lzma/xz support.
history.txt - history of the LZMA SDK history.txt - history of the LZMA SDK
@ -86,12 +91,6 @@ CPP/ -- CPP files
Compress - files related to compression/decompression Compress - files related to compression/decompression
Copy - Copy coder
RangeCoder - Range Coder (special code of compression/decompression)
LZMA - LZMA compression/decompression on C++
LZMA_Alone - file->file LZMA compression/decompression
Branch - Filters for x86, IA-64, ARM, ARM-Thumb, PowerPC and SPARC code
Archive - files related to archiving Archive - files related to archiving
Common - common files for archive handling Common - common files for archive handling
@ -100,6 +99,7 @@ CPP/ -- CPP files
Bundles - Modules that are bundles of other modules Bundles - Modules that are bundles of other modules
Alone7z - 7zr.exe: Standalone version of 7z.exe that supports only 7z/LZMA/BCJ/BCJ2 Alone7z - 7zr.exe: Standalone version of 7z.exe that supports only 7z/LZMA/BCJ/BCJ2
LzmaCon - lzma.exe: LZMA compression/decompression
Format7zR - 7zr.dll: Reduced version of 7za.dll: extracting/compressing to 7z/LZMA/BCJ/BCJ2 Format7zR - 7zr.dll: Reduced version of 7za.dll: extracting/compressing to 7z/LZMA/BCJ/BCJ2
Format7zExtractR - 7zxr.dll: Reduced version of 7zxa.dll: extracting from 7z/LZMA/BCJ/BCJ2. Format7zExtractR - 7zxr.dll: Reduced version of 7zxa.dll: extracting from 7z/LZMA/BCJ/BCJ2.
@ -527,7 +527,8 @@ static ISzAlloc g_Alloc = { SzAlloc, SzFree };
LzmaEnc_Destroy(enc, &g_Alloc, &g_Alloc); LzmaEnc_Destroy(enc, &g_Alloc, &g_Alloc);
If callback function return some error code, LzmaEnc_Encode also returns that code. If callback function return some error code, LzmaEnc_Encode also returns that code
or it can return the code like SZ_ERROR_READ, SZ_ERROR_WRITE or SZ_ERROR_PROGRESS.
Single-call RAM->RAM Compression Single-call RAM->RAM Compression
@ -549,8 +550,8 @@ Return code:
LZMA Defines Defines
------------ -------
_LZMA_SIZE_OPT - Enable some optimizations in LZMA Decoder to get smaller executable code. _LZMA_SIZE_OPT - Enable some optimizations in LZMA Decoder to get smaller executable code.
@ -562,6 +563,9 @@ _LZMA_UINT32_IS_ULONG - Define it if int is 16-bit on your compiler and long is
_LZMA_NO_SYSTEM_SIZE_T - Define it if you don't want to use size_t type. _LZMA_NO_SYSTEM_SIZE_T - Define it if you don't want to use size_t type.
_7ZIP_PPMD_SUPPPORT - Define it if you don't want to support PPMD method in AMSI-C .7z decoder.
C++ LZMA Encoder/Decoder C++ LZMA Encoder/Decoder
~~~~~~~~~~~~~~~~~~~~~~~~ ~~~~~~~~~~~~~~~~~~~~~~~~
C++ LZMA code use COM-like interfaces. So if you want to use it, C++ LZMA code use COM-like interfaces. So if you want to use it,

View File

@ -18,12 +18,10 @@
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" /> <Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration"> <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration">
<ConfigurationType>StaticLibrary</ConfigurationType> <ConfigurationType>StaticLibrary</ConfigurationType>
<CharacterSet>NotSet</CharacterSet>
<WholeProgramOptimization>true</WholeProgramOptimization> <WholeProgramOptimization>true</WholeProgramOptimization>
</PropertyGroup> </PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="Configuration"> <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="Configuration">
<ConfigurationType>StaticLibrary</ConfigurationType> <ConfigurationType>StaticLibrary</ConfigurationType>
<CharacterSet>NotSet</CharacterSet>
</PropertyGroup> </PropertyGroup>
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" /> <Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
<ImportGroup Label="ExtensionSettings"> <ImportGroup Label="ExtensionSettings">
@ -37,10 +35,6 @@
<PropertyGroup Label="UserMacros" /> <PropertyGroup Label="UserMacros" />
<PropertyGroup> <PropertyGroup>
<_ProjectFileVersion>10.0.30319.1</_ProjectFileVersion> <_ProjectFileVersion>10.0.30319.1</_ProjectFileVersion>
<OutDir Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">$(ProjectDir)$(Platform)\$(Configuration)\</OutDir>
<IntDir Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">$(ProjectDir)$(Platform)\$(Configuration)_temp\</IntDir>
<OutDir Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">$(ProjectDir)$(Platform)\$(Configuration)\</OutDir>
<IntDir Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">$(ProjectDir)$(Platform)\$(Configuration)_temp\</IntDir>
<CodeAnalysisRuleSet Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">AllRules.ruleset</CodeAnalysisRuleSet> <CodeAnalysisRuleSet Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">AllRules.ruleset</CodeAnalysisRuleSet>
<CodeAnalysisRules Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" /> <CodeAnalysisRules Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" />
<CodeAnalysisRuleAssemblies Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" /> <CodeAnalysisRuleAssemblies Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" />
@ -49,24 +43,19 @@
<CodeAnalysisRuleAssemblies Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" /> <CodeAnalysisRuleAssemblies Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" />
</PropertyGroup> </PropertyGroup>
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'"> <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
<BuildLog> <BuildLog />
<Path>$(IntDir)$(ProjectName)_BuildLog.htm</Path>
</BuildLog>
<ClCompile> <ClCompile>
<Optimization>Disabled</Optimization> <Optimization>Disabled</Optimization>
<AdditionalIncludeDirectories>$(ProjectDir)..\..\dependencies\zlib;$(ProjectDir);%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
<PreprocessorDefinitions>_CRT_SECURE_NO_WARNINGS;%(PreprocessorDefinitions)</PreprocessorDefinitions> <PreprocessorDefinitions>_CRT_SECURE_NO_WARNINGS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<MinimalRebuild>true</MinimalRebuild> <MinimalRebuild>true</MinimalRebuild>
<BasicRuntimeChecks>EnableFastChecks</BasicRuntimeChecks> <BasicRuntimeChecks>EnableFastChecks</BasicRuntimeChecks>
<RuntimeLibrary>MultiThreadedDebug</RuntimeLibrary> <RuntimeLibrary>MultiThreadedDebug</RuntimeLibrary>
<ProgramDataBaseFileName>$(IntDir)$(ProjectName).pdb</ProgramDataBaseFileName>
<DebugInformationFormat>EditAndContinue</DebugInformationFormat> <DebugInformationFormat>EditAndContinue</DebugInformationFormat>
<AdditionalIncludeDirectories>$(ProjectDir)..\..\dependencies\zlib;$(ProjectDir);$(ProjectDir)7z_C;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
</ClCompile> </ClCompile>
</ItemDefinitionGroup> </ItemDefinitionGroup>
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'"> <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
<BuildLog> <BuildLog />
<Path>$(IntDir)$(ProjectName)_BuildLog.htm</Path>
</BuildLog>
<ClCompile> <ClCompile>
<AdditionalIncludeDirectories>$(ProjectDir)..\..\dependencies\zlib;$(ProjectDir);%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories> <AdditionalIncludeDirectories>$(ProjectDir)..\..\dependencies\zlib;$(ProjectDir);%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
<PreprocessorDefinitions>_CRT_SECURE_NO_WARNINGS;%(PreprocessorDefinitions)</PreprocessorDefinitions> <PreprocessorDefinitions>_CRT_SECURE_NO_WARNINGS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
@ -80,7 +69,7 @@
<StringPooling>true</StringPooling> <StringPooling>true</StringPooling>
<FunctionLevelLinking>true</FunctionLevelLinking> <FunctionLevelLinking>true</FunctionLevelLinking>
<FloatingPointModel>Fast</FloatingPointModel> <FloatingPointModel>Fast</FloatingPointModel>
<MultiProcessorCompilation>true</MultiProcessorCompilation> <BufferSecurityCheck>false</BufferSecurityCheck>
</ClCompile> </ClCompile>
</ItemDefinitionGroup> </ItemDefinitionGroup>
<ItemGroup> <ItemGroup>
@ -88,11 +77,8 @@
<ClCompile Include="7z_C\7zBuf.c" /> <ClCompile Include="7z_C\7zBuf.c" />
<ClCompile Include="7z_C\7zCrc.c" /> <ClCompile Include="7z_C\7zCrc.c" />
<ClCompile Include="7z_C\7zCrcOpt.c" /> <ClCompile Include="7z_C\7zCrcOpt.c" />
<ClCompile Include="7z_C\7zDecode.c" /> <ClCompile Include="7z_C\7zDec.c" />
<ClCompile Include="7z_C\7zExtract.c" />
<ClCompile Include="7z_C\7zHeader.c" />
<ClCompile Include="7z_C\7zIn.c" /> <ClCompile Include="7z_C\7zIn.c" />
<ClCompile Include="7z_C\7zItem.c" />
<ClCompile Include="7z_C\7zStream.c" /> <ClCompile Include="7z_C\7zStream.c" />
<ClCompile Include="7z_C\Bcj2.c" /> <ClCompile Include="7z_C\Bcj2.c" />
<ClCompile Include="7z_C\Bra.c" /> <ClCompile Include="7z_C\Bra.c" />
@ -100,6 +86,8 @@
<ClCompile Include="7z_C\CpuArch.c" /> <ClCompile Include="7z_C\CpuArch.c" />
<ClCompile Include="7z_C\Lzma2Dec.c" /> <ClCompile Include="7z_C\Lzma2Dec.c" />
<ClCompile Include="7z_C\LzmaDec.c" /> <ClCompile Include="7z_C\LzmaDec.c" />
<ClCompile Include="7z_C\Ppmd7.c" />
<ClCompile Include="7z_C\Ppmd7Dec.c" />
<ClCompile Include="fex\Binary_Extractor.cpp" /> <ClCompile Include="fex\Binary_Extractor.cpp" />
<ClCompile Include="fex\blargg_common.cpp" /> <ClCompile Include="fex\blargg_common.cpp" />
<ClCompile Include="fex\blargg_errors.cpp" /> <ClCompile Include="fex\blargg_errors.cpp" />
@ -114,18 +102,17 @@
<ClCompile Include="fex\Zlib_Inflater.cpp" /> <ClCompile Include="fex\Zlib_Inflater.cpp" />
</ItemGroup> </ItemGroup>
<ItemGroup> <ItemGroup>
<ClInclude Include="7z_C\7z.h" />
<ClInclude Include="7z_C\7zAlloc.h" /> <ClInclude Include="7z_C\7zAlloc.h" />
<ClInclude Include="7z_C\7zBuf.h" /> <ClInclude Include="7z_C\7zBuf.h" />
<ClInclude Include="7z_C\7zCrc.h" /> <ClInclude Include="7z_C\7zCrc.h" />
<ClInclude Include="7z_C\7zExtract.h" />
<ClInclude Include="7z_C\7zHeader.h" />
<ClInclude Include="7z_C\7zIn.h" />
<ClInclude Include="7z_C\7zItem.h" />
<ClInclude Include="7z_C\Bcj2.h" /> <ClInclude Include="7z_C\Bcj2.h" />
<ClInclude Include="7z_C\Bra.h" /> <ClInclude Include="7z_C\Bra.h" />
<ClInclude Include="7z_C\CpuArch.h" /> <ClInclude Include="7z_C\CpuArch.h" />
<ClInclude Include="7z_C\Lzma2Dec.h" /> <ClInclude Include="7z_C\Lzma2Dec.h" />
<ClInclude Include="7z_C\LzmaDec.h" /> <ClInclude Include="7z_C\LzmaDec.h" />
<ClInclude Include="7z_C\Ppmd.h" />
<ClInclude Include="7z_C\Ppmd7.h" />
<ClInclude Include="7z_C\Types.h" /> <ClInclude Include="7z_C\Types.h" />
<ClInclude Include="fex\Binary_Extractor.h" /> <ClInclude Include="fex\Binary_Extractor.h" />
<ClInclude Include="fex\blargg_common.h" /> <ClInclude Include="fex\blargg_common.h" />
@ -153,7 +140,7 @@
<None Include="readme.txt" /> <None Include="readme.txt" />
</ItemGroup> </ItemGroup>
<ItemGroup> <ItemGroup>
<ProjectReference Include="..\zlib\project\vs2010\zlib.vcxproj"> <ProjectReference Include="..\..\dependencies\zlib\project\vs2010\zlib.vcxproj">
<Project>{3e03c179-8251-46e4-81f4-466f114bac63}</Project> <Project>{3e03c179-8251-46e4-81f4-466f114bac63}</Project>
</ProjectReference> </ProjectReference>
</ItemGroup> </ItemGroup>

View File

@ -1,12 +1,12 @@
<?xml version="1.0" encoding="utf-8"?> <?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003"> <Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<ItemGroup> <ItemGroup>
<Filter Include="7z">
<UniqueIdentifier>{4f3646e4-ddc5-4030-9ba1-7629a947e5db}</UniqueIdentifier>
</Filter>
<Filter Include="fex"> <Filter Include="fex">
<UniqueIdentifier>{40ba751f-4ce2-4162-85a2-0c2ae2f33ae2}</UniqueIdentifier> <UniqueIdentifier>{40ba751f-4ce2-4162-85a2-0c2ae2f33ae2}</UniqueIdentifier>
</Filter> </Filter>
<Filter Include="7z_C">
<UniqueIdentifier>{4f3646e4-ddc5-4030-9ba1-7629a947e5db}</UniqueIdentifier>
</Filter>
</ItemGroup> </ItemGroup>
<ItemGroup> <ItemGroup>
<ClCompile Include="fex\Binary_Extractor.cpp"> <ClCompile Include="fex\Binary_Extractor.cpp">
@ -46,52 +46,49 @@
<Filter>fex</Filter> <Filter>fex</Filter>
</ClCompile> </ClCompile>
<ClCompile Include="7z_C\7zAlloc.c"> <ClCompile Include="7z_C\7zAlloc.c">
<Filter>7z</Filter> <Filter>7z_C</Filter>
</ClCompile> </ClCompile>
<ClCompile Include="7z_C\7zBuf.c"> <ClCompile Include="7z_C\7zBuf.c">
<Filter>7z</Filter> <Filter>7z_C</Filter>
</ClCompile> </ClCompile>
<ClCompile Include="7z_C\7zCrc.c"> <ClCompile Include="7z_C\7zCrc.c">
<Filter>7z</Filter> <Filter>7z_C</Filter>
</ClCompile>
<ClCompile Include="7z_C\7zExtract.c">
<Filter>7z</Filter>
</ClCompile>
<ClCompile Include="7z_C\7zHeader.c">
<Filter>7z</Filter>
</ClCompile>
<ClCompile Include="7z_C\7zIn.c">
<Filter>7z</Filter>
</ClCompile>
<ClCompile Include="7z_C\7zItem.c">
<Filter>7z</Filter>
</ClCompile>
<ClCompile Include="7z_C\7zStream.c">
<Filter>7z</Filter>
</ClCompile>
<ClCompile Include="7z_C\Bcj2.c">
<Filter>7z</Filter>
</ClCompile>
<ClCompile Include="7z_C\Bra86.c">
<Filter>7z</Filter>
</ClCompile>
<ClCompile Include="7z_C\LzmaDec.c">
<Filter>7z</Filter>
</ClCompile>
<ClCompile Include="7z_C\CpuArch.c">
<Filter>7z</Filter>
</ClCompile> </ClCompile>
<ClCompile Include="7z_C\7zCrcOpt.c"> <ClCompile Include="7z_C\7zCrcOpt.c">
<Filter>7z</Filter> <Filter>7z_C</Filter>
</ClCompile> </ClCompile>
<ClCompile Include="7z_C\Lzma2Dec.c"> <ClCompile Include="7z_C\7zDec.c">
<Filter>7z</Filter> <Filter>7z_C</Filter>
</ClCompile>
<ClCompile Include="7z_C\7zIn.c">
<Filter>7z_C</Filter>
</ClCompile>
<ClCompile Include="7z_C\7zStream.c">
<Filter>7z_C</Filter>
</ClCompile>
<ClCompile Include="7z_C\Bcj2.c">
<Filter>7z_C</Filter>
</ClCompile> </ClCompile>
<ClCompile Include="7z_C\Bra.c"> <ClCompile Include="7z_C\Bra.c">
<Filter>7z</Filter> <Filter>7z_C</Filter>
</ClCompile> </ClCompile>
<ClCompile Include="7z_C\7zDecode.c"> <ClCompile Include="7z_C\Bra86.c">
<Filter>7z</Filter> <Filter>7z_C</Filter>
</ClCompile>
<ClCompile Include="7z_C\CpuArch.c">
<Filter>7z_C</Filter>
</ClCompile>
<ClCompile Include="7z_C\Lzma2Dec.c">
<Filter>7z_C</Filter>
</ClCompile>
<ClCompile Include="7z_C\LzmaDec.c">
<Filter>7z_C</Filter>
</ClCompile>
<ClCompile Include="7z_C\Ppmd7.c">
<Filter>7z_C</Filter>
</ClCompile>
<ClCompile Include="7z_C\Ppmd7Dec.c">
<Filter>7z_C</Filter>
</ClCompile> </ClCompile>
</ItemGroup> </ItemGroup>
<ItemGroup> <ItemGroup>
@ -140,44 +137,41 @@
<ClInclude Include="fex\Zlib_Inflater.h"> <ClInclude Include="fex\Zlib_Inflater.h">
<Filter>fex</Filter> <Filter>fex</Filter>
</ClInclude> </ClInclude>
<ClInclude Include="7z_C\7z.h">
<Filter>7z_C</Filter>
</ClInclude>
<ClInclude Include="7z_C\7zAlloc.h"> <ClInclude Include="7z_C\7zAlloc.h">
<Filter>7z</Filter> <Filter>7z_C</Filter>
</ClInclude> </ClInclude>
<ClInclude Include="7z_C\7zBuf.h"> <ClInclude Include="7z_C\7zBuf.h">
<Filter>7z</Filter> <Filter>7z_C</Filter>
</ClInclude> </ClInclude>
<ClInclude Include="7z_C\7zCrc.h"> <ClInclude Include="7z_C\7zCrc.h">
<Filter>7z</Filter> <Filter>7z_C</Filter>
</ClInclude>
<ClInclude Include="7z_C\7zExtract.h">
<Filter>7z</Filter>
</ClInclude>
<ClInclude Include="7z_C\7zHeader.h">
<Filter>7z</Filter>
</ClInclude>
<ClInclude Include="7z_C\7zIn.h">
<Filter>7z</Filter>
</ClInclude>
<ClInclude Include="7z_C\7zItem.h">
<Filter>7z</Filter>
</ClInclude> </ClInclude>
<ClInclude Include="7z_C\Bcj2.h"> <ClInclude Include="7z_C\Bcj2.h">
<Filter>7z</Filter> <Filter>7z_C</Filter>
</ClInclude> </ClInclude>
<ClInclude Include="7z_C\Bra.h"> <ClInclude Include="7z_C\Bra.h">
<Filter>7z</Filter> <Filter>7z_C</Filter>
</ClInclude> </ClInclude>
<ClInclude Include="7z_C\CpuArch.h"> <ClInclude Include="7z_C\CpuArch.h">
<Filter>7z</Filter> <Filter>7z_C</Filter>
</ClInclude>
<ClInclude Include="7z_C\LzmaDec.h">
<Filter>7z</Filter>
</ClInclude>
<ClInclude Include="7z_C\Types.h">
<Filter>7z</Filter>
</ClInclude> </ClInclude>
<ClInclude Include="7z_C\Lzma2Dec.h"> <ClInclude Include="7z_C\Lzma2Dec.h">
<Filter>7z</Filter> <Filter>7z_C</Filter>
</ClInclude>
<ClInclude Include="7z_C\LzmaDec.h">
<Filter>7z_C</Filter>
</ClInclude>
<ClInclude Include="7z_C\Ppmd7.h">
<Filter>7z_C</Filter>
</ClInclude>
<ClInclude Include="7z_C\Ppmd.h">
<Filter>7z_C</Filter>
</ClInclude>
<ClInclude Include="7z_C\Types.h">
<Filter>7z_C</Filter>
</ClInclude> </ClInclude>
</ItemGroup> </ItemGroup>
<ItemGroup> <ItemGroup>
@ -187,10 +181,10 @@
<None Include="license.txt" /> <None Include="license.txt" />
<None Include="readme.txt" /> <None Include="readme.txt" />
<None Include="7z_C\7zC.txt"> <None Include="7z_C\7zC.txt">
<Filter>7z</Filter> <Filter>7z_C</Filter>
</None> </None>
<None Include="7z_C\lzma.txt"> <None Include="7z_C\lzma.txt">
<Filter>7z</Filter> <Filter>7z_C</Filter>
</None> </None>
</ItemGroup> </ItemGroup>
</Project> </Project>

View File

@ -30,10 +30,10 @@ Global
{823DDC98-42D5-4A38-88CF-9DC06C788AE4}.Debug|Win32.Build.0 = Debug|Win32 {823DDC98-42D5-4A38-88CF-9DC06C788AE4}.Debug|Win32.Build.0 = Debug|Win32
{823DDC98-42D5-4A38-88CF-9DC06C788AE4}.Release|Win32.ActiveCfg = Release|Win32 {823DDC98-42D5-4A38-88CF-9DC06C788AE4}.Release|Win32.ActiveCfg = Release|Win32
{823DDC98-42D5-4A38-88CF-9DC06C788AE4}.Release|Win32.Build.0 = Release|Win32 {823DDC98-42D5-4A38-88CF-9DC06C788AE4}.Release|Win32.Build.0 = Release|Win32
{0008960E-E0DD-41A6-8265-00B31DDB4C21}.Debug|Win32.ActiveCfg = LIB Debug|Win32 {0008960E-E0DD-41A6-8265-00B31DDB4C21}.Debug|Win32.ActiveCfg = Debug|Win32
{0008960E-E0DD-41A6-8265-00B31DDB4C21}.Debug|Win32.Build.0 = LIB Debug|Win32 {0008960E-E0DD-41A6-8265-00B31DDB4C21}.Debug|Win32.Build.0 = Debug|Win32
{0008960E-E0DD-41A6-8265-00B31DDB4C21}.Release|Win32.ActiveCfg = LIB Release|Win32 {0008960E-E0DD-41A6-8265-00B31DDB4C21}.Release|Win32.ActiveCfg = Release|Win32
{0008960E-E0DD-41A6-8265-00B31DDB4C21}.Release|Win32.Build.0 = LIB Release|Win32 {0008960E-E0DD-41A6-8265-00B31DDB4C21}.Release|Win32.Build.0 = Release|Win32
{7AEC599C-7C82-4F00-AA60-411E0A359CB0}.Debug|Win32.ActiveCfg = Debug|Win32 {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|Win32.Build.0 = Debug|Win32
{7AEC599C-7C82-4F00-AA60-411E0A359CB0}.Release|Win32.ActiveCfg = Release|Win32 {7AEC599C-7C82-4F00-AA60-411E0A359CB0}.Release|Win32.ActiveCfg = Release|Win32

Binary file not shown.

View File

@ -1,4 +1,4 @@
<?xml version="1.0" encoding="utf-8"?> <?xml version="1.0" encoding="utf-8"?>
<Project DefaultTargets="Build" ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003"> <Project DefaultTargets="Build" ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<ItemGroup Label="ProjectConfigurations"> <ItemGroup Label="ProjectConfigurations">
<ProjectConfiguration Include="Debug|Win32"> <ProjectConfiguration Include="Debug|Win32">
@ -9,10 +9,6 @@
<Configuration>Release</Configuration> <Configuration>Release</Configuration>
<Platform>Win32</Platform> <Platform>Win32</Platform>
</ProjectConfiguration> </ProjectConfiguration>
<ProjectConfiguration Include="Template|Win32">
<Configuration>Template</Configuration>
<Platform>Win32</Platform>
</ProjectConfiguration>
</ItemGroup> </ItemGroup>
<PropertyGroup Label="Globals"> <PropertyGroup Label="Globals">
<ProjectName>VisualBoyAdvance-M</ProjectName> <ProjectName>VisualBoyAdvance-M</ProjectName>
@ -22,16 +18,9 @@
</PropertyGroup> </PropertyGroup>
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" /> <Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration"> <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration">
<ConfigurationType>Application</ConfigurationType>
<UseOfMfc>Static</UseOfMfc>
<CharacterSet>NotSet</CharacterSet>
<WholeProgramOptimization>true</WholeProgramOptimization> <WholeProgramOptimization>true</WholeProgramOptimization>
</PropertyGroup> </PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="Configuration"> <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="Configuration" />
<ConfigurationType>Application</ConfigurationType>
<UseOfMfc>Static</UseOfMfc>
<CharacterSet>NotSet</CharacterSet>
</PropertyGroup>
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" /> <Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
<ImportGroup Label="ExtensionSettings"> <ImportGroup Label="ExtensionSettings">
<Import Project="nasm.props" /> <Import Project="nasm.props" />
@ -47,15 +36,6 @@
<PropertyGroup Label="UserMacros" /> <PropertyGroup Label="UserMacros" />
<PropertyGroup> <PropertyGroup>
<_ProjectFileVersion>10.0.30319.1</_ProjectFileVersion> <_ProjectFileVersion>10.0.30319.1</_ProjectFileVersion>
<OutDir Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">$(ProjectDir)$(Platform)\$(Configuration)\</OutDir>
<IntDir Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">$(ProjectDir)$(Platform)\$(Configuration)_temp\</IntDir>
<PreBuildEventUseInBuild Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">true</PreBuildEventUseInBuild>
<PreLinkEventUseInBuild Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">false</PreLinkEventUseInBuild>
<LinkIncremental Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">true</LinkIncremental>
<PostBuildEventUseInBuild Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">false</PostBuildEventUseInBuild>
<OutDir Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">$(ProjectDir)$(Platform)\$(Configuration)\</OutDir>
<IntDir Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">$(ProjectDir)$(Platform)\$(Configuration)_temp\</IntDir>
<PreBuildEventUseInBuild Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">true</PreBuildEventUseInBuild>
<LinkIncremental Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" /> <LinkIncremental Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" />
<CodeAnalysisRuleSet Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">AllRules.ruleset</CodeAnalysisRuleSet> <CodeAnalysisRuleSet Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">AllRules.ruleset</CodeAnalysisRuleSet>
<CodeAnalysisRules Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" /> <CodeAnalysisRules Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" />
@ -63,20 +43,17 @@
<CodeAnalysisRuleSet Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">AllRules.ruleset</CodeAnalysisRuleSet> <CodeAnalysisRuleSet Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">AllRules.ruleset</CodeAnalysisRuleSet>
<CodeAnalysisRules Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" /> <CodeAnalysisRules Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" />
<CodeAnalysisRuleAssemblies Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" /> <CodeAnalysisRuleAssemblies Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" />
<CodeAnalysisRuleSet Condition="'$(Configuration)|$(Platform)'=='Template|Win32'">AllRules.ruleset</CodeAnalysisRuleSet>
<CodeAnalysisRules Condition="'$(Configuration)|$(Platform)'=='Template|Win32'" />
<CodeAnalysisRuleAssemblies Condition="'$(Configuration)|$(Platform)'=='Template|Win32'" />
<LibraryPath Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">C:\Program Files (x86)\OpenAL 1.1 SDK\libs\Win32;C:\Program Files (x86)\Microsoft DirectX SDK (June 2010)\Lib\x86;$(LibraryPath)</LibraryPath> <LibraryPath Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">C:\Program Files (x86)\OpenAL 1.1 SDK\libs\Win32;C:\Program Files (x86)\Microsoft DirectX SDK (June 2010)\Lib\x86;$(LibraryPath)</LibraryPath>
<LibraryPath Condition="'$(Configuration)|$(Platform)'=='Template|Win32'">C:\Program Files (x86)\OpenAL 1.1 SDK\libs\Win32;C:\Program Files (x86)\Microsoft DirectX SDK (June 2010)\Lib\x86;$(LibraryPath)</LibraryPath>
<IncludePath Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">C:\Program Files (x86)\OpenAL 1.1 SDK\include;C:\Program Files (x86)\Microsoft DirectX SDK (June 2010)\Include;$(IncludePath)</IncludePath> <IncludePath Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">C:\Program Files (x86)\OpenAL 1.1 SDK\include;C:\Program Files (x86)\Microsoft DirectX SDK (June 2010)\Include;$(IncludePath)</IncludePath>
<IncludePath Condition="'$(Configuration)|$(Platform)'=='Template|Win32'">C:\Program Files (x86)\OpenAL 1.1 SDK\include;C:\Program Files (x86)\Microsoft DirectX SDK (June 2010)\Include;$(IncludePath)</IncludePath>
<IncludePath Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">%programfiles%\OpenAL 1.1 SDK\include;$(DXSDK_DIR)\Include;$(IncludePath)</IncludePath> <IncludePath Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">%programfiles%\OpenAL 1.1 SDK\include;$(DXSDK_DIR)\Include;$(IncludePath)</IncludePath>
<LibraryPath Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">%programfiles%\OpenAL 1.1 SDK\libs\Win32;$(DXSDK_DIR)\lib\x86;$(LibraryPath)</LibraryPath> <LibraryPath Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">%programfiles%\OpenAL 1.1 SDK\libs\Win32;$(DXSDK_DIR)\lib\x86;$(LibraryPath)</LibraryPath>
<OutDir Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">$(ProjectDir)$(Platform)\$(Configuration)\</OutDir>
<IntDir Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">$(ProjectDir)$(Platform)\$(Configuration)_temp\</IntDir>
<OutDir Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">$(ProjectDir)$(Platform)\$(Configuration)\</OutDir>
<IntDir Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">$(ProjectDir)$(Platform)\$(Configuration)_temp\</IntDir>
</PropertyGroup> </PropertyGroup>
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'"> <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
<BuildLog> <BuildLog />
<Path>$(IntDir)$(ProjectName)_BuildLog.htm</Path>
</BuildLog>
<PreBuildEvent> <PreBuildEvent>
<Command>SubWCRev.exe ..\.. svnrev_template.h ..\..\src\svnrev.h</Command> <Command>SubWCRev.exe ..\.. svnrev_template.h ..\..\src\svnrev.h</Command>
</PreBuildEvent> </PreBuildEvent>
@ -93,43 +70,35 @@
<BasicRuntimeChecks>EnableFastChecks</BasicRuntimeChecks> <BasicRuntimeChecks>EnableFastChecks</BasicRuntimeChecks>
<SmallerTypeCheck>false</SmallerTypeCheck> <SmallerTypeCheck>false</SmallerTypeCheck>
<RuntimeLibrary>MultiThreadedDebug</RuntimeLibrary> <RuntimeLibrary>MultiThreadedDebug</RuntimeLibrary>
<StructMemberAlignment>Default</StructMemberAlignment>
<BufferSecurityCheck>false</BufferSecurityCheck> <BufferSecurityCheck>false</BufferSecurityCheck>
<FunctionLevelLinking>false</FunctionLevelLinking>
<EnableEnhancedInstructionSet>NotSet</EnableEnhancedInstructionSet> <EnableEnhancedInstructionSet>NotSet</EnableEnhancedInstructionSet>
<TreatWChar_tAsBuiltInType>false</TreatWChar_tAsBuiltInType>
<PrecompiledHeader> <PrecompiledHeader>
</PrecompiledHeader> </PrecompiledHeader>
<ProgramDataBaseFileName>$(IntDir)$(ProjectName).pdb</ProgramDataBaseFileName>
<WarningLevel>Level3</WarningLevel> <WarningLevel>Level3</WarningLevel>
<DebugInformationFormat>EditAndContinue</DebugInformationFormat> <DebugInformationFormat>EditAndContinue</DebugInformationFormat>
<FunctionLevelLinking>true</FunctionLevelLinking>
</ClCompile> </ClCompile>
<ResourceCompile> <ResourceCompile />
<PreprocessorDefinitions>_DEBUG;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<Culture>0x0409</Culture>
<AdditionalIncludeDirectories>%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
</ResourceCompile>
<Link> <Link>
<AdditionalDependencies>nafxcwd.lib;libcmtd.lib;zlibd.lib;libpngd.lib;%(AdditionalDependencies)</AdditionalDependencies>
<OutputFile>$(OutDir)VisualBoyAdvance-M.exe</OutputFile>
<Version> <Version>
</Version> </Version>
<AdditionalLibraryDirectories>..\..\..\dependencies\libpng\project\vs2010\Win32\LIB Debug;..\..\..\dependencies\zlib\project\vs2010\Win32\Debug;%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
<AdditionalManifestDependencies>%(AdditionalManifestDependencies)</AdditionalManifestDependencies>
<IgnoreSpecificDefaultLibraries>nafxcwd.lib;libcmtd.lib;%(IgnoreSpecificDefaultLibraries)</IgnoreSpecificDefaultLibraries>
<GenerateDebugInformation>true</GenerateDebugInformation>
<SubSystem>Windows</SubSystem> <SubSystem>Windows</SubSystem>
<OptimizeReferences>false</OptimizeReferences> <OptimizeReferences>false</OptimizeReferences>
<EnableCOMDATFolding>false</EnableCOMDATFolding> <EnableCOMDATFolding>false</EnableCOMDATFolding>
<DataExecutionPrevention> <DataExecutionPrevention>
</DataExecutionPrevention> </DataExecutionPrevention>
<MinimumRequiredVersion>5.0</MinimumRequiredVersion> <MinimumRequiredVersion>5.0</MinimumRequiredVersion>
<GenerateDebugInformation>true</GenerateDebugInformation>
<AdditionalDependencies>nafxcwd.lib;libcmtd.lib;%(AdditionalDependencies)</AdditionalDependencies>
<IgnoreSpecificDefaultLibraries>nafxcwd.lib;libcmtd.lib;%(IgnoreSpecificDefaultLibraries)</IgnoreSpecificDefaultLibraries>
<RandomizedBaseAddress>false</RandomizedBaseAddress>
</Link> </Link>
</ItemDefinitionGroup>
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
<BuildLog> <BuildLog>
<Path>$(IntDir)$(ProjectName)_BuildLog.htm</Path> <Path>$(IntDir)$(ProjectName)_BuildLog.htm</Path>
</BuildLog> </BuildLog>
</ItemDefinitionGroup>
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
<BuildLog />
<PreBuildEvent> <PreBuildEvent>
<Command>SubWCRev.exe ..\.. svnrev_template.h ..\..\src\svnrev.h</Command> <Command>SubWCRev.exe ..\.. svnrev_template.h ..\..\src\svnrev.h</Command>
</PreBuildEvent> </PreBuildEvent>
@ -143,7 +112,6 @@
/MP %(AdditionalOptions)</AdditionalOptions> /MP %(AdditionalOptions)</AdditionalOptions>
<InlineFunctionExpansion>AnySuitable</InlineFunctionExpansion> <InlineFunctionExpansion>AnySuitable</InlineFunctionExpansion>
<FavorSizeOrSpeed>Speed</FavorSizeOrSpeed> <FavorSizeOrSpeed>Speed</FavorSizeOrSpeed>
<WholeProgramOptimization>true</WholeProgramOptimization>
<AdditionalIncludeDirectories>..\..\fex;..\..\..\dependencies\libpng;..\..\..\dependencies\msvc;..\..\..\dependencies\SFML\include;..\..\..\dependencies\zlib;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories> <AdditionalIncludeDirectories>..\..\fex;..\..\..\dependencies\libpng;..\..\..\dependencies\msvc;..\..\..\dependencies\SFML\include;..\..\..\dependencies\zlib;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
<PreprocessorDefinitions>WIN32;_WINDOWS;NDEBUG;GBA_LOGGING;OEMRESOURCE;MMX;ASM;FINAL_VERSION;BKPT_SUPPORT;_CRT_SECURE_NO_DEPRECATE;HAS_FILE_EXTRACTOR;%(PreprocessorDefinitions)</PreprocessorDefinitions> <PreprocessorDefinitions>WIN32;_WINDOWS;NDEBUG;GBA_LOGGING;OEMRESOURCE;MMX;ASM;FINAL_VERSION;BKPT_SUPPORT;_CRT_SECURE_NO_DEPRECATE;HAS_FILE_EXTRACTOR;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<RuntimeLibrary>MultiThreaded</RuntimeLibrary> <RuntimeLibrary>MultiThreaded</RuntimeLibrary>
@ -151,36 +119,37 @@
<FloatingPointModel>Fast</FloatingPointModel> <FloatingPointModel>Fast</FloatingPointModel>
<PrecompiledHeader> <PrecompiledHeader>
</PrecompiledHeader> </PrecompiledHeader>
<MultiProcessorCompilation>true</MultiProcessorCompilation>
<IntrinsicFunctions>true</IntrinsicFunctions> <IntrinsicFunctions>true</IntrinsicFunctions>
<EnableFiberSafeOptimizations>true</EnableFiberSafeOptimizations> <EnableFiberSafeOptimizations>true</EnableFiberSafeOptimizations>
<OmitFramePointers>true</OmitFramePointers> <OmitFramePointers>true</OmitFramePointers>
<StringPooling>true</StringPooling> <StringPooling>true</StringPooling>
<FunctionLevelLinking>true</FunctionLevelLinking>
<WarningLevel>Level3</WarningLevel> <WarningLevel>Level3</WarningLevel>
<FunctionLevelLinking>true</FunctionLevelLinking>
<MultiProcessorCompilation>
</MultiProcessorCompilation>
</ClCompile> </ClCompile>
<ResourceCompile> <ResourceCompile />
<PreprocessorDefinitions>NDEBUG;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<AdditionalIncludeDirectories>%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
</ResourceCompile>
<Link> <Link>
<AdditionalDependencies>nafxcw.lib;libcmt.lib;zlib.lib;libpng.lib;%(AdditionalDependencies)</AdditionalDependencies> <AdditionalDependencies>nafxcw.lib;libcmt.lib;%(AdditionalDependencies)</AdditionalDependencies>
<Version> <Version>
</Version> </Version>
<AdditionalLibraryDirectories>..\..\..\dependencies\libpng\project\vs2010\Win32\LIB Release;..\..\..\dependencies\zlib\project\vs2010\Win32\Release;%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories> <IgnoreSpecificDefaultLibraries>nafxcw.lib;libcmt.lib;%(IgnoreSpecificDefaultLibraries)</IgnoreSpecificDefaultLibraries>
<AdditionalManifestDependencies>%(AdditionalManifestDependencies)</AdditionalManifestDependencies>
<IgnoreSpecificDefaultLibraries>nafxcw.lib;libcmt.lib;libcmtd.lib;%(IgnoreSpecificDefaultLibraries)</IgnoreSpecificDefaultLibraries>
<AssemblyDebug>false</AssemblyDebug>
<SubSystem>Windows</SubSystem> <SubSystem>Windows</SubSystem>
<MinimumRequiredVersion>5.0</MinimumRequiredVersion> <MinimumRequiredVersion>5.0</MinimumRequiredVersion>
<OptimizeReferences>true</OptimizeReferences> <OptimizeReferences>true</OptimizeReferences>
<EnableCOMDATFolding>true</EnableCOMDATFolding> <EnableCOMDATFolding>true</EnableCOMDATFolding>
<GenerateDebugInformation>true</GenerateDebugInformation> <GenerateDebugInformation>true</GenerateDebugInformation>
<AssemblyDebug>
</AssemblyDebug>
<RandomizedBaseAddress>false</RandomizedBaseAddress> <RandomizedBaseAddress>false</RandomizedBaseAddress>
</Link> </Link>
<NASM> <NASM>
<Optimization>1</Optimization> <Optimization>1</Optimization>
</NASM> </NASM>
<BuildLog />
<BuildLog>
<Path>$(IntDir)$(ProjectName)_BuildLog.htm</Path>
</BuildLog>
</ItemDefinitionGroup> </ItemDefinitionGroup>
<ItemGroup> <ItemGroup>
<ClInclude Include="..\..\src\win32\resource.h" /> <ClInclude Include="..\..\src\win32\resource.h" />
@ -693,13 +662,13 @@
<Project>{823ddc98-42d5-4a38-88cf-9dc06c788ae4}</Project> <Project>{823ddc98-42d5-4a38-88cf-9dc06c788ae4}</Project>
<ReferenceOutputAssembly>false</ReferenceOutputAssembly> <ReferenceOutputAssembly>false</ReferenceOutputAssembly>
</ProjectReference> </ProjectReference>
<ProjectReference Include="..\..\..\dependencies\zlib\project\vs2010\zlib.vcxproj">
<Project>{3e03c179-8251-46e4-81f4-466f114bac63}</Project>
</ProjectReference>
<ProjectReference Include="..\..\fex\File_Extractor2010.vcxproj"> <ProjectReference Include="..\..\fex\File_Extractor2010.vcxproj">
<Project>{7aec599c-7c82-4f00-aa60-411e0a359cb0}</Project> <Project>{7aec599c-7c82-4f00-aa60-411e0a359cb0}</Project>
<ReferenceOutputAssembly>false</ReferenceOutputAssembly> <ReferenceOutputAssembly>false</ReferenceOutputAssembly>
</ProjectReference> </ProjectReference>
<ProjectReference Include="..\..\..\dependencies\zlib\project\vs2010\zlib.vcxproj">
<Project>{3e03c179-8251-46e4-81f4-466f114bac63}</Project>
</ProjectReference>
</ItemGroup> </ItemGroup>
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" /> <Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
<ImportGroup Label="ExtensionTargets"> <ImportGroup Label="ExtensionTargets">

View File

@ -436,17 +436,12 @@ static bool utilIsImage(const char *file)
} }
#ifdef WIN32 #ifdef WIN32
#include <windows.h> #include <Windows.h>
#endif #endif
IMAGE_TYPE utilFindType(const char *file) IMAGE_TYPE utilFindType(const char *file)
{ {
char buffer [2048]; char buffer [2048];
utilFindType(file, buffer);
}
IMAGE_TYPE utilFindType(const char *file, char (&buffer)[2048])
{
#ifdef WIN32 #ifdef WIN32
DWORD dwNum = MultiByteToWideChar (CP_ACP, 0, file, -1, NULL, 0); DWORD dwNum = MultiByteToWideChar (CP_ACP, 0, file, -1, NULL, 0);
wchar_t *pwText; wchar_t *pwText;

View File

@ -23,7 +23,6 @@ bool utilIsGBImage(const char *);
bool utilIsGzipFile(const char *); bool utilIsGzipFile(const char *);
void utilStripDoubleExtension(const char *, char *); void utilStripDoubleExtension(const char *, char *);
IMAGE_TYPE utilFindType(const char *); IMAGE_TYPE utilFindType(const char *);
IMAGE_TYPE utilFindType(const char *, char (&)[2048]);
u8 *utilLoad(const char *, bool (*)(const char*), u8 *, int &); u8 *utilLoad(const char *, bool (*)(const char*), u8 *, int &);
void utilPutDword(u8 *, u32); void utilPutDword(u8 *, u32);

View File

@ -700,13 +700,15 @@ long ZEXPORT memtell(file)
z_off_t ZEXPORT memgzseek(gzFile file, z_off_t off, int whence) z_off_t ZEXPORT memgzseek(gzFile file, z_off_t off, int whence)
{ {
char buf[80];
if(whence != SEEK_CUR) { if(whence != SEEK_CUR) {
fputs("FIXME: memgzio does not support seeking\n", stderr); fputs("FIXME: memgzio does not support seeking\n", stderr);
exit(1); exit(1);
} }
// this is inefficient, but the best I can do without actually reading // this is inefficient, but the best I can do without actually reading
// the above code // the above code
char buf[80];
while(off > 0) { while(off > 0) {
int r = memgzread(file, buf, off > 80 ? 80 : off); int r = memgzread(file, buf, off > 80 ? 80 : off);
if(r <= 0) if(r <= 0)

View File

@ -27,11 +27,11 @@ bool genericflashcardEnable = false;
int gbCgbMode = 0; int gbCgbMode = 0;
u16 gbColorFilter[32768]; u16 gbColorFilter[32768];
bool gbColorOption = false; int gbColorOption = 0;
int gbPaletteOption = 0; int gbPaletteOption = 0;
int gbEmulatorType = 0; int gbEmulatorType = 0;
bool gbBorderOn = true; int gbBorderOn = 0;
bool gbBorderAutomatic = false; int gbBorderAutomatic = 0;
int gbBorderLineSkip = 160; int gbBorderLineSkip = 160;
int gbBorderRowSkip = 0; int gbBorderRowSkip = 0;
int gbBorderColumnSkip = 0; int gbBorderColumnSkip = 0;

View File

@ -25,11 +25,11 @@ extern u8 *gbMemoryMap[16];
extern int gbFrameSkip; extern int gbFrameSkip;
extern u16 gbColorFilter[32768]; extern u16 gbColorFilter[32768];
extern bool gbColorOption; extern int gbColorOption;
extern int gbPaletteOption; extern int gbPaletteOption;
extern int gbEmulatorType; extern int gbEmulatorType;
extern bool gbBorderOn; extern int gbBorderOn;
extern bool gbBorderAutomatic; extern int gbBorderAutomatic;
extern int gbCgbMode; extern int gbCgbMode;
extern int gbSgbMode; extern int gbSgbMode;
extern int gbWindowLine; extern int gbWindowLine;

View File

@ -298,7 +298,7 @@ static void count(u32 opcode, int cond_res)
#define EMIT0(op) #op"; " #define EMIT0(op) #op"; "
#define EMIT1(op,arg) #op" "arg"; " #define EMIT1(op,arg) #op" "arg"; "
#define EMIT2(op,src,dest) #op" "src", "dest"; " #define EMIT2(op,src,dest) #op" "src", "dest"; "
#define CONST(val) "$"#val #define KONST(val) "$"#val
#define ASMVAR(cvar) ASMVAR2 (__USER_LABEL_PREFIX__, cvar) #define ASMVAR(cvar) ASMVAR2 (__USER_LABEL_PREFIX__, cvar)
#define ASMVAR2(prefix,cvar) STRING (prefix) cvar #define ASMVAR2(prefix,cvar) STRING (prefix) cvar
#define STRING(x) #x #define STRING(x) #x
@ -331,7 +331,7 @@ static void count(u32 opcode, int cond_res)
#define EMIT0(op) __asm op #define EMIT0(op) __asm op
#define EMIT1(op,arg) __asm op arg #define EMIT1(op,arg) __asm op arg
#define EMIT2(op,src,dest) __asm op dest, src #define EMIT2(op,src,dest) __asm op dest, src
#define CONST(val) val #define KONST(val) val
#define VAR(var) var #define VAR(var) var
#define VARL(var) dword ptr var #define VARL(var) dword ptr var
#define REGREF1(index) reg[index] #define REGREF1(index) reg[index]
@ -350,15 +350,15 @@ static void count(u32 opcode, int cond_res)
// Helper macros for loading value / shift count // Helper macros for loading value / shift count
#define VALUE_LOAD_IMM \ #define VALUE_LOAD_IMM \
EMIT2(and, CONST(0x0F), eax) \ EMIT2(and, KONST(0x0F), eax) \
EMIT2(mov, REGREF2(eax,4), eax) \ EMIT2(mov, REGREF2(eax,4), eax) \
EMIT2(shr, CONST(7), ecx) \ EMIT2(shr, KONST(7), ecx) \
EMIT2(and, CONST(0x1F), ecx) EMIT2(and, KONST(0x1F), ecx)
#define VALUE_LOAD_REG \ #define VALUE_LOAD_REG \
EMIT2(and, CONST(0x0F), eax) \ EMIT2(and, KONST(0x0F), eax) \
EMIT2(mov, REGREF2(eax,4), eax) \ EMIT2(mov, REGREF2(eax,4), eax) \
EMIT2(movzx, ch, ecx) \ EMIT2(movzx, ch, ecx) \
EMIT2(and, CONST(0x0F), ecx) \ EMIT2(and, KONST(0x0F), ecx) \
EMIT2(mov, REGREF2(ecx,4), ecx) EMIT2(mov, REGREF2(ecx,4), ecx)
// Helper macros for setting flags // Helper macros for setting flags
@ -382,13 +382,13 @@ static void count(u32 opcode, int cond_res)
ALU_HEADER \ ALU_HEADER \
LOAD_C_FLAG \ LOAD_C_FLAG \
EMIT2(mov, ecx, edx) \ EMIT2(mov, ecx, edx) \
EMIT2(shr, CONST(14), edx) \ EMIT2(shr, KONST(14), edx) \
EMIT2(mov, ecx, eax) \ EMIT2(mov, ecx, eax) \
EMIT2(mov, ecx, esi) \ EMIT2(mov, ecx, esi) \
EMIT2(shr, CONST(10), esi) \ EMIT2(shr, KONST(10), esi) \
EMIT2(and, CONST(0x3C), edx) \ EMIT2(and, KONST(0x3C), edx) \
EMIT2(mov, REGREF1(edx), edx) \ EMIT2(mov, REGREF1(edx), edx) \
EMIT2(and, CONST(0x3C), esi) EMIT2(and, KONST(0x3C), esi)
#define LOAD_C_FLAG_YES EMIT2(mov, VAR(C_FLAG), bl) #define LOAD_C_FLAG_YES EMIT2(mov, VAR(C_FLAG), bl)
#define LOAD_C_FLAG_NO /*nothing*/ #define LOAD_C_FLAG_NO /*nothing*/
@ -416,14 +416,14 @@ static void count(u32 opcode, int cond_res)
VALUE_LOAD_REG \ VALUE_LOAD_REG \
EMIT2(test, cl, cl) \ EMIT2(test, cl, cl) \
EMIT1(jz, LABELREF(0,f)) \ EMIT1(jz, LABELREF(0,f)) \
EMIT2(cmp, CONST(0x20), cl) \ EMIT2(cmp, KONST(0x20), cl) \
EMIT1(je, LABELREF(1,f)) \ EMIT1(je, LABELREF(1,f)) \
EMIT1(ja, LABELREF(2,f)) \ EMIT1(ja, LABELREF(2,f)) \
EMIT2(shl, cl, eax) \ EMIT2(shl, cl, eax) \
EMIT1(setc, bl) \ EMIT1(setc, bl) \
EMIT1(jmp, LABELREF(0,f)) \ EMIT1(jmp, LABELREF(0,f)) \
LABEL(1) \ LABEL(1) \
EMIT2(test, CONST(1), al) \ EMIT2(test, KONST(1), al) \
EMIT1(setnz, bl) \ EMIT1(setnz, bl) \
EMIT2(xor, eax, eax) \ EMIT2(xor, eax, eax) \
EMIT1(jmp, LABELREF(0,f)) \ EMIT1(jmp, LABELREF(0,f)) \
@ -433,7 +433,7 @@ static void count(u32 opcode, int cond_res)
LABEL(0) LABEL(0)
#define VALUE_LSL_REG_NC \ #define VALUE_LSL_REG_NC \
VALUE_LOAD_REG \ VALUE_LOAD_REG \
EMIT2(cmp, CONST(0x20), cl) \ EMIT2(cmp, KONST(0x20), cl) \
EMIT1(jae, LABELREF(1,f)) \ EMIT1(jae, LABELREF(1,f)) \
EMIT2(shl, cl, eax) \ EMIT2(shl, cl, eax) \
EMIT1(jmp, LABELREF(0,f)) \ EMIT1(jmp, LABELREF(0,f)) \
@ -467,7 +467,7 @@ static void count(u32 opcode, int cond_res)
VALUE_LOAD_REG \ VALUE_LOAD_REG \
EMIT2(test, cl, cl) \ EMIT2(test, cl, cl) \
EMIT1(jz, LABELREF(0,f)) \ EMIT1(jz, LABELREF(0,f)) \
EMIT2(cmp, CONST(0x20), cl) \ EMIT2(cmp, KONST(0x20), cl) \
EMIT1(je, LABELREF(1,f)) \ EMIT1(je, LABELREF(1,f)) \
EMIT1(ja, LABELREF(2,f)) \ EMIT1(ja, LABELREF(2,f)) \
EMIT2(shr, cl, eax) \ EMIT2(shr, cl, eax) \
@ -484,7 +484,7 @@ static void count(u32 opcode, int cond_res)
LABEL(0) LABEL(0)
#define VALUE_LSR_REG_NC \ #define VALUE_LSR_REG_NC \
VALUE_LOAD_REG \ VALUE_LOAD_REG \
EMIT2(cmp, CONST(0x20), cl) \ EMIT2(cmp, KONST(0x20), cl) \
EMIT1(jae, LABELREF(1,f)) \ EMIT1(jae, LABELREF(1,f)) \
EMIT2(shr, cl, eax) \ EMIT2(shr, cl, eax) \
EMIT1(jmp, LABELREF(0,f)) \ EMIT1(jmp, LABELREF(0,f)) \
@ -500,7 +500,7 @@ static void count(u32 opcode, int cond_res)
EMIT1(setc, bl) \ EMIT1(setc, bl) \
EMIT1(jmp, LABELREF(0,f)) \ EMIT1(jmp, LABELREF(0,f)) \
LABEL(1) \ LABEL(1) \
EMIT2(sar, CONST(31), eax) \ EMIT2(sar, KONST(31), eax) \
EMIT1(sets, bl) \ EMIT1(sets, bl) \
LABEL(0) LABEL(0)
#define VALUE_ASR_IMM_NC \ #define VALUE_ASR_IMM_NC \
@ -509,7 +509,7 @@ static void count(u32 opcode, int cond_res)
EMIT2(sar, cl, eax) \ EMIT2(sar, cl, eax) \
EMIT1(jmp, LABELREF(0,f)) \ EMIT1(jmp, LABELREF(0,f)) \
LABEL(1) \ LABEL(1) \
EMIT2(sar, CONST(31), eax) \ EMIT2(sar, KONST(31), eax) \
LABEL(0) LABEL(0)
// OP Rd,Rb,Rm ASR Rs // OP Rd,Rb,Rm ASR Rs
@ -517,23 +517,23 @@ static void count(u32 opcode, int cond_res)
VALUE_LOAD_REG \ VALUE_LOAD_REG \
EMIT2(test, cl, cl) \ EMIT2(test, cl, cl) \
EMIT1(jz, LABELREF(0,f)) \ EMIT1(jz, LABELREF(0,f)) \
EMIT2(cmp, CONST(0x20), cl) \ EMIT2(cmp, KONST(0x20), cl) \
EMIT1(jae, LABELREF(1,f)) \ EMIT1(jae, LABELREF(1,f)) \
EMIT2(sar, cl, eax) \ EMIT2(sar, cl, eax) \
EMIT1(setc, bl) \ EMIT1(setc, bl) \
EMIT1(jmp, LABELREF(0,f)) \ EMIT1(jmp, LABELREF(0,f)) \
LABEL(1) \ LABEL(1) \
EMIT2(sar, CONST(31), eax) \ EMIT2(sar, KONST(31), eax) \
EMIT1(sets, bl) \ EMIT1(sets, bl) \
LABEL(0) LABEL(0)
#define VALUE_ASR_REG_NC \ #define VALUE_ASR_REG_NC \
VALUE_LOAD_REG \ VALUE_LOAD_REG \
EMIT2(cmp, CONST(0x20), cl) \ EMIT2(cmp, KONST(0x20), cl) \
EMIT1(jae, LABELREF(1,f)) \ EMIT1(jae, LABELREF(1,f)) \
EMIT2(sar, cl, eax) \ EMIT2(sar, cl, eax) \
EMIT1(jmp, LABELREF(0,f)) \ EMIT1(jmp, LABELREF(0,f)) \
LABEL(1) \ LABEL(1) \
EMIT2(sar, CONST(31), eax) \ EMIT2(sar, KONST(31), eax) \
LABEL(0) LABEL(0)
// OP Rd,Rb,Rm ROR # // OP Rd,Rb,Rm ROR #
@ -543,8 +543,8 @@ static void count(u32 opcode, int cond_res)
EMIT2(ror, cl, eax) \ EMIT2(ror, cl, eax) \
EMIT1(jmp, LABELREF(0,f)) \ EMIT1(jmp, LABELREF(0,f)) \
LABEL(1) \ LABEL(1) \
EMIT2(bt, CONST(0), ebx) \ EMIT2(bt, KONST(0), ebx) \
EMIT2(rcr, CONST(1), eax) \ EMIT2(rcr, KONST(1), eax) \
LABEL(0) \ LABEL(0) \
EMIT1(setc, bl) EMIT1(setc, bl)
#define VALUE_ROR_IMM_NC \ #define VALUE_ROR_IMM_NC \
@ -553,14 +553,14 @@ static void count(u32 opcode, int cond_res)
EMIT2(ror, cl, eax) \ EMIT2(ror, cl, eax) \
EMIT1(jmp, LABELREF(0,f)) \ EMIT1(jmp, LABELREF(0,f)) \
LABEL(1) \ LABEL(1) \
EMIT2(bt, CONST(0), VARL(C_FLAG)) \ EMIT2(bt, KONST(0), VARL(C_FLAG)) \
EMIT2(rcr, CONST(1), eax) \ EMIT2(rcr, KONST(1), eax) \
LABEL(0) LABEL(0)
// OP Rd,Rb,Rm ROR Rs // OP Rd,Rb,Rm ROR Rs
#define VALUE_ROR_REG_C \ #define VALUE_ROR_REG_C \
VALUE_LOAD_REG \ VALUE_LOAD_REG \
EMIT2(bt, CONST(0), ebx) \ EMIT2(bt, KONST(0), ebx) \
EMIT2(ror, cl, eax) \ EMIT2(ror, cl, eax) \
EMIT1(setc, bl) EMIT1(setc, bl)
#define VALUE_ROR_REG_NC \ #define VALUE_ROR_REG_NC \
@ -572,7 +572,7 @@ static void count(u32 opcode, int cond_res)
EMIT2(movzx, ch, ecx) \ EMIT2(movzx, ch, ecx) \
EMIT2(add, ecx, ecx) \ EMIT2(add, ecx, ecx) \
EMIT2(movzx, al, eax) \ EMIT2(movzx, al, eax) \
EMIT2(bt, CONST(0), ebx) \ EMIT2(bt, KONST(0), ebx) \
EMIT2(ror, cl, eax) \ EMIT2(ror, cl, eax) \
EMIT1(setc, bl) EMIT1(setc, bl)
#define VALUE_IMM_NC \ #define VALUE_IMM_NC \
@ -585,7 +585,7 @@ static void count(u32 opcode, int cond_res)
// Set condition codes iff the destination register is not R15 (PC) // Set condition codes iff the destination register is not R15 (PC)
#define CHECK_PC(OP, SETCOND) \ #define CHECK_PC(OP, SETCOND) \
EMIT2(cmp, CONST(0x3C), esi) \ EMIT2(cmp, KONST(0x3C), esi) \
EMIT1(je, LABELREF(8,f)) \ EMIT1(je, LABELREF(8,f)) \
OP SETCOND \ OP SETCOND \
EMIT1(jmp, LABELREF(9,f)) \ EMIT1(jmp, LABELREF(9,f)) \
@ -614,18 +614,18 @@ static void count(u32 opcode, int cond_res)
EMIT2(mov, edx, REGREF1(esi)) EMIT2(mov, edx, REGREF1(esi))
#define OP_ADDS CHECK_PC(OP_ADD, SETCOND_ADD) #define OP_ADDS CHECK_PC(OP_ADD, SETCOND_ADD)
#define OP_ADC \ #define OP_ADC \
EMIT2(bt, CONST(0), VARL(C_FLAG)) \ EMIT2(bt, KONST(0), VARL(C_FLAG)) \
EMIT2(adc, eax, edx) \ EMIT2(adc, eax, edx) \
EMIT2(mov, edx, REGREF1(esi)) EMIT2(mov, edx, REGREF1(esi))
#define OP_ADCS CHECK_PC(OP_ADC, SETCOND_ADD) #define OP_ADCS CHECK_PC(OP_ADC, SETCOND_ADD)
#define OP_SBC \ #define OP_SBC \
EMIT2(bt, CONST(0), VARL(C_FLAG)) \ EMIT2(bt, KONST(0), VARL(C_FLAG)) \
EMIT0(cmc) \ EMIT0(cmc) \
EMIT2(sbb, eax, edx) \ EMIT2(sbb, eax, edx) \
EMIT2(mov, edx, REGREF1(esi)) EMIT2(mov, edx, REGREF1(esi))
#define OP_SBCS CHECK_PC(OP_SBC, SETCOND_SUB) #define OP_SBCS CHECK_PC(OP_SBC, SETCOND_SUB)
#define OP_RSC \ #define OP_RSC \
EMIT2(bt, CONST(0), VARL(C_FLAG)) \ EMIT2(bt, KONST(0), VARL(C_FLAG)) \
EMIT0(cmc) \ EMIT0(cmc) \
EMIT2(sbb, edx, eax) \ EMIT2(sbb, edx, eax) \
EMIT2(mov, eax, REGREF1(esi)) EMIT2(mov, eax, REGREF1(esi))
@ -678,7 +678,7 @@ static void count(u32 opcode, int cond_res)
: "0" (offset), "c" (shift)); : "0" (offset), "c" (shift));
#define RRX_OFFSET \ #define RRX_OFFSET \
asm(EMIT2(btl,CONST(0),VAR(C_FLAG)) \ asm(EMIT2(btl,KONST(0),VAR(C_FLAG)) \
"rcr $1, %0" \ "rcr $1, %0" \
: "=r" (offset) \ : "=r" (offset) \
: "0" (offset)); : "0" (offset));

View File

@ -301,7 +301,7 @@ static INSN_REGPARM void thumbBreakpoint(u32 opcode)
#else #else
#define EMIT1(op,arg) #op" "arg"; " #define EMIT1(op,arg) #op" "arg"; "
#define EMIT2(op,src,dest) #op" "src", "dest"; " #define EMIT2(op,src,dest) #op" "src", "dest"; "
#define CONST(val) "$"#val #define KONST(val) "$"#val
#define ASMVAR(cvar) ASMVAR2 (__USER_LABEL_PREFIX__, cvar) #define ASMVAR(cvar) ASMVAR2 (__USER_LABEL_PREFIX__, cvar)
#define ASMVAR2(prefix,cvar) STRING (prefix) cvar #define ASMVAR2(prefix,cvar) STRING (prefix) cvar
#define STRING(x) #x #define STRING(x) #x
@ -328,7 +328,7 @@ static INSN_REGPARM void thumbBreakpoint(u32 opcode)
: \ : \
: "r" (value), "r" (reg[dest].I):"1"); : "r" (value), "r" (reg[dest].I):"1");
#define ADC_RD_RS \ #define ADC_RD_RS \
asm (EMIT2(bt,CONST(0),VAR(C_FLAG)) \ asm (EMIT2(bt,KONST(0),VAR(C_FLAG)) \
"adc %1, %%ebx;"\ "adc %1, %%ebx;"\
EMIT1(setsb, VAR(N_FLAG)) \ EMIT1(setsb, VAR(N_FLAG)) \
EMIT1(setzb, VAR(Z_FLAG)) \ EMIT1(setzb, VAR(Z_FLAG)) \
@ -346,7 +346,7 @@ static INSN_REGPARM void thumbBreakpoint(u32 opcode)
: "=m" (reg[(d)].I)); : "=m" (reg[(d)].I));
#define MOV_RN_O8(d) \ #define MOV_RN_O8(d) \
asm ("andl $0xFF, %%eax;"\ asm ("andl $0xFF, %%eax;"\
EMIT2(movb,CONST(0),VAR(N_FLAG)) \ EMIT2(movb,KONST(0),VAR(N_FLAG)) \
"movl %%eax, %0;"\ "movl %%eax, %0;"\
EMIT1(setzb, VAR(Z_FLAG)) \ EMIT1(setzb, VAR(Z_FLAG)) \
: "=m" (reg[(d)].I)); : "=m" (reg[(d)].I));
@ -360,7 +360,7 @@ static INSN_REGPARM void thumbBreakpoint(u32 opcode)
: \ : \
: "m" (reg[(d)].I)); : "m" (reg[(d)].I));
#define SBC_RD_RS \ #define SBC_RD_RS \
asm volatile (EMIT2(bt,CONST(0),VAR(C_FLAG)) \ asm volatile (EMIT2(bt,KONST(0),VAR(C_FLAG)) \
"cmc;"\ "cmc;"\
"sbb %1, %%ebx;"\ "sbb %1, %%ebx;"\
EMIT1(setsb, VAR(N_FLAG)) \ EMIT1(setsb, VAR(N_FLAG)) \
@ -465,9 +465,9 @@ static INSN_REGPARM void thumbBreakpoint(u32 opcode)
EMIT1(setcb, VAR(C_FLAG)) \ EMIT1(setcb, VAR(C_FLAG)) \
EMIT1(setob, VAR(V_FLAG)) EMIT1(setob, VAR(V_FLAG))
#define ADD_RD_RS_O3_0(N) \ #define ADD_RD_RS_O3_0(N) \
EMIT2(movb,CONST(0),VAR(C_FLAG)) \ EMIT2(movb,KONST(0),VAR(C_FLAG)) \
"add $0,%%ecx;" \ "add $0,%%ecx;" \
EMIT2(movb,CONST(0),VAR(V_FLAG)) EMIT2(movb,KONST(0),VAR(V_FLAG))
#define SUB_RD_RS_RN(N) \ #define SUB_RD_RS_RN(N) \
EMIT2(sub,VAR(reg)"+"#N"*4",ecx) \ EMIT2(sub,VAR(reg)"+"#N"*4",ecx) \
EMIT1(setncb, VAR(C_FLAG)) \ EMIT1(setncb, VAR(C_FLAG)) \
@ -477,9 +477,9 @@ static INSN_REGPARM void thumbBreakpoint(u32 opcode)
EMIT1(setncb, VAR(C_FLAG)) \ EMIT1(setncb, VAR(C_FLAG)) \
EMIT1(setob, VAR(V_FLAG)) EMIT1(setob, VAR(V_FLAG))
#define SUB_RD_RS_O3_0(N) \ #define SUB_RD_RS_O3_0(N) \
EMIT2(movb,CONST(1),VAR(C_FLAG)) \ EMIT2(movb,KONST(1),VAR(C_FLAG)) \
"sub $0,%%ecx;" \ "sub $0,%%ecx;" \
EMIT2(movb,CONST(0),VAR(V_FLAG)) EMIT2(movb,KONST(0),VAR(V_FLAG))
#endif #endif
#else // !__GNUC__ #else // !__GNUC__
#define ADD_RD_RS_RN(N) \ #define ADD_RD_RS_RN(N) \

View File

@ -1,7 +1,27 @@
// This file was written by denopqrihg // This file was written by denopqrihg
// with major changes by tjm // with major changes by tjm
#include <string.h>
#include <malloc.h>
#include <stdio.h>
int vbaid = 0;
const char *MakeInstanceFilename(const char *Input)
{
if (vbaid == 0)
return Input;
static char *result=NULL;
if (result!=NULL)
free(result);
result = (char *)malloc(strlen(Input)+3);
char *p = strrchr((char *)Input, '.');
sprintf(result, "%.*s-%d.%s", (int)(p-Input), Input, vbaid+1, p+1);
return result;
}
#ifndef NO_LINK #ifndef NO_LINK
// Joybus // Joybus
bool gba_joybus_enabled = false; bool gba_joybus_enabled = false;
@ -11,8 +31,6 @@ bool gba_link_enabled = false;
#define LOCAL_LINK_NAME "VBA link memory" #define LOCAL_LINK_NAME "VBA link memory"
#define IP_LINK_PORT 5738 #define IP_LINK_PORT 5738
#include <string.h>
#include <stdio.h>
#include "../common/Port.h" #include "../common/Port.h"
#include "GBA.h" #include "GBA.h"
#include "GBALink.h" #include "GBALink.h"
@ -144,7 +162,7 @@ sf::IPAddress joybusHostAddr = sf::IPAddress::LocalHost;
u8 tspeed = 3; u8 tspeed = 3;
u8 transfer = 0; u8 transfer = 0;
LINKDATA *linkmem = NULL; LINKDATA *linkmem = NULL;
int linkid = 0, vbaid = 0; int linkid = 0;
#if (defined __WIN32__ || defined _WIN32) #if (defined __WIN32__ || defined _WIN32)
HANDLE linksync[4]; HANDLE linksync[4];
#else #else
@ -214,21 +232,6 @@ int StartServer(void);
u16 StartRFU(u16); u16 StartRFU(u16);
const char *MakeInstanceFilename(const char *Input)
{
if (vbaid == 0)
return Input;
static char *result=NULL;
if (result!=NULL)
free(result);
result = (char *)malloc(strlen(Input)+3);
char *p = strrchr((char *)Input, '.');
sprintf(result, "%.*s-%d.%s", (int)(p-Input), Input, vbaid+1, p+1);
return result;
}
void StartLink(u16 value) void StartLink(u16 value)
{ {
if (ioMem == NULL) if (ioMem == NULL)
@ -1218,7 +1221,7 @@ void LinkServerThread(void *_sid){
fdset.Add(lanlink.tcpsocket); fdset.Add(lanlink.tcpsocket);
if(lanlink.terminate){ if(lanlink.terminate){
ReleaseSemaphore(linksync[vbaid], 1, NULL); ReleaseSemaphore(linksync[vbaid], 1, NULL);
return; goto CloseInfoDisplay;
} }
if(fdset.Wait(0.1)==1){ if(fdset.Wait(0.1)==1){
sf::Socket::Status st = sf::Socket::Status st =
@ -1247,6 +1250,8 @@ void LinkServerThread(void *_sid){
ls.tcpsocket[i].Send(outbuffer, 4); ls.tcpsocket[i].Send(outbuffer, 4);
} }
CloseInfoDisplay:
delete sid;
return; return;
} }
@ -1300,7 +1305,8 @@ void lserver::Recv(void){
fdset.Clear(); fdset.Clear();
for(i=0;i<lanlink.numslaves;i++) fdset.Add(tcpsocket[i+1]); for(i=0;i<lanlink.numslaves;i++) fdset.Add(tcpsocket[i+1]);
// was linktimeout/1000 (i.e., drop ms part), but that's wrong // was linktimeout/1000 (i.e., drop ms part), but that's wrong
if(fdset.Wait((float)linktimeout / 1000.0)==0){ if (fdset.Wait((float)(linktimeout / 1000.)) == 0)
{
return; return;
} }
howmanytimes++; howmanytimes++;
@ -1363,7 +1369,7 @@ bool lclient::Init(sf::IPAddress addr, ClientInfoDisplay *cid){
lanlink.terminate = false; lanlink.terminate = false;
lanlink.thread = new sf::Thread(LinkClientThread, cid); lanlink.thread = new sf::Thread(LinkClientThread, cid);
lanlink.thread->Launch(); lanlink.thread->Launch();
return 0; return true;
} }
void LinkClientThread(void *_cid){ void LinkClientThread(void *_cid){
@ -1378,7 +1384,8 @@ void LinkClientThread(void *_cid){
// stupid SFML has no way of giving what sort of error occurred // stupid SFML has no way of giving what sort of error occurred
// so we'll just have to do a retry loop, I guess. // so we'll just have to do a retry loop, I guess.
cid->Ping(); cid->Ping();
if(lanlink.terminate) return; if(lanlink.terminate)
goto CloseInfoDisplay;
// old code had broken sleep on socket, which isn't // old code had broken sleep on socket, which isn't
// even connected yet // even connected yet
// corrected sleep on socket worked, but this is more sane // corrected sleep on socket worked, but this is more sane
@ -1401,7 +1408,7 @@ void LinkClientThread(void *_cid){
cid->Ping(); cid->Ping();
if(lanlink.terminate) { if(lanlink.terminate) {
lanlink.tcpsocket.Close(); lanlink.tcpsocket.Close();
return; goto CloseInfoDisplay;
} }
} }
linkid = (int)READ16LE(&u16inbuffer[0]); linkid = (int)READ16LE(&u16inbuffer[0]);
@ -1420,7 +1427,7 @@ void LinkClientThread(void *_cid){
cid->Ping(); cid->Ping();
if(lanlink.terminate) { if(lanlink.terminate) {
lanlink.tcpsocket.Close(); lanlink.tcpsocket.Close();
return; goto CloseInfoDisplay;
} }
} }
@ -1428,6 +1435,8 @@ void LinkClientThread(void *_cid){
cid->Connected(); cid->Connected();
CloseInfoDisplay:
delete cid;
return; return;
} }
@ -1468,7 +1477,8 @@ void lclient::Recv(void){
// old code used socket # instead of mask again // old code used socket # instead of mask again
fdset.Add(lanlink.tcpsocket); fdset.Add(lanlink.tcpsocket);
// old code stripped off ms again // old code stripped off ms again
if(fdset.Wait((float)linktimeout / 1000.0)==0){ if (fdset.Wait((float)(linktimeout / 1000.)) == 0)
{
numtransfers = 0; numtransfers = 0;
return; return;
} }

View File

@ -51,16 +51,18 @@ enum
JOY_CMD_WRITE = 0x15 JOY_CMD_WRITE = 0x15
}; };
// Link implementation; only present if enabled extern const char *MakeInstanceFilename(const char *Input);
#ifndef NO_LINK #ifndef NO_LINK
// Link implementation
#include <SFML/System.hpp> #include <SFML/System.hpp>
#include <SFML/Network.hpp> #include <SFML/Network.hpp>
class ServerInfoDisplay class ServerInfoDisplay
{ {
public: public:
virtual void ShowServerIP(sf::IPAddress addr) = 0; virtual void ShowServerIP(const sf::IPAddress& addr) = 0;
virtual void ShowConnect(int player) = 0; virtual void ShowConnect(const int player) = 0;
virtual void Ping() = 0; virtual void Ping() = 0;
virtual void Connected() = 0; virtual void Connected() = 0;
}; };
@ -103,9 +105,9 @@ public:
class ClientInfoDisplay { class ClientInfoDisplay {
public: public:
virtual void ConnectStart(sf::IPAddress addr) = 0; virtual void ConnectStart(const sf::IPAddress& addr) = 0;
virtual void Ping() = 0; virtual void Ping() = 0;
virtual void ShowConnect(int player, int togo) = 0; virtual void ShowConnect(const int player, const int togo) = 0;
virtual void Connected() = 0; virtual void Connected() = 0;
}; };
@ -144,13 +146,13 @@ typedef struct {
} LANLINKDATA; } LANLINKDATA;
extern bool gba_joybus_enabled; extern bool gba_joybus_enabled;
extern bool gba_link_enabled;
extern sf::IPAddress joybusHostAddr; extern sf::IPAddress joybusHostAddr;
extern void JoyBusConnect(); extern void JoyBusConnect();
extern void JoyBusShutdown(); extern void JoyBusShutdown();
extern void JoyBusUpdate(int ticks); extern void JoyBusUpdate(int ticks);
extern bool gba_link_enabled;
extern bool InitLink(); extern bool InitLink();
extern void CloseLink(); extern void CloseLink();
extern void StartLink(u16); extern void StartLink(u16);
@ -161,7 +163,6 @@ extern void LinkChildStop();
extern void LinkChildSend(u16); extern void LinkChildSend(u16);
extern void CloseLanLink(); extern void CloseLanLink();
extern void CleanLocalLink(); extern void CleanLocalLink();
extern const char *MakeInstanceFilename(const char *Input);
extern LANLINKDATA lanlink; extern LANLINKDATA lanlink;
extern int vbaid; extern int vbaid;
extern bool rfu_enabled; extern bool rfu_enabled;
@ -173,15 +174,23 @@ extern int linkid;
#else #else
// stubs to keep #ifdef's out of mainline // stubs to keep #ifdef's out of mainline
#define StartLink(x) const bool gba_joybus_enabled = false;
#define StartGPLink(x) const bool gba_link_enabled = false;
#define LinkSSend(x)
#define LinkUpdate(x) inline void JoyBusConnect() { }
#define JoyBusUpdate(x) inline void JoyBusShutdown() { }
#define InitLink() false inline void JoyBusUpdate(int) { }
#define CloseLink()
#define gba_link_enabled false inline bool InitLink() { return true; }
#define gba_joybus_enabled false inline void CloseLink() { }
inline void StartLink(u16) { }
inline void StartGPLink(u16) { }
inline void LinkSSend(u16) { }
inline void LinkUpdate(int) { }
inline void LinkChildStop() { }
inline void LinkChildSend(u16) { }
inline void CloseLanLink() { }
inline void CleanLocalLink() { }
#endif #endif
#endif /* GBA_GBALINK_H */ #endif /* GBA_GBALINK_H */

View File

@ -1,3 +1,5 @@
#ifndef NO_LINK
#include "stdafx.h" #include "stdafx.h"
#include "vba.h" #include "vba.h"
#include "JoybusOptions.h" #include "JoybusOptions.h"
@ -74,3 +76,5 @@ void JoybusOptions::OnBnClickedOk()
OnOK(); OnOK();
} }
#endif // NO_LINK

View File

@ -1,3 +1,5 @@
#ifndef NO_LINK
#include "stdafx.h" #include "stdafx.h"
#include "vba.h" #include "vba.h"
#include "LinkOptions.h" #include "LinkOptions.h"
@ -492,28 +494,55 @@ void LinkOptions::OnCancel()
class Win32ServerInfoDisplay : public ServerInfoDisplay class Win32ServerInfoDisplay : public ServerInfoDisplay
{ {
Win32ServerInfoDisplay(ServerWait _dlg) : dlg(_dlg) {} public:
void ShowServerIP(sf::IPAddress addr) { Win32ServerInfoDisplay(ServerWait *_dlg)
dlg->m_serveraddress.Format("Server IP address is: %s", addr.ToString); {
dlg = _dlg;
} }
void ShowConnect(int player) {
dlg->m_plconn[i].Format("Player %d connected", player); ~Win32ServerInfoDisplay()
dlg->UpdateData(false); {
} if (dlg)
void Ping() { dlg->m_prgctrl.StepIt(); } {
void Connected() { // not connected
MessageBox(NULL, "All players connected", "Link", MB_OK); MessageBox(NULL, "Failed to connect.", "Link", MB_OK);
dlg->SendMessage(WM_CLOSE, 0, 0); dlg->SendMessage(WM_CLOSE, 0, 0);
} }
private:
ServerWait dlg; delete dlg;
dlg = NULL;
} }
void ShowServerIP(const sf::IPAddress& addr)
{
dlg->m_serveraddress.Format("Server IP address is: %s", addr.ToString());
}
void ShowConnect(const int player)
{
dlg->m_plconn[0].Format("Player %d connected", player);
dlg->UpdateData(false);
}
void Ping()
{
dlg->m_prgctrl.StepIt();
}
void Connected()
{
MessageBox(NULL, "All players connected", "Link", MB_OK);
dlg->SendMessage(WM_CLOSE, 0, 0);
delete dlg;
dlg = NULL;
}
private:
ServerWait *dlg;
};
void LinkServer::OnServerStart() void LinkServer::OnServerStart()
{ {
int errorcode;
ServerWait dlg;
UpdateData(TRUE); UpdateData(TRUE);
lanlink.numslaves = m_numplayers+1; lanlink.numslaves = m_numplayers+1;
@ -522,13 +551,18 @@ void LinkServer::OnServerStart()
lanlink.speed = m_speed==1 ? true : false; lanlink.speed = m_speed==1 ? true : false;
sf::IPAddress addr; sf::IPAddress addr;
Win32ServerInfoDisplay dlginfo(dlg); // These must be created on the heap - referenced from the connection thread
if(!ls.Init(&dlginfo)){ ServerWait *dlg = new ServerWait;
MessageBox("Error occured.\nPlease try again.", "Error", MB_OK); // Owns the ServerWait*
return; Win32ServerInfoDisplay *dlginfo = new Win32ServerInfoDisplay(dlg);
}
dlg.DoModal(); // ls thread will own the dlginfo
if (!ls.Init(dlginfo))
{
// Thread didn't get created
delete dlginfo;
MessageBox("Error occurred.\nPlease try again.", "Error", MB_OK);
}
return; return;
} }
@ -547,29 +581,59 @@ BOOL LinkClient::OnInitDialog()
class Win32ClientInfoDisplay : public ClientInfoDisplay class Win32ClientInfoDisplay : public ClientInfoDisplay
{ {
Win32ClientInfoDisplay(ServerWait _dlg) : dlg(_dlg) {} public:
void ConnectStart(sf::IPAddress addr) { Win32ClientInfoDisplay(ServerWait *_dlg)
dlg->SetWindowText("Connecting..."); {
dlg = _dlg;
} }
void ShowConnect(int player, int togo) {
dlg->m_serveraddress.Format("Connected as #%d", player); ~Win32ClientInfoDisplay()
if(togo) dlg->m_plconn[0].Format("Waiting for %d players to join", togo); {
else dlg->m_plconn[0].Format("All players joined."); if (dlg)
} {
void Ping() { dlg->m_prgctrl.StepIt(); } // not connected
void Connected() { MessageBox(NULL, "Failed to connect.", "Link", MB_OK);
MessageBox(NULL, "Connected.", "Link", MB_OK);
dlg->SendMessage(WM_CLOSE, 0, 0); dlg->SendMessage(WM_CLOSE, 0, 0);
} }
private:
ServerWait dlg; delete dlg;
dlg = NULL;
} }
void ConnectStart(const sf::IPAddress& addr)
{
dlg->SetWindowText("Connecting...");
}
void ShowConnect(const int player, const int togo)
{
dlg->m_serveraddress.Format("Connected as #%d", player);
if (togo)
dlg->m_plconn[0].Format("Waiting for %d players to join", togo);
else
dlg->m_plconn[0].Format("All players joined.");
}
void Ping()
{
dlg->m_prgctrl.StepIt();
}
void Connected()
{
MessageBox(NULL, "Connected.", "Link", MB_OK);
dlg->SendMessage(WM_CLOSE, 0, 0);
delete dlg;
dlg = NULL;
}
private:
ServerWait *dlg;
};
void LinkClient::OnLinkConnect() void LinkClient::OnLinkConnect()
{ {
char ipaddress[31]; char ipaddress[31];
int errorcode;
ServerWait dlg;
UpdateData(TRUE); UpdateData(TRUE);
@ -579,14 +643,23 @@ void LinkClient::OnLinkConnect()
m_serverip.GetWindowText(ipaddress, 30); m_serverip.GetWindowText(ipaddress, 30);
Win32ClientInfoDisplay dlginfo(dlg); // These must be created on the heap - referenced from the connection thread
if((errorcode=lc.Init(sf::IPAddress(std::string(ipaddress)), &dlginfo))!=0){ ServerWait *dlg = new ServerWait;
char message[50]; // Owns the ServerWait*
sprintf(message, "Error %d occured.\nPlease try again.", errorcode); Win32ClientInfoDisplay *dlginfo = new Win32ClientInfoDisplay(dlg);
MessageBox(message, "Error", MB_OK);
return; // lc thread will own the dlginfo
if (!lc.Init(sf::IPAddress(std::string(ipaddress)), dlginfo))
{
// Thread didn't get created
delete dlginfo;
MessageBox("Error occurred.\nPlease try again.", "Error", MB_OK);
} }
dlg.DoModal(); else
{
dlg->DoModal();
}
return; return;
} }
@ -674,3 +747,5 @@ BOOL LinkServer::PreTranslateMessage(MSG* pMsg)
return CDialog::PreTranslateMessage(pMsg); return CDialog::PreTranslateMessage(pMsg);
} }
#endif // NO_LINK

View File

@ -1547,7 +1547,7 @@ void MainWnd::OnOptionsVideoFullscreenmaxscale()
} }
} }
#ifndef NO_LINK
void MainWnd::OnLinkOptions() void MainWnd::OnLinkOptions()
{ {
LinkOptions dlg; LinkOptions dlg;
@ -1584,7 +1584,14 @@ void MainWnd::OnOptionsJoybus()
JoybusOptions dlg; JoybusOptions dlg;
dlg.DoModal(); dlg.DoModal();
} }
#else
void MainWnd::OnLinkOptions() { }
void MainWnd::OnOptionsLinkRFU() { }
void MainWnd::OnUpdateOptionsLinkEnable(CCmdUI*) { }
void MainWnd::OnOptionsLinkEnable() { }
void MainWnd::OnUpdateOptionsLinkRFU(CCmdUI*) { }
void MainWnd::OnOptionsJoybus() { }
#endif
void MainWnd::OnOptionsEmulatorGameoverrides() void MainWnd::OnOptionsEmulatorGameoverrides()
{ {

View File

@ -111,7 +111,7 @@ void winlog(const char *msg, ...);
/* Link /* Link
---------------------*/ ---------------------*/
extern int InitLink(void); extern bool InitLink(void);
extern void CloseLink(void); extern void CloseLink(void);
//extern int linkid; //extern int linkid;
extern char inifile[]; extern char inifile[];
@ -1254,7 +1254,11 @@ BOOL VBA::OnIdle(LONG lCount)
} else if(emulating && active && !paused) { } else if(emulating && active && !paused) {
for(int i = 0; i < 2; i++) { for(int i = 0; i < 2; i++) {
emulator.emuMain(emulator.emuCount); emulator.emuMain(emulator.emuCount);
if(lanlink.connected&&linkid&&lc.numtransfers==0) lc.CheckConn();
#ifndef NO_LINK
if (lanlink.connected && linkid && lc.numtransfers == 0)
lc.CheckConn();
#endif
if(rewindSaveNeeded && rewindMemory && emulator.emuWriteMemState) { if(rewindSaveNeeded && rewindMemory && emulator.emuWriteMemState) {
rewindCount++; rewindCount++;
@ -1618,6 +1622,7 @@ void VBA::loadSettings()
updateThrottle( (unsigned short)regQueryDwordValue( "throttle", 0 ) ); updateThrottle( (unsigned short)regQueryDwordValue( "throttle", 0 ) );
#ifndef NO_LINK
linktimeout = regQueryDwordValue("LinkTimeout", 1000); linktimeout = regQueryDwordValue("LinkTimeout", 1000);
rfu_enabled = regQueryDwordValue("RFU", false) ? true : false; rfu_enabled = regQueryDwordValue("RFU", false) ? true : false;
@ -1630,6 +1635,7 @@ void VBA::loadSettings()
} }
lanlink.active = regQueryDwordValue("LAN", 0) ? true : false; lanlink.active = regQueryDwordValue("LAN", 0) ? true : false;
#endif
Sm60FPS::bSaveMoreCPU = regQueryDwordValue("saveMoreCPU", 0); Sm60FPS::bSaveMoreCPU = regQueryDwordValue("saveMoreCPU", 0);
@ -2553,11 +2559,15 @@ void VBA::saveSettings()
regSetDwordValue("throttle", throttle); regSetDwordValue("throttle", throttle);
regSetStringValue("pluginName", pluginName); regSetStringValue("pluginName", pluginName);
regSetDwordValue("saveMoreCPU", Sm60FPS::bSaveMoreCPU); regSetDwordValue("saveMoreCPU", Sm60FPS::bSaveMoreCPU);
#ifndef NO_LINK
regSetDwordValue("LinkTimeout", linktimeout); regSetDwordValue("LinkTimeout", linktimeout);
regSetDwordValue("RFU", rfu_enabled); regSetDwordValue("RFU", rfu_enabled);
regSetDwordValue("linkEnabled", gba_link_enabled); regSetDwordValue("linkEnabled", gba_link_enabled);
regSetDwordValue("joybusEnabled", gba_joybus_enabled); regSetDwordValue("joybusEnabled", gba_joybus_enabled);
regSetStringValue("joybusHostAddr", joybusHostAddr.ToString().c_str()); regSetStringValue("joybusHostAddr", joybusHostAddr.ToString().c_str());
#endif
regSetDwordValue("lastFullscreen", lastFullscreen); regSetDwordValue("lastFullscreen", lastFullscreen);
regSetDwordValue("pauseWhenInactive", pauseWhenInactive); regSetDwordValue("pauseWhenInactive", pauseWhenInactive);

View File

@ -7,7 +7,7 @@
// http://www.hiend3d.com/hq2x.html // http://www.hiend3d.com/hq2x.html
// Modified by suanyuan // Modified by suanyuan
//--------------------------------------------------------------------------------------------------------------------------- //---------------------------------------------------------------------------------------------------------------------------
#ifdef __MSW__ #if defined(_WIN32)
#include <windows.h> #include <windows.h>
#else #else
#define HMODULE void * #define HMODULE void *