Index: orxonox/trunk/configure.ac
===================================================================
--- orxonox/trunk/configure.ac	(revision 4672)
+++ orxonox/trunk/configure.ac	(revision 4697)
@@ -221,7 +221,44 @@
     MWINDOWS="-mwindows"
 
-# checking gl header
-        #done before loop
-
+
+
+# checking for mingw32
+    AC_CHECK_LIB([mingw32], [main], FOUND_mingw32=yes)
+    if test x$FOUND_mingw32 = xyes; then
+        LIBS="$LIBS -lmingw32"
+    fi
+
+#-----------#
+# SDL (win) #
+#-----------#
+# checking for SDL-headers
+    AC_CHECK_HEADERS([SDL/SDL.h] ,,
+      [AC_MSG_ERROR([cannot find SDL headers]) ])
+
+#checking for libSDL
+    AC_CHECK_LIB([sdlmain], [main], FOUND_sdlmain=yes)
+    if test x$FOUND_sdlmain = xyes ; then
+       LIBS="$LIBS -lsdlmain"
+    else
+        echo "------------------"
+        echo "SDL library not found."
+        echo "please install the SDL library, which can be found at http://www.libsdl.org"
+        echo "------------------"
+        exit 1
+    fi
+    AC_CHECK_LIB([sdl], [main], FOUND_sdl=yes)
+    if test x$FOUND_sdl = xyes ; then
+       LIBS="$LIBS -lsdl"
+    else
+        echo "------------------"
+        echo "SDL library not found."
+        echo "please install the SDL library, which can be found at http://www.libsdl.org"
+        echo "------------------"
+        exit -1
+    fi
+
+#---------------#
+# open-GL (win) #
+#---------------#
 # checking gl header
    AC_CHECK_HEADERS(GL/gl.h ,,
@@ -255,35 +292,24 @@
     fi
 
-# checking for mingw32
-    AC_CHECK_LIB([mingw32], [main], FOUND_mingw32=yes)
-    if test x$FOUND_mingw32 = xyes; then
-        LIBS="$LIBS -lmingw32"
-    fi
-# checking for SDL-headers
-    AC_CHECK_HEADERS([SDL/SDL.h] ,,
-      [AC_MSG_ERROR([cannot find SDL headers]) ])
-
-#checking for libSDL
-    AC_CHECK_LIB([sdlmain], [main], FOUND_sdlmain=yes)
-    if test x$FOUND_sdlmain = xyes ; then
-       LIBS="$LIBS -lsdlmain"
-    else
-        echo "------------------"
-        echo "SDL library not found."
-        echo "please install the SDL library, which can be found at http://www.libsdl.org"
-        echo "------------------"
-        exit 1
-    fi
-    AC_CHECK_LIB([sdl], [main], FOUND_sdl=yes)
-    if test x$FOUND_sdl = xyes ; then
-       LIBS="$LIBS -lsdl"
-    else
-        echo "------------------"
-        echo "SDL library not found."
-        echo "please install the SDL library, which can be found at http://www.libsdl.org"
+#--------#
+# openAL #
+#--------#
+# checking for openAL-headers
+  AC_CHECK_HEADERS([AL/al.h] ,,
+      [AC_MSG_ERROR([cannot find openAL header.])])
+# checking for openAL-lib
+  AC_CHECK_LIB([OpenAL32], [main], [FOUND_openal=yes])
+  AC_CHECK_LIB([ALut], [main], [FOUND_ALut=yes])
+     if test x$FOUND_openal = xyes ; then
+      if test x$FOUND_ALut = xyes ; then
+       LIBS="$LIBS -lALut -lOpenAL32"
+     else
+        echo "------------------"
+        echo "openal library not found."
+        echo "please install the openal library, which can be found at http://www.openal.org"
         echo "------------------"
         exit -1
-    fi
-
+      fi
+     fi
     ;;
 #-------#
@@ -327,4 +353,22 @@
          exit -1
     fi
+
+#--------#
+# openAL #
+#--------#
+# checking for openAL-headers
+  AC_CHECK_HEADERS([AL/al.h] ,,
+      [AC_MSG_ERROR([cannot find openAL header.])])
+# checking for openAL-lib
+  AC_CHECK_LIB([openal], [main], [FOUND_openal=yes])
+     if test x$FOUND_openal = xyes ; then
+       LIBS="$LIBS -lopenal"
+     else
+        echo "------------------"
+        echo "openal library not found."
+        echo "please install the openal library, which can be found at http://www.openal.org"
+        echo "------------------"
+        exit -1
+     fi
 
 # checking for SDL
@@ -397,5 +441,5 @@
       [AC_CHECK_HEADERS([SDL/SDL_ttf.h] ,,AC_MSG_ERROR([cannot find SDL_ttf header.])]))
 # checking for SDL_ttf-lib
-  AC_CHECK_LIB([SDL_ttf], [main], [FOUND_SDL_ttf=yes])
+  AC_CHECK_LIB([SDL_ttf], [TTF_OpenFont], [FOUND_SDL_ttf=yes])
      if test x$FOUND_SDL_ttf = xyes ; then
        LIBS="$LIBS -lSDL_ttf"
@@ -427,72 +471,54 @@
    fi
 
-#--------#
-# openAL #
-#--------#
-# checking for openAL-headers
-  AC_CHECK_HEADERS([AL/al.h] ,,
-      [AC_MSG_ERROR([cannot find openAL header.])])
-# checking for openAL-lib
-  AC_CHECK_LIB([openal], [main], [FOUND_openal=yes])
-     if test x$FOUND_openal = xyes ; then
-       LIBS="$LIBS -lopenal"
-     else
-        echo "------------------"
-        echo "openal library not found."
-        echo "please install the openal library, which can be found at http://www.openal.org"
-        echo "------------------"
-        exit -1
-     fi
-
 #-----#
 # ogg #
 #-----#
-# checking for ogg-headers
-  AC_CHECK_HEADERS([ogg/ogg.h] ,,
-      [AC_MSG_ERROR([cannot find ogg header.])])
-# checking for ogg-lib
-  AC_CHECK_LIB([ogg], [main], [FOUND_ogg=yes])
-     if test x$FOUND_ogg = xyes ; then
-       LIBS="$LIBS -logg"
-     else
-        echo "------------------"
-        echo "ogg library not found."
-        echo "please install the ogg library, which can be found at http://www.xiph.org/ogg/vorbis/index.html"
-        echo "------------------"
-        exit -1
-     fi
+## checking for ogg-headers
+#  AC_CHECK_HEADERS([ogg/ogg.h] ,,
+#      [AC_MSG_ERROR([cannot find ogg header.])])
+## checking for ogg-lib
+#  AC_CHECK_LIB([ogg], [main], [FOUND_ogg=yes])
+#     if test x$FOUND_ogg = xyes ; then
+#       LIBS="$LIBS -logg"
+#     else
+#        echo "------------------"
+#        echo "ogg library not found."
+#        echo "please install the ogg library, which can be found at http://www.xiph.org/ogg/vorbis/index.html"
+#        echo "------------------"
+#        exit -1
+#     fi
 
 #--------#
 # vorbis #
 #--------#
-# checking for vorbis-lib
-  AC_CHECK_LIB([vorbis], [main], [FOUND_vorbis=yes])
-     if test x$FOUND_vorbis = xyes ; then
-       LIBS="$LIBS -lvorbis"
-     else
-        echo "------------------"
-        echo "vorbis library not found."
-        echo "please install the vorbis library, which can be found at http://www.xiph.org/ogg/vorbis/index.html"
-        echo "------------------"
-        exit -1
-     fi
+## checking for vorbis-lib
+#  AC_CHECK_LIB([vorbis], [main], [FOUND_vorbis=yes])
+#     if test x$FOUND_vorbis = xyes ; then
+#       LIBS="$LIBS -lvorbis"
+#     else
+#        echo "------------------"
+#        echo "vorbis library not found."
+#        echo "please install the vorbis library, which can be found at http://www.xiph.org/ogg/vorbis/index.html"
+#        echo "------------------"
+#        exit -1
+#     fi
 
 #------------#
 # vorbisfile #
 #------------#
-# checking for vorbis-headers
-  AC_CHECK_HEADERS([vorbis/vorbisfile.h] ,,
-      [AC_MSG_ERROR([cannot find vorbisfile header.])])
-# checking for vorbisfile-lib
-  AC_CHECK_LIB([vorbisfile], [main], [FOUND_vorbisfile=yes])
-     if test x$FOUND_vorbisfile = xyes ; then
-       LIBS="$LIBS -lvorbisfile"
-     else
-        echo "------------------"
-        echo "vorbisfile library not found."
-        echo "please install the vorbisfile library, which can be found at http://www.xiph.org/ogg/vorbis/index.html"
-        echo "------------------"
-        exit -1
-     fi
+## checking for vorbis-headers
+#  AC_CHECK_HEADERS([vorbis/vorbisfile.h] ,,
+#      [AC_MSG_ERROR([cannot find vorbisfile header.])])
+## checking for vorbisfile-lib
+#  AC_CHECK_LIB([vorbisfile], [main], [FOUND_vorbisfile=yes])
+#     if test x$FOUND_vorbisfile = xyes ; then
+#       LIBS="$LIBS -lvorbisfile"
+#     else
+#        echo "------------------"
+#        echo "vorbisfile library not found."
+#        echo "please install the vorbisfile library, which can be found at http://www.xiph.org/ogg/vorbis/index.html"
+#        echo "------------------"
+#        exit -1
+#     fi
 
 #-----#
