mxe/src/sdl.mk

37 lines
1.2 KiB
Makefile
Raw Normal View History

2012-03-28 14:46:58 +01:00
# This file is part of MXE.
2012-03-29 11:14:15 +01:00
# See index.html for further information.
2008-11-09 00:06:16 +00:00
PKG := sdl
$(PKG)_IGNORE :=
$(PKG)_VERSION := 1.2.15
$(PKG)_CHECKSUM := 3b979798933fb98aa1edebcc108829d6474aad00
$(PKG)_SUBDIR := SDL-$($(PKG)_VERSION)
$(PKG)_FILE := SDL-$($(PKG)_VERSION).tar.gz
$(PKG)_URL := http://www.libsdl.org/release/$($(PKG)_FILE)
$(PKG)_DEPS := gcc libiconv
2008-11-09 00:06:16 +00:00
define $(PKG)_UPDATE
$(WGET) -q -O- 'http://hg.libsdl.org/SDL/tags' | \
$(SED) -n 's,.*release-\([0-9][^<]*\).*,\1,p' | \
grep '^1\.' | \
$(SORT) -V | \
tail -1
2008-11-09 00:06:16 +00:00
endef
define $(PKG)_BUILD
$(SED) -i 's,-mwindows,-lwinmm -mwindows,' '$(1)/configure'
2008-11-09 00:06:16 +00:00
cd '$(1)' && ./configure \
2013-12-15 13:54:47 +00:00
$(MXE_CONFIGURE_OPTS) \
--enable-threads \
--enable-directx \
--disable-stdio-redirect
$(MAKE) -C '$(1)' -j '$(JOBS)'
$(MAKE) -C '$(1)' -j 1 install-bin install-hdrs install-lib install-data
ln -sf '$(PREFIX)/$(TARGET)/bin/sdl-config' '$(PREFIX)/bin/$(TARGET)-sdl-config'
2010-11-26 23:26:52 +00:00
2010-01-22 02:53:37 +00:00
'$(TARGET)-gcc' \
-W -Wall -Werror -ansi -pedantic \
2010-02-16 02:49:06 +00:00
'$(2).c' -o '$(PREFIX)/$(TARGET)/bin/test-sdl.exe' \
`'$(TARGET)-pkg-config' sdl --cflags --libs`
2008-11-09 00:06:16 +00:00
endef