From 22ebfaa77a2a80a72e6dffff7946e7179f7a23ec Mon Sep 17 00:00:00 2001 From: =?utf8?q?Michael=20B=C3=BCsch?= Date: Mon, 4 Jan 2010 21:06:15 +0000 Subject: [PATCH] Add SDL_mixer SVN-Revision: 19037 --- libs/libsdl_mixer/Makefile | 66 ++++++++++++++++++++++++++++++ libs/libsdl_mixer/files/sdl-config | 3 ++ 2 files changed, 69 insertions(+) create mode 100644 libs/libsdl_mixer/Makefile create mode 100755 libs/libsdl_mixer/files/sdl-config diff --git a/libs/libsdl_mixer/Makefile b/libs/libsdl_mixer/Makefile new file mode 100644 index 000000000..97f1621c7 --- /dev/null +++ b/libs/libsdl_mixer/Makefile @@ -0,0 +1,66 @@ +# +# Copyright (C) 2010 OpenWrt.org +# +# This is free software, licensed under the GNU General Public License v2. +# See /LICENSE for more information. +# + +include $(TOPDIR)/rules.mk + +PKG_NAME:=libsdl-mixer +PKG_VERSION:=1.2.11 +PKG_RELEASE:=1 + +PKG_SOURCE:=SDL_mixer-$(PKG_VERSION).tar.gz +PKG_SOURCE_URL:=http://www.libsdl.org/projects/SDL_mixer/release/ +PKG_MD5SUM:=65ada3d997fe85109191a5fb083f248c +PKG_BUILD_DIR:=$(BUILD_DIR)/SDL_mixer-$(PKG_VERSION) + +include $(INCLUDE_DIR)/package.mk + +define Package/libsdl-mixer + SECTION:=libs + CATEGORY:=Libraries + TITLE:=Simple DirectMedia Layer Sound Mixer + URL:=http://www.libsdl.org/projects/SDL_mixer/ + DEPENDS:=+libsdl +libmikmod +endef + +define Package/libsdl-mixer/description + SDL_mixer is a sample multi-channel audio mixer library. +endef + +TARGET_CFLAGS += -I$(STAGING_DIR)/usr/include/SDL + +CONFIGURE_ARGS += \ + --with-sdl-exec-prefix=$(PKG_BUILD_DIR) + +define Build/Configure + $(INSTALL_DIR) $(PKG_BUILD_DIR)/bin + $(INSTALL_BIN) ./files/sdl-config $(PKG_BUILD_DIR)/bin/ + $(call Build/Configure/Default) +endef + +define Build/Compile + rm -rf $(PKG_INSTALL_DIR) + $(MAKE) -C $(PKG_BUILD_DIR) \ + DESTDIR="$(PKG_INSTALL_DIR)" \ + all install +endef + +define Build/InstallDev + $(INSTALL_DIR) $(1)/usr/include/SDL $(1)/usr/lib + $(CP) \ + $(PKG_INSTALL_DIR)/usr/include/SDL/SDL_mixer.h \ + $(1)/usr/include/SDL/ + $(CP) \ + $(PKG_INSTALL_DIR)/usr/lib/libSDL_mixer*.{a,so*} \ + $(1)/usr/lib/ +endef + +define Package/libsdl-mixer/install + $(INSTALL_DIR) $(1)/usr/lib + $(CP) $(PKG_INSTALL_DIR)/usr/lib/libSDL_mixer*.so.* $(1)/usr/lib/ +endef + +$(eval $(call BuildPackage,libsdl-mixer)) diff --git a/libs/libsdl_mixer/files/sdl-config b/libs/libsdl_mixer/files/sdl-config new file mode 100755 index 000000000..e496baf66 --- /dev/null +++ b/libs/libsdl_mixer/files/sdl-config @@ -0,0 +1,3 @@ +#!/bin/sh +# Fake sdl-config +echo "-lSDL -ldirect -ldirectfb -lfusion" -- 2.30.2