build-scripts/windows-buildbot-zipper.bat
author Sam Lantinga
Tue, 10 Jan 2017 08:54:33 -0800
changeset 10806 36f40b8cc979
parent 9264 c1eab6da82c1
child 11168 93e083869445
permissions -rw-r--r--
Fixed bugs 2570, 3145, improved OpenGL ES context support on Windows and X11

Mark Callow

The attached patch does the following for the X11 and Windows platforms, the only ones where SDL attempts to use context_create_es_profile:

- Adds SDL_HINT_OPENGL_ES_DRIVER by which the application can
say to use the OpenGL ES driver & EGL rather than the Open GL
driver. (For bug #2570)
- Adds code to {WIN,X11}_GL_InitExtensions to determine the maximum
OpenGL ES version supported by the OpenGL driver (for bug #3145)
- Modifies the test that determines whether to use the OpenGL
driver or the real OpenGL ES driver to take into account the
hint, the requested and supported ES version and whether ES 1.X
is being requested. (For bug #2570 & bug #3145)
- Enables the testgles2 test for __WINDOWS__ and __LINUX__ and adds
the test to the VisualC projects.

With the fix in place I have run testdraw2, testgl and testgles2 without any issues and have run my own apps that use OpenGL, OpenGL ES 3 and OpenGL ES 1.1.
icculus@9263
     1
@echo off
icculus@9263
     2
rem just a helper batch file for collecting up files and zipping them.
icculus@9263
     3
rem usage: windows-buildbot-zipper.bat <zipfilename>
icculus@9263
     4
rem must be run from root of SDL source tree.
icculus@9263
     5
icculus@9264
     6
IF EXIST VisualC\Win32\Release GOTO okaydir
icculus@9263
     7
echo Please run from root of source tree after doing a Release build.
icculus@9263
     8
GOTO done
icculus@9263
     9
icculus@9263
    10
:okaydir
icculus@9263
    11
erase /q /f /s zipper
icculus@9263
    12
IF EXIST zipper GOTO zippermade
icculus@9263
    13
mkdir zipper
icculus@9263
    14
:zippermade
icculus@9263
    15
cd zipper
icculus@9263
    16
mkdir SDL
icculus@9263
    17
cd SDL
icculus@9263
    18
mkdir include
icculus@9263
    19
mkdir lib
icculus@9263
    20
mkdir lib\win32
icculus@9263
    21
copy ..\..\include\*.h include\
icculus@9264
    22
copy ..\..\VisualC\Win32\Release\SDL2.dll lib\win32\
icculus@9264
    23
copy ..\..\VisualC\Win32\Release\SDL2.lib lib\win32\
icculus@9264
    24
copy ..\..\VisualC\Win32\Release\SDL2main.lib lib\win32\
icculus@9263
    25
cd ..
icculus@9263
    26
zip -9r ..\%1 SDL
icculus@9263
    27
cd ..
icculus@9263
    28
erase /q /f /s zipper
icculus@9263
    29
icculus@9263
    30
:done
icculus@9263
    31