Index: code/branches/buildsystem2/cmake/CheckOGREPlugins.cmake
===================================================================
--- code/branches/buildsystem2/cmake/CheckOGREPlugins.cmake	(revision 2626)
+++ code/branches/buildsystem2/cmake/CheckOGREPlugins.cmake	(revision 2628)
@@ -49,10 +49,10 @@
       NAMES ${_plugin}
       PATHS $ENV{OGRE_HOME} $ENV{OGRE_PLUGIN_DIR}
-      PATH_SUFFIXES lib lib/OGRE bin bin/Release bin/release Release release
+      PATH_SUFFIXES bin/Release bin/release Release release lib lib/OGRE bin
     )
     FIND_LIBRARY(OGRE_PLUGIN_${_plugin}_DEBUG
-      NAMES ${_plugin}d ${_plugin}_d
+      NAMES ${_plugin}d ${_plugin}_d ${_plugin}
       PATHS $ENV{OGRE_HOME} $ENV{OGRE_PLUGIN_DIR}
-      PATH_SUFFIXES lib lib/OGRE bin bin/Debug bin/debug Debug debug
+      PATH_SUFFIXES bin/Debug bin/debug Debug debug lib lib/OGRE bin
     )
     # We only need at least one render system. Check at the end.
@@ -67,6 +67,7 @@
     IF(OGRE_PLUGIN_${_plugin}_OPTIMIZED)
       # If debug version is not available, release will do as well
-      IF(NOT OGRE_PLUGIN_${_plugin}_DEBUG)
-        SET(OGRE_PLUGIN_${_plugin}_DEBUG ${OGRE_PLUGIN_${_plugin}_OPTIMIZED} CACHE STRING "" FORCE)
+      IF(OGRE_PLUGIN_${_plugin}_DEBUG STREQUAL OGRE_PLUGIN_${_plugin}_OPTIMIZED)
+        # In this case the library finder didn't find real debug versions
+        SET(OGRE_PLUGIN_${_plugin}_DEBUG "OGRE_PLUGIN_${_plugin}_DEBUG-NOTFOUND" CACHE STRING "" FORCE)
       ENDIF()
       MARK_AS_ADVANCED(OGRE_PLUGIN_${_plugin}_OPTIMIZED OGRE_PLUGIN_${_plugin}_DEBUG)
@@ -74,26 +75,26 @@
       ### Set variables to configure orxonox.ini correctly afterwards in bin/ ###
       # Check and set the folders
-      GET_FILENAME_COMPONENT(_release_folder ${OGRE_PLUGIN_${_plugin}_OPTIMIZED} PATH)
-      IF(OGRE_PLUGINS_FOLDER_RELEASE AND NOT OGRE_PLUGINS_FOLDER_RELEASE STREQUAL _release_folder)
+      GET_FILENAME_COMPONENT(_plugins_folder ${OGRE_PLUGIN_${_plugin}_OPTIMIZED} PATH)
+      IF(OGRE_PLUGINS_FOLDER_RELEASE AND NOT OGRE_PLUGINS_FOLDER_RELEASE STREQUAL _plugins_folder)
         MESSAGE(FATAL_ERROR "Ogre release plugins have to be in the same folder!")
       ENDIF()
-      SET(OGRE_PLUGINS_FOLDER_RELEASE ${_release_folder})
-      GET_FILENAME_COMPONENT(_debug_folder ${OGRE_PLUGIN_${_plugin}_DEBUG} PATH)
-      IF(OGRE_PLUGINS_FOLDER_DEBUG AND NOT OGRE_PLUGINS_FOLDER_DEBUG STREQUAL _debug_folder)
+      SET(OGRE_PLUGINS_FOLDER_RELEASE ${_plugins_folder})
+      IF(OGRE_PLUGIN_${_plugin}_DEBUG)
+        GET_FILENAME_COMPONENT(_plugins_folder ${OGRE_PLUGIN_${_plugin}_DEBUG} PATH)
+      ENDIF()
+      IF(OGRE_PLUGINS_FOLDER_DEBUG AND NOT OGRE_PLUGINS_FOLDER_DEBUG STREQUAL _plugins_folder)
         MESSAGE(FATAL_ERROR "Ogre debug plugins have to be in the same folder!")
       ENDIF()
-      SET(OGRE_PLUGINS_FOLDER_DEBUG ${_debug_folder})
+      SET(OGRE_PLUGINS_FOLDER_DEBUG ${_plugins_folder})
 
-      # Create a list with the plugins for relase and debug configurations
+      # Create a list with the plugins for release and debug configurations
       LIST(APPEND OGRE_PLUGINS_RELEASE ${_plugin})
-      IF(OGRE_PLUGIN_${_plugin}_DEBUG)
-        # Determine debug postfix ("d" or "_d")
-        IF(OGRE_PLUGIN_${_plugin}_DEBUG MATCHES "_d\\.|_d$")
-          LIST(APPEND OGRE_PLUGINS_DEBUG "${_plugin}_d")
-        ELSE()
-          LIST(APPEND OGRE_PLUGINS_DEBUG "${_plugin}d")
-        ENDIF()
+      # Determine debug postfix ("d" or "_d" or none)
+      IF(OGRE_PLUGIN_${_plugin}_DEBUG MATCHES "_d\\.|_d$")
+        LIST(APPEND OGRE_PLUGINS_DEBUG "${_plugin}_d")
+      ELSEIF(OGRE_PLUGIN_${_plugin}_DEBUG MATCHES "d\\.|d$")
+        LIST(APPEND OGRE_PLUGINS_DEBUG "${_plugin}d")
       ELSE()
-        LIST(APPEND OGRE_PLUGINS_DEBUG ${_plugin})
+        LIST(APPEND OGRE_PLUGINS_DEBUG "${_plugin}")
       ENDIF()
     ENDIF(OGRE_PLUGIN_${_plugin}_OPTIMIZED)
Index: code/branches/buildsystem2/cmake/FindALUT.cmake
===================================================================
--- code/branches/buildsystem2/cmake/FindALUT.cmake	(revision 2626)
+++ code/branches/buildsystem2/cmake/FindALUT.cmake	(revision 2628)
@@ -67,6 +67,6 @@
 # Handle the REQUIRED argument and set ALUT_FOUND
 FIND_PACKAGE_HANDLE_STANDARD_ARGS(ALUT DEFAULT_MSG
+    ALUT_LIBRARY_OPTIMIZED
     ALUT_INCLUDE_DIR
-    ALUT_LIBRARY_OPTIMIZED
 )
 
Index: code/branches/buildsystem2/cmake/FindCEGUI.cmake
===================================================================
--- code/branches/buildsystem2/cmake/FindCEGUI.cmake	(revision 2626)
+++ code/branches/buildsystem2/cmake/FindCEGUI.cmake	(revision 2628)
@@ -54,6 +54,6 @@
 # Also checks the version requirements if given
 FIND_PACKAGE_HANDLE_ADVANCED_ARGS(CEGUI DEFAULT_MSG "${CEGUI_VERSION}"
+  CEGUI_LIBRARY_OPTIMIZED
   CEGUI_INCLUDE_DIR
-  CEGUI_LIBRARY_OPTIMIZED
 )
 
Index: code/branches/buildsystem2/cmake/FindDirectX.cmake
===================================================================
--- code/branches/buildsystem2/cmake/FindDirectX.cmake	(revision 2626)
+++ code/branches/buildsystem2/cmake/FindDirectX.cmake	(revision 2628)
@@ -40,7 +40,7 @@
 # Handle the REQUIRED argument and set DIRECTX_FOUND
 FIND_PACKAGE_HANDLE_STANDARD_ARGS(DirectX DEFAULT_MSG
-  DIRECTX_INCLUDE_DIR
   DIRECTX_LIBRARY_input
   DIRECTX_LIBRARY_guid
+  DIRECTX_INCLUDE_DIR
 )
 
Index: code/branches/buildsystem2/cmake/FindENet.cmake
===================================================================
--- code/branches/buildsystem2/cmake/FindENet.cmake	(revision 2626)
+++ code/branches/buildsystem2/cmake/FindENet.cmake	(revision 2628)
@@ -53,6 +53,6 @@
 # Also check the the version requirements
 FIND_PACKAGE_HANDLE_ADVANCED_ARGS(ENet DEFAULT_MSG ${ENET_VERSION}
+  ENET_LIBRARY_OPTIMIZED
   ENET_INCLUDE_DIR
-  ENET_LIBRARY_OPTIMIZED
 )
 
Index: code/branches/buildsystem2/cmake/FindLua.cmake
===================================================================
--- code/branches/buildsystem2/cmake/FindLua.cmake	(revision 2626)
+++ code/branches/buildsystem2/cmake/FindLua.cmake	(revision 2628)
@@ -156,6 +156,6 @@
 
 FIND_PACKAGE_HANDLE_ADVANCED_ARGS(Lua DEFAULT_MSG "${LUA_VERSION_LONG}"
+  LUA_LIBRARIES
   LUA_INCLUDE_DIR
-  LUA_LIBRARIES
 )
 
Index: code/branches/buildsystem2/cmake/FindOGRE.cmake
===================================================================
--- code/branches/buildsystem2/cmake/FindOGRE.cmake	(revision 2626)
+++ code/branches/buildsystem2/cmake/FindOGRE.cmake	(revision 2628)
@@ -42,6 +42,6 @@
 # Also check the version requirements
 FIND_PACKAGE_HANDLE_ADVANCED_ARGS(OGRE DEFAULT_MSG ${OGRE_VERSION}
+  OGRE_LIBRARY_OPTIMIZED
   OGRE_INCLUDE_DIR
-  OGRE_LIBRARY_OPTIMIZED
 )
 
Index: code/branches/buildsystem2/cmake/FindOgg.cmake
===================================================================
--- code/branches/buildsystem2/cmake/FindOgg.cmake	(revision 2626)
+++ code/branches/buildsystem2/cmake/FindOgg.cmake	(revision 2628)
@@ -38,6 +38,6 @@
 # Handle the REQUIRED argument and set OGG_FOUND
 FIND_PACKAGE_HANDLE_STANDARD_ARGS(Ogg DEFAULT_MSG
+  OGG_LIBRARY_OPTIMIZED
   OGG_INCLUDE_DIR
-  OGG_LIBRARY_OPTIMIZED
 )
 
Index: code/branches/buildsystem2/cmake/LibraryConfig.cmake
===================================================================
--- code/branches/buildsystem2/cmake/LibraryConfig.cmake	(revision 2626)
+++ code/branches/buildsystem2/cmake/LibraryConfig.cmake	(revision 2628)
@@ -115,9 +115,8 @@
   ENDIF()
 ENDIF()
+# Notfiy user
+FIND_PACKAGE_HANDLE_STANDARD_ARGS(OpenAL DEFAULT_MSG OPENAL_LIBRARY OPENAL_INCLUDE_DIR)
 # Hide variables created by the script
-MARK_AS_ADVANCED(
-  OPENAL_INCLUDE_DIR
-  OPENAL_LIBRARY
-)
+MARK_AS_ADVANCED(OPENAL_INCLUDE_DIR OPENAL_LIBRARY)
 
 ##### TCL #####
@@ -129,8 +128,4 @@
 SET(TCL_FIND_QUIETLY FALSE)
 FIND_PACKAGE_HANDLE_STANDARD_ARGS(TCL DEFAULT_MSG TCL_LIBRARY TCL_INCLUDE_PATH)
-# Workaround a CMake bug that doesn't set the variables to the cache
-# Occurs at least on CMake 2.6.2 and 2.6.0 under Windows
-SET(TCL_LIBRARY ${TCL_LIBRARY} CACHE FILEPATH "")
-SET(TCL_INCLUDE_PATH ${TCL_INCLUDE_PATH} CACHE PATH "")
 
 ##### Boost #####
