Do ensure_dir_structure_for *before* de-duping paths
Andrew Rodland [Thu, 24 Feb 2011 20:56:32 +0000 (14:56 -0600)]
this makes the de-dup work properly on win32 with the short name transformation.

lib/local/lib.pm

index dd3d5da..5f2d981 100644 (file)
@@ -207,6 +207,8 @@ sub setup_local_lib_for {
   my $interpolate = LITERAL_ENV;
   my @active_lls = $class->active_paths;
 
+  $path = $class->ensure_dir_structure_for($path);
+
   if (! $deactivating) {
     if (@active_lls && $active_lls[-1] eq $path) {
       exit 0 if $0 eq '-';
@@ -221,8 +223,6 @@ sub setup_local_lib_for {
     }
   }
 
-  $path = $class->ensure_dir_structure_for($path);
-
   if ($0 eq '-') {
     $class->print_environment_vars_for($path, $deactivating, $interpolate);
     exit 0;