aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authormarha <marha@users.sourceforge.net>2009-11-23 15:23:16 +0000
committermarha <marha@users.sourceforge.net>2009-11-23 15:23:16 +0000
commit699ed6596b3b351dbbd88c1c2ef00eb07af9c1ee (patch)
treefc332f4b5adc964e2f5a7a3b69db8c96204f046a
parent29556eae54fc97f382b8d690dfc3a47a742800dc (diff)
downloadvcxsrv-699ed6596b3b351dbbd88c1c2ef00eb07af9c1ee.tar.gz
vcxsrv-699ed6596b3b351dbbd88c1c2ef00eb07af9c1ee.tar.bz2
vcxsrv-699ed6596b3b351dbbd88c1c2ef00eb07af9c1ee.zip
- Solved problems when running opengl with indirect rendering (export LIBGL_ALWAYS_INDIRECT=1)
- removed mesaopengl32.dll (not needed anymore)
-rw-r--r--building.txt5
-rw-r--r--mesalib/src/mesa/glapi/glapi.c6
-rw-r--r--mesalib/src/mesa/glapi/glapi.h10
-rw-r--r--mesalib/windows/VC8/mesa/mesa.sln9
-rw-r--r--mesalib/windows/VC8/mesa/mesa/mesa.vcproj8
-rw-r--r--mesalib/windows/VC8/mesa/swrast_dri/swrast_dri.vcproj28
-rw-r--r--xorg-server/glx/glapi.c4
-rw-r--r--xorg-server/glx/glapi.h29
-rw-r--r--xorg-server/installer/vcxsrv.nsi1
-rw-r--r--xorg-server/makefile6
10 files changed, 57 insertions, 49 deletions
diff --git a/building.txt b/building.txt
index d7464de8c..89b0ff995 100644
--- a/building.txt
+++ b/building.txt
@@ -28,11 +28,6 @@ Building pthreads:
- run 'nmake VC-static'
- run 'nmake VC-static-debug'
-Building mesa
-- goto mesalib\windows\VC8\mesa
-- open mesa.sln
-- Build configuration 'Release'
-
Building mhmake
- open tools\mhmake\mhmake.sln in Visual C++ 2008 Express Edition
- Build the Debug and Release configurations
diff --git a/mesalib/src/mesa/glapi/glapi.c b/mesalib/src/mesa/glapi/glapi.c
index e36fccb35..216dede90 100644
--- a/mesalib/src/mesa/glapi/glapi.c
+++ b/mesalib/src/mesa/glapi/glapi.c
@@ -223,16 +223,18 @@ void FreeAllTSD(void)
#endif /* defined(THREADS) */
+#ifndef INSERVER
PUBLIC struct _glapi_table *_glapi_Dispatch =
(struct _glapi_table *) __glapi_noop_table;
PUBLIC void *_glapi_Context = NULL;
+#endif
#endif /* defined(GLX_USE_TLS) */
/*@}*/
-
+#ifndef INSERVER
/**
* We should call this periodically from a function such as glXMakeCurrent
* in order to test if multiple threads are being used.
@@ -264,7 +266,7 @@ _glapi_check_multithread(void)
CHECK_MULTITHREAD_UNLOCK();
#endif
}
-
+#endif
/**
diff --git a/mesalib/src/mesa/glapi/glapi.h b/mesalib/src/mesa/glapi/glapi.h
index 5fb540122..8a5006fd9 100644
--- a/mesalib/src/mesa/glapi/glapi.h
+++ b/mesalib/src/mesa/glapi/glapi.h
@@ -90,8 +90,14 @@ extern __thread void * _glapi_tls_Context
#else
-extern void *_glapi_Context;
-extern struct _glapi_table *_glapi_Dispatch;
+#ifdef INSERVER
+#define EXTERN _declspec(dllimport)
+#else
+#define EXTERN extern
+#endif
+
+EXTERN void *_glapi_Context;
+EXTERN struct _glapi_table *_glapi_Dispatch;
# ifdef THREADS
# define GET_CURRENT_CONTEXT(C) GLcontext *C = (GLcontext *) (_glapi_Context ? _glapi_Context : _glapi_get_context())
diff --git a/mesalib/windows/VC8/mesa/mesa.sln b/mesalib/windows/VC8/mesa/mesa.sln
index e858c37f6..8a008cfbd 100644
--- a/mesalib/windows/VC8/mesa/mesa.sln
+++ b/mesalib/windows/VC8/mesa/mesa.sln
@@ -19,7 +19,6 @@ Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "osmesa", "osmesa\osmesa.vcp
EndProject
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "swrast_dri", "swrast_dri\swrast_dri.vcproj", "{FEF62E6F-A7E0-47BE-99A0-2494717DBDB7}"
ProjectSection(ProjectDependencies) = postProject
- {A1B24907-E196-4826-B6AF-26723629B633} = {A1B24907-E196-4826-B6AF-26723629B633}
{2120C974-2717-4709-B44F-D6E6D0A56448} = {2120C974-2717-4709-B44F-D6E6D0A56448}
EndProjectSection
EndProject
@@ -32,21 +31,13 @@ Global
EndGlobalSection
GlobalSection(ProjectConfigurationPlatforms) = postSolution
{A1B24907-E196-4826-B6AF-26723629B633}.Debug Static CRT|Win32.ActiveCfg = Debug Static CRT|Win32
- {A1B24907-E196-4826-B6AF-26723629B633}.Debug Static CRT|Win32.Build.0 = Debug Static CRT|Win32
{A1B24907-E196-4826-B6AF-26723629B633}.Debug|Win32.ActiveCfg = Debug|Win32
- {A1B24907-E196-4826-B6AF-26723629B633}.Debug|Win32.Build.0 = Debug|Win32
{A1B24907-E196-4826-B6AF-26723629B633}.Release Static CRT|Win32.ActiveCfg = Release Static CRT|Win32
- {A1B24907-E196-4826-B6AF-26723629B633}.Release Static CRT|Win32.Build.0 = Release Static CRT|Win32
{A1B24907-E196-4826-B6AF-26723629B633}.Release|Win32.ActiveCfg = Release|Win32
- {A1B24907-E196-4826-B6AF-26723629B633}.Release|Win32.Build.0 = Release|Win32
{2E50FDAF-430B-475B-AE6B-60B68F2875BA}.Debug Static CRT|Win32.ActiveCfg = Debug Static CRT|Win32
- {2E50FDAF-430B-475B-AE6B-60B68F2875BA}.Debug Static CRT|Win32.Build.0 = Debug Static CRT|Win32
{2E50FDAF-430B-475B-AE6B-60B68F2875BA}.Debug|Win32.ActiveCfg = Debug|Win32
- {2E50FDAF-430B-475B-AE6B-60B68F2875BA}.Debug|Win32.Build.0 = Debug|Win32
{2E50FDAF-430B-475B-AE6B-60B68F2875BA}.Release Static CRT|Win32.ActiveCfg = Release Static CRT|Win32
- {2E50FDAF-430B-475B-AE6B-60B68F2875BA}.Release Static CRT|Win32.Build.0 = Release Static CRT|Win32
{2E50FDAF-430B-475B-AE6B-60B68F2875BA}.Release|Win32.ActiveCfg = Release|Win32
- {2E50FDAF-430B-475B-AE6B-60B68F2875BA}.Release|Win32.Build.0 = Release|Win32
{2120C974-2717-4709-B44F-D6E6D0A56448}.Debug Static CRT|Win32.ActiveCfg = Debug Static CRT|Win32
{2120C974-2717-4709-B44F-D6E6D0A56448}.Debug Static CRT|Win32.Build.0 = Debug Static CRT|Win32
{2120C974-2717-4709-B44F-D6E6D0A56448}.Debug|Win32.ActiveCfg = Debug|Win32
diff --git a/mesalib/windows/VC8/mesa/mesa/mesa.vcproj b/mesalib/windows/VC8/mesa/mesa/mesa.vcproj
index 330ab8db9..7ce4e1385 100644
--- a/mesalib/windows/VC8/mesa/mesa/mesa.vcproj
+++ b/mesalib/windows/VC8/mesa/mesa/mesa.vcproj
@@ -47,7 +47,7 @@
OmitFramePointers="true"
WholeProgramOptimization="true"
AdditionalIncludeDirectories="../../../../include,../../../../src/mesa,../../../../src/mesa/glapi,../../../../src/mesa/main,../../../../src/mesa/shader,../../../../src/mesa/shader/slang,../../../../src/mesa/shader/grammar"
- PreprocessorDefinitions="NDEBUG;WIN32;_LIB;_DLL;BUILD_GL32;MESA_MINWARN;_CRT_SECURE_NO_DEPRECATE"
+ PreprocessorDefinitions="NDEBUG;WIN32;_LIB;_DLL;BUILD_GL32;MESA_MINWARN;_CRT_SECURE_NO_DEPRECATE;INSERVER"
StringPooling="true"
RuntimeLibrary="2"
EnableFunctionLevelLinking="true"
@@ -118,7 +118,7 @@
AdditionalOptions="/Zm1000 "
Optimization="0"
AdditionalIncludeDirectories="../../../../include,../../../../src/mesa,../../../../src/mesa/glapi,../../../../src/mesa/main,../../../../src/mesa/shader,../../../../src/mesa/shader/slang,../../../../src/mesa/shader/grammar"
- PreprocessorDefinitions="_DEBUG;WIN32;_LIB;_DLL;BUILD_GL32;MESA_MINWARN;_CRT_SECURE_NO_DEPRECATE"
+ PreprocessorDefinitions="_DEBUG;WIN32;_LIB;_DLL;BUILD_GL32;MESA_MINWARN;_CRT_SECURE_NO_DEPRECATE;INSERVER"
BasicRuntimeChecks="3"
RuntimeLibrary="3"
BrowseInformation="1"
@@ -189,7 +189,7 @@
AdditionalOptions="/Zm1000 "
Optimization="0"
AdditionalIncludeDirectories="../../../../include,../../../../src/mesa,../../../../src/mesa/glapi,../../../../src/mesa/main,../../../../src/mesa/shader,../../../../src/mesa/shader/slang,../../../../src/mesa/shader/grammar"
- PreprocessorDefinitions="_DEBUG;WIN32;_LIB;BUILD_GL32;MESA_MINWARN;_CRT_SECURE_NO_DEPRECATE"
+ PreprocessorDefinitions="_DEBUG;WIN32;_LIB;BUILD_GL32;MESA_MINWARN;_CRT_SECURE_NO_DEPRECATE;INSERVER"
BasicRuntimeChecks="3"
RuntimeLibrary="1"
BrowseInformation="1"
@@ -262,7 +262,7 @@
OmitFramePointers="true"
WholeProgramOptimization="true"
AdditionalIncludeDirectories="../../../../include,../../../../src/mesa,../../../../src/mesa/glapi,../../../../src/mesa/main,../../../../src/mesa/shader,../../../../src/mesa/shader/slang,../../../../src/mesa/shader/grammar"
- PreprocessorDefinitions="NDEBUG;WIN32;_LIB;BUILD_GL32;MESA_MINWARN;_CRT_SECURE_NO_DEPRECATE"
+ PreprocessorDefinitions="NDEBUG;WIN32;_LIB;BUILD_GL32;MESA_MINWARN;_CRT_SECURE_NO_DEPRECATE;INSERVER"
StringPooling="true"
ExceptionHandling="0"
RuntimeLibrary="0"
diff --git a/mesalib/windows/VC8/mesa/swrast_dri/swrast_dri.vcproj b/mesalib/windows/VC8/mesa/swrast_dri/swrast_dri.vcproj
index 763a8883e..f61c5833d 100644
--- a/mesalib/windows/VC8/mesa/swrast_dri/swrast_dri.vcproj
+++ b/mesalib/windows/VC8/mesa/swrast_dri/swrast_dri.vcproj
@@ -49,7 +49,7 @@
Name="VCCLCompilerTool"
Optimization="0"
AdditionalIncludeDirectories="../../../../include;../../../../src/mesa/drivers/dri/common;../../../../src/mesa"
- PreprocessorDefinitions="_DEBUG;WIN32;_WINDOWS;_USRDLL;SWRAST_DRI_EXPORTS;_DLL;BUILD_GL32;MESA_MINWARN;IN_DRI_DRIVER"
+ PreprocessorDefinitions="_DEBUG;WIN32;_WINDOWS;_USRDLL;SWRAST_DRI_EXPORTS;_DLL;BUILD_GL32;MESA_MINWARN;IN_DRI_DRIVER;INSERVER"
BasicRuntimeChecks="3"
RuntimeLibrary="3"
BrowseInformation="1"
@@ -72,11 +72,11 @@
<Tool
Name="VCLinkerTool"
AdditionalOptions="/MACHINE:I386"
- AdditionalDependencies="gdi32.lib user32.lib"
+ AdditionalDependencies="gdi32.lib user32.lib vcxsrv_dbg.lib"
OutputFile="$(OutDir)\swrast_dri.dll"
LinkIncremental="1"
SuppressStartupBanner="true"
- AdditionalLibraryDirectories="$(TargetDir)"
+ AdditionalLibraryDirectories="&quot;$(TargetDir)&quot;;&quot;..\..\..\..\..\xorg-server\obj\servdebug&quot;"
GenerateDebugInformation="true"
ProgramDatabaseFile="$(TargetDir)swrast_dri.pdb"
RandomizedBaseAddress="1"
@@ -141,7 +141,7 @@
OmitFramePointers="true"
WholeProgramOptimization="true"
AdditionalIncludeDirectories="../../../../include;../../../../src/mesa/drivers/dri/common;../../../../src/mesa"
- PreprocessorDefinitions="NDEBUG;WIN32;_WINDOWS;_USRDLL;SWRAST_DRI_EXPORTS;_DLL;BUILD_GL32;MESA_MINWARN;IN_DRI_DRIVER"
+ PreprocessorDefinitions="NDEBUG;WIN32;_WINDOWS;_USRDLL;SWRAST_DRI_EXPORTS;_DLL;BUILD_GL32;MESA_MINWARN;IN_DRI_DRIVER;INSERVER"
StringPooling="true"
ExceptionHandling="0"
RuntimeLibrary="2"
@@ -167,11 +167,11 @@
<Tool
Name="VCLinkerTool"
AdditionalOptions="/MACHINE:I386"
- AdditionalDependencies="gdi32.lib user32.lib"
+ AdditionalDependencies="gdi32.lib user32.lib vcxsrv.lib"
OutputFile="$(OutDir)\swrast_dri.dll"
LinkIncremental="1"
SuppressStartupBanner="true"
- AdditionalLibraryDirectories="$(TargetDir)"
+ AdditionalLibraryDirectories="$(TargetDir);&quot;..\..\..\..\..\xorg-server\obj\servrelease&quot;"
ProgramDatabaseFile="$(TargetDir)swrast_dri.pdb"
LinkTimeCodeGeneration="1"
RandomizedBaseAddress="1"
@@ -234,7 +234,7 @@
Name="VCCLCompilerTool"
Optimization="0"
AdditionalIncludeDirectories="../../../../include;../../../../src/mesa/drivers/dri/common;../../../../src/mesa"
- PreprocessorDefinitions="_DEBUG;WIN32;_WINDOWS;_USRDLL;SWRAST_DRI_EXPORTS;BUILD_GL32;MESA_MINWARN;IN_DRI_DRIVER"
+ PreprocessorDefinitions="_DEBUG;WIN32;_WINDOWS;_USRDLL;SWRAST_DRI_EXPORTS;BUILD_GL32;MESA_MINWARN;IN_DRI_DRIVER;INSERVER"
BasicRuntimeChecks="3"
RuntimeLibrary="1"
BrowseInformation="1"
@@ -257,11 +257,11 @@
<Tool
Name="VCLinkerTool"
AdditionalOptions="/MACHINE:I386"
- AdditionalDependencies="gdi32.lib user32.lib"
+ AdditionalDependencies="gdi32.lib user32.lib vcxsrv_dbg.lib"
OutputFile="$(OutDir)\swrast_dri.dll"
LinkIncremental="1"
SuppressStartupBanner="true"
- AdditionalLibraryDirectories="$(TargetDir)"
+ AdditionalLibraryDirectories="$(TargetDir);&quot;..\..\..\..\..\xorg-server\obj\servdebug&quot;"
GenerateDebugInformation="true"
ProgramDatabaseFile="$(TargetDir)swrast_dri.pdb"
RandomizedBaseAddress="1"
@@ -326,7 +326,7 @@
OmitFramePointers="true"
WholeProgramOptimization="true"
AdditionalIncludeDirectories="../../../../include;../../../../src/mesa/drivers/dri/common;../../../../src/mesa"
- PreprocessorDefinitions="NDEBUG;WIN32;_WINDOWS;_USRDLL;SWRAST_DRI_EXPORTS;BUILD_GL32;MESA_MINWARN;IN_DRI_DRIVER"
+ PreprocessorDefinitions="NDEBUG;WIN32;_WINDOWS;_USRDLL;SWRAST_DRI_EXPORTS;BUILD_GL32;MESA_MINWARN;IN_DRI_DRIVER;INSERVER"
StringPooling="true"
ExceptionHandling="0"
RuntimeLibrary="0"
@@ -352,11 +352,11 @@
<Tool
Name="VCLinkerTool"
AdditionalOptions="/MACHINE:I386"
- AdditionalDependencies="gdi32.lib user32.lib"
+ AdditionalDependencies="gdi32.lib user32.lib vcxsrv.lib"
OutputFile="$(OutDir)\swrast_dri.dll"
LinkIncremental="1"
SuppressStartupBanner="true"
- AdditionalLibraryDirectories="$(TargetDir)"
+ AdditionalLibraryDirectories="$(TargetDir);&quot;..\..\..\..\..\xorg-server\obj\servrelease&quot;"
ProgramDatabaseFile="$(TargetDir)swrast_dri.pdb"
LinkTimeCodeGeneration="1"
RandomizedBaseAddress="1"
@@ -394,6 +394,10 @@
Filter="cpp;c;cxx;rc;def;r;odl;idl;hpj;bat"
>
<File
+ RelativePath="..\..\..\..\src\mesa\drivers\common\driverfuncs.c"
+ >
+ </File>
+ <File
RelativePath="..\..\..\..\src\mesa\drivers\dri\swrast\swrast.c"
>
</File>
diff --git a/xorg-server/glx/glapi.c b/xorg-server/glx/glapi.c
index d6a568e88..9cd703030 100644
--- a/xorg-server/glx/glapi.c
+++ b/xorg-server/glx/glapi.c
@@ -54,7 +54,11 @@
#include <dix-config.h>
#include <X11/Xfuncproto.h>
+#ifdef _MSC_VER
+#define PUBLIC _declspec(dllexport)
+#else
#define PUBLIC _X_EXPORT
+#endif
#else
diff --git a/xorg-server/glx/glapi.h b/xorg-server/glx/glapi.h
index 8f2cf6621..68e5cd328 100644
--- a/xorg-server/glx/glapi.h
+++ b/xorg-server/glx/glapi.h
@@ -73,6 +73,11 @@ typedef void (*_glapi_warning_func)(void *ctx, const char *str, ...);
*/
#define MAX_EXTENSION_FUNCS 300
+#ifdef _MSC_VER
+#define EXTERN _declspec(dllexport)
+#else
+#define EXTERN extern
+#endif
/**
** Define the GET_CURRENT_CONTEXT() macro.
@@ -90,8 +95,8 @@ extern __thread void * _glapi_tls_Context
#else
-extern void *_glapi_Context;
-extern struct _glapi_table *_glapi_Dispatch;
+EXTERN void *_glapi_Context;
+EXTERN struct _glapi_table *_glapi_Dispatch;
# ifdef THREADS
# define GET_CURRENT_CONTEXT(C) GLcontext *C = (GLcontext *) (_glapi_Context ? _glapi_Context : _glapi_get_context())
@@ -106,29 +111,29 @@ extern struct _glapi_table *_glapi_Dispatch;
** GL API public functions
**/
-extern void
+EXTERN void
_glapi_noop_enable_warnings(GLboolean enable);
-extern void
+EXTERN void
_glapi_set_warning_func(_glapi_warning_func func);
-extern void
+EXTERN void
_glapi_check_multithread(void);
-extern void
+EXTERN void
_glapi_set_context(void *context);
-extern void *
+EXTERN void *
_glapi_get_context(void);
-extern void
+EXTERN void
_glapi_set_dispatch(struct _glapi_table *dispatch);
-extern struct _glapi_table *
+EXTERN struct _glapi_table *
_glapi_get_dispatch(void);
@@ -144,7 +149,7 @@ struct _glapi_table *
_glapi_get_override_dispatch(int layer);
-extern GLuint
+EXTERN GLuint
_glapi_get_dispatch_table_size(void);
@@ -152,11 +157,11 @@ extern void
_glapi_check_table(const struct _glapi_table *table);
-extern int
+EXTERN int
_glapi_add_dispatch( const char * const * function_names,
const char * parameter_signature );
-extern GLint
+EXTERN GLint
_glapi_get_proc_offset(const char *funcName);
diff --git a/xorg-server/installer/vcxsrv.nsi b/xorg-server/installer/vcxsrv.nsi
index fe2492a0f..1d92d7442 100644
--- a/xorg-server/installer/vcxsrv.nsi
+++ b/xorg-server/installer/vcxsrv.nsi
@@ -85,7 +85,6 @@ Section "VcXsrv (required)"
File "..\XErrorDB"
File "..\hw\xwin\xlaunch\obj\release\xlaunch.exe"
File "..\..\tools\plink\obj\release\plink.exe"
- File "..\..\mesalib\windows\VC8\mesa\Release\mesaopengl32.dll"
File "..\..\mesalib\windows\VC8\mesa\Release\swrast_dri.dll"
SetOutPath $INSTDIR\fonts
File /r "..\fonts\*.*"
diff --git a/xorg-server/makefile b/xorg-server/makefile
index 61f94c3a9..c9b9e7e62 100644
--- a/xorg-server/makefile
+++ b/xorg-server/makefile
@@ -125,9 +125,11 @@ load_makefile xkbdata.src\makefile MAKESERVER=0 DEBUG=0
all: $(APP).exe xlaunch.exe xkbcomp.exe protocol.txt XKeysymDB XErrorDB \
..\libX11\nls\all fonts.src\all xkbdata.src\all plink.exe xclock.exe xcalc.exe \
- xwininfo.exe mesaopengl32.dll swrast_dri.dll
+ xwininfo.exe swrast_dri.dll
-swrast_dri.dll: ..\mesalib\lib\swrast_dri.dll
+
+load_makefile ..\mesalib\windows\VC8\mesa\makefile MAKESERVER=0 DEBUG=0
+swrast_dri.dll: ..\mesalib\windows\VC8\mesa\Release\swrast_dri.dll
copy $< $@
mesaopengl32.dll: ..\mesalib\lib\mesaopengl32.dll