Package: pgagent
Version: 3.4.0-1
Severity: normal
Tags: patch
User: [email protected]
Usertags: wx3.0
Dear maintainer,
We're aiming to migrate the archive to using wxwidgets3.0 instead of
wxwidgets2.8.
I've rebuilt you package using the attached patch. I don't have any
postgres databases to hand to test it with, but I've fixed an wx debug
message I was getting on exit with "pgagent -f". It would be good to
have some more thorough testing from someone who actually uses this
package though.
Cheers,
Olly
diff -Nru pgagent-3.4.0/debian/changelog pgagent-3.4.0/debian/changelog
--- pgagent-3.4.0/debian/changelog 2014-03-07 05:45:50.000000000 +1300
+++ pgagent-3.4.0/debian/changelog 2014-05-27 12:12:05.000000000 +1200
@@ -1,3 +1,10 @@
+pgagent (3.4.0-1.1) unstable; urgency=low
+
+ * Non-maintainer upload.
+ * Update to use wxwidgets3.0 (new patch 02_use-wx3.0.patch).
+
+ -- Olly Betts <[email protected]> Tue, 27 May 2014 12:11:57 +1200
+
pgagent (3.4.0-1) unstable; urgency=medium
* New upstream release.
diff -Nru pgagent-3.4.0/debian/control pgagent-3.4.0/debian/control
--- pgagent-3.4.0/debian/control 2014-03-07 05:49:05.000000000 +1300
+++ pgagent-3.4.0/debian/control 2014-03-19 03:15:22.000000000 +1300
@@ -3,7 +3,7 @@
Priority: optional
Maintainer: Gerfried Fuchs <[email protected]>
Uploaders: Christoph Berg <[email protected]>
-Build-Depends: debhelper (>= 9), cmake, libwxgtk2.8-dev, libpq-dev (>= 8.1),
+Build-Depends: debhelper (>= 9), cmake, libwxbase3.0-dev, libpq-dev (>= 8.1),
postgresql-server-dev-all
Standards-Version: 3.9.5
Homepage: http://www.pgadmin.org/
diff -Nru pgagent-3.4.0/debian/patches/03_use-wx3.0.patch pgagent-3.4.0/debian/patches/03_use-wx3.0.patch
--- pgagent-3.4.0/debian/patches/03_use-wx3.0.patch 1970-01-01 12:00:00.000000000 +1200
+++ pgagent-3.4.0/debian/patches/03_use-wx3.0.patch 2014-05-27 12:58:21.000000000 +1200
@@ -0,0 +1,99 @@
+--- a/CMakeLists.txt
++++ b/CMakeLists.txt
+@@ -86,9 +86,8 @@
+ ################################################################################
+ # Find wxWidgets
+ ################################################################################
+-SET(WX_DEBUG NO CACHE BOOL "Use the debug build of wxWidgets?")
+ SET(WX_STATIC ${STATIC_BUILD})
+-SET(WX_VERSION "2.8")
++SET(WX_VERSION "3.0")
+ SET(WX_UNICODE YES)
+ SET(WX_MODULES "base")
+
+@@ -184,7 +183,6 @@
+ MESSAGE(STATUS " wxWidgets path : ${WX_ROOT_DIR}")
+ MESSAGE(STATUS " wxWidgets config binary : ${WX_CONFIG_PATH}")
+ MESSAGE(STATUS " wxWidgets Static linking : ${WX_STATIC}")
+-MESSAGE(STATUS " wxWidgets Debug? : ${WX_DEBUG}")
+ MESSAGE(STATUS "================================================================================")
+ MESSAGE(STATUS " ")
+
+--- a/cmake/FindWX.cmake
++++ b/cmake/FindWX.cmake
+@@ -16,8 +16,7 @@
+ # If not set, the default values shown will be used. Booleans must
+ # be either YES or NO:
+ #
+-# WX_VERSION = "2.8"
+-# WX_DEBUG = NO
++# WX_VERSION = "3.0"
+ # WX_STATIC = NO
+ # WX_UNICODE = YES
+ # WX_MODULES = "base" (a list).
+@@ -73,21 +72,11 @@
+ ###############################################################################
+
+ IF(NOT WX_VERSION OR WX_VERSION STREQUAL "")
+- SET(_version "2.8")
++ SET(_version "3.0")
+ ELSE(NOT WX_VERSION OR WX_VERSION STREQUAL "")
+ SET(_version ${WX_VERSION})
+ ENDIF(NOT WX_VERSION OR WX_VERSION STREQUAL "")
+
+-IF(NOT WX_DEBUG OR WX_DEBUG STREQUAL "")
+- SET(_debug "no")
+-ELSE(NOT WX_DEBUG OR WX_DEBUG STREQUAL "")
+- IF(WX_DEBUG)
+- SET(_debug "yes")
+- ELSE(WX_DEBUG)
+- SET(_debug "no")
+- ENDIF(WX_DEBUG)
+-ENDIF(NOT WX_DEBUG OR WX_DEBUG STREQUAL "")
+-
+ IF(NOT WX_STATIC OR WX_STATIC STREQUAL "")
+ SET(_static "no")
+ ELSE(NOT WX_STATIC OR WX_STATIC STREQUAL "")
+@@ -114,7 +103,7 @@
+ SET(_modules ${WX_MODULES})
+ ENDIF(NOT WX_MODULES OR WX_MODULES STREQUAL "")
+
+-SET(_build_desc "version: ${_version}, debug: ${_debug}, static: ${_static}, unicode: ${_unicode}, modules: ${_modules}")
++SET(_build_desc "version: ${_version}, static: ${_static}, unicode: ${_unicode}, modules: ${_modules}")
+
+ ###############################################################################
+ # Here we go...
+@@ -249,7 +238,7 @@
+ ELSE(WIN32 AND NOT CYGWIN AND NOT MSYS)
+
+ # Set up the wx-config command line
+- SET(_args "--version=${_version} --debug=${_debug} --static=${_static} --unicode=${_unicode} ${_modules}")
++ SET(_args "--version=${_version} --static=${_static} --unicode=${_unicode} ${_modules}")
+
+ IF(NOT $ENV{WXWIN} STREQUAL "")
+ FIND_PROGRAM(WX_CONFIG_PATH wx-config
+--- a/pgAgent.cpp
++++ b/pgAgent.cpp
+@@ -155,11 +155,22 @@
+ return 0;
+ }
+
++extern "C" {
++static void ignore_debug_log_messages()
++{
++ wxLog::SetLogLevel(wxLOG_Info);
++}
++}
+
+ void MainLoop()
+ {
+ int attemptCount = 1;
+
++ // Needed to set wx logging to ignore debug level log messages before
++ // we exit to avoid this message from wx3.0:
++ // 09:42:09: Debug: In file ../src/unix/threadpsx.cpp at line 261: 'pthread_mutex_destroy()' failed with error 0x00000010 (Device or resource busy).
++ atexit(ignore_debug_log_messages);
++
+ // OK, let's get down to business
+ do
+ {
diff -Nru pgagent-3.4.0/debian/patches/series pgagent-3.4.0/debian/patches/series
--- pgagent-3.4.0/debian/patches/series 2014-03-07 05:43:53.000000000 +1300
+++ pgagent-3.4.0/debian/patches/series 2014-03-19 03:02:58.000000000 +1300
@@ -1,2 +1,3 @@
01_fix-CMakeLists.txt
02_autopkgtest
+03_use-wx3.0.patch