First I went to Chui's website: http://chui.dcemu.co.uk/sdl.html and I downloaded the Precompiled Libraries and Headers
and put the files in addons like the instructions ask to do.
Then I downloaded the examples, however when I try to run make on the examples I have errors with the elf files.
Here are my errors:
For the framerate example:
Code: Select all
/opt/toolchains/dc/sh-elf/bin/sh-elf-gcc -O2 -fomit-frame-pointer -ml -m4-single-only -ffunction-sections -fdata-sections -I/opt/toolchains/dc/kos/include -I/opt/toolchains/dc/kos/kernel/arch/dreamcast/include -I/opt/toolchains/dc/kos/addons/include -I/opt/toolchains/dc/kos/../kos-ports/include -D_arch_dreamcast -D_arch_sub_pristine -Wall -g -fno-builtin -fno-strict-aliasing -I/opt/toolchains/dc/kos/addons/include -I/opt/toolchains/dc/kos/addons/include/SDL -O3 -fomit-frame-pointer -DDREAMCAST -ml -m4-single-only -Wl,-Ttext=0x8c010000 -Wl,--gc-sections -T/opt/toolchains/dc/kos/utils/ldscripts/shlelf.xc -nodefaultlibs -L/opt/toolchains/dc/kos/lib/dreamcast -L/opt/toolchains/dc/kos/addons/lib/dreamcast -L/opt/toolchains/dc/kos/../kos-ports/lib -o framerate.elf \
framerate.o -lSDL_gfx -lSDL_129 -lm -Wl,--start-group -lkallisti -lc -lgcc -Wl,--end-group
/opt/toolchains/dc/kos/addons/lib/dreamcast/libSDL_129.a(SDL_systhread.o): In function `SDL_SYS_WaitThread':
/opt/dc/kos-ports/SDL-1.2.9/src/thread/dc/SDL_systhread.c:93: undefined reference to `_thd_wait'
/opt/toolchains/dc/kos/addons/lib/dreamcast/libSDL_129.a(SDL_sysjoystick.o): In function `SDL_SYS_JoystickInit':
/opt/dc/kos-ports/SDL-1.2.9/src/joystick/dc/SDL_sysjoystick.c:131: undefined reference to `_maple_device_func'
/opt/dc/kos-ports/SDL-1.2.9/src/joystick/dc/SDL_sysjoystick.c:131: undefined reference to `_maple_first_kb'
/opt/dc/kos-ports/SDL-1.2.9/src/joystick/dc/SDL_sysjoystick.c:131: undefined reference to `_maple_first_mouse'
/opt/toolchains/dc/kos/addons/lib/dreamcast/libSDL_129.a(SDL_sysjoystick.o): In function `SDL_SYS_JoystickName':
/opt/dc/kos-ports/SDL-1.2.9/src/joystick/dc/SDL_sysjoystick.c:140: undefined reference to `_maple_compat_resolve'
/opt/toolchains/dc/kos/addons/lib/dreamcast/libSDL_129.a(SDL_sysjoystick.o): In function `joyUpdate':
/opt/dc/kos-ports/SDL-1.2.9/src/joystick/dc/SDL_sysjoystick.c:219: undefined reference to `_cont_get_cond'
/opt/toolchains/dc/kos/addons/lib/dreamcast/libSDL_129.a(SDL_dcvideo.o): In function `__ask_60hz_wait':
/opt/dc/kos-ports/SDL-1.2.9/src/video/dc/60hz.h:771: undefined reference to `_maple_device_func'
/opt/dc/kos-ports/SDL-1.2.9/src/video/dc/60hz.h:771: undefined reference to `_cont_get_cond'
/opt/toolchains/dc/kos/addons/lib/dreamcast/libSDL_129.a(SDL_dcevents.o): In function `DC_PumpEvents':
/opt/dc/kos-ports/SDL-1.2.9/src/video/dc/SDL_dcevents.c:104: undefined reference to `_maple_first_kb'
/opt/dc/kos-ports/SDL-1.2.9/src/video/dc/SDL_dcevents.c:104: undefined reference to `_maple_first_mouse'
/opt/dc/kos-ports/SDL-1.2.9/src/video/dc/SDL_dcevents.c:104: undefined reference to `_mouse_get_cond'
collect2: error: ld returned 1 exit status
Makefile:19: recipe for target 'framerate.elf' failed
make: *** [framerate.elf] Error 1
Code: Select all
/opt/toolchains/dc/sh-elf/bin/sh-elf-gcc -O2 -fomit-frame-pointer -ml -m4-single-only -ffunction-sections -fdata-sections -I/opt/toolchains/dc/kos/include -I/opt/toolchains/dc/kos/kernel/arch/dreamcast/include -I/opt/toolchains/dc/kos/addons/include -I/opt/toolchains/dc/kos/../kos-ports/include -D_arch_dreamcast -D_arch_sub_pristine -Wall -g -fno-builtin -fno-strict-aliasing -I/opt/toolchains/dc/kos/addons/include -I/opt/toolchains/dc/kos/addons/include/SDL -O3 -fomit-frame-pointer -DDREAMCAST -ml -m4-single-only -Wl,-Ttext=0x8c010000 -Wl,--gc-sections -T/opt/toolchains/dc/kos/utils/ldscripts/shlelf.xc -nodefaultlibs -L/opt/toolchains/dc/kos/lib/dreamcast -L/opt/toolchains/dc/kos/addons/lib/dreamcast -L/opt/toolchains/dc/kos/../kos-ports/lib -o fonts.elf \
fonts.o -lSDL_gfx -lSDL_129 -lm -Wl,--start-group -lkallisti -lc -lgcc -Wl,--end-group
/opt/toolchains/dc/kos/addons/lib/dreamcast/libSDL_129.a(SDL_systhread.o): In function `SDL_SYS_WaitThread':
/opt/dc/kos-ports/SDL-1.2.9/src/thread/dc/SDL_systhread.c:93: undefined reference to `_thd_wait'
/opt/toolchains/dc/kos/addons/lib/dreamcast/libSDL_129.a(SDL_sysjoystick.o): In function `SDL_SYS_JoystickInit':
/opt/dc/kos-ports/SDL-1.2.9/src/joystick/dc/SDL_sysjoystick.c:131: undefined reference to `_maple_device_func'
/opt/dc/kos-ports/SDL-1.2.9/src/joystick/dc/SDL_sysjoystick.c:131: undefined reference to `_maple_first_kb'
/opt/dc/kos-ports/SDL-1.2.9/src/joystick/dc/SDL_sysjoystick.c:131: undefined reference to `_maple_first_mouse'
/opt/toolchains/dc/kos/addons/lib/dreamcast/libSDL_129.a(SDL_sysjoystick.o): In function `SDL_SYS_JoystickName':
/opt/dc/kos-ports/SDL-1.2.9/src/joystick/dc/SDL_sysjoystick.c:140: undefined reference to `_maple_compat_resolve'
/opt/toolchains/dc/kos/addons/lib/dreamcast/libSDL_129.a(SDL_sysjoystick.o): In function `joyUpdate':
/opt/dc/kos-ports/SDL-1.2.9/src/joystick/dc/SDL_sysjoystick.c:219: undefined reference to `_cont_get_cond'
/opt/toolchains/dc/kos/addons/lib/dreamcast/libSDL_129.a(SDL_dcvideo.o): In function `__ask_60hz_wait':
/opt/dc/kos-ports/SDL-1.2.9/src/video/dc/60hz.h:771: undefined reference to `_maple_device_func'
/opt/dc/kos-ports/SDL-1.2.9/src/video/dc/60hz.h:771: undefined reference to `_cont_get_cond'
/opt/toolchains/dc/kos/addons/lib/dreamcast/libSDL_129.a(SDL_dcevents.o): In function `DC_PumpEvents':
/opt/dc/kos-ports/SDL-1.2.9/src/video/dc/SDL_dcevents.c:104: undefined reference to `_maple_first_kb'
/opt/dc/kos-ports/SDL-1.2.9/src/video/dc/SDL_dcevents.c:104: undefined reference to `_maple_first_mouse'
/opt/dc/kos-ports/SDL-1.2.9/src/video/dc/SDL_dcevents.c:104: undefined reference to `_mouse_get_cond'
collect2: error: ld returned 1 exit status
Makefile:19: recipe for target 'fonts.elf' failed
make: *** [fonts.elf] Error 1