From d8cc375543fea8adfe304e9a569491b740edc4c9 Mon Sep 17 00:00:00 2001 From: ponce Date: Tue, 24 Jul 2012 21:05:04 +0200 Subject: system/gsmartcontrol: Updated for version 0.8.6. Also adds a fix for gcc-4.7.x and a patch for glib >= 2.31. Signed-off-by: Robby Workman --- system/gsmartcontrol/04_glib2.31.patch | 42 +++++++++++++++++++++++++++ system/gsmartcontrol/README | 2 -- system/gsmartcontrol/gsmartcontrol.SlackBuild | 8 ++++- system/gsmartcontrol/gsmartcontrol.info | 6 ++-- 4 files changed, 52 insertions(+), 6 deletions(-) create mode 100644 system/gsmartcontrol/04_glib2.31.patch (limited to 'system') diff --git a/system/gsmartcontrol/04_glib2.31.patch b/system/gsmartcontrol/04_glib2.31.patch new file mode 100644 index 0000000000000..9f5073c1927a4 --- /dev/null +++ b/system/gsmartcontrol/04_glib2.31.patch @@ -0,0 +1,42 @@ +Description: Fixed compilation under Glib 2.31.x. +Origin: Upstream, http://svn.berlios.de/viewvc/gsmartcontrol/trunk/gsmartcontrol/src/hz/sync_policy_glib.h?r1=27&r2=72&view=patch +Author: Alexander Shaduri +Bug-Ubuntu: https://bugs.launchpad.net/bugs/935155 +Bug-Debian: http://bugs.debian.org/665677 + +--- gsmartcontrol/src/hz/sync_policy_glib.h 2011/03/06 10:43:38 27 ++++ gsmartcontrol/src/hz/sync_policy_glib.h 2011/11/02 16:00:39 72 +@@ -17,30 +17,14 @@ + // Glib-based policy. + + +-// Note: g_static_mutex_*lock() functions may give warnings about breaking strict-aliasing rules. +-// The warnings are completely harmless and visible on some versions of glib only. +-// However, due to their number, I decided to implement this workaround. +- +-#ifndef _WIN32 +- // same as stock version, but an additional cast to (void*) is added. +- #define hz_glib_static_mutex_get_mutex(mutex) \ +- ( g_thread_use_default_impl ? ((GMutex*) ((void*)((mutex)->static_mutex.pad))) : \ +- g_static_mutex_get_mutex_impl_shortcut(&((mutex)->runtime_mutex)) ) +- +-#else +- // win32 has different definition of this macro, so default to stock version. +- #define hz_glib_static_mutex_get_mutex(mutex) g_static_mutex_get_mutex(mutex) +-#endif +- +- + #define hz_glib_static_mutex_lock(mutex) \ +- g_mutex_lock(hz_glib_static_mutex_get_mutex(mutex)) ++ g_mutex_lock(g_static_mutex_get_mutex(mutex)) + + #define hz_glib_static_mutex_trylock(mutex) \ +- g_mutex_trylock(hz_glib_static_mutex_get_mutex(mutex)) ++ g_mutex_trylock(g_static_mutex_get_mutex(mutex)) + + #define hz_glib_static_mutex_unlock(mutex) \ +- g_mutex_unlock(hz_glib_static_mutex_get_mutex(mutex)) ++ g_mutex_unlock(g_static_mutex_get_mutex(mutex)) + + + diff --git a/system/gsmartcontrol/README b/system/gsmartcontrol/README index 1013d5aba38fc..a401718d3a39c 100644 --- a/system/gsmartcontrol/README +++ b/system/gsmartcontrol/README @@ -4,5 +4,3 @@ controlling SMART (Self-Monitoring, Analysis, and Reporting Technology) data on modern hard disk drives. It allows you to inspect the drive's SMART data to determine its health, as well as run various tests on it. - -Requires gtkmm, available at SlackBuilds.org diff --git a/system/gsmartcontrol/gsmartcontrol.SlackBuild b/system/gsmartcontrol/gsmartcontrol.SlackBuild index d2281a368b0c1..eb26c43f5af1e 100644 --- a/system/gsmartcontrol/gsmartcontrol.SlackBuild +++ b/system/gsmartcontrol/gsmartcontrol.SlackBuild @@ -23,7 +23,7 @@ # ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. PRGNAM=gsmartcontrol -VERSION=0.8.5 +VERSION=0.8.6 BUILD=${BUILD:-1} TAG=${TAG:-_SBo} @@ -61,6 +61,12 @@ cd $PRGNAM-$VERSION chown -R root:root . chmod -R u+w,go+r-w,a-s . +# Fix build with gcc-4.7.x +sed -i "s/\tdestroy/\tthis->destroy/" src/gsc_text_window.h + +# Patch from debian for glib >= 2.31 +patch -p1 < $CWD/04_glib2.31.patch + CFLAGS="$SLKCFLAGS" \ CXXFLAGS="$SLKCFLAGS" \ ./configure \ diff --git a/system/gsmartcontrol/gsmartcontrol.info b/system/gsmartcontrol/gsmartcontrol.info index 8dbb1acd9798f..c970700b8deb3 100644 --- a/system/gsmartcontrol/gsmartcontrol.info +++ b/system/gsmartcontrol/gsmartcontrol.info @@ -1,8 +1,8 @@ PRGNAM="gsmartcontrol" -VERSION="0.8.5" +VERSION="0.8.6" HOMEPAGE="http://gsmartcontrol.berlios.de/home/index.php/en/Home" -DOWNLOAD="http://download.berlios.de/gsmartcontrol/gsmartcontrol-0.8.5.tar.bz2" -MD5SUM="654ee0b77665206d4d8a46080c5747b6" +DOWNLOAD="http://download.berlios.de/gsmartcontrol/gsmartcontrol-0.8.6.tar.bz2" +MD5SUM="d2ac685e2e73b05f7ba74c93623af739" DOWNLOAD_x86_64="" MD5SUM_x86_64="" REQUIRES="gtkmm" -- cgit v1.2.3