mesa: new MESA_EXTENSION_MAX_YEAR env var
[mesa.git] / docs / README.MINGW32
index 75709ed43d8996c491182d7819346051b37d8627..9477b2bd3182ccd12175845f75d508e8b314b64e 100644 (file)
-August 30, 1998 -- Paul Garceau (pgarceau@teleport.com)\r
-\r
-DISCLAIMER:  I make this extension to the Mesa 3-D Graphics Library as a service\r
-to the general public.  I can, in no way support or make any guarantee that the\r
-EGCS-Mingw32 build or any Gnu-Win32 build will work for your system. The\r
-associated packages and batch files I have included as part of the EGCS-Mingw32\r
-extension are provided "As-is" with out any guarantee of support or functionality\r
-from the author of this EGCS-Mingw32 native windows port of the Mesa 3-D Graphics\r
-Library.\r
-\r
-       Feel free to modify or change things as you see fit, just remember that\r
-I can't support any modifications you might want to make to the files which I\r
-have included OR the lgpl protected Mesa 3-D Graphics Library.\r
-\r
-\r
-       EGCS-Mingw32 Beta 3.08 Archive Manifest:\r
-               mingw32.bat\r
-               src/makefile.nt4\r
-               src/wmesa.c\r
-               src-glu/makefile.nt4\r
-\r
-###############\r
-\r
-Greetings,\r
-\r
-       In order to build the Mingw32 set of Mesa 3-D Graphics Library for Beta3.08\r
-it will be necessary for you to use the Dos or Command Prompt that is available\r
-on most of the i86 based MS Windows machines.  Also, I believe that this build\r
-will run on Win95, Win98, WinNT4 and WinNT5.\r
-\r
-       I haven't tested Win95/98 or WinNT5.  This build was generated under\r
-WinNT4 with SP3 installed.\r
-\r
-       This has not been tested under any systems outside of\r
-a WinNT4 Workstation with EGCS-Mingw32 toolchain, v.1.0.2 installed.\r
-\r
-       EGCS-Mingw32 uses a variation of gcc to handle its build.  The Mesa 3-D\r
-Graphics Library build that I have generated is based, in small part, on the\r
-Cygwin32 build and associated makefiles that Stephane Rehel (rehel@worldnet.fr)\r
-defined back in 1997.  The EGCS-Mingw32 toolchain is capable of generating\r
-native windows code and, as of the date of this readme, can be obtained from:\r
-\r
-       http://www.xraylith.wisc.edu/~khan/software/gnu-win32/egcs-mingw32-102.html\r
-\r
-       Much thanks to the combined efforts of Mumit Khan, Jan-Jaap Vanderhagen\r
-and Colin Peters for making it possible for the EGCS-Mingw32 toolchain to exist.\r
-\r
-Installing EGCS-Mingw32 Build Revisions:\r
-\r
-       To install the makefile and source revisions incorporated with this build\r
-of the Mesa 3-D Graphics Library, you'll have to use a version of winzip.  I am\r
-in the process of finding a suitable Win32 compatible tar executable so that if\r
-you don't have winzip, you can still decompress the files into their respective\r
-folders/directories.\r
-\r
-       a) Move the mingw32.zip file to the top level of the hard drive on your\r
-system.\r
-\r
-       b) Copy all of the Beta 3.08 src/windows files to the src/ directory.\r
-\r
-       b) Open the Winzip file\r
-\r
-       c) Verify that the files will be properly extracted.\r
-\r
-       d) Extract the files with the Winzip "Overwrite" and "Use Folder Names"\r
-          options enabled.\r
-\r
-       The zip file directory structure extraction defaults to the top level of\r
-the hard drive where the mingw32.zip file exists unless otherwise instructed by\r
-you.\r
-\r
-       The version of wmesa.c included with the mingw32 archive needs to replace\r
-the current version of the Beta 3.08 wmesa.c file in order for the egcs-mingw32\r
-build to work.  This is because the original Win32 stuff assumes that the glut\r
-utilities are to be installed.  The Glut utilities are not part of the\r
-egcs-mingw32 build for Beta 3.08.\r
-\r
-\r
-Build Considerations:\r
-\r
-       In order to get the build to work, I needed to create a special makefile\r
-for each library which the Mesa 3-D Graphics Library requires since there is no\r
-comparable make-config/config on a native windows platform.\r
-\r
-       Since I was only creating a few of the possible libraries for \r
-Mesa (gl, glu), I only created the new make files in their respective libraries\r
-src, src-glu).  For libMesaaux.a. you will find a makefile for it in the\r
-src-aux directory.  libMesatk.a and libglut.a were not ported.\r
-\r
-       The build itself is a .bat based build and uses Gnu Make,Version 3.76.1 to\r
-process the makefiles noted above.  The build must be run from the directory\r
-where the mingw32.bat file is.  You can get the binary version of Make 3.76.1\r
-from Jan-Jaap van der Heijden's site in Germany:\r
-\r
-       http://agnes.dida.physik.uni-essen.de/~janjaap/mingw32/download.html\r
-\r
-       It was necessary to modify some source code, specifically the source code\r
-in the src-glu directory.  I needed to modify nurbs.c, quadric.c and tess.c in\r
-order to get them to work using the EGCS-Mingw32 toolchain.\r
-\r
-       The original EGCS-Mingw32 Toolchain, is available from:\r
-\r
-       http://www.xraylith.wisc.edu/~khan/software/gnu-win32/egcs-mingw32-102.html     \r
-\r
-Running the Build:\r
-\r
-       Ok, now that we've got the basics out of the way, follows is all you need\r
-to do in order to build the EGCS-Mingw32 version of libMesaGL.a and libMesaGLU.a:\r
-\r
-       Open your Command Prompt/Dos prompt.\r
-       Go to your Mesa-3.0 beta 'root' directory.\r
-               This is the same directory that the Mesa mingw32.zip file was\r
-               originally stored in if you've installed the Mesa-3.0 beta 3-D\r
-               Graphics Library source as outlined in the "readme" file included\r
-               with the Mesa-3.0 beta distribution.\r
-       At the command line type: mingw32\r
-               mingw32 is the .bat file that actually does the build.\r
-\r
-       Enjoy!\r
-\r
-       Peace,\r
-\r
-               Paul G. (pgarceau@teleport.com)
\ No newline at end of file
+                            Mesa 6.1 for MinGW32
+                            ~~~~~~~~~~~~~~~~~~~~
+
+
+
+Quick & dirty start:
+--------------------
+
+       mingw32-make -f Makefile.mgw [OPTIONS...]
+
+   Look into the corresponding makefiles for further information.
+   Check README.3DFX to find out how to compile Mesa Glide3 driver
+   with MinGW32!
+
+
+
+*******************************************************************************
+The Mingw port for Mesa 3-D Graphics Library was created August 30, 1998 by Paul Garceau.
+
+Updated January 13, 2000; June 3, 2005 -- Paul Garceau <pgarceau@users.sourceforge.net>
+
+DISCLAIMER:  I make this port of the Mesa 3-D Graphics Library as a service
+to the general public.  I can, in no way support or make any guarantee that the
+build will work for your system.
+
+Acknowledgements:
+
+       Daniel Borca, whose work and commitment to maintaining the Mingw port of the Mesa 3-D Graphics Library has been, and will continue to be greatly appreciated by an overworked and underpaid developer such as myself.
+       Without the creative inspiration and personal commitment provided by Mumit Khan, Jan-Jaap Vanderhagen and Colin Peters, Mingw would never have existed.         Acknowledgements also need to be given to all of the developers who have worked on Mingw, Mesa and Msys over the years.
+       Last, but certainly far from the least, Brian Paul, who has dedicated at least the last seven or eight years of his life to making Mesa 3-D Graphics Library what it is today and managing the development for all of those years.
+*********************************************************************************
+
+Greetings,
+
+       Feel free to modify or change things related to the Mingw build as you see fit, just remember that, the author of the current build may not be able to support any modifications you might want to make to the files which have been included for the build.
+
+Mesa core components are licensed under XFree-86 (for more on licensing of Mesa 3-D Graphics Library, check out the Mesa homepage (http://www.mesa3d.org).
+
+The Mingw generated libraries themselves are licensed under the GNU-LGPL license.  Source code for Mingw can be found at http://www.mingw.org.  For licensing terms on Mingw, please visit http://www.mingw.org.
+
+       It is recommended that you use the latest "stable" release of Mingw.  "Candidates" are beta testing distributions for Mingw.  Mingw is available at http://www.mingw.org.
+
+       This build has been tested under WinNT4/SP6.  Win9x and WinNT5 remain untested by me.  I have not tested any of the demos included with Mesa3d.
+
+Installation:
+
+       This readme assumes that you already have extracted the necessary files to a working directory/folder that Mingw can use to build the Mesa3D libraries and that you know where that directory/folder is located on your Windows system.  If you have any questions about how to set things up properly which is specific to Mesa3D, the folks on the Mesa3D mailing lists (http://www.mesa3d.org) would probably be happy to assist you.  Also you can probably ask anyone on the Mingw mailing lists for any questions specific to Mingw (http://www.mingw.org)
+
+Targets and Environment variables used for Mingw build:
+
+       Before going into the actual build of the libraries, here is a list of available targets for the make process:
+
+       "all" or "libgl"  -- this target will build libopengl.a, a static library.  It will not build the demos, etc.
+
+       clean -- this target will clean up most of the Mesa 3-D Graphics Library/object code from your hard drive.
+
+       realclean -- this target will clean up all of the Mesa 3D Graphics Library and the Mesa object code that it can find.
+
+       Environment Variables:
+
+       The environment variables are used to determine what sort of graphics driver support needs to be included in the finished Mesa 3-D Graphics Library.
+
+       GLIDE           path to Glide3 SDK; used with FX.
+                       default = $(TOP)/glide3
+       FX=1            build for 3dfx Glide3. Note that this disables
+                       compilation of most WMesa code and requires fxMesa.
+                       As a consequence, you'll need the Win32 Glide3
+                       library to build any application.
+                       default = no
+       ICD=1           build the installable client driver interface
+                       (windows opengl driver interface)
+                       default = no
+       X86=1           optimize for x86 (if possible, use MMX, SSE, 3DNow).
+                       default = no
+
+       
+Running the Build:
+
+       Launch Mingw.
+       From the Windows Command Prompt:
+       Set Environment Variables (as needed).
+       "cd" to your Mesa3D 'root' directory.
+       Enter "mingw32-make -f makefile.mgw <target>
+
+       That's all there is to it.
+
+       Enjoy!
+
+               Paul G. <pgarceau@users.sourceforge.net>
+               Daniel Borca <dborca@users.sourceforge.net>
+
+
+
+******This section is added by Heromyth <zxpmyth@yahoo.com.cn>*************
+
+====================
+Updated on 2007-7-21
+====================
+
+Notice:
+       1) The generated DLLs are *not* compatible with the ones built
+with the other compilers like VC8, especially for GLUT. 
+
+       2) Although more tests are needed, it can be used individually!
+
+       3) You can set the options about whether using STDCALL to build MESA. The 
+config file is <Mesa3D-root>\configs\config.mgw. The default setting is that:
+               ALL_USING_STDCALL = 1
+, which means using STDCALL to build MESA. 
+
+       4) Of course, you can MESA without using STDCALL,I like this:) 
+The setting is :
+               ALL_USING_STDCALL = 0
+To do this, however, you must modify wingdi.h which is in MingW's include dir. 
+For example, run:
+       notepad C:\MingW\include\wingdi.h
+, and delete all the lines where all the wgl*() functions are. Because they would 
+be conflicted with the ones in <Mesa3D-root>\include\GL\mesa_wgl.h.
+
+>>>>>>>>>> Conflicted Functions List >>>>>>>>>>
+WINGDIAPI BOOL WINAPI wglCopyContext(HGLRC,HGLRC,UINT);
+WINGDIAPI HGLRC WINAPI wglCreateContext(HDC);
+WINGDIAPI HGLRC WINAPI wglCreateLayerContext(HDC,int);
+WINGDIAPI BOOL WINAPI wglDeleteContext(HGLRC);
+WINGDIAPI BOOL WINAPI wglDescribeLayerPlane(HDC,int,int,UINT,LPLAYERPLANEDESCRIPTOR);
+WINGDIAPI HGLRC WINAPI wglGetCurrentContext(void);
+WINGDIAPI HDC WINAPI wglGetCurrentDC(void);
+WINGDIAPI int WINAPI wglGetLayerPaletteEntries(HDC,int,int,int,COLORREF*);
+WINGDIAPI PROC WINAPI wglGetProcAddress(LPCSTR);
+WINGDIAPI BOOL WINAPI wglMakeCurrent(HDC,HGLRC);
+WINGDIAPI BOOL WINAPI wglRealizeLayerPalette(HDC,int,BOOL);
+WINGDIAPI int WINAPI wglSetLayerPaletteEntries(HDC,int,int,int,const COLORREF*);
+WINGDIAPI BOOL WINAPI wglShareLists(HGLRC,HGLRC);
+WINGDIAPI BOOL WINAPI wglSwapLayerBuffers(HDC,UINT);
+WINGDIAPI BOOL WINAPI wglUseFontBitmapsA(HDC,DWORD,DWORD,DWORD);
+WINGDIAPI BOOL WINAPI wglUseFontBitmapsW(HDC,DWORD,DWORD,DWORD);
+WINGDIAPI BOOL WINAPI wglUseFontOutlinesA(HDC,DWORD,DWORD,DWORD,FLOAT,FLOAT,int,LPGLYPHMETRICSFLOAT);
+WINGDIAPI BOOL WINAPI wglUseFontOutlinesW(HDC,DWORD,DWORD,DWORD,FLOAT,FLOAT,int,LPGLYPHMETRICSFLOAT);
+<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
+
+====================
+Updated on 2007-7-22
+====================
+       I havn't thought that I would find a better way to solve my problems so soon. 
+I changed the method in which the import-libs and DLLs are made. After this update,
+the DLLs of MESA are more optimized and more compatible. 
+       It seems that there is no need to keep the building way of 'NO-STDCALL'.The 
+way of USING_STDCALL is so nice! The file <Mesa3D-root>\configs\config.mgw is 
+also not needed, and can be deleted safely!
+       
+
+
+*********************************************************************************
\ No newline at end of file