[libmarpa-r2-perl] 01/32: Adding marpa.def
Jonas Smedegaard
dr at jones.dk
Sat May 17 21:24:12 UTC 2014
This is an automated email from the git hooks/post-receive script.
js pushed a commit to annotated tag Marpa-R2-2.085_004
in repository libmarpa-r2-perl.
commit e0a05edefdef62d1a0408be288383aed82547048
Author: Jeffrey Kegler <JKEGL at cpan.org>
Date: Wed Apr 23 16:44:40 2014 -0700
Adding marpa.def
---
cpan/libmarpa/Makefile | 18 +++++++++++-------
cpan/libmarpa/ac/Makefile.am | 2 +-
cpan/libmarpa/ami/Makefile | 2 +-
cpan/libmarpa/bin/texi2proto.pl | 22 +++++++++++++++++++---
cpan/libmarpa/dev/.gitignore | 1 +
cpan/libmarpa/dev/Makefile | 4 ++--
cpan/libmarpa/slif/Makefile | 2 +-
7 files changed, 36 insertions(+), 15 deletions(-)
diff --git a/cpan/libmarpa/Makefile b/cpan/libmarpa/Makefile
index aecac8c..628f2c0 100644
--- a/cpan/libmarpa/Makefile
+++ b/cpan/libmarpa/Makefile
@@ -54,7 +54,8 @@ STAGE_FILES = \
stage/marpa_tavl.h \
stage/NEWS \
stage/README \
- stage/VERSION.in
+ stage/VERSION.in \
+ stage/marpa.def
dummy:
@echo install is the main target
@@ -76,6 +77,9 @@ stage/Makefile.am: ac/Makefile.am
stage/marpa.c: dev/marpa.c
cp $? $@
+stage/marpa.def: dev/marpa.def
+ cp $? $@
+
stage/marpa.h: public/marpa.h
cp $? $@
@@ -112,22 +116,22 @@ stage/marpa_tavl.h: tavl/marpa_tavl.h
stage/marpa_tavl.c: tavl/marpa_tavl.c
cp $? $@
-stage/NEWS: ac/NEWS
+stage/AUTHORS: ac/AUTHORS
cp $? $@
-stage/AUTHORS: ac/AUTHORS
+stage/COPYING.LESSER: ac/COPYING.LESSER
cp $? $@
-stage/README: ac/README
+stage/ChangeLog: ac/ChangeLog
cp $? $@
-stage/VERSION.in: public/VERSION.in
+stage/NEWS: ac/NEWS
cp $? $@
-stage/COPYING.LESSER: ac/COPYING.LESSER
+stage/README: ac/README
cp $? $@
-stage/ChangeLog: ac/ChangeLog
+stage/VERSION.in: public/VERSION.in
cp $? $@
doc/README: ac_doc/README
diff --git a/cpan/libmarpa/ac/Makefile.am b/cpan/libmarpa/ac/Makefile.am
index 2cf9286..1ff128a 100644
--- a/cpan/libmarpa/ac/Makefile.am
+++ b/cpan/libmarpa/ac/Makefile.am
@@ -25,7 +25,7 @@ libmarpa_la_SOURCES = marpa.c marpa.h \
marpa_tavl.c marpa_tavl.h \
marpa_ami.c marpa_ami.h \
marpa_codes.c marpa_slif.c
-EXTRA_DIST = VERSION
+EXTRA_DIST = VERSION marpa.def
libmarpa_la_LIBADD = $(LIBOBJS)
libmarpa_la_LDFLAGS = -release $(MARPA_MAJOR_VERSION).$(MARPA_MINOR_VERSION).$(MARPA_MICRO_VERSION)
include_HEADERS = marpa.h \
diff --git a/cpan/libmarpa/ami/Makefile b/cpan/libmarpa/ami/Makefile
index 76d25d8..ae97724 100644
--- a/cpan/libmarpa/ami/Makefile
+++ b/cpan/libmarpa/ami/Makefile
@@ -72,7 +72,7 @@ marpa_ami.c.p40: marpa_ami.w
marpa_ami.h.p50: api.texi internal.texi
cat api.texi internal.texi | \
- perl ../bin/texi2proto.pl > marpa_ami.h.p50
+ perl ../bin/texi2proto.pl /dev/null > marpa_ami.h.p50
update_texi:
emacs -batch internal.texi \
diff --git a/cpan/libmarpa/bin/texi2proto.pl b/cpan/libmarpa/bin/texi2proto.pl
index 4b37d43..d79623c 100644
--- a/cpan/libmarpa/bin/texi2proto.pl
+++ b/cpan/libmarpa/bin/texi2proto.pl
@@ -20,12 +20,23 @@ use warnings;
use English qw( -no_match_vars );
use Fatal qw(open close);
+sub usage {
+ say STDERR "usage: $0 def_file <texi_file > proto_file";
+ exit 1;
+}
+
+usage() unless @ARGV == 1;
+my ($def_file) = @ARGV;
+open my $def_fh, q{>}, $def_file;
+
+my @protos;
my @defs;
LINE: while ( my $line = <STDIN> ) {
next LINE if $line =~ m/ [{] Macro [}] /xms;
- if ( $line =~ /[@]deftypefun/xms ) {
+ next LINE if $line !~ m/[@]deftypefun/xms;
+
my $def = q{};
while ( $line =~ / [@] \s* \z /xms ) {
$def .= $line;
@@ -38,11 +49,16 @@ LINE: while ( my $line = <STDIN> ) {
$def =~ s/ [@]code[{] ([^}]*) [}]/$1/xmsg;
$def =~ s/\s+/ /xmsg;
$def =~ s/\s \z/;/xmsg;
+ push @protos, $def;
+
+ $def =~ s/ \s* [(] .* //xms;
+ $def =~ s/ \s* [(] .* //xms;
+ $def =~ s/ \A .* \s //xms;
push @defs, $def;
- } ## end if ( $line =~ /[@]deftypefun/xms )
} ## end while ( my $line = <STDIN> )
-say join "\n", @defs;
+say join "\n", @protos;
+say {$def_fh} "EXPORTS\n", join "\n", map { q{ } . $_ } @defs;
# vim: expandtab shiftwidth=4:
diff --git a/cpan/libmarpa/dev/.gitignore b/cpan/libmarpa/dev/.gitignore
index ccd91f2..b33ae6c 100644
--- a/cpan/libmarpa/dev/.gitignore
+++ b/cpan/libmarpa/dev/.gitignore
@@ -5,6 +5,7 @@
/marpa[.]c[.]p10
/marpa[.]c[.]p40
/marpa[.]c[.]p50
+/marpa[.]def
/marpa[.]h[.]p50
/marpa[.]h[.]p80
/marpa[.]idx
diff --git a/cpan/libmarpa/dev/Makefile b/cpan/libmarpa/dev/Makefile
index c9b043c..2e8afea 100644
--- a/cpan/libmarpa/dev/Makefile
+++ b/cpan/libmarpa/dev/Makefile
@@ -54,9 +54,9 @@ marpa.c: $(MARPA_C_PIECES)
marpa.h.p50 marpa.c.p10 marpa.c.p50: ../shared/copyright_page_license.w marpa.w
$(CTANGLE) marpa.w
-marpa.h.p80: api.texi internal.texi
+marpa.h.p80 marpa.def: api.texi internal.texi
cat api.texi internal.texi | \
- perl ../bin/texi2proto.pl > marpa.h.p80
+ perl ../bin/texi2proto.pl marpa.def > marpa.h.p80
CPPWRAP = perl ../bin/cppwrap.pl
diff --git a/cpan/libmarpa/slif/Makefile b/cpan/libmarpa/slif/Makefile
index a37b5a0..66d246d 100644
--- a/cpan/libmarpa/slif/Makefile
+++ b/cpan/libmarpa/slif/Makefile
@@ -73,7 +73,7 @@ marpa_slif.c.p40: marpa_slif.w
marpa_slif.h.p80: api.texi internal.texi
cat api.texi internal.texi | \
- perl ../bin/texi2proto.pl > marpa_slif.h.p80
+ perl ../bin/texi2proto.pl /dev/null > marpa_slif.h.p80
marpa_slif.h-ops marpa_slif.c-ops: create_ops.pl
perl create_ops.pl marpa_slif.h-ops | $(CPPWRAP) marpa_slif.c-ops > marpa_slif.c-ops
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-perl/packages/libmarpa-r2-perl.git
More information about the Pkg-perl-cvs-commits
mailing list