388 | | require Win32::Hardlink; |
389 | | print STDERR "util::hard_link: win32: using copy for hard link.\n"; |
390 | | &File::Copy::copy ($src, $dest); |
391 | | } else { |
392 | | if (!link($src, $dest)) { |
393 | | print STDERR "util::hard_link: unable to create hard link. "; |
394 | | print STDERR " Attempting to copy file: $src -> $dest\n"; |
395 | | &File::Copy::copy ($src, $dest); |
396 | | } |
| 383 | &File::Copy::copy ($src, $dest); |
| 384 | |
| 385 | } elsif (!link($src, $dest)) { |
| 386 | print STDERR "util::hard_link: unable to create hard link. "; |
| 387 | print STDERR " Attempting to copy file: $src -> $dest\n"; |
| 388 | &File::Copy::copy ($src, $dest); |
420 | | if ( (Win32::FsType() =~ /^ntfs$/i) && |
421 | | ($src =~ /^.:\\.*/) && ($dest =~ /^.:\\.*/) && |
422 | | (substr($src,0,3) eq substr($dest,0,3)) ) { |
423 | | # if filesystem is NTFS and both source and destination is on the same local drive, |
424 | | # use hardlink instead of symlink |
425 | | #print STDERR "util::soft_link: win32: using hard link instead of soft ink.\n"; |
426 | | hard_link($src,$dest); |
427 | | } else { |
428 | | #print STDERR "util::soft_link: win32: using copy for soft link.\n "; |
429 | | &File::Copy::copy ($src, $dest); |
430 | | } |
| 411 | # symlink not supported on windows |
| 412 | &File::Copy::copy ($src, $dest); |