#! /usr/bin/perl # # This code mostly stolen from easy-import written by J^vrg Wunsch # # $Id: modulesupdate,v 1.8 2000/04/02 05:42:12 mharo Exp $ # $FreeBSD$ use strict; my $tmpdir; if ($ENV{CVSROOT} eq "") { $ENV{CVSROOT}="pcvs.freebsd.org:/home/pcvs"; } sub goodbye { my ($exitstatus)=@_; chdir "/tmp"; print `rm -rf $tmpdir`; exit $exitstatus; } sub contains { # look if the first parameter is contained in the list following it my($item, @list) = @_; foreach my $i (@list) { return 1 if $i eq $item; } return 0; } sub lsmodules { # list all known CVS modules my(%rv, $mname, $mpath); %rv = (); open(CVS, "cvs -R co -c|") || die "cvs: $!"; while() { chomp; chomp; ($mname,$mpath) = split; next if $mname eq ""; $rv{$mname} = $mpath; } close(CVS); return %rv; } my %cvsmods = &lsmodules; my $modulename = shift; my $modulepath = shift; my $dont_do_it = ""; $tmpdir=`mktemp -d -t mu`; chomp $tmpdir; chdir $tmpdir or die "$tmpdir: $!"; if ($modulepath eq "") { print "Error: Must specify both modulename and modulepath\n"; &goodbye(1); } if (&contains($modulename, keys(%cvsmods))) { print "Error: $modulename already exists in modules\n"; &goodbye(1); } my $mod = ""; foreach my $tmp (sort(keys(%cvsmods))) { if ($tmp gt $modulename) { $mod = $tmp; last; } } my $cmd; if ($mod eq "") { # we are going to append our module $cmd = "\$\na\n"; } else { # we can insert it $cmd = "/^" . $mod . "[ \t]/\ni\n"; } print "Checking out the modules database...\n"; system("cvs -R co modules") && die "failed.\n"; my $len = length($modulename); print "Inserting new module...\n"; open(ED, "|ed modules/modules") || die "Cannot start ed\n"; print ED "$cmd$modulename" . "\t" x ($len < 8 ? 2 : 1) . "$modulepath\n.\nw\nq\n"; close(ED); print "Commiting new modules database...\n"; system("cvs -R $dont_do_it commit -m \" " . "$modulename --> $modulepath\" modules") && die "Commit failed\n"; # cleanup &goodbye; ption> FreeBSD GNOME current development ports (https://github.com/freebsd/freebsd-ports-gnome)
aboutsummaryrefslogtreecommitdiffstats
path: root/x11/libXpm
Commit message (Expand)AuthorAgeFilesLines
* - Update X.org ports to 7.3.flz2007-09-142-5/+4
* Port libXpm additionally installs sxpm(1) when more dependencies are present.lesi2007-06-052-2/+4
* - Welcome X.org 7.2 \o/.flz2007-05-204-493/+8
* Conversion to a single libtool environment.ade2006-02-231-1/+0
* SHA256ifyedwin2006-01-241-0/+1
* Mass-conversion to the USE_AUTOTOOLS New World Order. The code presentade2005-11-151-1/+1
* At Kris's request, back out the MACHINE_ARCH spelling correction untilobrien2005-04-121-1/+1
* Assist getting more ports working on AMD64 by obeying theobrien2005-04-111-1/+1
* Remove hardcoding of MTREE_FILE. This is handled in bsd.port.mk sincelesi2005-03-061-1/+0
* Fix MASTER_SITES.lesi2005-02-151-1/+1
* Apply fixes for CAN-2004-0687 and CAN-2004-0688 in libXpm (stack-based andanholt2004-09-162-0/+474
* Register missing CONFLICTS, mostly on xorg-libraries-*anholt2004-07-271-1/+1
* Apply a big libtool patch to allow porters to use the libtool installed bymarcus2004-07-101-1/+1
* Update to 3.5.1.anholt2004-05-113-33/+3
* Use the right MTREE_FILEarved2004-04-191-0/+1
* Add a missing xpm.h to the plist, and bring in some patches from Freedesktopmarcus2004-04-163-2/+32
* SIZEify (maintainer timeout)trevor2004-03-311-0/+1
* Declare CONFLICTS between freedesktop.org X extension/library ports andlofi2004-03-251-0/+2
* Whoa there, boy, that's a mighty big commit y'all have there...ade2004-03-141-1/+1
* Bump PORTREVISION on all ports that depend on gettext to aid with upgrading.marcus2004-02-041-0/+1