@@ -661,10 +661,8 @@ public static IStatus extract(ArchiveInputStream in, File destFolder, int stripP
661
661
if (entry .getKey ().exists () && overwrite ) {
662
662
entry .getKey ().delete ();
663
663
}
664
- // do not make symlinks in windows
665
- if (!Platform .getOS ().equals (Platform .OS_WIN32 )) {
666
- symlink (entry .getValue (), entry .getKey ());
667
- }
664
+
665
+ symlink (entry .getValue (), entry .getKey ());
668
666
entry .getKey ().setLastModified (symLinksModifiedTimes .get (entry .getKey ()).longValue ());
669
667
}
670
668
@@ -677,10 +675,19 @@ public static IStatus extract(ArchiveInputStream in, File destFolder, int stripP
677
675
678
676
}
679
677
680
- private static void symlink (String something , File somewhere ) throws IOException , InterruptedException {
681
- Process process = Runtime .getRuntime ().exec (new String [] { "ln" , "-s" , something , somewhere .getAbsolutePath () }, //$NON-NLS-1$ //$NON-NLS-2$
682
- null , somewhere .getParentFile ());
683
- process .waitFor ();
678
+ private static void symlink (String from , File to ) throws IOException , InterruptedException {
679
+ if (Platform .getOS ().equals (Platform .OS_WIN32 )) {
680
+ // needs special rights only one board seems to fail due to this
681
+ // Process process = Runtime.getRuntime().exec(new String[] {
682
+ // "mklink", from, to.getAbsolutePath() }, //$NON-NLS-1$
683
+ // null, to.getParentFile());
684
+ // process.waitFor();
685
+ } else {
686
+ Process process = Runtime .getRuntime ().exec (new String [] { "ln" , "-s" , from , to .getAbsolutePath () }, //$NON-NLS-1$ //$NON-NLS-2$
687
+ null , to .getParentFile ());
688
+ process .waitFor ();
689
+ }
690
+
684
691
}
685
692
686
693
private static void link (File something , File somewhere ) throws IOException , InterruptedException {
0 commit comments