Commit 368eded6 authored by Nick Mathewson's avatar Nick Mathewson 👁
Browse files

r8920@totoro: nickm | 2006-10-07 11:40:06 -0400

 Fix IRIX builds so that IRIX no longer self-detects as win32.  For once, this is not the fault of Windows: Apparently, some helpful person decided that the the MIPSpro C Compiler should give a warning on #error rather than actually failing.  How... "innovative."  (Bug found by pnx; thanks!)


svn:r8635
parent b45c2100
......@@ -76,31 +76,6 @@ AC_PROG_CC
AC_PROG_MAKE_SET
AC_PROG_RANLIB
# If WIN32 is defined and non-zero, we are building for win32
AC_MSG_CHECKING([for win32])
AC_TRY_COMPILE(,
[
#ifdef WIN32
#if WIN32
//all is well
#else
#error
#endif
#else
#error
#endif
],
bwin32=true; AC_MSG_RESULT([yes]),
bwin32=false; AC_MSG_RESULT([no])
)
if test $bwin32 = true; then
AC_DEFINE(MS_WINDOWS,1, [Define to 1 if we are building for a Windows platform.])
fi
# The big search for OpenSSL
# copied from openssh's configure.ac
tryssldir=""
......@@ -141,6 +116,29 @@ AC_ARG_WITH(tor-group,
)
AC_SUBST(TORGROUP)
dnl If WIN32 is defined and non-zero, we are building for win32
AC_MSG_CHECKING([for win32])
AC_TRY_RUN([int main(int c, char **v) {
#ifdef WIN32
#if WIN32
return 0;
#else
return 1;
#endif
#else
return 2;
#endif
}],
bwin32=true; AC_MSG_RESULT([yes]),
bwin32=false; AC_MSG_RESULT([no])
)
if test $bwin32 = true; then
AC_DEFINE(MS_WINDOWS, 1, [Define to 1 if we are building for Windows.])
fi
AC_SEARCH_LIBS(socket, [socket])
AC_SEARCH_LIBS(gethostbyname, [nsl])
AC_SEARCH_LIBS(dlopen, [dl])
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment