SubWCRev is no longer standalone, removed from dependencies and pointed the project files to find it via path
updated DevInfo.txt applied khh's patch for gbalink.cpp though more changes are required to bring trunk up to building since the Wx patches git-svn-id: https://svn.code.sf.net/p/vbam/code/trunk@1064 a31d4220-a93d-0410-bf67-fe4944624d44
This commit is contained in:
parent
7f627ac7b0
commit
541ecbda78
|
@ -44,9 +44,10 @@ Refer to the instructions below for further assistance:
|
|||
|
||||
===Win32/MFC===
|
||||
This is the full-featured Windows build using the MFC GUI.
|
||||
The project files are located in trunk/project/vc2008_mfc (VBA2008.sln).
|
||||
The project files are located in /project/vc2008_mfc (VBA2008.sln) and /project/vs2010_mfc (VBA2010.sln).
|
||||
You also have to install Microsoft's DirectX SDK for Direct3D, DirectInput & XAudio2.
|
||||
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, which is compatible to the NASM syntax.
|
||||
Install NASM somewhere and add it to your compiler's executable file paths.
|
||||
All .asm files will be handled with the "nasm.rules" build rules file which comes with this project file.
|
||||
SubWCRev.exe is used to append the svn versioning to the output executable, this should already be present if you pulled from the svn, but will require installing if you downloaded the project as a tarball.
|
Binary file not shown.
|
@ -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">
|
||||
<ItemGroup Label="ProjectConfigurations">
|
||||
<ProjectConfiguration Include="Debug|Win32">
|
||||
|
@ -78,7 +78,7 @@
|
|||
<Path>$(IntDir)$(ProjectName)_BuildLog.htm</Path>
|
||||
</BuildLog>
|
||||
<PreBuildEvent>
|
||||
<Command>..\..\..\dependencies\SubWCRev.exe ..\.. svnrev_template.h ..\..\src\svnrev.h</Command>
|
||||
<Command>SubWCRev.exe ..\.. svnrev_template.h ..\..\src\svnrev.h</Command>
|
||||
</PreBuildEvent>
|
||||
<Midl>
|
||||
<PreprocessorDefinitions>_DEBUG;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
|
@ -131,7 +131,7 @@
|
|||
<Path>$(IntDir)$(ProjectName)_BuildLog.htm</Path>
|
||||
</BuildLog>
|
||||
<PreBuildEvent>
|
||||
<Command>..\..\..\dependencies\SubWCRev.exe ..\.. svnrev_template.h ..\..\src\svnrev.h</Command>
|
||||
<Command>SubWCRev.exe ..\.. svnrev_template.h ..\..\src\svnrev.h</Command>
|
||||
</PreBuildEvent>
|
||||
<Midl>
|
||||
<PreprocessorDefinitions>_DEBUG;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
|
|
|
@ -24,7 +24,7 @@ bool gba_link_enabled = false;
|
|||
#define _(x) x
|
||||
#endif
|
||||
#define N_(x) x
|
||||
#ifdef __WIN32__
|
||||
#if (defined __WIN32__ || defined _WIN32)
|
||||
#include <windows.h>
|
||||
#else
|
||||
#include <sys/mman.h>
|
||||
|
@ -145,19 +145,19 @@ u8 tspeed = 3;
|
|||
u8 transfer = 0;
|
||||
LINKDATA *linkmem = NULL;
|
||||
int linkid = 0, vbaid = 0;
|
||||
#ifdef __WIN32__
|
||||
#if (defined __WIN32__ || defined _WIN32)
|
||||
HANDLE linksync[4];
|
||||
#else
|
||||
sem_t *linksync[4];
|
||||
#endif
|
||||
int savedlinktime = 0;
|
||||
#ifdef __WIN32__
|
||||
#if (defined __WIN32__ || defined _WIN32)
|
||||
HANDLE mmf = NULL;
|
||||
#else
|
||||
int mmf = -1;
|
||||
#endif
|
||||
char linkevent[] =
|
||||
#ifndef __WIN32__
|
||||
#if !(defined __WIN32__ || defined _WIN32)
|
||||
"/"
|
||||
#endif
|
||||
"VBA link event ";
|
||||
|
@ -964,7 +964,7 @@ bool InitLink()
|
|||
{
|
||||
linkid = 0;
|
||||
|
||||
#ifdef __WIN32__
|
||||
#if (defined __WIN32__ || defined _WIN32)
|
||||
if((mmf=CreateFileMapping(INVALID_HANDLE_VALUE, NULL, PAGE_READWRITE, 0, sizeof(LINKDATA), LOCAL_LINK_NAME))==NULL){
|
||||
systemMessage(0, N_("Error creating file mapping"));
|
||||
return false;
|
||||
|
@ -1019,7 +1019,7 @@ bool InitLink()
|
|||
break;
|
||||
}
|
||||
if(vbaid == 4){
|
||||
#ifdef __WIN32__
|
||||
#if (defined __WIN32__ || defined _WIN32)
|
||||
UnmapViewOfFile(linkmem);
|
||||
CloseHandle(mmf);
|
||||
#else
|
||||
|
@ -1039,7 +1039,7 @@ bool InitLink()
|
|||
|
||||
for(i=0;i<4;i++){
|
||||
linkevent[sizeof(linkevent)-2]=(char)i+'1';
|
||||
#ifdef __WIN32__
|
||||
#if (defined __WIN32__ || defined _WIN32)
|
||||
linksync[i] = firstone ?
|
||||
CreateSemaphore(NULL, 0, 4, linkevent) :
|
||||
OpenSemaphore(SEMAPHORE_ALL_ACCESS, false, linkevent);
|
||||
|
@ -1126,7 +1126,7 @@ void CloseLink(void){
|
|||
|
||||
for(i=0;i<4;i++){
|
||||
if(linksync[i]!=NULL){
|
||||
#ifdef __WIN32__
|
||||
#if (defined __WIN32__ || defined _WIN32)
|
||||
ReleaseSemaphore(linksync[i], 1, NULL);
|
||||
CloseHandle(linksync[i]);
|
||||
#else
|
||||
|
@ -1138,7 +1138,7 @@ void CloseLink(void){
|
|||
#endif
|
||||
}
|
||||
}
|
||||
#ifdef __WIN32__
|
||||
#if (defined __WIN32__ || defined _WIN32)
|
||||
CloseHandle(mmf);
|
||||
UnmapViewOfFile(linkmem);
|
||||
|
||||
|
@ -1159,7 +1159,7 @@ void CloseLink(void){
|
|||
// this may be necessary under MSW as well, but I wouldn't know how
|
||||
void CleanLocalLink()
|
||||
{
|
||||
#ifndef __WIN32__
|
||||
#if !(defined __WIN32__ || defined _WIN32)
|
||||
shm_unlink("/" LOCAL_LINK_NAME);
|
||||
for(int i = 0; i < 4; i++) {
|
||||
linkevent[sizeof(linkevent) - 2] = '1' + i;
|
||||
|
@ -1383,7 +1383,11 @@ void LinkClientThread(void *_cid){
|
|||
// even connected yet
|
||||
// corrected sleep on socket worked, but this is more sane
|
||||
// and probably less portable... works with mingw32 at least
|
||||
usleep(100000);
|
||||
#if (defined __WIN32__ || defined _WIN32)
|
||||
Sleep(100); // in milliseconds
|
||||
#else
|
||||
usleep(100000); // in microseconds
|
||||
#endif
|
||||
}
|
||||
|
||||
numbytes = 0;
|
||||
|
|
Loading…
Reference in New Issue