=== modified file 'CMakeLists.txt'
--- CMakeLists.txt	2010-10-12 10:20:28 +0000
+++ CMakeLists.txt	2010-10-13 11:58:32 +0000
@@ -133,6 +143,17 @@
 #find_package(Boost 1.36 QUIET)
 #check_find_package_result(Boost_FOUND "Boost")
 
+######################
+# Find Expat library #
+######################
+find_package(EXPAT QUIET) # REQUIRED ensures that Expat must be found
+include_directories (${EXPAT_INCLUDE_DIR}) # We need Expats's headers, so include them
+check_find_package_result(EXPAT_FOUND "Expat")
+if (EXPAT_FOUND)
+MESSAGE(STATUS ${EXPAT_LIBRARY})
+SET(CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} -lexpat")
+endif(EXPAT_FOUND)
+
 ##########################
 # Find wxWidgets library #
 ##########################
@@ -142,9 +163,17 @@
 
 # On Apple only wxwidgets 2.9 or higher doesn't need to find aui part of base
 if(APPLE)
-    find_package(wxWidgets COMPONENTS gl adv html core net base xml QUIET)
+	if(EXPAT_FOUND)
+		find_package(wxWidgets COMPONENTS gl adv html core net base xml QUIET)
+	else(EXPAT_FOUND)
+		find_package(wxWidgets COMPONENTS gl adv html core net base xml expat QUIET)
+	endif(EXPAT_FOUND)
 else(APPLE)
-    find_package(wxWidgets COMPONENTS gl aui adv html core net base xml QUIET)
+	if(EXPAT_FOUND)
+		find_package(wxWidgets COMPONENTS gl aui adv html core net base xml QUIET)
+	else(EXPAT_FOUND)
+		find_package(wxWidgets COMPONENTS gl aui adv html core net base xml expat QUIET)
+	endif(EXPAT_FOUND)
 endif(APPLE)
 check_find_package_result(wxWidgets_FOUND "wxWidgets")
 
