use Win32; use Config(); use File::Spec; $^X = Win32::GetShortPathName($^X); do File::Spec->catfile( $Config::Config{bin}, 'cpan.bat' );