Merge pull request #53 from heil/prosody
[feed/packages.git] / lang / luaexpat / Makefile
1 #
2 # Copyright (C) 2009 OpenWrt.org
3 #
4 # This is free software, licensed under the GNU General Public License v2.
5 # See /LICENSE for more information.
6 #
7
8 include $(TOPDIR)/rules.mk
9
10 PKG_NAME:=luaexpat
11 PKG_VERSION:=1.2.0
12 PKG_RELEASE:=1
13
14 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
15 PKG_SOURCE_URL:=http://matthewwild.co.uk/projects/luaexpat
16 PKG_MD5SUM:=03efe50c7f30a34580701e6527d7bfee
17
18 include $(INCLUDE_DIR)/package.mk
19
20 define Package/luaexpat
21 SUBMENU:=Lua
22 SECTION:=lang
23 CATEGORY:=Languages
24 TITLE:=LuaExpat
25 URL:=http://www.keplerproject.org/luaexpat/
26 MAINTAINER:=W. Michael Petullo <mike@flyn.org>
27 DEPENDS:=+lua +libexpat
28 endef
29
30 define Package/luaexpat/description
31 LuaExpat is a SAX XML parser based on the Expat library.
32 endef
33
34 define Build/Configure
35 endef
36
37 define Build/Compile
38 $(CP) files/compat-5.1r5 $(PKG_BUILD_DIR)/compat-5.1r5
39 $(MAKE) -C $(PKG_BUILD_DIR) \
40 EXPAT_INC="$(STAGING_DIR)/usr/include/" \
41 LUA_INC="$(STAGING_DIR)/usr/include/" \
42 LUA_LIBDIR="$(STAGING_DIR)/usr/lib/" \
43 COMPAT_DIR="$(PKG_BUILD_DIR)/compat-5.1r5" \
44 LIB_OPTION="-shared $(TARGET_LDFLAGS)" \
45 CC="$(TARGET_CC) $(TARGET_CFLAGS) $(FPIC) -std=c99" \
46 LD="$(TARGET_CROSS)ld -shared"
47 endef
48
49 define Package/luaexpat/install
50 $(INSTALL_DIR) $(1)/usr/lib/lua
51 $(INSTALL_DATA) $(PKG_BUILD_DIR)/src/lxp.so.1.2.0 $(1)/usr/lib/lua/lxp.so
52 $(INSTALL_DIR) $(1)/usr/lib/lua/lxp
53 $(INSTALL_DATA) $(PKG_BUILD_DIR)/src/lxp/lom.lua $(1)/usr/lib/lua/lxp
54 endef
55
56 $(eval $(call BuildPackage,luaexpat))