diff options
author | Christian Beier <[email protected]> | 2009-10-02 14:44:10 +0200 |
---|---|---|
committer | Johannes Schindelin <[email protected]> | 2009-10-02 16:54:38 +0200 |
commit | a92f7f46a675a3533a0a89b6fe2d509e43a2aa8f (patch) | |
tree | f411e78a3f33d32c1b09e89f7f707be6d4b77c61 /configure.ac | |
parent | 65b68e668284eb4aa18614db21cd8d393e37d0c0 (diff) | |
download | libtdevnc-a92f7f46a675a3533a0a89b6fe2d509e43a2aa8f.tar.gz libtdevnc-a92f7f46a675a3533a0a89b6fe2d509e43a2aa8f.zip |
mingw32 crosscompile fixes.
SOCKET is redefined in winsock2.h so #undef it where winsock2.h
is included. The changes in rfbproto.c circumvent crosscompiler
errors like 'S_IFMT' undeclared ...', the Makefile.am changes
avoid building linux specific stuff for a win32 host target.
Also added configure option to specify sdl-config.
Signed-off-by: Christian Beier <[email protected]>
Signed-off-by: Johannes Schindelin <[email protected]>
Diffstat (limited to 'configure.ac')
-rw-r--r-- | configure.ac | 22 |
1 files changed, 18 insertions, 4 deletions
diff --git a/configure.ac b/configure.ac index 65e258c..2eb1961 100644 --- a/configure.ac +++ b/configure.ac @@ -647,11 +647,23 @@ AM_CONDITIONAL(WITH_TIGHTVNC_FILETRANSFER, test "$with_tightvnc_filetransfer" = AM_CONDITIONAL(HAVE_LIBZ, test ! -z "$HAVE_ZLIB_H") AM_CONDITIONAL(HAVE_LIBJPEG, test ! -z "$HAVE_JPEGLIB_H") + +SDLCONFIG="sdl-config" +AC_ARG_WITH(sdl-config, +[[ --with-sdl-config=FILE + Use the given path to sdl-config when determining + SDL configuration; defaults to "sdl-config"]], +[ + if test "$withval" != "yes" -a "$withval" != ""; then + SDLCONFIG=$withval + fi +]) + if test -z "$with_sdl"; then - if sdl-config --version >/dev/null 2>&1; then + if $SDLCONFIG --version >/dev/null 2>&1; then with_sdl=yes - SDL_CFLAGS=`sdl-config --cflags` - SDL_LIBS=`sdl-config --libs` + SDL_CFLAGS=`$SDLCONFIG --cflags` + SDL_LIBS=`$SDLCONFIG --libs` else with_sdl=no fi @@ -660,7 +672,9 @@ AM_CONDITIONAL(HAVE_LIBSDL, test "x$with_sdl" = "xyes") AC_SUBST(SDL_CFLAGS) AC_SUBST(SDL_LIBS) -MINGW=`uname -s | grep MINGW 2>/dev/null` + +AC_CANONICAL_HOST +MINGW=`echo $host_os | grep mingw32 2>/dev/null` AM_CONDITIONAL(MINGW, test ! -z "$MINGW" ) if test ! -z "$MINGW"; then WSOCKLIB="-lws2_32" |