1 |
dnl ***** BEGIN LICENSE BLOCK ***** |
2 |
dnl Version: MPL 1.1/GPL 2.0/LGPL 2.1 |
3 |
dnl |
4 |
dnl The contents of this file are subject to the Mozilla Public License Version |
5 |
dnl 1.1 (the "License"); you may not use this file except in compliance with |
6 |
dnl the License. You may obtain a copy of the License at |
7 |
dnl http://www.mozilla.org/MPL/ |
8 |
dnl |
9 |
dnl Software distributed under the License is distributed on an "AS IS" basis, |
10 |
dnl WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License |
11 |
dnl for the specific language governing rights and limitations under the |
12 |
dnl License. |
13 |
dnl |
14 |
dnl The Original Code is mozilla.org code. |
15 |
dnl |
16 |
dnl The Initial Developer of the Original Code is the |
17 |
dnl Mozilla Foundation <http://www.mozilla.org> |
18 |
dnl |
19 |
dnl Portions created by the Initial Developer are Copyright (C) 2009 |
20 |
dnl the Initial Developer. All Rights Reserved. |
21 |
dnl |
22 |
dnl Contributor(s): |
23 |
dnl Benjamin Smedberg |
24 |
dnl |
25 |
dnl Alternatively, the contents of this file may be used under the terms of |
26 |
dnl either of the GNU General Public License Version 2 or later (the "GPL"), |
27 |
dnl or the GNU Lesser General Public License Version 2.1 or later (the "LGPL"), |
28 |
dnl in which case the provisions of the GPL or the LGPL are applicable instead |
29 |
dnl of those above. If you wish to allow use of your version of this file only |
30 |
dnl under the terms of either the GPL or the LGPL, and not to allow others to |
31 |
dnl use your version of this file under the terms of the MPL, indicate your |
32 |
dnl decision by deleting the provisions above and replace them with the notice |
33 |
dnl and other provisions required by the GPL or the LGPL. If you do not delete |
34 |
dnl the provisions above, a recipient may use your version of this file under |
35 |
dnl the terms of any one of the MPL, the GPL or the LGPL. |
36 |
dnl |
37 |
dnl ***** END LICENSE BLOCK ***** |
38 |
|
39 |
AC_DEFUN(MOZ_PROG_CHECKMSYS, |
40 |
[AC_REQUIRE([AC_INIT_BINSH])dnl |
41 |
if test `uname -s | grep -c MINGW 2>/dev/null` != "0"; then |
42 |
msyshost=1 |
43 |
fi |
44 |
]) |
45 |
|
46 |
AC_DEFUN(MOZ_PATH_PROG, |
47 |
[ AC_PATH_PROG($1,$2,$3,$4) |
48 |
if test "$msyshost"; then |
49 |
case "[$]$1" in |
50 |
/*) |
51 |
tmp_DIRNAME=`dirname "[$]$1"` |
52 |
tmp_BASENAME=`basename "[$]$1"` |
53 |
tmp_PWD=`cd "$tmp_DIRNAME" && pwd -W` |
54 |
$1="$tmp_PWD/$tmp_BASENAME" |
55 |
if test -e "[$]$1.exe"; then |
56 |
$1="[$]$1.exe" |
57 |
fi |
58 |
esac |
59 |
fi |
60 |
]) |
61 |
|
62 |
AC_DEFUN(MOZ_PATH_PROGS, |
63 |
[ AC_PATH_PROGS($1,$2,$3,$4) |
64 |
if test "$msyshost"; then |
65 |
case "[$]$1" in |
66 |
/*) |
67 |
tmp_DIRNAME=`dirname "[$]$1"` |
68 |
tmp_BASENAME=`basename "[$]$1"` |
69 |
tmp_PWD=`cd "$tmp_DIRNAME" && pwd -W` |
70 |
$1="$tmp_PWD/$tmp_BASENAME" |
71 |
if test -e "[$]$1.exe"; then |
72 |
$1="[$]$1.exe" |
73 |
fi |
74 |
esac |
75 |
fi |
76 |
]) |