Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

[PATCH] ensure include/parrot/oplib/ directory exists

8 views
Skip to first unread message

Andy Dougherty

unread,
Nov 29, 2004, 4:28:23 PM11/29/04
to Perl6 Internals
A fresh checkout of parrot failed trying to create ops.h. The
problem is that the directory include/parrot/oplib/ is not listed in
MANIFEST and hence doesn't exist. I'm guessing this is a left-over from
the ops cleanup.

This patch ensures that the directory exists before trying to write to it.
(ops2c.pl already had this logic; this patch just replicates it in
ops2pm.pl.)

diff -r -u parrot-current/build_tools/ops2pm.pl parrot-andy/build_tools/ops2pm.pl
--- parrot-current/build_tools/ops2pm.pl Mon Nov 29 10:30:33 2004
+++ parrot-andy/build_tools/ops2pm.pl Mon Nov 29 16:03:00 2004
@@ -225,6 +225,10 @@
# finally create an include file with opcode number

my $inc_f = "include/parrot/oplib/ops.h";
+my $inc_dir = "include/parrot/oplib";
+if (! -d $inc_dir) {
+ mkdir($inc_dir, 0755) or die "ops2pm.pl: Could not mkdir $inc_dir: $!\n";
+}
open OUT, ">$inc_f" or die "Can't write $inc_f: $!";

print OUT <<END_C;

--
Andy Dougherty doug...@lafayette.edu

Leopold Toetsch

unread,
Nov 30, 2004, 6:16:07 AM11/30/04
to Andy Dougherty, perl6-i...@perl.org
Andy Dougherty <doug...@lafayette.edu> wrote:

> This patch ensures that the directory exists before trying to write to it.
> (ops2c.pl already had this logic; this patch just replicates it in
> ops2pm.pl.)

Thanks, applied.
leo

0 new messages