pkgsrc-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[pkgsrc/trunk]: pkgsrc/textproc/p5-sdf Initial import of p5-sdf.



details:   https://anonhg.NetBSD.org/pkgsrc/rev/9de266140d96
branches:  trunk
changeset: 339311:9de266140d96
user:      schmonz <schmonz%pkgsrc.org@localhost>
date:      Tue Sep 10 21:20:35 2019 +0000

description:
Initial import of p5-sdf.

SDF (Simple Document Format) is a freely available document development
system which generates high quality outputs in a variety of formats from
a single source. The output formats supported include PostScript, HTML,
POD, plain text, man pages, LaTeX, SGML, Windows help, MIF and RTF. If
the idea of specifying documents in a logical manner via a simple markup
language sounds appealing, SDF may be useful to you.

SDF documents are simple to create and maintain, minimising the time
spent on documentation. In particular, SDF directly supports the
creation and maintenance of large, on-line documentation systems
(including intranets) via centralised hypertext management and
rule-based hypertext generation.

diffstat:

 textproc/p5-sdf/DESCR                               |   12 +
 textproc/p5-sdf/Makefile                            |   17 ++
 textproc/p5-sdf/distinfo                            |   11 +
 textproc/p5-sdf/patches/patch-perllib_sdf_subs.pl   |   65 +++++++++
 textproc/p5-sdf/patches/patch-perllib_sdf_tohtml.pl |   48 +++++++
 textproc/p5-sdf/patches/patch-perllib_sdf_tomif.pl  |  135 ++++++++++++++++++++
 textproc/p5-sdf/patches/patch-perllib_sdf_topod.pl  |   27 ++++
 textproc/p5-sdf/patches/patch-perllib_sdf_tosgml.pl |   55 ++++++++
 8 files changed, 370 insertions(+), 0 deletions(-)

diffs (truncated from 402 to 300 lines):

diff -r 251d411c65dc -r 9de266140d96 textproc/p5-sdf/DESCR
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/textproc/p5-sdf/DESCR     Tue Sep 10 21:20:35 2019 +0000
@@ -0,0 +1,12 @@
+SDF (Simple Document Format) is a freely available document development
+system which generates high quality outputs in a variety of formats from
+a single source. The output formats supported include PostScript, HTML,
+POD, plain text, man pages, LaTeX, SGML, Windows help, MIF and RTF. If
+the idea of specifying documents in a logical manner via a simple markup
+language sounds appealing, SDF may be useful to you.
+
+SDF documents are simple to create and maintain, minimising the time
+spent on documentation. In particular, SDF directly supports the
+creation and maintenance of large, on-line documentation systems
+(including intranets) via centralised hypertext management and
+rule-based hypertext generation.
diff -r 251d411c65dc -r 9de266140d96 textproc/p5-sdf/Makefile
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/textproc/p5-sdf/Makefile  Tue Sep 10 21:20:35 2019 +0000
@@ -0,0 +1,17 @@
+# $NetBSD: Makefile,v 1.1 2019/09/10 21:20:35 schmonz Exp $
+
+DISTNAME=      sdf-2.001beta1
+PKGNAME=       p5-${DISTNAME}
+CATEGORIES=    textproc perl5
+MASTER_SITES=  ${HOMEPAGE}
+
+MAINTAINER=    schmonz%NetBSD.org@localhost
+HOMEPAGE=      https://cpan.metacpan.org/authors/id/I/IA/IANC/
+COMMENT=       Simple Document Format to generate multiple output formats
+LICENSE=       2-clause-bsd
+
+PERL5_PACKLIST=        auto/SDF/.packlist
+USE_LANGUAGES= # none
+
+.include "../../lang/perl5/module.mk"
+.include "../../mk/bsd.pkg.mk"
diff -r 251d411c65dc -r 9de266140d96 textproc/p5-sdf/distinfo
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/textproc/p5-sdf/distinfo  Tue Sep 10 21:20:35 2019 +0000
@@ -0,0 +1,11 @@
+$NetBSD: distinfo,v 1.1 2019/09/10 21:20:35 schmonz Exp $
+
+SHA1 (sdf-2.001beta1.tar.gz) = 01bf3f7e36ae139f68018e1561586da451bc5c8e
+RMD160 (sdf-2.001beta1.tar.gz) = 013680e244550cdd86c54c8f0eabb420fcd8a885
+SHA512 (sdf-2.001beta1.tar.gz) = 8230b90e4c425a18f79305856cea4f7a3f0c1994d93b74a67debe0740f454d7fa81e68c4d818fd4c14d8d690f7af40449c10520c219495b3854ef17747b72ce5
+Size (sdf-2.001beta1.tar.gz) = 788018 bytes
+SHA1 (patch-perllib_sdf_subs.pl) = 0e975864b1268e816b0a5ef4097eaa0396bed49c
+SHA1 (patch-perllib_sdf_tohtml.pl) = 0c0d1baafc75c0780a56d33cd45200dbd322254d
+SHA1 (patch-perllib_sdf_tomif.pl) = 649a2b16b1365ddc7fec69799264ab625f80e454
+SHA1 (patch-perllib_sdf_topod.pl) = 87aaf3b276cd319d81803edb39b3f4f860538642
+SHA1 (patch-perllib_sdf_tosgml.pl) = 4672455c6472be072aa94949d015247d50643c30
diff -r 251d411c65dc -r 9de266140d96 textproc/p5-sdf/patches/patch-perllib_sdf_subs.pl
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/textproc/p5-sdf/patches/patch-perllib_sdf_subs.pl Tue Sep 10 21:20:35 2019 +0000
@@ -0,0 +1,65 @@
+$NetBSD: patch-perllib_sdf_subs.pl,v 1.1 2019/09/10 21:20:35 schmonz Exp $
+
+Use /m instead of $*, no longer available in Perl 5.30.
+Patch from Debian: 005_multiline.diff
+
+--- perllib/sdf/subs.pl.orig   1998-10-26 08:24:46.000000000 +0000
++++ perllib/sdf/subs.pl
+@@ -620,10 +620,6 @@ sub ExecEventsStyleMask {
+     local($event, $action, $mask);
+     local($old_match_rule);
+ 
+-    # Ensure multi-line matching is enabled
+-    $old_match_rule = $*;
+-    $* = 1;
+-
+     for ($event = $#code; $event >= 0; $event--) {
+ 
+         # get the action to execute, if any
+@@ -632,7 +628,7 @@ sub ExecEventsStyleMask {
+ 
+         # Mask out events
+         $mask = $mask[$event];
+-        next if $mask ne '' && $style !~ /^$mask$/;
++        next if $mask ne '' && $style !~ /^$mask$/m;
+         return if $attr{'noevents'};
+ 
+         # execute the action
+@@ -640,8 +636,6 @@ sub ExecEventsStyleMask {
+         &'AppMsg("warning", "execution of '$action' failed: $@") if $@;
+     }
+ 
+-    # Restore the multi-line match flag setting
+-    $* = $old_match_rule;
+ }
+ 
+ #
+@@ -654,11 +648,6 @@ sub ExecEventsNameMask {
+     local(*code, *mask) = @_;
+ #   local();
+     local($event, $action, $mask);
+-    local($old_match_rule);
+-
+-    # Ensure multi-line matching is enabled
+-    $old_match_rule = $*;
+-    $* = 1;
+ 
+     for ($event = $#code; $event >= 0; $event--) {
+ 
+@@ -668,15 +657,12 @@ sub ExecEventsNameMask {
+ 
+         # Mask out events
+         $mask = $mask[$event];
+-        next if $mask ne '' && $name !~ /^$mask$/;
++        next if $mask ne '' && $name !~ /^$mask$/m;
+ 
+         # execute the action
+         eval $action;
+         &'AppMsg("warning", "execution of '$action' failed: $@") if $@;
+     }
+-
+-    # Restore the multi-line match flag setting
+-    $* = $old_match_rule;
+ }
+ #
+ # >>Description::
diff -r 251d411c65dc -r 9de266140d96 textproc/p5-sdf/patches/patch-perllib_sdf_tohtml.pl
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/textproc/p5-sdf/patches/patch-perllib_sdf_tohtml.pl       Tue Sep 10 21:20:35 2019 +0000
@@ -0,0 +1,48 @@
+$NetBSD: patch-perllib_sdf_tohtml.pl,v 1.1 2019/09/10 21:20:35 schmonz Exp $
+
+Use /m instead of $*, no longer available in Perl 5.30.
+Patch from Debian: 005_multiline.diff
+
+--- perllib/sdf/tohtml.pl.orig 1998-10-23 22:59:44.000000000 +0000
++++ perllib/sdf/tohtml.pl
+@@ -759,19 +759,12 @@ sub _HtmlEscape {
+ #   local($result);
+     local($old_match_flag);
+ 
+-    # Enable multi-line matching
+-    $old_match_flag = $*;
+-    $* = 1;
+-
+     # Escape the symbols
+     $text =~ s/\&/&amp;/g;
+     $text =~ s/\</&lt;/g;
+     $text =~ s/\>/&gt;/g;
+     $text =~ s/\"/&quot;/g;
+ 
+-    # Reset multi-line matching flag
+-    $* = $old_match_flag;
+-
+     # Return result
+     $text;
+ }
+@@ -865,10 +858,6 @@ sub _HtmlAddAnchors {
+     local($user_ext);
+     local($old_match_flag);
+ 
+-    # Enable multi-line matching
+-    $old_match_flag = $*;
+-    $* = 1;
+-
+     # For hypertext jumps, surround the text. If the
+     # text contains a jump, the existing jump is removed.
+     if ($attr{'jump'} ne '') {
+@@ -904,9 +893,6 @@ sub _HtmlAddAnchors {
+         $result++;
+     }
+ 
+-    # Reset multi-line matching flag
+-    $* = $old_match_flag;
+-
+     # Return result
+     return $result;
+ }
diff -r 251d411c65dc -r 9de266140d96 textproc/p5-sdf/patches/patch-perllib_sdf_tomif.pl
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/textproc/p5-sdf/patches/patch-perllib_sdf_tomif.pl        Tue Sep 10 21:20:35 2019 +0000
@@ -0,0 +1,135 @@
+$NetBSD: patch-perllib_sdf_tomif.pl,v 1.1 2019/09/10 21:20:35 schmonz Exp $
+
+Use /m instead of $*, no longer available in Perl 5.30.
+Patch from Debian: 005_multiline.diff
+
+--- perllib/sdf/tomif.pl.orig  1998-10-23 22:59:43.000000000 +0000
++++ perllib/sdf/tomif.pl
+@@ -660,16 +660,12 @@ sub _MifAddSection {
+ sub _MifEscape {
+     local(*text, $escape_space) = @_;
+ #   local();
+-    local($orig_linematch_flag);
+ 
+-    $orig_linematch_flag = $*;
+-    $* = 1;
+     $text =~ s/([\\>])/\\$1/g;
+     $text =~ s/\t/\\t/g;
+     $text =~ s/'/\\q/g;
+     $text =~ s/`/\\Q/g;
+     $text =~ s/ /\\ /g if $escape_space;
+-    $* = $orig_linematch_flag;
+ }
+ 
+ #
+@@ -1984,7 +1980,7 @@ sub _MifFinalise {
+     local(@out_result);
+     local($pwidth, $pheight);
+     local($component_prefix);
+-    local(%offset, $old_match_rule);
++    local(%offset);
+     local(%merged_ctrls, %merged_vars, %merged_xrefs);
+     local(%merged_paras, %merged_fonts, %merged_tbls);
+     local($mainflow);
+@@ -2099,12 +2095,9 @@ $igc_start = time;
+         "<Notes ",
+         "> # end of Notes",
+         @text);
+-    $old_match_rule = $*;
+-    $* = 1;
+     $mainflow =~ s/\<ParaLine/$&\n  <TextRectID $_MIF_TEXTFLOW_MAIN>/;
+     $mainflow =~ s/\n/\n /g;
+     $mainflow .= "\n> # end of TextFlow";
+-    $* = $old_match_rule;
+ 
+     # Add the text flows to the  import table
+     push(@out_result, join("\n", @_mif_textflows, $mainflow));
+@@ -2315,7 +2308,7 @@ sub _MifAddTextFlow {
+     local(*text, $tag, $mif) = @_;
+     local($id);
+     local(@hdr, @flow);
+-    local($textflow, $old_match_rule);
++    local($textflow);
+ 
+     # Get the next text flow id
+     $id = $_mif_textflow_cnt++;
+@@ -2340,12 +2333,9 @@ sub _MifAddTextFlow {
+     # Convert to a text flow
+     if (@flow) {
+         $textflow = join("\n", @flow);
+-        $old_match_rule = $*;
+-        $* = 1;
+         $textflow =~ s/\<ParaLine/$&\n  <TextRectID $id>/;
+         $textflow =~ s/\n/\n /g;
+         $textflow .= "\n> # end of TextFlow";
+-        $* = $old_match_rule;
+     }
+ 
+     # If nothing was generated, build the text flow with a dummy paragraph
+@@ -2805,7 +2795,7 @@ sub _MifAddLists {
+     local(%attr);
+     local($layout);
+     local($i);
+-    local($old_match_rule, $toc_offset);
++    local($toc_offset);
+ 
+     # Set some flags based on the output ultimately generated
+     $target = $SDF_USER'var{'OPT_TARGET'};
+@@ -2833,8 +2823,6 @@ sub _MifAddLists {
+     # Insert the generated lists before the first level 1 heading
+     push(@_mif_toc_list, @_mif_lof_list, @_mif_lot_list);
+     if (@_mif_toc_list) {
+-        $old_match_rule = $*;
+-        $* = 1;
+         $toc_offset = 0;
+         para:
+         for ($i = 0; $i <= $#text; $i++) {
+@@ -2843,7 +2831,6 @@ sub _MifAddLists {
+                 last para;
+             }
+         }
+-        $* = $old_match_rule;
+         splice(@text, $toc_offset, 0, @_mif_toc_list);
+     }
+ }
+@@ -2901,15 +2888,9 @@ sub _MifMerge {
+     local(*template, *import, %offset) = @_;
+     local(@new);
+     local($record, $obj);
+-    local($old_match_rule);
+     local($merged_pages, $merged_textflows, %ref_textflow);
+     local($side_width);
+     local($page_type, $page_name, $page_size, $cover_rect);
+-    
+-    # To permit multi-line matching, save the old state here and
+-    # restore it later      
+-    $old_match_rule = $*;
+-    $* = 1;
+ 
+     #
+     # Do the merge. We ignore BookComponent objects
+@@ -2926,14 +2907,14 @@ sub _MifMerge {
+     while($record = shift(@template)) {
+     
+         # Find the object 'name'
+-        unless ($record =~ /^\<(\w+)/) {
++        unless ($record =~ /^\<(\w+)/m) {
+             &AppExit("fatal", "MIF template error - expecting object");
+         }       
+         $obj = $1;
+ 
+         # Patch the comment to claim responsibility
+         if ($obj eq 'MIFFile') {
+-            $record =~ s/\>.*$/>/;



Home | Main Index | Thread Index | Old Index