diff options
author | knu <knu@FreeBSD.org> | 2001-03-17 23:06:40 +0000 |
---|---|---|
committer | knu <knu@FreeBSD.org> | 2001-03-17 23:06:40 +0000 |
commit | 5af0f8e0b624d1ecc466dbbb03c3752e84477980 (patch) | |
tree | 9b44c39548c01cb67f27f82cd17ac5fed198a40d /sysutils | |
parent | 1483eed57cd48b8fb8be1d67d0d784124a73816e (diff) | |
download | FreeBSD-ports-5af0f8e0b624d1ecc466dbbb03c3752e84477980.zip FreeBSD-ports-5af0f8e0b624d1ecc466dbbb03c3752e84477980.tar.gz |
Add portupgrade, a tool to upgrade installed packages with ports.
It upgrades ports without reinstalling dependent packages by directly
modifying the package info recorded in the files under /var/db/pkg.
e.g.
portupgrade gtk
portupgrade -cC gnome\*
It currently has many design flaws (to me at least) but I am releasing
this because it's functionally stable enough to use. (I believe.. ;)
Use with care, at your own risk.
Diffstat (limited to 'sysutils')
-rw-r--r-- | sysutils/Makefile | 1 | ||||
-rw-r--r-- | sysutils/portupgrade-devel/Makefile | 32 | ||||
-rw-r--r-- | sysutils/portupgrade-devel/distinfo | 1 | ||||
-rw-r--r-- | sysutils/portupgrade-devel/pkg-comment | 1 | ||||
-rw-r--r-- | sysutils/portupgrade-devel/pkg-descr | 23 | ||||
-rw-r--r-- | sysutils/portupgrade-devel/pkg-plist | 12 | ||||
-rw-r--r-- | sysutils/portupgrade/Makefile | 32 | ||||
-rw-r--r-- | sysutils/portupgrade/distinfo | 1 | ||||
-rw-r--r-- | sysutils/portupgrade/pkg-comment | 1 | ||||
-rw-r--r-- | sysutils/portupgrade/pkg-descr | 23 | ||||
-rw-r--r-- | sysutils/portupgrade/pkg-plist | 12 |
11 files changed, 139 insertions, 0 deletions
diff --git a/sysutils/Makefile b/sysutils/Makefile index 0c42f46..6ed85b3 100644 --- a/sysutils/Makefile +++ b/sysutils/Makefile @@ -88,6 +88,7 @@ SUBDIR += p5-Unix-Syslog SUBDIR += pib SUBDIR += pkg_remove + SUBDIR += portupgrade SUBDIR += prips SUBDIR += procmap SUBDIR += pslist diff --git a/sysutils/portupgrade-devel/Makefile b/sysutils/portupgrade-devel/Makefile new file mode 100644 index 0000000..4ffbae3 --- /dev/null +++ b/sysutils/portupgrade-devel/Makefile @@ -0,0 +1,32 @@ +# New ports collection makefile for: portupgrade +# Date created: 18 March 2001 +# Whom: Akinori MUSHA aka knu <knu@idaemons.org> +# +# $FreeBSD$ +# + +PORTNAME= portupgrade +PORTVERSION= 1.14 +CATEGORIES= sysutils +MASTER_SITES= ${MASTER_SITE_LOCAL} +MASTER_SITE_SUBDIR= knu +DISTNAME= pkgtools-20010318 + +MAINTAINER= knu@FreeBSD.org + +RUN_DEPENDS= ${RUBY_SITELIBDIR}/optparse.rb:${PORTSDIR}/devel/ruby-optparse + +USE_RUBY= yes + +NO_BUILD= yes + +do-install: + cd ${WRKSRC} && ${RUBY} install.rb + ${MKDIR} ${PREFIX}/share/zsh/site-functions + ${INSTALL_DATA} ${WRKSRC}/misc/zsh/* ${PREFIX}/share/zsh/site-functions/ +.if !defined(NOPORTDOCS) + ${MKDIR} ${PREFIX}/share/doc/${PORTNAME} + ${INSTALL_DATA} ${WRKSRC}/README ${PREFIX}/share/doc/${PORTNAME}/ +.endif + +.include <bsd.port.mk> diff --git a/sysutils/portupgrade-devel/distinfo b/sysutils/portupgrade-devel/distinfo new file mode 100644 index 0000000..0387e80 --- /dev/null +++ b/sysutils/portupgrade-devel/distinfo @@ -0,0 +1 @@ +MD5 (pkgtools-20010318.tar.gz) = 521197d6b16ef8f55482c1d819979d41 diff --git a/sysutils/portupgrade-devel/pkg-comment b/sysutils/portupgrade-devel/pkg-comment new file mode 100644 index 0000000..9b81313 --- /dev/null +++ b/sysutils/portupgrade-devel/pkg-comment @@ -0,0 +1 @@ +A tool to upgrade installed packages with ports diff --git a/sysutils/portupgrade-devel/pkg-descr b/sysutils/portupgrade-devel/pkg-descr new file mode 100644 index 0000000..10d2151 --- /dev/null +++ b/sysutils/portupgrade-devel/pkg-descr @@ -0,0 +1,23 @@ +Portupgrade is a tool to upgrade installed packages with ports. + +It upgrades ports without reinstalling dependent packages by directly +modifying the package info recorded in the files under /var/db/pkg. + +The procedures it takes is shown as follows: + + 1. Build the corresponding port of the given package + + 2. Fix the dependency info of the ones which depends on the given + package + + 3. Save the +REQUIRED_BY list of the given package + + 4. Uninstall the given package forcibly if -u is specified + + 5. Install the port + + 6. Restore the +REQUIRED_BY list + +The usage can be shown by running it without arguments or with a -h. + +Author: Akinori MUSHA <knu@FreeBSD.org> diff --git a/sysutils/portupgrade-devel/pkg-plist b/sysutils/portupgrade-devel/pkg-plist new file mode 100644 index 0000000..8423e51 --- /dev/null +++ b/sysutils/portupgrade-devel/pkg-plist @@ -0,0 +1,12 @@ +sbin/portupgrade +%%RUBY_SITELIBDIR%%/pkg.rb +%%RUBY_SITELIBDIR%%/pkgdb.rb +%%RUBY_SITELIBDIR%%/pkginfo.rb +%%RUBY_SITELIBDIR%%/pkgversion.rb +%%RUBY_SITELIBDIR%%/portinfo.rb +%%RUBY_SITELIBDIR%%/ports.rb +%%RUBY_SITELIBDIR%%/portsdb.rb +share/zsh/site-functions/_portupgrade +@unexec if [ ! -x %D/bin/zsh ]; then rmdir -p %D/share/zsh/site-functions; fi +%%PORTDOCS%%share/doc/portupgrade/README +%%PORTDOCS%%@dirrm share/doc/portupgrade diff --git a/sysutils/portupgrade/Makefile b/sysutils/portupgrade/Makefile new file mode 100644 index 0000000..4ffbae3 --- /dev/null +++ b/sysutils/portupgrade/Makefile @@ -0,0 +1,32 @@ +# New ports collection makefile for: portupgrade +# Date created: 18 March 2001 +# Whom: Akinori MUSHA aka knu <knu@idaemons.org> +# +# $FreeBSD$ +# + +PORTNAME= portupgrade +PORTVERSION= 1.14 +CATEGORIES= sysutils +MASTER_SITES= ${MASTER_SITE_LOCAL} +MASTER_SITE_SUBDIR= knu +DISTNAME= pkgtools-20010318 + +MAINTAINER= knu@FreeBSD.org + +RUN_DEPENDS= ${RUBY_SITELIBDIR}/optparse.rb:${PORTSDIR}/devel/ruby-optparse + +USE_RUBY= yes + +NO_BUILD= yes + +do-install: + cd ${WRKSRC} && ${RUBY} install.rb + ${MKDIR} ${PREFIX}/share/zsh/site-functions + ${INSTALL_DATA} ${WRKSRC}/misc/zsh/* ${PREFIX}/share/zsh/site-functions/ +.if !defined(NOPORTDOCS) + ${MKDIR} ${PREFIX}/share/doc/${PORTNAME} + ${INSTALL_DATA} ${WRKSRC}/README ${PREFIX}/share/doc/${PORTNAME}/ +.endif + +.include <bsd.port.mk> diff --git a/sysutils/portupgrade/distinfo b/sysutils/portupgrade/distinfo new file mode 100644 index 0000000..0387e80 --- /dev/null +++ b/sysutils/portupgrade/distinfo @@ -0,0 +1 @@ +MD5 (pkgtools-20010318.tar.gz) = 521197d6b16ef8f55482c1d819979d41 diff --git a/sysutils/portupgrade/pkg-comment b/sysutils/portupgrade/pkg-comment new file mode 100644 index 0000000..9b81313 --- /dev/null +++ b/sysutils/portupgrade/pkg-comment @@ -0,0 +1 @@ +A tool to upgrade installed packages with ports diff --git a/sysutils/portupgrade/pkg-descr b/sysutils/portupgrade/pkg-descr new file mode 100644 index 0000000..10d2151 --- /dev/null +++ b/sysutils/portupgrade/pkg-descr @@ -0,0 +1,23 @@ +Portupgrade is a tool to upgrade installed packages with ports. + +It upgrades ports without reinstalling dependent packages by directly +modifying the package info recorded in the files under /var/db/pkg. + +The procedures it takes is shown as follows: + + 1. Build the corresponding port of the given package + + 2. Fix the dependency info of the ones which depends on the given + package + + 3. Save the +REQUIRED_BY list of the given package + + 4. Uninstall the given package forcibly if -u is specified + + 5. Install the port + + 6. Restore the +REQUIRED_BY list + +The usage can be shown by running it without arguments or with a -h. + +Author: Akinori MUSHA <knu@FreeBSD.org> diff --git a/sysutils/portupgrade/pkg-plist b/sysutils/portupgrade/pkg-plist new file mode 100644 index 0000000..8423e51 --- /dev/null +++ b/sysutils/portupgrade/pkg-plist @@ -0,0 +1,12 @@ +sbin/portupgrade +%%RUBY_SITELIBDIR%%/pkg.rb +%%RUBY_SITELIBDIR%%/pkgdb.rb +%%RUBY_SITELIBDIR%%/pkginfo.rb +%%RUBY_SITELIBDIR%%/pkgversion.rb +%%RUBY_SITELIBDIR%%/portinfo.rb +%%RUBY_SITELIBDIR%%/ports.rb +%%RUBY_SITELIBDIR%%/portsdb.rb +share/zsh/site-functions/_portupgrade +@unexec if [ ! -x %D/bin/zsh ]; then rmdir -p %D/share/zsh/site-functions; fi +%%PORTDOCS%%share/doc/portupgrade/README +%%PORTDOCS%%@dirrm share/doc/portupgrade |