Makefile.dc
author Sam Lantinga <slouken@libsdl.org>
Tue, 25 Jan 2005 16:57:11 +0000
changeset 1032 c1c2efca4548
parent 509 dad72daf44b3
child 1461 11134dc42da8
permissions -rw-r--r--
Date: Mon, 24 Jan 2005 21:37:56 +0800
From: Chris Taylor
Subject: Patch to put back dynamic OpenGL loading for MPW

I sent a patch a while ago that removes dynamic OpenGL loading for
Macintosh Programmer's Workshop. Dynamic loading DOES actually work
when an SDL program is built with MPW, it just has to be set up for it.
(Whoops!!) This is the ideal way to get OpenGL extensions to work,
which D2X uses quite a few of.

This patch puts dynamic loading back in SDL for Mac OS 9. It applies to
current CVS. I noticed that two members need to be set when
DrawSprocket is used.
slouken@509
     1
#GL=1
slouken@509
     2
slouken@509
     3
CC = sh-elf-gcc -ml -m4-single-only
slouken@509
     4
AR = sh-elf-ar
slouken@509
     5
KOS_BASE=/prog/kos-1.1.7
slouken@509
     6
INCS = -I$(KOS_BASE)/libc/include -I$(KOS_BASE)/include -I$(KOS_BASE)/kernel/arch/dreamcast/include
slouken@509
     7
DEFS =-DNO_SIGNAL_H -DENABLE_DC
slouken@509
     8
slouken@509
     9
ifdef GL
slouken@509
    10
DEFS += -DHAVE_OPENGL
slouken@509
    11
TARGET = libSDL_gl.a
slouken@509
    12
else
slouken@509
    13
TARGET = libSDL.a
slouken@509
    14
endif
slouken@509
    15
slouken@509
    16
OPTFLAGS=-O2 -fomit-frame-pointer
slouken@509
    17
CFLAGS=-D_arch_dreamcast $(DEFS) $(INCS) -Iinclude -Isrc -Isrc/audio -Isrc/cdrom -Isrc/endian -Isrc/events -Isrc/joystick -Isrc/thread/dc -Isrc/thread -Isrc/timer -Isrc/video $(OPTFLAGS)
slouken@509
    18
slouken@509
    19
SRCS = \
slouken@509
    20
	src/audio/dc/SDL_dcaudio.c \
slouken@509
    21
	src/audio/dc/aica.c \
slouken@509
    22
	src/audio/SDL_audio.c \
slouken@509
    23
	src/audio/SDL_audiocvt.c \
slouken@509
    24
	src/audio/SDL_audiodev.c \
slouken@509
    25
	src/audio/SDL_audiomem.c \
slouken@509
    26
	src/audio/SDL_mixer.c \
slouken@509
    27
	src/audio/SDL_wave.c \
slouken@509
    28
	src/cdrom/dc/SDL_syscdrom.c \
slouken@509
    29
	src/cdrom/SDL_cdrom.c \
slouken@509
    30
	src/endian/SDL_endian.c \
slouken@509
    31
	src/events/SDL_active.c \
slouken@509
    32
	src/events/SDL_events.c \
slouken@509
    33
	src/events/SDL_expose.c \
slouken@509
    34
	src/events/SDL_keyboard.c \
slouken@509
    35
	src/events/SDL_mouse.c \
slouken@509
    36
	src/events/SDL_quit.c \
slouken@509
    37
	src/events/SDL_resize.c \
slouken@509
    38
	src/file/SDL_rwops.c \
slouken@509
    39
	src/joystick/dc/SDL_sysjoystick.c \
slouken@509
    40
	src/joystick/SDL_joystick.c \
slouken@509
    41
	src/SDL.c \
slouken@509
    42
	src/SDL_error.c \
slouken@509
    43
	src/SDL_fatal.c \
slouken@509
    44
	src/SDL_getenv.c \
slouken@509
    45
	src/SDL_loadso.c \
slouken@509
    46
	src/thread/dc/SDL_syscond.c \
slouken@509
    47
	src/thread/dc/SDL_sysmutex.c \
slouken@509
    48
	src/thread/dc/SDL_syssem.c \
slouken@509
    49
	src/thread/dc/SDL_systhread.c \
slouken@509
    50
	src/thread/SDL_thread.c \
slouken@509
    51
	src/timer/dc/SDL_systimer.c \
slouken@509
    52
	src/timer/SDL_timer.c \
slouken@509
    53
	src/video/dc/SDL_dcevents.c \
slouken@509
    54
	src/video/dc/SDL_dcvideo.c \
slouken@509
    55
	src/video/SDL_blit.c \
slouken@509
    56
	src/video/SDL_blit_0.c \
slouken@509
    57
	src/video/SDL_blit_1.c \
slouken@509
    58
	src/video/SDL_blit_A.c \
slouken@509
    59
	src/video/SDL_blit_N.c \
slouken@509
    60
	src/video/SDL_bmp.c \
slouken@509
    61
	src/video/SDL_cursor.c \
slouken@509
    62
	src/video/SDL_gamma.c \
slouken@509
    63
	src/video/SDL_pixels.c \
slouken@509
    64
	src/video/SDL_RLEaccel.c \
slouken@509
    65
	src/video/SDL_stretch.c \
slouken@509
    66
	src/video/SDL_surface.c \
slouken@509
    67
	src/video/SDL_video.c \
slouken@509
    68
	src/video/SDL_yuv.c \
slouken@509
    69
	src/video/SDL_yuv_sw.c \
slouken@509
    70
slouken@509
    71
OBJS = $(SRCS:.c=.o)
slouken@509
    72
slouken@509
    73
TEST = \
slouken@509
    74
	test/checkkeys.c \
slouken@509
    75
	test/graywin.c \
slouken@509
    76
	test/loopwave.c \
slouken@509
    77
	test/testalpha.c \
slouken@509
    78
	test/testbitmap.c \
slouken@509
    79
	test/testcdrom.c \
slouken@509
    80
	test/testerror.c \
slouken@509
    81
	test/testgamma.c \
slouken@509
    82
	test/testgl.c \
slouken@509
    83
	test/testhread.c \
slouken@509
    84
	test/testjoystick.c \
slouken@509
    85
	test/testkeys.c \
slouken@509
    86
	test/testlock.c \
slouken@509
    87
	test/testoverlay.c \
slouken@509
    88
	test/testpalette.c \
slouken@509
    89
	test/testsem.c \
slouken@509
    90
	test/testsprite.c \
slouken@509
    91
	test/testtimer.c \
slouken@509
    92
	test/testtypes.c \
slouken@509
    93
	test/testver.c \
slouken@509
    94
	test/testvidinfo.c \
slouken@509
    95
	test/testwin.c \
slouken@509
    96
	test/testwm.c \
slouken@509
    97
	test/threadwin.c \
slouken@509
    98
	test/torturethread.c \
slouken@509
    99
slouken@509
   100
clean:
slouken@509
   101
	rm $(OBJS)
slouken@509
   102
slouken@509
   103
$(TARGET) : $(OBJS)
slouken@509
   104
	$(AR) rcs $(TARGET) $(OBJS)
slouken@509
   105