ports/71201: Please Apply the clkao's patch for p5-VCP
June-Yen Huang
jihuang at gate.sinica.edu.tw
Tue Aug 31 16:30:16 UTC 2004
>Number: 71201
>Category: ports
>Synopsis: Please Apply the clkao's patch for p5-VCP
>Confidential: no
>Severity: non-critical
>Priority: medium
>Responsible: freebsd-ports-bugs
>State: open
>Quarter:
>Keywords:
>Date-Required:
>Class: update
>Submitter-Id: current-users
>Arrival-Date: Tue Aug 31 16:30:15 GMT 2004
>Closed-Date:
>Last-Modified:
>Originator: June-Yen Huang
>Release: FreeBSD 5.2.1-RELEASE-p4 i386
>Organization:
Intitutes of Information Science , Academia , Taiwan R.O.C
>Environment:
System: FreeBSD 140-109-226-121.adsl.sinica.edu.tw 5.2.1-RELEASE-p4 FreeBSD 5.2.1-RELEASE-p4 #7: Sat Apr 3 17:16:23 CST 2004 root at 140-109-226-121.adsl.sinica.edu.tw:/usr/obj/usr/src/sys/Betelgeuse i386
>Description:
clkao at clkao dot org,
hack the VCP source code for his SVK toy.
to make his VCP::Dest::SVK module work,
it's requried to apply those patch against VCP,
but no hurt on original VCP functionality.
>How-To-Repeat:
build p5-VCP-Dest-SVK and p5-VCP , it will not work fine in 'svk mirror ' command.
>Fix:
please apply this patch againt ports-dir
Index: files/patch-bin::vcp
===================================================================
--- files/patch-bin::vcp (revision 0)
+++ files/patch-bin::vcp (revision 234)
@@ -0,0 +1,41 @@
+--- bin/vcp.orig Fri Mar 19 05:30:20 2004
++++ bin/vcp Tue Apr 13 02:08:37 2004
+@@ -360,8 +360,6 @@
+ || -S _ < 1_000_000 # That would be toooo big
+ );
+
+- print banner() if $is_vcp_file;
+-
+ $vcp_spec = $is_vcp_file
+ ? VCP::ConfigFileUtils::parse_config_file( $source_spec )
+ : ! $cant_be_vcp_file
+@@ -375,6 +373,7 @@
+ $vcp_filename = $source_spec;
+ shift @ARGV;
+ }
++
+ };
+
+ if ( $vcp_spec ) {
+@@ -418,6 +417,10 @@
+ $spec = "";
+ }
+
++ print banner()
++ if $type eq "dest" && length $spec && $spec ne "-";
++ ## Don't emit the banner if we're emitting to STDOUT.
++
+ push @plugins, load_module( $spec, $type, $default_scheme, $value );
+
+ die "extra parameters for $tag: ", shell_quote( @$value ), "\n"
+@@ -442,6 +445,10 @@
+ $type = "Dest";
+ $default_scheme = "revml";
+ }
++
++ print banner()
++ if $type eq "Dest" && length $spec && $spec ne "-";
++ ## Don't emit the banner if we're emitting to STDOUT.
+
+ ## We pass \@ARGV to the constructors for source and dest so
+ ## that they may parse some of @ARGV and leave the rest.
Index: files/patch-MANIFEST
===================================================================
--- files/patch-MANIFEST (revision 0)
+++ files/patch-MANIFEST (revision 234)
@@ -0,0 +1,16 @@
+--- MANIFEST.orig Fri Mar 19 05:38:29 2004
++++ MANIFEST Mon Jul 12 04:45:29 2004
+@@ -53,7 +53,6 @@
+ lib/VCP/Filter/dumpdata.pm
+ lib/VCP/Filter/identity.pm
+ lib/VCP/Filter/labelmap.pm
+-lib/VCP/Filter/logmemsize.pm
+ lib/VCP/Filter/map.pm
+ lib/VCP/Filter/sort.pm
+ lib/VCP/Filter/stringedit.pm
+@@ -164,4 +163,4 @@
+ t/95p42p4.t
+ t/99p4_label_branch_rev_1.t
+ t/buildpss.ksh,v
+-t/swapnfs.c,v
++META.yml Module meta-data (added by MakeMaker)
Index: files/patch-META.yml
===================================================================
--- files/patch-META.yml (revision 0)
+++ files/patch-META.yml (revision 234)
@@ -0,0 +1,27 @@
+--- META.yml.orig Thu Jan 1 08:00:00 1970
++++ META.yml Sun Jul 18 01:49:37 2004
+@@ -0,0 +1,24 @@
++# http://module-build.sourceforge.net/META-spec.html
++#XXXXXXX This is a prototype!!! It will change in the future!!! XXXXX#
++name: VCP
++version: 0.9
++version_from: lib/VCP.pm
++installdirs: site
++requires:
++ Digest::MD5: 0
++ File::Temp: 0
++ HTML::Element: 0
++ IPC::Run3: 0
++ MIME::Base64: 0
++ Pod::HTML_Elements: 0
++ Pod::Links: 0
++ Pod::Select: 0
++ Pod::Text: 0
++ Pod::Usage: 0
++ Regexp::Shellish: 0.93
++ Text::Diff: 0
++ XML::Parser: 0
++ XML::ValidWriter: 0.38
++
++distribution_type: module
++generated_by: ExtUtils::MakeMaker version 6.17
Index: files/patch-lib::VCP::Filter::logmemsize.pm
===================================================================
--- files/patch-lib::VCP::Filter::logmemsize.pm (revision 0)
+++ files/patch-lib::VCP::Filter::logmemsize.pm (revision 234)
@@ -0,0 +1,110 @@
+--- lib/VCP/Filter/logmemsize.pm.orig Sat Nov 15 04:41:49 2003
++++ lib/VCP/Filter/logmemsize.pm Thu Jan 1 08:00:00 1970
+@@ -1,107 +0,0 @@
+-package VCP::Filter::logmemsize ;
+-
+-=head1 NAME
+-
+-VCP::Filter::logmemsize - developement logging filter
+-
+-=head1 DESCRIPTION
+-
+-Watches memory size. Only works on linux for now.
+-
+-Not a supported module, API and behavior may change without warning.
+-
+-=cut
+-
+-$VERSION = 0.1 ;
+-
+-use strict ;
+-
+-my $start_size;
+-
+-
+-sub get_size {
+- open F, "/proc/$$/statm" or return 0;
+- my ( $s ) = <F> =~ /^(\d+)/;
+- close F;
+-
+- return $s * 4;
+-}
+-
+-sub get_sizes {
+- my $s = get_size;
+-
+- return ( $s - $start_size, "KB (", $s, "KB)" );
+-}
+-
+-BEGIN {
+- $start_size = get_size;
+-}
+-
+-use base qw( VCP::Filter );
+-use fields qw( LogString );
+-
+-use VCP::Utils qw( empty );
+-use VCP::Logger qw( pr lg );
+-
+-END {
+- lg "memsize: ", get_sizes;
+-}
+-
+-sub new {
+- my $class = shift ;
+- $class = ref $class || $class ;
+-
+- my ( $spec, $options ) = @_;
+-
+- my $self = $class->SUPER::new( @_ );
+- $self->{LogString} = shift @$options if $options;
+- $self->{LogString} = "" unless defined $self->{LogString};
+- $self->{LogString} .= " " unless empty $self->{LogString};
+-
+- lg $self->{LogString}, "starting memsize: (${start_size}KB)";
+- lg $self->{LogString}, "memsize: ", get_sizes;
+-
+- return $self;
+-}
+-
+-
+-sub handle_header {
+- my VCP::Filter::logmemsize $self = shift ;
+-
+- lg $self->{LogString}, "memsize: ", get_sizes;
+-
+- $self->SUPER::handle_header( @_ );
+-}
+-
+-sub handle_rev {
+- my VCP::Filter::logmemsize $self = shift ;
+-
+- lg $self->{LogString}, "memsize: ", get_sizes;
+- $self->SUPER::handle_rev( @_ );
+-}
+-
+-
+-sub handle_footer {
+- my VCP::Filter::logmemsize $self = shift ;
+-
+- lg $self->{LogString}, "memsize: ", get_sizes;
+- $self->SUPER::handle_footer ( @_ );
+- lg $self->{LogString}, "memsize: ", get_sizes;
+-}
+-
+-=back
+-
+-=head1 AUTHOR
+-
+-Barrie Slaymaker <barries at slaysys.com>
+-
+-=head1 COPYRIGHT
+-
+-Copyright (c) 2000, 2001, 2002 Perforce Software, Inc.
+-All rights reserved.
+-
+-See L<VCP::License|VCP::License> (C<vcp help license>) for the terms of use.
+-
+-=cut
+-
+-1
Index: files/patch-lib::VCP::UIMachines.pm
===================================================================
--- files/patch-lib::VCP::UIMachines.pm (revision 0)
+++ files/patch-lib::VCP::UIMachines.pm (revision 234)
@@ -0,0 +1,11 @@
+--- lib/VCP/UIMachines.pm.orig Fri Jan 30 11:06:03 2004
++++ lib/VCP/UIMachines.pm Thu Apr 8 19:01:51 2004
+@@ -2,7 +2,7 @@
+
+ =begin hackers
+
+-DO NOT EDIT!!! GENERATED FROM ui_machines/vcp_ui.tt2 by /usr/bin/stml AT Thu Jan 29 22:06:02 2004
++DO NOT EDIT!!! GENERATED FROM ui_machines/vcp_ui.tt2 by C:\Perl\bin\stml AT Mon Jan 5 12:44:59 2004
+
+ =end hackers
+
Index: files/patch-lib::VCP::Utils::p4.pm
===================================================================
--- files/patch-lib::VCP::Utils::p4.pm (revision 0)
+++ files/patch-lib::VCP::Utils::p4.pm (revision 234)
@@ -0,0 +1,11 @@
+--- lib/VCP/Utils/p4.pm.orig Fri Jan 30 10:48:39 2004
++++ lib/VCP/Utils/p4.pm Mon Apr 19 00:35:59 2004
+@@ -830,7 +830,7 @@
+ $self->p4( [ "client", "-i" ], \$client_spec, \my $out ) ;
+
+ die "unexpected stdout from p4:\np4: ", $out
+- unless $out =~ /^Client\s.*\ssaved\./ ;
++ unless $out =~ /^Client\s.*\s(saved|.*not changed)\./ ;
+ }
+
+ =item split_repo_server
Index: files/patch-bin::dump_rev_map
===================================================================
--- files/patch-bin::dump_rev_map (revision 0)
+++ files/patch-bin::dump_rev_map (revision 234)
@@ -0,0 +1,11 @@
+--- bin/dump_rev_map.orig Thu Oct 9 03:09:00 2003
++++ bin/dump_rev_map Fri Apr 16 01:25:58 2004
+@@ -2,7 +2,7 @@
+
+ use strict;
+ use VCP::Debug qw( :debug );
+-BEGIN { enable_debug ".*"; }
++#BEGIN { enable_debug ".*"; }
+
+ use VCP::RevMapDB;
+
Index: files/patch-lib::VCP::Source::p4.pm
===================================================================
--- files/patch-lib::VCP::Source::p4.pm (revision 0)
+++ files/patch-lib::VCP::Source::p4.pm (revision 234)
@@ -0,0 +1,13 @@
+--- lib/VCP/Source/p4.pm.orig Fri Jan 30 10:48:36 2004
++++ lib/VCP/Source/p4.pm Mon Apr 19 01:10:03 2004
+@@ -781,8 +781,9 @@
+ next ;
+ }
+ next if $spec =~ m{^error: //\.\.\.\@.+ file(\(s\))?( not in label.)?$} ;
++ next if $spec =~ m{^error: //\.\.\..+ - no such file\(s\)\.};
+ $spec =~ /^.*?: *(\/\/.*#\d+)/
+- or die "Couldn't parse name & rev from '$spec' in p4 output:\n$files\n" ;
++ or die "Couldn't parse name & rev from '$spec' in p4 output:\n$files\n";
+ my $id = $1;
+
+ debug "p4 label '$label' => '$id'" if debugging ;
Index: files/patch-lib::VCP.pm
===================================================================
--- files/patch-lib::VCP.pm (revision 0)
+++ files/patch-lib::VCP.pm (revision 234)
@@ -0,0 +1,7 @@
+--- lib/VCP.pm.orig Fri Mar 19 05:30:51 2004
++++ lib/VCP.pm Mon Jul 12 21:21:10 2004
+@@ -174,3 +174,4 @@
+ =cut
+
+ 1
++;
Index: files/patch-bin::build_vcp_executable.pl
===================================================================
--- files/patch-bin::build_vcp_executable.pl (revision 0)
+++ files/patch-bin::build_vcp_executable.pl (revision 234)
@@ -0,0 +1,47 @@
+--- bin/build_vcp_executable.pl.orig Sat Jan 31 12:03:32 2004
++++ bin/build_vcp_executable.pl Tue Apr 13 02:08:36 2004
+@@ -7,7 +7,8 @@
+ =head1 SYNOPSIS
+
+ cd VCP
+- bin\build_vcp_executable.pl
++ bin\build_vcp_executable.pl ## build ./vcp-bin or ./vcp.exe
++ bin\build_vcp_executable.pl --build-vcp-pl ## build ./vcp.pl
+
+ =head1 DESCRIPTION
+
+@@ -65,8 +66,13 @@
+ use lib "lib";
+ use constant is_win32 => $^O =~ /Win32/i;
+
++use Getopt::Long;
+ use VCP::TestUtils qw( run );
+
++GetOptions( "build-vcp-pl" => \my $build_vcp_pl ) or die $!;
++warn "ignoring command line parameter(s): ", join ", ", map "\"$_\"", @ARGV
++ if @ARGV;
++
+ ## VCP uses lazy loading extensively...
+ my %skip_modules = (
+ "VCP::TestUtils" => 1,
+@@ -121,7 +127,7 @@
+ close VCP_OUT;
+ }
+
+-my $exe_name = is_win32 ? "vcp.exe" : "vcp-bin";
++my $exe_name = $build_vcp_pl ? "vcp.pl" : is_win32 ? "vcp.exe" : "vcp-bin";
+
+ if ( 1 ) {
+ if ( -e $exe_name ) {
+@@ -130,8 +136,9 @@
+
+ my @cmd = (
+ "pp",
+- "-o", $exe_name,
+-# "-p", "-B", "-o", "vcp.pl",
++ $build_vcp_pl
++ ? ( "-P", "-o", "vcp.pl" )
++ : ( "-o", $exe_name ),
+ "-lib=lib",
+ sort(
+ map "--add=$_", @modules#, map "lib/$_", @pod_files
Index: files/patch-lib::VCP::Filter::changesets.pm
===================================================================
--- files/patch-lib::VCP::Filter::changesets.pm (revision 0)
+++ files/patch-lib::VCP::Filter::changesets.pm (revision 234)
@@ -0,0 +1,22 @@
+--- lib/VCP/Filter/changesets.pm.orig Fri Jan 30 10:48:34 2004
++++ lib/VCP/Filter/changesets.pm Sun Jul 18 01:39:02 2004
+@@ -666,8 +666,8 @@
+ if ( !$change ) {
+ my @future_indexes =
+ grep $_ != $r_index,
+- unpack "w*", $changes->[$change_index]
+- if $changes->[$change_index];
++ unpack "w*",
++ exists $changes->[$change_index] ? $changes->[$change_index] : '';
+
+ undef $changes->[$change_index];
+
+@@ -780,7 +780,7 @@
+
+ my $r_index = delete $self->{INDEXES_BY_ID}->{$r->id};
+
+- if ( $children->[$r_index] ) {
++ if ( exists $children->[$r_index] ) {
+ push @cur_indexes, unpack "w*", $children->[$r_index];
+ }
+ undef $children->[$r_index]; ## undef $foo releases extra memory
>Release-Note:
>Audit-Trail:
>Unformatted:
More information about the freebsd-ports-bugs
mailing list