Linux Beta 2.3 Fix

This commit is contained in:
StFi 2013-03-04 19:52:26 +01:00
parent e16722e2d2
commit 9736433110
11 changed files with 278 additions and 262 deletions

6
.gitignore vendored
View File

@ -1,3 +1,9 @@
#################
## Kdevelop 4.X
#################
.kdev4/
rpgxEF.kdev4
#################
## Eclipse
#################

View File

@ -392,7 +392,6 @@ ifneq (,$(findstring "$(PLATFORM)", "linux" "gnu_kfreebsd" "kfreebsd-gnu"))
THREAD_LIBS=-lpthread
LIBS=-ldl -lm
LIBS += -L/emul/linux/x86/usr/lib
CLIENT_LIBS=$(SDL_LIBS)
RENDERER_LIBS = $(SDL_LIBS) -lGL

View File

@ -36,7 +36,7 @@ This is the only way control passes into the module.
This must be the very first function compiled into the .q3vm file
================
*/
int vmMain( int command, int arg0, int arg1, int arg2, int arg3, int arg4, int arg5, int arg6 ) {
Q_EXPORT intptr_t vmMain( int command, int arg0, int arg1, int arg2, int arg3, int arg4, int arg5, int arg6 ) {
switch ( command ) {
case CG_INIT:
CG_Init( arg0, arg1 );

View File

@ -10,7 +10,7 @@
static intptr_t (QDECL *syscall)( intptr_t arg, ... ) = (intptr_t (QDECL *)( intptr_t, ...))-1;
void dllEntry( intptr_t (QDECL *syscallptr)( intptr_t arg,... ) ) {
Q_EXPORT void dllEntry( intptr_t (QDECL *syscallptr)( intptr_t arg,... ) ) {
syscall = syscallptr;
}

View File

@ -499,7 +499,7 @@ This is the only way control passes into the module.
This MUST be the very first function compiled into the .q3vm file
================
*/
intptr_t vmMain( int command, int arg0, int arg1, int arg2, int arg3, int arg4, int arg5, int arg6 ) {
Q_EXPORT intptr_t vmMain( int command, int arg0, int arg1, int arg2, int arg3, int arg4, int arg5, int arg6 ) {
switch ( command ) {
case GAME_INIT:
G_InitGame( arg0, arg1, arg2 );

View File

@ -7,7 +7,7 @@
static intptr_t (QDECL *syscall)( intptr_t arg, ... ) = (intptr_t (QDECL *)( intptr_t, ...))-1;
void dllEntry( intptr_t (QDECL *syscallptr)( intptr_t arg,... ) ) {
Q_EXPORT void dllEntry( intptr_t (QDECL *syscallptr)( intptr_t arg,... ) ) {
syscall = syscallptr;
}

View File

@ -44,6 +44,16 @@
#endif
#endif
#if (defined _MSC_VER)
#define Q_EXPORT __declspec(dllexport)
#elif (defined __SUNPRO_C)
#define Q_EXPORT __global
#elif ((__GNUC__ >= 3) && (!__EMX__) && (!sun))
#define Q_EXPORT __attribute__((visibility("default")))
#else
#define Q_EXPORT
#endif
/**********************************************************************
VM Considerations

View File

@ -60,14 +60,13 @@ char *Sys_DefaultHomePath(void)
Com_sprintf(homePath, sizeof(homePath), "%s%c", p, PATH_SEP);
#ifdef ELITEFORCE
#ifdef MACOS_X
Q_strcat(homePath, sizeof(homePath), "/Library/Application Support/STVEF");
Q_strcat(homePath, sizeof(homePath), "Library/Application Support/STVEF");
#else
Q_strcat(homePath, sizeof(homePath), "/.stvef");
Q_strcat(homePath, sizeof(homePath), ".stvef");
#endif
#else
#ifdef MACOS_X
Q_strcat(homePath, sizeof(homePath),
"Library/Application Support/");
Q_strcat(homePath, sizeof(homePath), "Library/Application Support/");
if(com_homepath->string[0])
Q_strcat(homePath, sizeof(homePath), com_homepath->string);

View File

@ -20,7 +20,7 @@ This is the only way control passes into the module.
This must be the very first function compiled into the .qvm file
================
*/
int vmMain( int command, int arg0, int arg1, int arg2, int arg3, int arg4, int arg5, int arg6 ) {
Q_EXPORT intptr_t vmMain( int command, int arg0, int arg1, int arg2, int arg3, int arg4, int arg5, int arg6 ) {
switch ( command ) {
case UI_GETAPIVERSION:
return UI_API_VERSION;

View File

@ -10,7 +10,7 @@
static intptr_t (QDECL *syscall)( intptr_t arg, ... ) = (intptr_t (QDECL *)( intptr_t, ...))-1;
void dllEntry( intptr_t (QDECL *syscallptr)( intptr_t arg,... ) ) {
Q_EXPORT void dllEntry( intptr_t (QDECL *syscallptr)( intptr_t arg,... ) ) {
syscall = syscallptr;
}

View File

@ -109,6 +109,7 @@ static char *s_wideResolutions16x9[] =
{
"854x480",
"1280x720",
"1366x768",
"1920x1080",
0
};
@ -117,6 +118,7 @@ static videoResolutions_t videoResolutions16x9[] =
{
{ 854, 480 },
{ 1280, 720 },
{ 1366, 768 },
{ 1920, 1080 }
};
@ -158,7 +160,7 @@ static int s_wideScreenSets = 2;
//store the number of resolutions in each array.
//This will be necessary when we change the lists over
static int s_resolutionNums[] = {9,3,5};
static int s_resolutionNums[] = {9,4,5};
//finally for reference sake, use an enum
typedef enum