[svn:parrot] r36779 - trunk/config/init

allison at svn.parrot.org allison at svn.parrot.org
Sun Feb 15 23:42:09 UTC 2009


Author: allison
Date: Sun Feb 15 23:42:08 2009
New Revision: 36779
URL: https://trac.parrot.org/parrot/changeset/36779

Log:
[install] Calculate the versioned directory name once during the configure
process, and save it.

Modified:
   trunk/config/init/install.pm

Modified: trunk/config/init/install.pm
==============================================================================
--- trunk/config/init/install.pm	Sun Feb 15 23:38:50 2009	(r36778)
+++ trunk/config/init/install.pm	Sun Feb 15 23:42:08 2009	(r36779)
@@ -35,6 +35,19 @@
     $ep =~ s{/\z}{} if defined $ep;
     my $eprefix = $ep ? $ep : $prefix;
 
+    # Install in versioned subdirectories, "/usr/lib/parrot/1.5.0/...". Skip
+    # the "/parrot" or "/1.5.0" subdirectories if these are included in the
+    # prefix.
+    my $versiondir = '';
+    unless ($prefix =~ /parrot/) {
+        $versiondir .= '/parrot';
+    }
+    my $version = $conf->option_or_data('VERSION');
+    unless ($prefix =~ /$version/) {
+        $versiondir .= "/$version"; 
+        $versiondir .= $conf->option_or_data('DEVEL');
+    }
+
     #  --bindir=DIR           user executables [EPREFIX/bin]
     my $bindir = assign_dir( $conf, 'bindir', $eprefix, '/bin' );
 
@@ -91,7 +104,8 @@
         mandir         => $mandir,
 
         # parrot internal use only
-        doc_dir => $datadir . "/doc",
+        doc_dir        => $datadir . "/doc",
+        versiondir     => $versiondir,
     );
 
     return 1;


More information about the parrot-commits mailing list