[net] Telephony: Yate: Added conffiles. Fixes overwriting of configuration on reinst...
[openwrt/svn-archive/archive.git] / devel / diffutils / Makefile
1 #
2 # Copyright (C) 2008-2010 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:=diffutils
11 PKG_VERSION:=3.0
12 PKG_RELEASE:=1
13
14 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
15 PKG_SOURCE_URL:=@GNU/diffutils
16 PKG_MD5SUM:=684aaba1baab743a2a90e52162ff07da
17
18 PKG_INSTALL:=1
19
20 include $(INCLUDE_DIR)/package.mk
21
22 define Package/diffutils
23 SECTION:=devel
24 CATEGORY:=Development
25 TITLE:=diffutils
26 URL:=http://www.gnu.org/software/diffutils/
27 endef
28
29 define Package/diffutils/description
30 The Diffutils package contains programs that show the differences between
31 files or directories.
32 endef
33
34 CONFIGURE_VARS += \
35 ac_cv_func_mempcpy=n \
36
37 define Package/diffutils/install
38 $(INSTALL_DIR) $(1)/usr/bin
39 $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/{sdiff,diff3,diff,cmp} $(1)/usr/bin/
40 endef
41
42 define Package/diffutils/preinst
43 #!/bin/sh
44 if [ -e $${IPKG_INSTROOT}/usr/bin/diff ]; then
45 rm $${IPKG_INSTROOT}/usr/bin/diff;
46 fi
47 endef
48
49 define Package/diffutils/postrm
50 #!/bin/sh
51 ln -sf ../../bin/busybox $${IPKG_INSTROOT}/usr/bin/diff
52 $${IPKG_INSTROOT}/usr/bin/diff 2>&1 | grep 'applet not found' > /dev/null 2>&1 && rm $${IPKG_INSTROOT}/usr/bin/diff
53 exit 0
54 endef
55
56 $(eval $(call BuildPackage,diffutils))