Bug 1731304 [wpt PR 30802] - Update wpt metadata, a=testonly
[gecko.git] / build / autoconf / mozprog.m4
blob08747b495f70135aba6e8e9177648228f3b11103
1 dnl This Source Code Form is subject to the terms of the Mozilla Public
2 dnl License, v. 2.0. If a copy of the MPL was not distributed with this
3 dnl file, You can obtain one at http://mozilla.org/MPL/2.0/.
5 AC_DEFUN([MOZ_PROG_CHECKMSYS],
6 [AC_REQUIRE([AC_INIT_BINSH])dnl
7 if test `uname -s | grep -c MINGW 2>/dev/null` != "0"; then
8   msyshost=1
9 fi
12 AC_DEFUN([MOZ_PATH_PROG],
13 [ AC_PATH_PROG($1,$2,$3,$4)
14   if test "$msyshost"; then
15     case "[$]$1" in
16     /*)
17       tmp_DIRNAME=`dirname "[$]$1"`
18       tmp_BASENAME=`basename "[$]$1"`
19       tmp_PWD=`cd "$tmp_DIRNAME" && pwd -W`
20       $1="$tmp_PWD/$tmp_BASENAME"
21       if test -e "[$]$1.exe"; then
22         $1="[$]$1.exe"
23       fi
24     esac
25   fi
28 AC_DEFUN([MOZ_PATH_PROGS],
29 [  AC_PATH_PROGS($1,$2,$3,$4)
30   if test "$msyshost"; then
31     case "[$]$1" in
32     /*)
33       tmp_DIRNAME=`dirname "[$]$1"`
34       tmp_BASENAME=`basename "[$]$1"`
35       tmp_PWD=`cd "$tmp_DIRNAME" && pwd -W`
36       $1="$tmp_PWD/$tmp_BASENAME"
37       if test -e "[$]$1.exe"; then
38         $1="[$]$1.exe"
39       fi
40     esac
41   fi