Mercurial > mxe-octave
changeset 736:9232c79dac70
bugfix and test program for package sdl_mixer
author | Volker Grabsch <vog@notjusthosting.com> |
---|---|
date | Sun, 14 Feb 2010 19:59:37 +0100 |
parents | 0967c751db7a |
children | 740910a9aa12 |
files | src/sdl_mixer-test.c src/sdl_mixer.mk |
diffstat | 2 files changed, 29 insertions(+), 0 deletions(-) [+] |
line wrap: on
line diff
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/src/sdl_mixer-test.c Sun Feb 14 19:59:37 2010 +0100 @@ -0,0 +1,16 @@ +/* This file is part of mingw-cross-env. */ +/* See doc/index.html for further information. */ + +#include <SDL_mixer.h> + +int main(int argc, char* argv[]) +{ + int initted; + + (void)argc; + (void)argv; + + initted = Mix_Init(MIX_INIT_FLAC | MIX_INIT_OGG | MIX_INIT_MOD); + Mix_Quit(); + return 0; +}
--- a/src/sdl_mixer.mk Sun Feb 14 19:59:01 2010 +0100 +++ b/src/sdl_mixer.mk Sun Feb 14 19:59:37 2010 +0100 @@ -20,6 +20,12 @@ endef define $(PKG)_BUILD + $(SED) 's,^\(Requires:.*\),\1 vorbisfile,' -i '$(1)/SDL_mixer.pc.in' + echo \ + 'Libs.private:' \ + "`$(PREFIX)/$(TARGET)/bin/libmikmod-config --libs`" \ + "`$(PREFIX)/$(TARGET)/bin/smpeg-config --libs`" \ + >> '$(1)/SDL_mixer.pc.in' $(SED) 's,for path in /usr/local; do,for path in; do,' -i '$(1)/configure' cd '$(1)' && ./configure \ --host='$(TARGET)' \ @@ -40,4 +46,11 @@ LIBMIKMOD_CONFIG='$(PREFIX)/$(TARGET)/bin/libmikmod-config' \ LIBS='-lvorbis -logg' $(MAKE) -C '$(1)' -j '$(JOBS)' install bin_PROGRAMS= sbin_PROGRAMS= noinst_PROGRAMS= + + '$(TARGET)-gcc' \ + -W -Wall -Werror -ansi -pedantic \ + `'$(TARGET)-pkg-config' SDL_mixer --cflags` \ + '$(2).c' \ + `'$(TARGET)-pkg-config' SDL_mixer --libs` \ + -o '$(PREFIX)/$(TARGET)/bin/test-sdl_mixer.exe' endef