Upstream version 9.38.207.0
[platform/framework/web/crosswalk.git] / src / native_client / scons.bat
1 @echo off\r
2 :: Copyright (c) 2011 The Native Client Authors. All rights reserved.\r
3 :: Use of this source code is governed by a BSD-style license that can be\r
4 :: found in the LICENSE file.\r
5 \r
6 setlocal\r
7 \r
8 :: If this batch file is run directly thru cygwin, we will get the wrong\r
9 :: version of python. To avoid this, if we detect cygwin, we need to then\r
10 :: invoke the shell script which will then re-invoke this batch file with\r
11 :: cygwin stripped out of the path.\r
12 :: Detect cygwin by trying to run bash.\r
13 bash --version >NUL 2>&1\r
14 if %ERRORLEVEL% == 0 (\r
15     bash "%~dp0\scons" %* || exit 1\r
16     goto end\r
17 )\r
18 \r
19 :: Preserve a copy of the PATH (in case we need it later, mainly for cygwin).\r
20 set PRESCONS_PATH=%PATH%\r
21 \r
22 :: Stop incessant CYGWIN complains about "MS-DOS style path"\r
23 set CYGWIN=nodosfilewarning %CYGWIN%\r
24 \r
25 :: Run the included copy of scons.\r
26 python "%~dp0\scons.py" %*\r
27 \r
28 :end\r