src/Makefile.wat
changeset 1190 173c063d4f55
     1.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     1.2 +++ b/src/Makefile.wat	Wed Nov 23 07:29:56 2005 +0000
     1.3 @@ -0,0 +1,132 @@
     1.4 +#=============================================================================
     1.5 +#          This is a Watcom makefile to build SDL.DLL for OS/2
     1.6 +#
     1.7 +#
     1.8 +#=============================================================================
     1.9 +
    1.10 +dllname=SDL
    1.11 +
    1.12 +audioobjs = audio\SDL_audio.obj audio\SDL_audiocvt.obj audio\SDL_audiomem.obj &
    1.13 +            audio\SDL_mixer.obj audio\SDL_mixer_MMX_VC.obj audio\SDL_wave.obj &
    1.14 +            audio\SDL_dart.obj
    1.15 +cdromobjs = cdrom\SDL_cdrom.obj cdrom\SDL_syscdrom.obj
    1.16 +cpuinfoobjs = cpuinfo\SDL_cpuinfo.obj
    1.17 +endianobjs = endian\SDL_endian.obj
    1.18 +eventsobjs = events\SDL_active.obj events\SDL_events.obj events\SDL_expose.obj &
    1.19 +             events\SDL_keyboard.obj events\SDL_mouse.obj events\SDL_quit.obj &
    1.20 +             events\SDL_resize.obj
    1.21 +fileobjs = file\SDL_rwops.obj
    1.22 +hermesobjs = hermes\mmx_main.obj hermes\mmxp2_32.obj hermes\x86_main.obj &
    1.23 +             hermes\x86p_16.obj hermes\x86p_32.obj
    1.24 +joystickobjs = joystick\SDL_joystick.obj joystick\SDL_sysjoystick.obj
    1.25 +threadobjs = thread\SDL_thread.obj thread\SDL_sysmutex.obj &
    1.26 +             thread\SDL_syssem.obj thread\SDL_systhread.obj &
    1.27 +             thread\SDL_syscond.obj
    1.28 +timerobjs = timer\SDL_timer.obj timer\SDL_systimer.obj
    1.29 +videoobjs = video\SDL_blit.obj video\SDL_blit_0.obj video\SDL_blit_1.obj &
    1.30 +            video\SDL_blit_A.obj video\SDL_blit_N.obj video\SDL_bmp.obj &
    1.31 +            video\SDL_cursor.obj video\SDL_gamma.obj video\SDL_pixels.obj &
    1.32 +            video\SDL_RLEaccel.obj video\SDL_stretch.obj video\SDL_surface.obj &
    1.33 +            video\SDL_video.obj video\SDL_yuv.obj video\SDL_yuv_mmx.obj &
    1.34 +            video\SDL_yuv_sw.obj video\SDL_os2fslib.obj
    1.35 +
    1.36 +object_files= SDL.obj SDL_error.obj SDL_fatal.obj SDL_getenv.obj &
    1.37 +              SDL_loadso.obj $(audioobjs) $(cpuinfoobjs) $(endianobjs) &
    1.38 +              $(eventsobjs) $(fileobjs) $(joystickobjs) &
    1.39 +              $(threadobjs) $(timerobjs) $(videoobjs) $(cdromobjs)
    1.40 +	      
    1.41 +
    1.42 +# Extra stuffs to pass to C compiler:
    1.43 +ExtraCFlags=
    1.44 +
    1.45 +#
    1.46 +#==============================================================================
    1.47 +#
    1.48 +!include ..\Watcom.mif
    1.49 +
    1.50 +.before
    1.51 +    @set include=$(%os2tk)\h;$(%include);../include;./thread;./thread/os2;./video;./cdrom;./cdrom/os2;./joystick;./joystick/os2;
    1.52 +
    1.53 +all : check_subdir_objects $(dllname).dll $(dllname).lib
    1.54 +
    1.55 +$(dllname).dll : $(dllname).lnk $(object_files)
    1.56 +    wlink @$(dllname)
    1.57 +
    1.58 +check_subdir_objects: .always .symbolic
    1.59 +    @cd audio
    1.60 +    @wmake -h -f Makefile.wat
    1.61 +    @cd ..\cdrom
    1.62 +    @wmake -h -f Makefile.wat
    1.63 +    @cd ..\cpuinfo
    1.64 +    @wmake -h -f Makefile.wat
    1.65 +    @cd ..\endian
    1.66 +    @wmake -h -f Makefile.wat
    1.67 +    @cd ..\events
    1.68 +    @wmake -h -f Makefile.wat
    1.69 +    @cd ..\file
    1.70 +    @wmake -h -f Makefile.wat
    1.71 +    @cd ..\joystick
    1.72 +    @wmake -h -f Makefile.wat
    1.73 +    @cd ..\thread
    1.74 +    @wmake -h -f Makefile.wat
    1.75 +    @cd ..\timer
    1.76 +    @wmake -h -f Makefile.wat
    1.77 +    @cd ..\video
    1.78 +    @wmake -h -f Makefile.wat
    1.79 +    @cd ..
    1.80 +
    1.81 +$(dllname).lnk :
    1.82 +    @echo Creating linker file ($(dllname).lnk)...
    1.83 +    @echo $#============================================================================= >$^@
    1.84 +    @echo $#              This is a linker file to build SDL.DLL for OS/2 >>$^@
    1.85 +    @echo $# >>$^@
    1.86 +    @echo $# Generated automatically by Makefile.wat >>$^@
    1.87 +    @echo $#============================================================================= >>$^@
    1.88 +    @echo SYSTEM 386 LX DLL INITINSTANCE TERMINSTANCE >>$^@
    1.89 +    @echo NAME $^& >>$^@
    1.90 +    @for %i in ($(object_files)) do @echo FILE %i >>$^@
    1.91 +    @echo LIBPATH %os2tk%\lib >>$^@
    1.92 +    @echo LIBPATH %fslib% >>$^@
    1.93 +    @echo LIB mmpm2.lib >>$^@
    1.94 +    @echo LIB fslib.lib >>$^@
    1.95 +    @echo OPTION QUIET >>$^@
    1.96 +    @echo OPTION MAP=$^&.map >>$^@
    1.97 +    @echo OPTION DESCRIPTION 'Simple DirectMedia Layer v1.2.7' >>$^@
    1.98 +    @echo OPTION ELIMINATE >>$^@
    1.99 +    @echo OPTION MANYAUTODATA >>$^@
   1.100 +    @echo OPTION OSNAME='OS/2 and eComStation' >>$^@
   1.101 +    @echo OPTION SHOWDEAD >>$^@
   1.102 +    @echo Linker file created!
   1.103 +
   1.104 +$(dllname).lib : $(dllname).dll
   1.105 +    implib $(dllname).lib $(dllname).dll
   1.106 +
   1.107 +clean : .SYMBOLIC
   1.108 +    @if exist *.dll del *.dll
   1.109 +    @if exist *.lib del *.lib
   1.110 +    @if exist *.obj del *.obj
   1.111 +    @if exist *.lnk del *.lnk
   1.112 +    @if exist *.map del *.map
   1.113 +    @if exist *.res del *.res
   1.114 +    @if exist *.lst del *.lst
   1.115 +    @cd audio
   1.116 +    @wmake -h -f Makefile.wat clean
   1.117 +    @cd ..\cdrom
   1.118 +    @wmake -h -f Makefile.wat clean
   1.119 +    @cd ..\cpuinfo
   1.120 +    @wmake -h -f Makefile.wat clean
   1.121 +    @cd ..\endian
   1.122 +    @wmake -h -f Makefile.wat clean
   1.123 +    @cd ..\events
   1.124 +    @wmake -h -f Makefile.wat clean
   1.125 +    @cd ..\file
   1.126 +    @wmake -h -f Makefile.wat clean
   1.127 +    @cd ..\joystick
   1.128 +    @wmake -h -f Makefile.wat clean
   1.129 +    @cd ..\thread
   1.130 +    @wmake -h -f Makefile.wat clean
   1.131 +    @cd ..\timer
   1.132 +    @wmake -h -f Makefile.wat clean
   1.133 +    @cd ..\video
   1.134 +    @wmake -h -f Makefile.wat clean
   1.135 +    @cd ..