r44322 - in /trunk/libembperl-perl: Makefile.PL debian/changelog debian/patches/Makefile.PL.patch debian/patches/modperl.patch debian/patches/series debian/patches/utf8.patch debian/rules epdom.c epinit.c epmain.c
gregoa at users.alioth.debian.org
gregoa at users.alioth.debian.org
Sat Sep 19 19:13:31 UTC 2009
Author: gregoa
Date: Sat Sep 19 19:13:25 2009
New Revision: 44322
URL: http://svn.debian.org/wsvn/pkg-perl/?sc=1&rev=44322
Log:
finish splitting out patches
Added:
trunk/libembperl-perl/debian/patches/Makefile.PL.patch
trunk/libembperl-perl/debian/patches/utf8.patch
Modified:
trunk/libembperl-perl/Makefile.PL
trunk/libembperl-perl/debian/changelog
trunk/libembperl-perl/debian/patches/modperl.patch
trunk/libembperl-perl/debian/patches/series
trunk/libembperl-perl/debian/rules
trunk/libembperl-perl/epdom.c
trunk/libembperl-perl/epinit.c
trunk/libembperl-perl/epmain.c
Modified: trunk/libembperl-perl/Makefile.PL
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libembperl-perl/Makefile.PL?rev=44322&op=diff
==============================================================================
--- trunk/libembperl-perl/Makefile.PL (original)
+++ trunk/libembperl-perl/Makefile.PL Sat Sep 19 19:13:25 2009
@@ -246,15 +246,13 @@
{ # with Apache 2, make sure we have the same defines as mod_perl
$txt =~ s/-O\d//g if ($ccdebug =~ /-O\d/) ;
$txt =~ /CCFLAGS\s*=(.*?)\n/s ;
- my $extra = "$Config{cppflags} " . `apxs2 -q CFLAGS` ;
- my $flags = "$mp2cfg->{MODPERL_CCOPTS} $extra" || $1 ;
+ my $flags = $mp2cfg->{MODPERL_CCOPTS} || $1 ;
$txt =~ s/CCFLAGS\s*=(.*?)\n/CCFLAGS = $ccdebug $flags\n/s ;
}
else
{
- my $extra = "$Config{cppflags} " . Apache::src->new->ccflags ;
$txt =~ s/-O\d//g if ($ccdebug =~ /-O\d/) ;
- $txt =~ s/CCFLAGS\s*=/CCFLAGS = $ccdebug $extra/ ;
+ $txt =~ s/CCFLAGS\s*=/CCFLAGS = $ccdebug / ;
}
@@ -305,15 +303,6 @@
$man -> {$k} = $v ;
}
}
-
-
- # Debian hack - strip .pl from executables
- while (($k, $v) = each %{$self->{MAN1PODS}})
- {
- $v =~ s/\.pl// or next;
- $self->{MAN1PODS}{$k} = $v;
- }
-
foreach my $hash (qw(MAN3PODS PM))
{
@@ -328,14 +317,6 @@
$self -> MM::post_initialize (@_) ;
}
-sub MY::libscan {
- my ($self, $path) = @_;
-
- # Debian hack - strip .pl from executables
- return $path if $path =~ s/\.pl\b//;
-
- $self->MM::libscan($path);
-}
sub MY::post_constants
{
@@ -345,8 +326,6 @@
my $txt = $self -> MM::post_constants (@_) ;
$txt .= "\n# Change name of dynamic lib, in case we need two of them (with and w/o Apache support)\nINST_DYNAMIC = \$(INST_ARCHAUTODIR)\\\$(DLBASE).NoApache.\$(DLEXT)\n" if ($EPNOAPACHELIB) ;
- $txt .= "\n# Change name of dynamic lib, in case we need two of them (different Apache versions)\nINST_DYNAMIC = \$(INST_ARCHAUTODIR)/\$(DLBASE)-13.\$(DLEXT)\n" if ($mod_perl::VERSION and $mod_perl::VERSION < 1.99) ;
-
return $txt ;
@@ -357,8 +336,21 @@
sub GetString
{
my ($prompt, $default) = @_ ;
- return prompt($prompt, $default) ;
- }
+
+ printf ("%s [%s]", $prompt, $default) ;
+ chomp ($_ = <STDIN>) ;
+ s/\s+$//;
+ if (!/^\s*$/)
+ {return $_ ;}
+ else
+ {
+ if ($_ eq "")
+ {return $default ;}
+ else
+ { return "" ; }
+
+ }
+ }
## ----------------------------------------------------------------------------
@@ -554,26 +546,26 @@
$apache_src = '' if ($apache_src eq '-') ;
}
-if (1)
+if (!$apache && $apache_src eq '')
{
# check for mod_perl 2.0
- eval 'use Apache2; use Apache::BuildConfig' unless $ENV{FORCEMP1};
-
- if (!$ENV{FORCEMP1} and $@ eq '')
+ eval 'use Apache2; use Apache::BuildConfig' ;
+
+ if ($@ eq '')
{
$mp2cfg = Apache::BuildConfig -> new ;
- $apache_src ||= $mp2cfg -> {MP_AP_PREFIX} || $mp2cfg -> {ap_includedir} ;
+ $apache_src = $mp2cfg -> {MP_AP_PREFIX} || $mp2cfg -> {ap_includedir} ;
print "Found mod_perl 2.0\n" ;
}
else
{
- eval 'use Apache2::BuildConfig' unless $ENV{FORCEMP1};
-
- if (!$ENV{FORCEMP1} and $@ eq '')
+ eval 'use Apache2::BuildConfig' ;
+
+ if ($@ eq '')
{
$mp2Apache2 = 1 ;
$mp2cfg = Apache2::BuildConfig -> new ;
- $apache_src ||= $mp2cfg -> {MP_AP_PREFIX} || $mp2cfg -> {ap_includedir} ;
+ $apache_src = $mp2cfg -> {MP_AP_PREFIX} || $mp2cfg -> {ap_includedir} ;
print "Found mod_perl 2.0\n" ;
}
else
@@ -582,11 +574,11 @@
if ($@ eq '')
{
- $apache_src ||= $Apache::MyConfig::Setup{Apache_Src} ;
+ $apache_src = $Apache::MyConfig::Setup{Apache_Src} ;
}
else
{
- $apache_src ||= '' ;
+ $apache_src = '' ;
}
}
}
@@ -794,10 +786,7 @@
$i = '' ;
$o = '' ;
}
-
-if ($mp2cfg) {
- $i .= " -I$mp2cfg->{apr_includedir}" if $mp2cfg->{apr_includedir};
-}
+
if ($win32 && $apache)
{ # borrowed from mod_perl
@@ -1301,11 +1290,9 @@
'INC' => "-I$EPPATH $i",
'VERSION' => undef,
'VERSION_FROM' => "$EPPATH/Embperl.pm",
- 'CCFLAGS' => $Config{cppflags}.($mp2cfg?`apxs2 -q CFLAGS`:Apache::src->new->ccflags),
$optdebug?('OPTIMIZE' => $ccdebug):(),
) ;
-$i = "-I$EPPATH $i";
open FH, ">xs/mmargs.pl" or die "Cannot open xs/mmargs.pl ($!).\n
Modified: trunk/libembperl-perl/debian/changelog
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libembperl-perl/debian/changelog?rev=44322&op=diff
==============================================================================
--- trunk/libembperl-perl/debian/changelog (original)
+++ trunk/libembperl-perl/debian/changelog Sat Sep 19 19:13:25 2009
@@ -25,6 +25,8 @@
* Update jawnsy's email address
[ gregor herrmann ]
+ * Split out all changes to upstream code into proper patches managed by
+ quilt.
* Add patch cgi_pm.patch by Niko Tyni to avoid FTBFS if a newer CGI.pm is
present at test time (closes: #521971).
* Update debian/copyright.
Added: trunk/libembperl-perl/debian/patches/Makefile.PL.patch
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libembperl-perl/debian/patches/Makefile.PL.patch?rev=44322&op=file
==============================================================================
--- trunk/libembperl-perl/debian/patches/Makefile.PL.patch (added)
+++ trunk/libembperl-perl/debian/patches/Makefile.PL.patch Sat Sep 19 19:13:25 2009
@@ -1,0 +1,160 @@
+Description:
+ - remove extensions from scripts
+ - <more>
+
+--- a/Makefile.PL
++++ b/Makefile.PL
+@@ -246,13 +246,15 @@
+ { # with Apache 2, make sure we have the same defines as mod_perl
+ $txt =~ s/-O\d//g if ($ccdebug =~ /-O\d/) ;
+ $txt =~ /CCFLAGS\s*=(.*?)\n/s ;
+- my $flags = $mp2cfg->{MODPERL_CCOPTS} || $1 ;
++ my $extra = "$Config{cppflags} " . `apxs2 -q CFLAGS` ;
++ my $flags = "$mp2cfg->{MODPERL_CCOPTS} $extra" || $1 ;
+ $txt =~ s/CCFLAGS\s*=(.*?)\n/CCFLAGS = $ccdebug $flags\n/s ;
+ }
+ else
+ {
++ my $extra = "$Config{cppflags} " . Apache::src->new->ccflags ;
+ $txt =~ s/-O\d//g if ($ccdebug =~ /-O\d/) ;
+- $txt =~ s/CCFLAGS\s*=/CCFLAGS = $ccdebug / ;
++ $txt =~ s/CCFLAGS\s*=/CCFLAGS = $ccdebug $extra/ ;
+ }
+
+
+@@ -304,6 +306,15 @@
+ }
+ }
+
++
++ # Debian hack - strip .pl from executables
++ while (($k, $v) = each %{$self->{MAN1PODS}})
++ {
++ $v =~ s/\.pl// or next;
++ $self->{MAN1PODS}{$k} = $v;
++ }
++
++
+ foreach my $hash (qw(MAN3PODS PM))
+ {
+ foreach (keys %{$self->{$hash}})
+@@ -317,6 +328,14 @@
+ $self -> MM::post_initialize (@_) ;
+ }
+
++sub MY::libscan {
++ my ($self, $path) = @_;
++
++ # Debian hack - strip .pl from executables
++ return $path if $path =~ s/\.pl\b//;
++
++ $self->MM::libscan($path);
++}
+
+ sub MY::post_constants
+ {
+@@ -326,6 +345,8 @@
+ my $txt = $self -> MM::post_constants (@_) ;
+
+ $txt .= "\n# Change name of dynamic lib, in case we need two of them (with and w/o Apache support)\nINST_DYNAMIC = \$(INST_ARCHAUTODIR)\\\$(DLBASE).NoApache.\$(DLEXT)\n" if ($EPNOAPACHELIB) ;
++ $txt .= "\n# Change name of dynamic lib, in case we need two of them (different Apache versions)\nINST_DYNAMIC = \$(INST_ARCHAUTODIR)/\$(DLBASE)-13.\$(DLEXT)\n" if ($mod_perl::VERSION and $mod_perl::VERSION < 1.99) ;
++
+
+ return $txt ;
+
+@@ -336,21 +357,8 @@
+ sub GetString
+ {
+ my ($prompt, $default) = @_ ;
+-
+- printf ("%s [%s]", $prompt, $default) ;
+- chomp ($_ = <STDIN>) ;
+- s/\s+$//;
+- if (!/^\s*$/)
+- {return $_ ;}
+- else
+- {
+- if ($_ eq "")
+- {return $default ;}
+- else
+- { return "" ; }
+-
+- }
+- }
++ return prompt($prompt, $default) ;
++ }
+
+ ## ----------------------------------------------------------------------------
+
+@@ -546,26 +554,26 @@
+ $apache_src = '' if ($apache_src eq '-') ;
+ }
+
+-if (!$apache && $apache_src eq '')
++if (1)
+ {
+ # check for mod_perl 2.0
+- eval 'use Apache2; use Apache::BuildConfig' ;
++ eval 'use Apache2; use Apache::BuildConfig' unless $ENV{FORCEMP1};
+
+- if ($@ eq '')
++ if (!$ENV{FORCEMP1} and $@ eq '')
+ {
+ $mp2cfg = Apache::BuildConfig -> new ;
+- $apache_src = $mp2cfg -> {MP_AP_PREFIX} || $mp2cfg -> {ap_includedir} ;
++ $apache_src ||= $mp2cfg -> {MP_AP_PREFIX} || $mp2cfg -> {ap_includedir} ;
+ print "Found mod_perl 2.0\n" ;
+ }
+ else
+ {
+- eval 'use Apache2::BuildConfig' ;
++ eval 'use Apache2::BuildConfig' unless $ENV{FORCEMP1};
+
+- if ($@ eq '')
++ if (!$ENV{FORCEMP1} and $@ eq '')
+ {
+ $mp2Apache2 = 1 ;
+ $mp2cfg = Apache2::BuildConfig -> new ;
+- $apache_src = $mp2cfg -> {MP_AP_PREFIX} || $mp2cfg -> {ap_includedir} ;
++ $apache_src ||= $mp2cfg -> {MP_AP_PREFIX} || $mp2cfg -> {ap_includedir} ;
+ print "Found mod_perl 2.0\n" ;
+ }
+ else
+@@ -574,11 +582,11 @@
+
+ if ($@ eq '')
+ {
+- $apache_src = $Apache::MyConfig::Setup{Apache_Src} ;
++ $apache_src ||= $Apache::MyConfig::Setup{Apache_Src} ;
+ }
+ else
+ {
+- $apache_src = '' ;
++ $apache_src ||= '' ;
+ }
+ }
+ }
+@@ -786,7 +794,10 @@
+ $i = '' ;
+ $o = '' ;
+ }
+-
++
++if ($mp2cfg) {
++ $i .= " -I$mp2cfg->{apr_includedir}" if $mp2cfg->{apr_includedir};
++}
+
+ if ($win32 && $apache)
+ { # borrowed from mod_perl
+@@ -1290,9 +1301,11 @@
+ 'INC' => "-I$EPPATH $i",
+ 'VERSION' => undef,
+ 'VERSION_FROM' => "$EPPATH/Embperl.pm",
++ 'CCFLAGS' => $Config{cppflags}.($mp2cfg?`apxs2 -q CFLAGS`:Apache::src->new->ccflags),
+ $optdebug?('OPTIMIZE' => $ccdebug):(),
+ ) ;
+
++$i = "-I$EPPATH $i";
+
+
+ open FH, ">xs/mmargs.pl" or die "Cannot open xs/mmargs.pl ($!).\n
Modified: trunk/libembperl-perl/debian/patches/modperl.patch
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libembperl-perl/debian/patches/modperl.patch?rev=44322&op=diff
==============================================================================
--- trunk/libembperl-perl/debian/patches/modperl.patch (original)
+++ trunk/libembperl-perl/debian/patches/modperl.patch Sat Sep 19 19:13:25 2009
@@ -15,7 +15,7 @@
+ $file =~ s/(.*)\./$1-13./ ;
}
+-] ;
+ #print STDERR "\n*** bs load file = $file ***\n" ;
-+
- ] ;
--
+
++] ;
Modified: trunk/libembperl-perl/debian/patches/series
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libembperl-perl/debian/patches/series?rev=44322&op=diff
==============================================================================
--- trunk/libembperl-perl/debian/patches/series (original)
+++ trunk/libembperl-perl/debian/patches/series Sat Sep 19 19:13:25 2009
@@ -4,3 +4,5 @@
new_process_group.patch
delay.patch
modperl.patch
+utf8.patch
+Makefile.PL.patch
Added: trunk/libembperl-perl/debian/patches/utf8.patch
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libembperl-perl/debian/patches/utf8.patch?rev=44322&op=file
==============================================================================
--- trunk/libembperl-perl/debian/patches/utf8.patch (added)
+++ trunk/libembperl-perl/debian/patches/utf8.patch Sat Sep 19 19:13:25 2009
@@ -1,0 +1,51 @@
+Author: Angus Lees <gus at debian.org>
+Description: UTF-8 input/output escaping (Closes: #154672)
+
+--- a/epinit.c
++++ b/epinit.c
+@@ -1124,7 +1124,7 @@
+ { /* New Field -> store it */
+ pSVV = newSVpv (pVal, nVal) ;
+ #ifdef UTF8_IS_START
+- if (mayutf8 && is_utf8_string(pVal, nVal))
++ if (mayutf8 && is_utf8_string((U8*)pVal, nVal))
+ SvUTF8_on (pSVV) ;
+ #endif
+ if (hv_store (pFormHash, pKey, nKey, pSVV, 0) == NULL)
+--- a/epdom.c
++++ b/epdom.c
+@@ -242,8 +242,8 @@
+ else
+ {
+ char buf[256] ;
+- /*
+- sprintf (buf, "%u bytes", n) ;
++ /*
++ sprintf (buf, "%zu bytes", n) ;
+ LogErrorParam (a, rcOutOfMemory, "str_malloc failed", buf) ;
+ */
+ sprintf (buf, "str_malloc: Out of memory (%u bytes)", n + sizeof (size_t)) ;
+@@ -274,7 +274,7 @@
+ {
+ char buf[256] ;
+ /*
+- sprintf (buf, "%u bytes", n) ;
++ sprintf (buf, "%zu bytes", n) ;
+ LogErrorParam (a, rcOutOfMemory, "str_malloc_dbg failed", buf) ;
+ */
+ sprintf (buf, "str_malloc: Out of memory (%u bytes)", n + sizeof (size_t)) ;
+--- a/epmain.c
++++ b/epmain.c
+@@ -816,10 +816,12 @@
+ SPAGAIN ;
+ #ifdef APACHE
+ if (r -> pApacheReq)
++ {
+ if (rc >= 400)
+ r -> pApacheReq -> status = rc ;
+ else
+ r -> pApacheReq -> status = 500 ;
++ }
+ #endif
+
+ SetHashValueInt (r, r -> pThread -> pHeaderHash, "Content-Length", GetContentLength (r) ) ;
Modified: trunk/libembperl-perl/debian/rules
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libembperl-perl/debian/rules?rev=44322&op=diff
==============================================================================
--- trunk/libembperl-perl/debian/rules (original)
+++ trunk/libembperl-perl/debian/rules Sat Sep 19 19:13:25 2009
@@ -44,7 +44,7 @@
pod2text < $< > $@
config: config-stamp
-config-stamp:
+config-stamp: $(QUILT_STAMPFN)
FORCEMP=0
dh_testdir
APACHE_HDR=$(APACHE_HDR) \
@@ -55,7 +55,7 @@
touch $@
build: build-stamp
-build-stamp: $(POD2TEXT) config-stamp $(QUILT_STAMPFN)
+build-stamp: $(POD2TEXT) config-stamp
dh_testdir
$(MAKE) -j1 OPTIMIZE="$(OPTIMIZE)" LD_RUN_PATH=""
$(MAKE) -j1 TESTARGS="$(TESTARGS)" test
@@ -93,8 +93,7 @@
dh_testdir
dh_testroot
- $(RM) build-stamp
- [ ! -f Makefile ] || $(MAKE) realclean
+ [ ! -f Makefile ] || ( touch Makefile && $(MAKE) realclean )
$(RM) $(POD2TEXT) dbinitembperlapache
dh_clean
Modified: trunk/libembperl-perl/epdom.c
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libembperl-perl/epdom.c?rev=44322&op=diff
==============================================================================
--- trunk/libembperl-perl/epdom.c (original)
+++ trunk/libembperl-perl/epdom.c Sat Sep 19 19:13:25 2009
@@ -242,8 +242,8 @@
else
{
char buf[256] ;
- /*
- sprintf (buf, "%zu bytes", n) ;
+ /*
+ sprintf (buf, "%u bytes", n) ;
LogErrorParam (a, rcOutOfMemory, "str_malloc failed", buf) ;
*/
sprintf (buf, "str_malloc: Out of memory (%u bytes)", n + sizeof (size_t)) ;
@@ -274,7 +274,7 @@
{
char buf[256] ;
/*
- sprintf (buf, "%zu bytes", n) ;
+ sprintf (buf, "%u bytes", n) ;
LogErrorParam (a, rcOutOfMemory, "str_malloc_dbg failed", buf) ;
*/
sprintf (buf, "str_malloc: Out of memory (%u bytes)", n + sizeof (size_t)) ;
Modified: trunk/libembperl-perl/epinit.c
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libembperl-perl/epinit.c?rev=44322&op=diff
==============================================================================
--- trunk/libembperl-perl/epinit.c (original)
+++ trunk/libembperl-perl/epinit.c Sat Sep 19 19:13:25 2009
@@ -1124,7 +1124,7 @@
{ /* New Field -> store it */
pSVV = newSVpv (pVal, nVal) ;
#ifdef UTF8_IS_START
- if (mayutf8 && is_utf8_string((U8*)pVal, nVal))
+ if (mayutf8 && is_utf8_string(pVal, nVal))
SvUTF8_on (pSVV) ;
#endif
if (hv_store (pFormHash, pKey, nKey, pSVV, 0) == NULL)
Modified: trunk/libembperl-perl/epmain.c
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libembperl-perl/epmain.c?rev=44322&op=diff
==============================================================================
--- trunk/libembperl-perl/epmain.c (original)
+++ trunk/libembperl-perl/epmain.c Sat Sep 19 19:13:25 2009
@@ -816,12 +816,10 @@
SPAGAIN ;
#ifdef APACHE
if (r -> pApacheReq)
- {
if (rc >= 400)
r -> pApacheReq -> status = rc ;
else
r -> pApacheReq -> status = 500 ;
- }
#endif
SetHashValueInt (r, r -> pThread -> pHeaderHash, "Content-Length", GetContentLength (r) ) ;
More information about the Pkg-perl-cvs-commits
mailing list