added missing {
[swftools.git] / m4 / mingw.m4
1 AC_DEFUN(RFX_CHECK_MING,
2 [
3 AC_CANONICAL_HOST
4 AC_EXEEXT
5
6 AC_MSG_CHECKING([for target system])
7 CYGWIN=
8 MINGW=
9 case $host_os in
10     *cygwin* ) CYGWIN=yes;;
11     *mingw* ) MINGW=yes;;
12 esac
13
14 AR=ar
15 if test "x$MINGW" = "xyes"; then
16     #fix for the debian distribution of mingw
17     if test -x "/usr/i586-mingw32msvc/bin/ar";then
18         AR="/usr/i586-mingw32msvc/bin/ar"
19     fi
20     if test -x "/usr/i586-mingw32msvc/bin/ranlib";then
21         RANLIB="/usr/i586-mingw32msvc/bin/ranlib"
22     fi
23     #fix for the gentoo distribution of mingw
24     if test -x "/opt/xmingw/bin/i386-mingw32msvc-ar";then
25         AR="/opt/xmingw/bin/i386-mingw32msvc-ar"
26     fi
27     if test -x "/opt/xmingw/bin/i386-mingw32msvc-ranlib";then
28         RANLIB="/opt/xmingw/bin/i386-mingw32msvc-ranlib"
29     fi
30     if test -x "/opt/xmingw/bin/i386-mingw32msvc-strip";then
31         STRIP="/opt/xmingw/bin/i386-mingw32msvc-strip"
32     fi
33 fi
34 AC_SUBST(AR)
35
36 dnl Checks for system services
37
38 if test "x${CYGWIN}" = "xyes"; then
39     AC_DEFINE_UNQUOTED(CYGWIN, 1)
40     AC_MSG_RESULT(cygwin)
41 else
42     if test "x${MINGW}" = "xyes"; then
43         AC_DEFINE_UNQUOTED(MINGW, 1)
44         WIN32=1
45         AC_DEFINE_UNQUOTED(WIN32, 1)
46         LIBS="$LIBS -lws2_32 -lgdi32"
47         AC_MSG_RESULT(mingw)
48     else
49         LINUX=1
50         export LINUX
51         AC_DEFINE_UNQUOTED(LINUX, 1)
52         AC_MSG_RESULT()
53     fi
54 fi
55 ])