admin/netdata: Update to 1.9.0
[feed/packages.git] / lang / luaposix / Makefile
1 #
2 # Copyright (C) 2011 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:=luaposix
11 PKG_VERSION:=v33.2.1
12 PKG_RELEASE:=5
13
14 PKG_SOURCE:=release-$(PKG_VERSION).tar.gz
15 PKG_SOURCE_URL:=https://github.com/luaposix/luaposix/archive/
16 PKG_HASH:=4fb34dfea67f4cf3194cdecc6614c9aea67edc3c4093d34137669ea869c358e1
17 PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)-release-$(PKG_VERSION)
18 PKG_REMOVE_FILES:=aclocal.m4
19 PKG_FIXUP:=autoreconf
20 PKG_MAINTAINER:=Maxim Storchak <m.storchak@gmail.com>
21 PKG_LICENSE:=MIT
22 PKG_LICENSE_FILES:=COPYING
23
24 include $(INCLUDE_DIR)/package.mk
25
26 define Package/luaposix
27 SUBMENU:=Lua
28 SECTION:=lang
29 CATEGORY:=Languages
30 TITLE:=luaposix
31 URL:=http://luaforge.net/projects/luaposix/
32 DEPENDS:=+lua +librt
33 PKG_BUILD_DEPENDS:=+lua/host
34 endef
35
36 define Package/luaposix/description
37 luaposix is a general POSIX library for Lua providing access
38 to various low level libc functions.
39 endef
40
41 CONFIGURE_VARS += ac_cv_path_LDOC="true"
42
43 TARGET_CFLAGS += -DLUA_USE_LINUX $(FPIC) -std=gnu99
44 ifeq ($(CONFIG_USE_MUSL),y)
45 TARGET_CFLAGS += -D_POSIX_PRIORITY_SCHEDULING
46 endif
47
48 ifneq ($(CONFIG_USE_GLIBC),)
49 ifeq ($(CONFIG_EGLIBC_OPTION_EGLIBC_UTMP),)
50 TARGET_CFLAGS += -DNO_GETLOGIN
51 endif
52 endif
53
54
55 define Package/luaposix/install
56 $(INSTALL_DIR) $(1)/usr/lib/lua/posix
57 $(INSTALL_BIN) $(PKG_BUILD_DIR)/ext/posix/.libs/posix.so $(1)/usr/lib/lua
58 $(INSTALL_BIN) $(PKG_BUILD_DIR)/lib/posix.lua $(1)/usr/lib/lua
59 endef
60
61 $(eval $(call BuildPackage,luaposix))