[svn:parrot] r42395 - trunk/runtime/parrot/library

fperrad at svn.parrot.org fperrad at svn.parrot.org
Tue Nov 10 06:13:43 UTC 2009


Author: fperrad
Date: Tue Nov 10 06:13:41 2009
New Revision: 42395
URL: https://trac.parrot.org/parrot/changeset/42395

Log:
[distutils] pge allows multi source files

Modified:
   trunk/runtime/parrot/library/distutils.pir

Modified: trunk/runtime/parrot/library/distutils.pir
==============================================================================
--- trunk/runtime/parrot/library/distutils.pir	Tue Nov 10 01:01:34 2009	(r42394)
+++ trunk/runtime/parrot/library/distutils.pir	Tue Nov 10 06:13:41 2009	(r42395)
@@ -294,7 +294,7 @@
 
 the key is the PIR pathname
 
-the value is the PGE pathname
+the value is an array of PGE pathname or a single PGE pathname
 
 =cut
 
@@ -312,11 +312,21 @@
     $P0 = iter hash
   L1:
     unless $P0 goto L2
-    .local string pir, pge
+    .local string pir, src
     pir = shift $P0
-    pge = $P0[pir]
-    $I0 = newer(pir, pge)
+    .local pmc srcs
+    srcs = $P0[pir]
+    $I0 = does srcs, 'array'
+    unless $I0 goto L3
+    $I0 = newer(pir, srcs)
+    if $I0 goto L1
+    src = join ' ', srcs
+    goto L4
+  L3:
+    src = srcs
+    $I0 = newer(pir, src)
     if $I0 goto L1
+  L4:
     .local string cmd
     cmd = get_parrot()
     cmd .= " "
@@ -325,7 +335,7 @@
     cmd .= "/library/PGE/Perl6Grammar.pbc --output="
     cmd .= pir
     cmd .= " "
-    cmd .= pge
+    cmd .= src
     system(cmd)
     goto L1
   L2:


More information about the parrot-commits mailing list