From ba3359722cbf8aa7b0ed39e1f81d1d74ec88fecd Mon Sep 17 00:00:00 2001 From: Waldemar Brodkorb Date: Sat, 30 May 2009 20:39:07 +0200 Subject: optimize ipkg package management - generate ipkg control file from PKG_* variables - automatically install init scripts from ./files/*.init set #PKG pkgname to set the binary package - rename FWINIT -> INIT - move postinst and conffiles meta data to ./files - update the packages to the latest upstream version - remove some unready or unused package (strongswan,..) more cleanups needed after allmodconfig --- package/portmap/Makefile | 18 ++++++++++-------- package/portmap/files/portmap.init | 4 +++- package/portmap/files/portmap.postinst | 5 +++++ package/portmap/ipkg/portmap.control | 4 ---- package/portmap/ipkg/portmap.postinst | 5 ----- 5 files changed, 18 insertions(+), 18 deletions(-) create mode 100644 package/portmap/files/portmap.postinst delete mode 100644 package/portmap/ipkg/portmap.control delete mode 100644 package/portmap/ipkg/portmap.postinst (limited to 'package/portmap') diff --git a/package/portmap/Makefile b/package/portmap/Makefile index f5f019607..e4eba9d32 100644 --- a/package/portmap/Makefile +++ b/package/portmap/Makefile @@ -9,13 +9,21 @@ PKG_NAME:= portmap PKG_VERSION:= 6.0 PKG_RELEASE:= 1 PKG_MD5SUM:= ac108ab68bf0f34477f8317791aaf1ff -MASTER_SITES:= http://neil.brown.name/portmap/ +PKG_DESCR:= RPC portmapper +PKG_SECTION:= net +PKG_URL:= http://neil.brown.name/portmap +PKG_SITES:= http://neil.brown.name/portmap/ + DISTFILES:= ${PKG_NAME}-${PKG_VERSION}.tgz WRKDIST= ${WRKDIR}/${PKG_NAME}_${PKG_VERSION} include ${TOPDIR}/mk/package.mk -$(eval $(call PKG_template,PORTMAP,portmap,${PKG_VERSION}-${PKG_RELEASE})) +ifneq ($(strip ${ADK_PACKAGE_PORTMAP_LIBWRAP}),) +PKG_DEPENDS:= libwrap +endif + +$(eval $(call PKG_template,PORTMAP,${PKG_NAME},${PKG_VERSION}-${PKG_RELEASE},${PKG_DEPENDS},${PKG_DESCR},${PKG_SECTION})) ifneq ($(strip ${ADK_PACKAGE_PORTMAP_LIBWRAP}),) MAKE_FLAGS+= WRAP_LIB='-L${STAGING_DIR}/usr/lib -lwrap' @@ -28,13 +36,7 @@ MAKE_FLAGS+= ${TARGET_CONFIGURE_OPTS} \ CFLAGS='${TCFLAGS}' do-install: - ${INSTALL_DIR} ${IDIR_PORTMAP}/etc/init.d ${INSTALL_DIR} ${IDIR_PORTMAP}/usr/sbin - ${INSTALL_BIN} ./files/portmap.init \ - ${IDIR_PORTMAP}/etc/init.d/portmap ${INSTALL_BIN} ${WRKBUILD}/portmap ${IDIR_PORTMAP}/usr/sbin/ -ifneq ($(strip ${ADK_PACKAGE_PORTMAP_LIBWRAP}),) - echo 'Depends: libwrap' >>${IDIR_PORTMAP}/CONTROL/control -endif include ${TOPDIR}/mk/pkg-bottom.mk diff --git a/package/portmap/files/portmap.init b/package/portmap/files/portmap.init index 19e54ee77..a42c2e2e0 100644 --- a/package/portmap/files/portmap.init +++ b/package/portmap/files/portmap.init @@ -1,5 +1,7 @@ #!/bin/sh -#FWINIT 60 +#PKG portmap +#INIT 60 + . /etc/rc.conf case $1 in diff --git a/package/portmap/files/portmap.postinst b/package/portmap/files/portmap.postinst new file mode 100644 index 000000000..1017d2251 --- /dev/null +++ b/package/portmap/files/portmap.postinst @@ -0,0 +1,5 @@ +#!/bin/sh +. $IPKG_INSTROOT/etc/functions.sh +add_rcconf portmap +add_group portmap 20 +add_user portmap 20 20 /tmp/.portmap diff --git a/package/portmap/ipkg/portmap.control b/package/portmap/ipkg/portmap.control deleted file mode 100644 index 88fc963fa..000000000 --- a/package/portmap/ipkg/portmap.control +++ /dev/null @@ -1,4 +0,0 @@ -Package: portmap -Priority: optional -Section: net -Description: The RPC Portmapper diff --git a/package/portmap/ipkg/portmap.postinst b/package/portmap/ipkg/portmap.postinst deleted file mode 100644 index 1017d2251..000000000 --- a/package/portmap/ipkg/portmap.postinst +++ /dev/null @@ -1,5 +0,0 @@ -#!/bin/sh -. $IPKG_INSTROOT/etc/functions.sh -add_rcconf portmap -add_group portmap 20 -add_user portmap 20 20 /tmp/.portmap -- cgit v1.2.3