wok-current rev 8884

Fix xfmedia using patches to make it support exo 0.6
author Antoine Bodin <gokhlayeh@slitaz.org>
date Sun Feb 27 04:58:52 2011 +0100 (2011-02-27)
parents fea0477a2ec7
children 93cc0370fce7
files xfmedia/receipt xfmedia/stuff/xfmedia-dbus-0.6-support.patch xfmedia/stuff/xfmedia-empty-prev-next-fix.patch xfmedia/stuff/xfmedia-exo-0.6.patch
line diff
     1.1 --- a/xfmedia/receipt	Sun Feb 27 03:53:25 2011 +0100
     1.2 +++ b/xfmedia/receipt	Sun Feb 27 04:58:52 2011 +0100
     1.3 @@ -6,8 +6,7 @@
     1.4  SHORT_DESC="Xfce Media Player"
     1.5  MAINTAINER="erjo@slitaz.org"
     1.6  DEPENDS="libxfcegui4 libexo xine-lib xorg-libXss xorg-libXtst taglib"
     1.7 -BUILD_DEPENDS="libxfcegui4-dev libexo-dev xine-lib-dev xorg-libXss-dev \
     1.8 -xorg-scrnsaverproto xcb-util-dev util-linux-ng-uuid-dev"
     1.9 +BUILD_DEPENDS="exo util-linux-ng-uuid intltool"
    1.10  TARBALL="$PACKAGE-$VERSION.tar.bz2"
    1.11  WEB_SITE="http://spuriousinterrupt.org/projects/xfmedia"
    1.12  WGET_URL="http://spuriousinterrupt.org/files/xfmedia/xfmedia-0.9.2.tar.bz2"
    1.13 @@ -16,6 +15,9 @@
    1.14  compile_rules()
    1.15  {
    1.16  	cd $src
    1.17 +	patch -Np1 -i $stuff/xfmedia-dbus-0.6-support.patch
    1.18 +	patch -Np1 -i $stuff/xfmedia-empty-prev-next-fix.patch
    1.19 +	patch -Np1 -i $stuff/xfmedia-exo-0.6.patch
    1.20  	./configure \
    1.21  		--prefix=/usr \
    1.22  		--sysconfdir=/etc \
    1.23 @@ -23,7 +25,7 @@
    1.24  		--disable-startup-notification \
    1.25  		$CONFIGURE_ARGS || return 1
    1.26  	sed -i 's/define HAVE_XSCREENSAVER_EXTENSION .*/undef HAVE_XSCREENSAVER_EXTENSION/' config.h
    1.27 -	make && make DESTDIR=$PWD/_pkg install
    1.28 +	make && make install
    1.29  }
    1.30  
    1.31  # Rules to gen a SliTaz package suitable for Tazpkg.
     2.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     2.2 +++ b/xfmedia/stuff/xfmedia-dbus-0.6-support.patch	Sun Feb 27 04:58:52 2011 +0100
     2.3 @@ -0,0 +1,14 @@
     2.4 +diff -Naur xfmedia-0.9.1.orig/src/remote.c xfmedia-0.9.1/src/remote.c
     2.5 +--- xfmedia-0.9.1.orig/src/remote.c	2005-09-05 00:56:37.000000000 -0400
     2.6 ++++ xfmedia-0.9.1/src/remote.c	2006-04-08 00:27:18.000000000 -0400
     2.7 +@@ -55,6 +55,10 @@
     2.8 + #define DBUS_REQUEST_NAME_REPLY_PRIMARY_OWNER DBUS_SERVICE_REPLY_PRIMARY_OWNER
     2.9 + #endif
    2.10 + 
    2.11 ++#ifndef DBUS_NAME_FLAG_PROHIBIT_REPLACEMENT
    2.12 ++#define DBUS_NAME_FLAG_PROHIBIT_REPLACEMENT DBUS_NAME_FLAG_DO_NOT_QUEUE
    2.13 ++#endif
    2.14 ++
    2.15 + #endif  /* HAVE_DBUS */
    2.16 + 
    2.17 + #include <libxfce4util/libxfce4util.h>
     3.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     3.2 +++ b/xfmedia/stuff/xfmedia-empty-prev-next-fix.patch	Sun Feb 27 04:58:52 2011 +0100
     3.3 @@ -0,0 +1,25 @@
     3.4 +diff -wbBur xfmedia-0.9.2/src/mainwin.c xfmedia-0.9.2.my/src/mainwin.c
     3.5 +--- xfmedia-0.9.2/src/mainwin.c	2006-11-27 07:21:23.000000000 +0000
     3.6 ++++ xfmedia-0.9.2.my/src/mainwin.c	2010-11-01 13:01:17.000000000 +0000
     3.7 +@@ -1865,6 +1865,10 @@
     3.8 +     gboolean use_playlist_q  = xfmedia_playlist_queue_n_entries(mwin->playlist_q);
     3.9 +     gboolean ret = FALSE;
    3.10 +     
    3.11 ++    if(xfmedia_playlist_get_n_entries(mwin->plist) == 0)
    3.12 ++//    if(xfmedia_playlist_queue_is_empty(mwin->plist))
    3.13 ++	return;
    3.14 ++
    3.15 +     if(mwin->cur_playing
    3.16 +        && xfmedia_settings_get_bool("/xfmedia/playlist/shuffle")
    3.17 +        && !use_playlist_q )
    3.18 +@@ -1899,6 +1903,10 @@
    3.19 + {
    3.20 +     gint tot_items, idx = -1;
    3.21 +     
    3.22 ++    if(xfmedia_playlist_get_n_entries(mwin->plist) == 0)
    3.23 ++//    if(xfmedia_playlist_queue_is_empty(mwin->plist))
    3.24 ++	return;
    3.25 ++
    3.26 +     if(xfmedia_settings_get_bool("/xfmedia/playlist/shuffle")) {
    3.27 +         XfmediaPlaylistEntryRef *ref = NULL;
    3.28 +         gboolean playing = FALSE;
     4.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     4.2 +++ b/xfmedia/stuff/xfmedia-exo-0.6.patch	Sun Feb 27 04:58:52 2011 +0100
     4.3 @@ -0,0 +1,196 @@
     4.4 +diff -wbBur xfmedia-0.9.2/configure xfmedia-0.9.2.my/configure
     4.5 +--- xfmedia-0.9.2/configure	2006-11-27 20:20:59.000000000 +0000
     4.6 ++++ xfmedia-0.9.2.my/configure	2011-01-31 17:15:58.000000000 +0000
     4.7 +@@ -27417,7 +27417,7 @@
     4.8 + 
     4.9 + 
    4.10 +   if test x"$xdt_cv_EXO_check" = x"yes"; then
    4.11 +-    if $PKG_CONFIG --exists "exo-0.3 >= 0.3.0" >/dev/null 2>&1; then
    4.12 ++    if $PKG_CONFIG --exists "exo-1 >= 0.3.0" >/dev/null 2>&1; then
    4.13 + 
    4.14 + 
    4.15 +   # minimum supported version of pkg-config
    4.16 +@@ -27501,22 +27501,22 @@
    4.17 +   fi
    4.18 + 
    4.19 + 
    4.20 +-  { echo "$as_me:$LINENO: checking for exo-0.3 >= 0.3.0" >&5
    4.21 +-echo $ECHO_N "checking for exo-0.3 >= 0.3.0... $ECHO_C" >&6; }
    4.22 +-  if $PKG_CONFIG "--atleast-version=0.3.0" "exo-0.3" >/dev/null 2>&1; then
    4.23 +-    EXO_VERSION=`$PKG_CONFIG --modversion "exo-0.3"`
    4.24 ++  { echo "$as_me:$LINENO: checking for exo-1 >= 0.3.0" >&5
    4.25 ++echo $ECHO_N "checking for exo-1 >= 0.3.0... $ECHO_C" >&6; }
    4.26 ++  if $PKG_CONFIG "--atleast-version=0.3.0" "exo-1" >/dev/null 2>&1; then
    4.27 ++    EXO_VERSION=`$PKG_CONFIG --modversion "exo-1"`
    4.28 +     { echo "$as_me:$LINENO: result: $EXO_VERSION" >&5
    4.29 + echo "${ECHO_T}$EXO_VERSION" >&6; }
    4.30 + 
    4.31 +     { echo "$as_me:$LINENO: checking EXO_CFLAGS" >&5
    4.32 + echo $ECHO_N "checking EXO_CFLAGS... $ECHO_C" >&6; }
    4.33 +-    EXO_CFLAGS=`$PKG_CONFIG --cflags "exo-0.3"`
    4.34 ++    EXO_CFLAGS=`$PKG_CONFIG --cflags "exo-1"`
    4.35 +     { echo "$as_me:$LINENO: result: $EXO_CFLAGS" >&5
    4.36 + echo "${ECHO_T}$EXO_CFLAGS" >&6; }
    4.37 + 
    4.38 +     { echo "$as_me:$LINENO: checking EXO_LIBS" >&5
    4.39 + echo $ECHO_N "checking EXO_LIBS... $ECHO_C" >&6; }
    4.40 +-    EXO_LIBS=`$PKG_CONFIG --libs "exo-0.3"`
    4.41 ++    EXO_LIBS=`$PKG_CONFIG --libs "exo-1"`
    4.42 +     { echo "$as_me:$LINENO: result: $EXO_LIBS" >&5
    4.43 + echo "${ECHO_T}$EXO_LIBS" >&6; }
    4.44 + 
    4.45 +@@ -27535,15 +27535,15 @@
    4.46 + 
    4.47 +         EXO_FOUND="yes"
    4.48 + 
    4.49 +-  elif $PKG_CONFIG --exists "exo-0.3" >/dev/null 2>&1; then
    4.50 +-    xdt_cv_version=`$PKG_CONFIG --modversion "exo-0.3"`
    4.51 ++  elif $PKG_CONFIG --exists "exo-1" >/dev/null 2>&1; then
    4.52 ++    xdt_cv_version=`$PKG_CONFIG --modversion "exo-1"`
    4.53 +     { echo "$as_me:$LINENO: result: found, but $xdt_cv_version" >&5
    4.54 + echo "${ECHO_T}found, but $xdt_cv_version" >&6; }
    4.55 + 
    4.56 + 
    4.57 +-      echo "*** The required package exo-0.3 was found on your system,"
    4.58 ++      echo "*** The required package exo-1 was found on your system,"
    4.59 +       echo "*** but the installed version ($xdt_cv_version) is too old."
    4.60 +-      echo "*** Please upgrade exo-0.3 to atleast version 0.3.0, or adjust"
    4.61 ++      echo "*** Please upgrade exo-1 to atleast version 0.3.0, or adjust"
    4.62 +       echo "*** the PKG_CONFIG_PATH environment variable if you installed"
    4.63 +       echo "*** the new version of the package in a nonstandard prefix so"
    4.64 +       echo "*** pkg-config is able to find it."
    4.65 +@@ -27554,8 +27554,8 @@
    4.66 + echo "${ECHO_T}not found" >&6; }
    4.67 + 
    4.68 + 
    4.69 +-      echo "*** The required package exo-0.3 was not found on your system."
    4.70 +-      echo "*** Please install exo-0.3 (atleast version 0.3.0) or adjust"
    4.71 ++      echo "*** The required package exo-1 was not found on your system."
    4.72 ++      echo "*** Please install exo-1 (atleast version 0.3.0) or adjust"
    4.73 +       echo "*** the PKG_CONFIG_PATH environment variable if you"
    4.74 +       echo "*** installed the package in a nonstandard prefix so that"
    4.75 +       echo "*** pkg-config is able to find it."
    4.76 +@@ -27564,14 +27564,14 @@
    4.77 +   fi
    4.78 + 
    4.79 +     else
    4.80 +-      { echo "$as_me:$LINENO: checking for optional package exo-0.3 >= 0.3.0" >&5
    4.81 +-echo $ECHO_N "checking for optional package exo-0.3 >= 0.3.0... $ECHO_C" >&6; }
    4.82 ++      { echo "$as_me:$LINENO: checking for optional package exo-1 >= 0.3.0" >&5
    4.83 ++echo $ECHO_N "checking for optional package exo-1 >= 0.3.0... $ECHO_C" >&6; }
    4.84 +       { echo "$as_me:$LINENO: result: not found" >&5
    4.85 + echo "${ECHO_T}not found" >&6; }
    4.86 +     fi
    4.87 +   else
    4.88 +-    { echo "$as_me:$LINENO: checking for optional package exo-0.3" >&5
    4.89 +-echo $ECHO_N "checking for optional package exo-0.3... $ECHO_C" >&6; }
    4.90 ++    { echo "$as_me:$LINENO: checking for optional package exo-1" >&5
    4.91 ++echo $ECHO_N "checking for optional package exo-1... $ECHO_C" >&6; }
    4.92 +     { echo "$as_me:$LINENO: result: disabled" >&5
    4.93 + echo "${ECHO_T}disabled" >&6; }
    4.94 +   fi
    4.95 +diff -wbBur xfmedia-0.9.2/src/main.c xfmedia-0.9.2.my/src/main.c
    4.96 +--- xfmedia-0.9.2/src/main.c	2006-11-27 07:21:23.000000000 +0000
    4.97 ++++ xfmedia-0.9.2.my/src/main.c	2011-02-01 11:08:02.000000000 +0000
    4.98 +@@ -388,6 +388,23 @@
    4.99 +     return optind;
   4.100 + }
   4.101 + 
   4.102 ++/**
   4.103 ++ * exo_str_get_md5_str:
   4.104 ++ * @contents : The string to create a digest of.
   4.105 ++ *
   4.106 ++ * Creates a character array MD5 digestof the string
   4.107 ++ * @contents.
   4.108 ++ *
   4.109 ++ * Return value: A newly-allocated character array which
   4.110 ++ *               should be free with g_free() when no
   4.111 ++ *               longer needed.
   4.112 ++ **/
   4.113 ++gchar*
   4.114 ++exo_str_get_md5_str (const gchar *contents)
   4.115 ++{
   4.116 ++  return g_compute_checksum_for_string (G_CHECKSUM_MD5, contents, -1);
   4.117 ++}
   4.118 ++
   4.119 + int
   4.120 + main(int argc, char **argv)
   4.121 + {
   4.122 +diff -wbBur xfmedia-0.9.2/src/mediamarks.c xfmedia-0.9.2.my/src/mediamarks.c
   4.123 +--- xfmedia-0.9.2/src/mediamarks.c	2006-11-27 07:21:23.000000000 +0000
   4.124 ++++ xfmedia-0.9.2.my/src/mediamarks.c	2011-02-01 11:04:42.000000000 +0000
   4.125 +@@ -684,9 +684,9 @@
   4.126 +     
   4.127 +     render = exo_cell_renderer_ellipsized_text_new();
   4.128 +     if(gtk_major_version == 2 && gtk_minor_version >= 6)
   4.129 +-		g_object_set(G_OBJECT(render), "ellipsize", EXO_PANGO_ELLIPSIZE_END, NULL);
   4.130 ++		g_object_set(G_OBJECT(render), "ellipsize", PANGO_ELLIPSIZE_END, NULL);
   4.131 + 	else {
   4.132 +-		g_object_set(G_OBJECT(render), "ellipsize", EXO_PANGO_ELLIPSIZE_END,
   4.133 ++		g_object_set(G_OBJECT(render), "ellipsize", PANGO_ELLIPSIZE_END,
   4.134 + 				"ellipsize-set", TRUE, NULL);
   4.135 + 	}
   4.136 +     gtk_tree_view_column_pack_start(col, render, TRUE);
   4.137 +@@ -1693,9 +1693,9 @@
   4.138 +     
   4.139 +     render = exo_cell_renderer_ellipsized_text_new();
   4.140 +     if(gtk_major_version == 2 && gtk_minor_version >= 6)
   4.141 +-		g_object_set(G_OBJECT(render), "ellipsize", EXO_PANGO_ELLIPSIZE_END, NULL);
   4.142 ++		g_object_set(G_OBJECT(render), "ellipsize", PANGO_ELLIPSIZE_END, NULL);
   4.143 + 	else {
   4.144 +-		g_object_set(G_OBJECT(render), "ellipsize", EXO_PANGO_ELLIPSIZE_END,
   4.145 ++		g_object_set(G_OBJECT(render), "ellipsize", PANGO_ELLIPSIZE_END,
   4.146 + 				"ellipsize-set", TRUE, NULL);
   4.147 + 	}
   4.148 +     gtk_tree_view_column_pack_start(col, render, TRUE);
   4.149 +@@ -1705,9 +1705,9 @@
   4.150 +     
   4.151 +     render = exo_cell_renderer_ellipsized_text_new();
   4.152 +     if(gtk_major_version == 2 && gtk_minor_version >= 6)
   4.153 +-		g_object_set(G_OBJECT(render), "ellipsize", EXO_PANGO_ELLIPSIZE_END, NULL);
   4.154 ++		g_object_set(G_OBJECT(render), "ellipsize", PANGO_ELLIPSIZE_END, NULL);
   4.155 + 	else {
   4.156 +-		g_object_set(G_OBJECT(render), "ellipsize", EXO_PANGO_ELLIPSIZE_END,
   4.157 ++		g_object_set(G_OBJECT(render), "ellipsize", PANGO_ELLIPSIZE_END,
   4.158 + 				"ellipsize-set", TRUE, NULL);
   4.159 + 	}
   4.160 +     col = gtk_tree_view_column_new_with_attributes(_("Location"), render,
   4.161 +diff -wbBur xfmedia-0.9.2/src/playlist.c xfmedia-0.9.2.my/src/playlist.c
   4.162 +--- xfmedia-0.9.2/src/playlist.c	2006-11-27 07:21:22.000000000 +0000
   4.163 ++++ xfmedia-0.9.2.my/src/playlist.c	2011-02-01 11:04:47.000000000 +0000
   4.164 +@@ -1409,9 +1409,9 @@
   4.165 +     
   4.166 +     render = exo_cell_renderer_ellipsized_text_new();
   4.167 + 	if(gtk_major_version == 2 && gtk_minor_version >= 6)
   4.168 +-		g_object_set(G_OBJECT(render), "ellipsize", EXO_PANGO_ELLIPSIZE_END, NULL);
   4.169 ++		g_object_set(G_OBJECT(render), "ellipsize", PANGO_ELLIPSIZE_END, NULL);
   4.170 + 	else {
   4.171 +-		g_object_set(G_OBJECT(render), "ellipsize", EXO_PANGO_ELLIPSIZE_END,
   4.172 ++		g_object_set(G_OBJECT(render), "ellipsize", PANGO_ELLIPSIZE_END,
   4.173 + 				"ellipsize-set", TRUE, NULL);
   4.174 + 	}
   4.175 +     col = gtk_tree_view_column_new_with_attributes(_("Title"), render, "text",
   4.176 +diff -wbBur xfmedia-0.9.2/src/settings-dialog.c xfmedia-0.9.2.my/src/settings-dialog.c
   4.177 +--- xfmedia-0.9.2/src/settings-dialog.c	2006-11-27 07:21:23.000000000 +0000
   4.178 ++++ xfmedia-0.9.2.my/src/settings-dialog.c	2011-02-01 11:04:53.000000000 +0000
   4.179 +@@ -552,7 +552,7 @@
   4.180 +     render = exo_cell_renderer_ellipsized_text_new();
   4.181 +     col = gtk_tree_view_column_new_with_attributes("name", render,
   4.182 +             "text", PLUGINS_NAME, NULL);
   4.183 +-    g_object_set(G_OBJECT(render), "ellipsize", EXO_PANGO_ELLIPSIZE_END,
   4.184 ++    g_object_set(G_OBJECT(render), "ellipsize", PANGO_ELLIPSIZE_END,
   4.185 +             "ellipsize-set", TRUE, NULL);
   4.186 +     gtk_tree_view_append_column(GTK_TREE_VIEW(treeview), col);
   4.187 +     
   4.188 +diff -wbBur xfmedia-0.9.2/src/xfmedia-playlist-queue.c xfmedia-0.9.2.my/src/xfmedia-playlist-queue.c
   4.189 +--- xfmedia-0.9.2/src/xfmedia-playlist-queue.c	2006-11-27 07:21:22.000000000 +0000
   4.190 ++++ xfmedia-0.9.2.my/src/xfmedia-playlist-queue.c	2011-02-01 11:04:57.000000000 +0000
   4.191 +@@ -171,7 +171,7 @@
   4.192 +     
   4.193 +     render = exo_cell_renderer_ellipsized_text_new();
   4.194 +     g_object_set(G_OBJECT(render),
   4.195 +-                 "ellipsize", EXO_PANGO_ELLIPSIZE_END,
   4.196 ++                 "ellipsize", PANGO_ELLIPSIZE_END,
   4.197 +                  "ellipsize-set", TRUE,
   4.198 +                  NULL);
   4.199 +     col = gtk_tree_view_column_new_with_attributes("display-name", render,