removed os2 support & support for building SDL with watcom.

This commit is contained in:
Ozkan Sezer
2022-11-22 19:18:47 +03:00
parent 01d137592c
commit 8d6fda4810
79 changed files with 3 additions and 10017 deletions

View File

@@ -269,22 +269,14 @@ testnative$(EXE): $(srcdir)/testnative.c \
$(CC) -o $@ $^ $(CFLAGS) $(LIBS) @XLIB@
endif
ifeq (@ISOS2@,true)
testnative$(EXE): $(srcdir)/testnative.c \
$(srcdir)/testnativeos2.c
$(CC) -o $@ $^ $(CFLAGS) $(LIBS)
endif
#there's probably a better way of doing this
ifeq (@ISMACOSX@,false)
ifeq (@ISWINDOWS@,false)
ifeq (@ISUNIX@,false)
ifeq (@ISOS2@,false)
testnative$(EXE): ;
endif
endif
endif
endif
testoverlay2$(EXE): $(srcdir)/testoverlay2.c $(srcdir)/testyuv_cvt.c $(srcdir)/testutils.c
$(CC) -o $@ $^ $(CFLAGS) $(LIBS)

View File

@@ -1,18 +0,0 @@
# Open Watcom makefile to build SDL3 tests for OS/2
# wmake -f Makefile.os2
#
# To error out upon warnings: wmake -f Makefile.os2 ENABLE_WERROR=1
SYSTEM = os2v2
INCPATH = -I"$(%WATCOM)/h/os2" -I"$(%WATCOM)/h"
CFLAGS = -bt=os2 -d0 -q -bm -5s -fp5 -fpi87 -sg -oteanbmier -ei
CFLAGS+= -wx -wcd=303
!ifeq ENABLE_WERROR 1
CFLAGS+= -we
!endif
TNSRCS = testnative.c testnativeos2.c
!include watcom.mif

View File

@@ -1,21 +0,0 @@
# Open Watcom makefile to build SDL3 tests for Win32
# wmake -f Makefile.w32
#
# To error out upon warnings: wmake -f Makefile.w32 ENABLE_WERROR=1
SYSTEM = nt
INCPATH = -I"$(%WATCOM)/h/nt" -I"$(%WATCOM)/h" -I"../src/video/khronos"
CFLAGS = -bt=nt -d0 -q -bm -5s -fp5 -fpi87 -sg -oteanbmier -ei
CFLAGS+= -wx -wcd=303
!ifeq ENABLE_WERROR 1
CFLAGS+= -we
!endif
CFLAGS+= -DSDL_MAIN_HANDLED
CFLAGS+= -DHAVE_OPENGL
GLLIBS = opengl32.lib
TNSRCS = testnative.c testnativew32.c
!include watcom.mif

9
test/configure vendored
View File

@@ -633,7 +633,6 @@ SDL_CFLAGS
PKG_CONFIG_LIBDIR
PKG_CONFIG_PATH
PKG_CONFIG
ISOS2
ISUNIX
ISWINDOWS
ISMACOSX
@@ -3557,7 +3556,6 @@ fi
ISUNIX="false"
ISWINDOWS="false"
ISMACOSX="false"
ISOS2="false"
case "$host" in
*-*-cygwin* | *-*-mingw*)
@@ -3658,12 +3656,6 @@ fi
MATHLIB=""
SYS_GL_LIBS=""
;;
*-*-os2*)
ISOS2="true"
EXE=".exe"
MATHLIB=""
SYS_GL_LIBS=""
;;
*)
ISUNIX="true"
EXE=""
@@ -3718,7 +3710,6 @@ esac
SDL_VERSION=3.0.0

View File

@@ -18,7 +18,6 @@ dnl (Haiku, for example, sets none of these.)
ISUNIX="false"
ISWINDOWS="false"
ISMACOSX="false"
ISOS2="false"
dnl Figure out which math library to use
case "$host" in
@@ -76,12 +75,6 @@ case "$host" in
MATHLIB=""
SYS_GL_LIBS=""
;;
*-*-os2*)
ISOS2="true"
EXE=".exe"
MATHLIB=""
SYS_GL_LIBS=""
;;
*)
dnl Oh well, call it Unix...
ISUNIX="true"
@@ -97,7 +90,6 @@ AC_SUBST(MATHLIB)
AC_SUBST(ISMACOSX)
AC_SUBST(ISWINDOWS)
AC_SUBST(ISUNIX)
AC_SUBST(ISOS2)
dnl Check for SDL
SDL_VERSION=3.0.0

View File

@@ -32,9 +32,6 @@ static NativeWindowFactory *factories[] = {
#endif
#ifdef TEST_NATIVE_COCOA
&CocoaWindowFactory,
#endif
#ifdef TEST_NATIVE_OS2
&OS2WindowFactory,
#endif
NULL
};

View File

@@ -13,7 +13,6 @@
/* Definitions for platform dependent windowing functions to test SDL
integration with native windows
*/
#include "SDL.h"
/* This header includes all the necessary system headers for native windows */
@@ -44,8 +43,3 @@ extern NativeWindowFactory X11WindowFactory;
#define TEST_NATIVE_COCOA
extern NativeWindowFactory CocoaWindowFactory;
#endif
#ifdef SDL_VIDEO_DRIVER_OS2
#define TEST_NATIVE_OS2
extern NativeWindowFactory OS2WindowFactory;
#endif

View File

@@ -1,57 +0,0 @@
/*
Copyright (C) 1997-2022 Sam Lantinga <slouken@libsdl.org>
This software is provided 'as-is', without any express or implied
warranty. In no event will the authors be held liable for any damages
arising from the use of this software.
Permission is granted to anyone to use this software for any purpose,
including commercial applications, and to alter it and redistribute it
freely.
*/
#include "testnative.h"
#ifdef TEST_NATIVE_OS2
#define WIN_CLIENT_CLASS "SDL Test"
static void *CreateWindowNative(int w, int h);
static void DestroyWindowNative(void *window);
NativeWindowFactory OS2WindowFactory = {
"DIVE",
CreateWindowNative,
DestroyWindowNative
};
static void *CreateWindowNative(int w, int h)
{
HWND hwnd, hwndFrame;
ULONG ulFrameFlags = FCF_TASKLIST | FCF_DLGBORDER | FCF_TITLEBAR |
FCF_SYSMENU | FCF_SHELLPOSITION |
FCF_SIZEBORDER | FCF_MINBUTTON | FCF_MAXBUTTON;
WinRegisterClass(0, WIN_CLIENT_CLASS, WinDefWindowProc,
CS_SIZEREDRAW | CS_MOVENOTIFY,
sizeof(ULONG)); /* We should have minimum 4 bytes. */
hwndFrame = WinCreateStdWindow(HWND_DESKTOP, 0, &ulFrameFlags,
WIN_CLIENT_CLASS, "SDL Test", 0, 0, 1, &hwnd);
if (hwndFrame == NULLHANDLE) {
return NULL;
}
WinSetWindowPos(hwndFrame, HWND_TOP, 0, 0, w, h,
SWP_ZORDER | SWP_ACTIVATE | SWP_SIZE | SWP_SHOW);
return (void *)hwndFrame; /* We may return client or frame window
handle for SDL_CreateWindowFrom(). */
}
static void DestroyWindowNative(void *window)
{
WinDestroyWindow((HWND) window);
}
#endif /* TEST_NATIVE_OS2 */

View File

@@ -1,122 +0,0 @@
INCPATH+= -I"../include"
LIBPATH = ..
LIBS = SDL3.lib SDL3test.lib testutils.lib
#CFLAGS+= -DHAVE_SDL_TTF
#TTFLIBS = SDL3ttf.lib
CFLAGS+= $(INCPATH)
TARGETS = testatomic.exe testdisplayinfo.exe testbounds.exe testdraw2.exe &
testdrawchessboard.exe testdropfile.exe testerror.exe testfile.exe &
testfilesystem.exe testgamecontroller.exe testgeometry.exe testgesture.exe &
testhittesting.exe testhotplug.exe testiconv.exe testime.exe testlocale.exe &
testintersections.exe testjoystick.exe testkeys.exe testloadso.exe &
testlock.exe testmessage.exe testoverlay2.exe testplatform.exe &
testpower.exe testsensor.exe testrelative.exe testrendercopyex.exe &
testrendertarget.exe testrumble.exe testscale.exe testsem.exe &
testshader.exe testshape.exe testsprite2.exe testspriteminimal.exe &
teststreaming.exe testthread.exe testtimer.exe testver.exe &
testviewport.exe testwm2.exe torturethread.exe checkkeys.exe &
checkkeysthreads.exe testmouse.exe testgles.exe testgles2.exe &
controllermap.exe testhaptic.exe testqsort.exe testresample.exe &
testaudioinfo.exe testaudiocapture.exe loopwave.exe loopwavequeue.exe &
testsurround.exe testyuv.exe testgl2.exe testvulkan.exe testnative.exe &
testautomation.exe testaudiohotplug.exe testcustomcursor.exe testmultiaudio.exe &
testoffscreen.exe testurl.exe
noninteractive = &
testatomic.exe &
testerror.exe &
testfilesystem.exe &
testkeys.exe &
testlocale.exe &
testplatform.exe &
testpower.exe &
testqsort.exe &
testthread.exe &
testtimer.exe &
testver.exe
needs_audio = &
testaudioinfo.exe &
testsurround.exe
needs_display = &
testbounds.exe &
testdisplayinfo.exe
TESTS = $(noninteractive) $(needs_audio) $(needs_display)
# testautomation sources
TASRCS = testautomation.c &
testautomation_audio.c testautomation_clipboard.c &
testautomation_events.c testautomation_guid.c &
testautomation_hints.c testautomation_joystick.c &
testautomation_keyboard.c testautomation_main.c &
testautomation_math.c testautomation_mouse.c &
testautomation_pixels.c testautomation_platform.c &
testautomation_rect.c testautomation_render.c &
testautomation_rwops.c testautomation_sdltest.c &
testautomation_stdlib.c testautomation_surface.c &
testautomation_syswm.c testautomation_timer.c &
testautomation_video.c
OBJS = $(TARGETS:.exe=.obj)
COBJS = $(CSRCS:.c=.obj)
TAOBJS = $(TASRCS:.c=.obj)
TNOBJS = $(TNSRCS:.c=.obj)
all: testutils.lib $(TARGETS)
.c: ../src/test
.obj.exe:
wlink SYS $(SYSTEM) libpath $(LIBPATH) lib {$(LIBS)} op q op el file {$<} name $@
.c.obj:
wcc386 $(CFLAGS) -fo=$^@ $<
# specials
testvulkan.obj: testvulkan.c
# new vulkan headers result in lots of W202 warnings
wcc386 $(CFLAGS) -wcd=202 -fo=$^@ $<
testautomation.exe: $(TAOBJS)
wlink SYS $(SYSTEM) libpath $(LIBPATH) lib {$(LIBS)} op q op el file {$<} name $@
testnative.exe: $(TNOBJS)
wlink SYS $(SYSTEM) libpath $(LIBPATH) lib {$(LIBS)} op q op el file {$<} name $@
testoverlay2.exe: testoverlay2.obj testyuv_cvt.obj
wlink SYS $(SYSTEM) libpath $(LIBPATH) lib {$(LIBS)} op q op el file {$<} name $@
testyuv.exe: testyuv.obj testyuv_cvt.obj
wlink SYS $(SYSTEM) libpath $(LIBPATH) lib {$(LIBS)} op q op el file {$<} name $@
testshader.exe: testshader.obj
wlink SYS $(SYSTEM) libpath $(LIBPATH) lib {$(LIBS) $(GLLIBS)} op q op el file {$<} name $@
testime.exe: testime.obj
wlink SYS $(SYSTEM) libpath $(LIBPATH) lib {$(LIBS) $(TTFLIBS)} op q op el file {$<} name $@
testutils.lib: testutils.obj
wlib -q -b -n -c -pa -s -t -zld -ii -io $@ $<
check: .SYMBOLIC $(TESTS)
@set SDL_AUDIODRIVER=dummy
@set SDL_VIDEODRIVER=dummy
@copy "../SDL3.dll" .
@for %exe in ($(TESTS)) do %exe
check-quick: .SYMBOLIC $(TESTS)
@set SDL_TESTS_QUICK=1
@set SDL_AUDIODRIVER=dummy
@set SDL_VIDEODRIVER=dummy
@copy "../SDL3.dll" .
@for %exe in ($(TESTS)) do %exe
clean: .SYMBOLIC
rm -f *.obj *.err
distclean: .SYMBOLIC clean
rm -f *.exe *.lib