diff --git a/acinclude.m4 b/acinclude.m4
index a40a55b..41d0c57 100644
--- a/acinclude.m4
+++ b/acinclude.m4
@@ -682,14 +682,14 @@ AC_DEFUN([SETUP_WXWIDGETS],
 			WX_NEW_CPPFLAGS=`${WX_CONFIG} --cppflags --unicode=yes --debug=yes --version=${WX_VERSION} 2> /dev/null`
 			CPPFLAGS="$CPPFLAGS $WX_NEW_CPPFLAGS -g -O0"
 			
-			pgadmin3_LDADD=`${WX_CONFIG} ${WX_STATIC} --libs std,stc,ogl --unicode=yes --debug=yes --version=${WX_VERSION} 2> /dev/null`
+			pgadmin3_LDADD=`${WX_CONFIG} ${WX_STATIC} --libs std,stc,ogl,aui --unicode=yes --debug=yes --version=${WX_VERSION} 2> /dev/null`
 			pgsTest_LDADD=`${WX_CONFIG} ${WX_STATIC} --libs base,core,xml --unicode=yes --debug=yes --version=${WX_VERSION} 2> /dev/null`
 			pgScript_LDADD=`${WX_CONFIG} ${WX_STATIC} --libs base,core,xml --unicode=yes --debug=yes --version=${WX_VERSION} 2> /dev/null`
 		else
 			WX_NEW_CPPFLAGS=`${WX_CONFIG} --cppflags --unicode=yes --debug=no --version=${WX_VERSION} 2> /dev/null`
 			CPPFLAGS="$CPPFLAGS $WX_NEW_CPPFLAGS -O2 -DEMBED_XRC"
 		
-			pgadmin3_LDADD=`${WX_CONFIG} ${WX_STATIC} --libs std,stc,ogl --unicode=yes --debug=no --version=${WX_VERSION} 2> /dev/null`
+			pgadmin3_LDADD=`${WX_CONFIG} ${WX_STATIC} --libs std,stc,ogl,aui --unicode=yes --debug=no --version=${WX_VERSION} 2> /dev/null`
 			pgsTest_LDADD=`${WX_CONFIG} ${WX_STATIC} --libs base,core,xml --unicode=yes --debug=no --version=${WX_VERSION} 2> /dev/null`
 			pgScript_LDADD=`${WX_CONFIG} ${WX_STATIC} --libs base,core,xml --unicode=yes --debug=no --version=${WX_VERSION} 2> /dev/null`
 		fi
diff --git a/bootstrap b/bootstrap
old mode 100644
new mode 100755
diff --git a/pgadmin/frm/frmQuery.cpp b/pgadmin/frm/frmQuery.cpp
index 7ee0b73..a211856 100644
--- a/pgadmin/frm/frmQuery.cpp
+++ b/pgadmin/frm/frmQuery.cpp
@@ -417,7 +417,7 @@ frmQuery::frmQuery(frmMain *form, const wxString &_title, pgConn *_conn, const w
 	// Add the database selection bar
 	cbConnection = new wxBitmapComboBox(this, CTRLID_CONNECTION, wxEmptyString, wxDefaultPosition, wxSize(-1, -1), wxArrayString(), wxCB_READONLY | wxCB_DROPDOWN);
 	cbConnection->Append(conn->GetName(), CreateBitmap(GetServerColour(conn)), (void *)conn);
-	cbConnection->Append(_("<new connection>"), wxNullBitmap, (void *)0);
+	cbConnection->Append(_("<new connection>"), wxNullBitmap, (void*) NULL);
 
 	//Create SQL editor notebook
 	sqlNotebook = new wxAuiNotebook(this, CTL_NTBKCENTER, wxDefaultPosition, wxDefaultSize, wxAUI_NB_TOP | wxAUI_NB_TAB_SPLIT | wxAUI_NB_TAB_MOVE | wxAUI_NB_SCROLL_BUTTONS | wxAUI_NB_WINDOWLIST_BUTTON);
@@ -994,7 +994,7 @@ void frmQuery::OnChangeConnection(wxCommandEvent &ev)
 			pgConn *newconn = dlg.CreateConn(applicationname, createdNewConn);
 			if (newconn && createdNewConn)
 			{
-				cbConnection->Insert(newconn->GetName(), CreateBitmap(GetServerColour(newconn)), sel, (void *)newconn);
+				cbConnection->Insert(newconn->GetName(), CreateBitmap(GetServerColour(newconn)), sel, (wxClientData*)newconn);
 				cbConnection->SetSelection(sel);
 				OnChangeConnection(ev);
 			}
diff --git a/pgadmin/utils/sysLogger.cpp b/pgadmin/utils/sysLogger.cpp
index bfc07bc..3a26ca5 100644
--- a/pgadmin/utils/sysLogger.cpp
+++ b/pgadmin/utils/sysLogger.cpp
@@ -27,6 +27,8 @@
 wxLogLevel sysLogger::logLevel = LOG_ERRORS;
 wxString sysLogger::logFile = wxT("debug.log");
 
+#if !wxCHECK_VERSION(2, 9, 0)
+
 // IMPLEMENT_LOG_FUNCTION(Sql) from wx../common/log.c
 void wxVLogQuietError(const wxChar *szFormat, va_list argptr)
 {
@@ -128,6 +130,7 @@ void wxLogScriptVerbose(const wxChar *szFormat, ...)
 	va_end(argptr);
 }
 
+#endif
 
 void sysLogger::DoLog(wxLogLevel level, const wxChar *msg, time_t timestamp)
 {