fixes variables, oops
[openwrt.git] / package / ipkg / Makefile
1 # Copyright (C) 2008 OpenWrt.org
2 #
3 # This is free software, licensed under the GNU General Public License v2.
4 # See /LICENSE for more information.
5 #
6 # $Id$
7
8 include $(TOPDIR)/rules.mk
9
10 PKG_NAME:=ipkg
11 PKG_VERSION:=0.99.163
12 PKG_RELEASE:=1
13
14 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
15 PKG_SOURCE_URL:=http://ftp.gwdg.de/pub/linux/handhelds/packages/ipkg \
16 http://www.handhelds.org/packages/ipkg \
17 http://www.gtlib.gatech.edu/pub/handhelds.org/packages/ipkg
18 PKG_MD5SUM:=0b10ad2924611bccaea8ddf98481a192
19
20 PKG_FIXUP = libtool
21
22 include $(INCLUDE_DIR)/package.mk
23
24 define Package/ipkg
25 SECTION:=base
26 CATEGORY:=Base system
27 TITLE:=Itsy package management system
28 URL:=http://handhelds.org/moin/moin.cgi/Ipkg
29 endef
30
31 define Package/ipkg/description
32 Lightweight package management system
33 ipkg is the Itsy Package Management System, for handling
34 installation and removal of packages on a system. It can
35 recursively follow dependencies and download all packages
36 necessary to install a particular package.
37 .
38 ipkg knows how to install both .ipk and .deb packages.
39 endef
40
41 TARGET_CFLAGS += $(FPIC)
42 CONFIGURE_ARGS += $(DISABLE_LARGEFILE)
43
44 define Build/Compile
45 $(MAKE) -C $(PKG_BUILD_DIR) \
46 CC="$(TARGET_CC)" \
47 DESTDIR="$(PKG_INSTALL_DIR)" \
48 all install
49 endef
50
51 define Package/ipkg/preinst
52 if [ -L $${IPKG_INSTROOT}/usr/bin/ipkg ] ; then
53 echo -e "Removing busybox ipkg symlink"
54 rm $${IPKG_INSTROOT}/usr/bin/ipkg
55 fi
56 endef
57
58 define Package/ipkg/postrm
59 if [ "$(busybox ipkg 2>&1)" != "busybox: applet not found" ] ; then
60 echo -e "Reinstalling busybox ipkg symlink"
61 ln -sf ../../bin/busybox $${IPKG_INSTROOT}/usr/bin/ipkg
62 fi
63 endef
64
65 define Package/ipkg/install
66 $(INSTALL_DIR) $(1)/usr/bin
67 $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/ipkg-cl $(1)/usr/bin/ipkg
68 $(INSTALL_DIR) $(1)/usr/lib
69 $(CP) $(PKG_INSTALL_DIR)/usr/lib/libipkg.so.* $(1)/usr/lib/
70 endef
71
72 define Build/InstallDev
73 mkdir -p $(1)/usr/include
74 $(CP) $(PKG_INSTALL_DIR)/usr/include/libipkg $(1)/usr/include/
75 endef
76
77 $(eval $(call BuildPackage,ipkg))
This page took 0.048589 seconds and 5 git commands to generate.