summaryrefslogtreecommitdiffstats
path: root/WebKitTools/Scripts/pdevenv
diff options
context:
space:
mode:
Diffstat (limited to 'WebKitTools/Scripts/pdevenv')
-rwxr-xr-xWebKitTools/Scripts/pdevenv24
1 files changed, 24 insertions, 0 deletions
diff --git a/WebKitTools/Scripts/pdevenv b/WebKitTools/Scripts/pdevenv
new file mode 100755
index 0000000..8072adf
--- /dev/null
+++ b/WebKitTools/Scripts/pdevenv
@@ -0,0 +1,24 @@
+#!/usr/bin/perl -w
+
+use strict;
+use warnings;
+
+use File::Temp qw/tempfile/;
+use FindBin;
+
+my ($fh, $path) = tempfile(UNLINK => 0, SUFFIX => '.cmd') or die;
+
+chomp(my $vcBin = `cygpath -w "$FindBin::Bin/../vcbin"`);
+
+print $fh "\@echo off\n\n";
+print $fh "call \"\%VS80COMNTOOLS\%\\vsvars32.bat\"\n\n";
+print $fh "set PATH=$vcBin;\%PATH\%\n\n";
+print $fh "devenv.com /useenv " . join(" ", @ARGV) . "\n";
+
+close $fh;
+
+chmod 0755, $path;
+
+chomp($path = `cygpath -w -s '$path'`);
+
+exec("cmd /c \"call $path\"");