add packages_10.03.2 in preparation for the 10.03.2 interim release
[10.03/packages.git] / libs / newt / Makefile
1 #
2 # Copyright (C) 2006-2011 OpenWrt.org
3 # Copyright (C) 2011 SMBPhone Inc.
4 #
5 # This is free software, licensed under the GNU General Public License v2.
6 # See /LICENSE for more information.
7 #
8
9 include $(TOPDIR)/rules.mk
10
11 PKG_NAME:=newt
12 PKG_VERSION:=0.52.12
13 PKG_RELEASE:=1
14
15 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
16 PKG_SOURCE_URL:=https://fedorahosted.org/releases/n/e/newt/
17 PKG_MD5SUM:=51b04128d9e1bf000fa769c417b74486
18
19 include $(INCLUDE_DIR)/package.mk
20
21 define Package/libnewt
22   URL:=http://fedorahosted.org/newt/
23   SECTION:=libs
24   CATEGORY:=Libraries
25   TITLE:=Not Erik's Windowing Toolkit
26   DEPENDS:= +libslang2 +libpopt
27 endef
28
29 define Package/libnewt/description
30   Programming library for colour text mode widget-based user interfaces,
31   based on S-Lang.
32 endef
33
34 define Package/whiptail
35   URL:=http://fedorahosted.org/newt/
36   SECTION:=utils
37   CATEGORY:=Utilities
38   TITLE:=Dialog boxes from shell scripts
39   DEPENDS:= +libnewt
40 endef
41
42 define Package/whiptail/description
43   A lightweight replacement for the dialog command (dialog boxes from shell
44   scripts), based on libnewt.
45 endef
46
47 TARGET_CFLAGS += $(FPIC) -I$(STAGING_DIR)/usr/include -L$(STAGING_DIR)/usr/lib
48
49 CONFIGURE_ARGS += \
50         --disable-nls \
51         --without-tcl \
52         --without-gpm-support
53
54 define Package/libnewt/install
55         $(INSTALL_DIR) $(1)/usr/lib
56         $(CP) $(PKG_BUILD_DIR)/libnewt.so* $(1)/usr/lib/
57 endef
58
59 define Build/InstallDev
60         $(INSTALL_DIR) $(1)/usr/include
61         $(CP) $(PKG_BUILD_DIR)/newt.h $(1)/usr/include/
62
63         $(INSTALL_DIR) $(1)/usr/lib
64         $(CP) $(PKG_BUILD_DIR)/libnewt.{a,so*} $(1)/usr/lib/
65 endef
66
67 define Package/whiptail/install
68         $(INSTALL_DIR) $(1)/usr/bin
69         $(INSTALL_BIN) $(PKG_BUILD_DIR)/whiptail $(1)/usr/bin/  
70 endef
71
72 $(eval $(call BuildPackage,libnewt))
73 $(eval $(call BuildPackage,whiptail))
74