summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTomas Chvatal <scarabeus@gentoo.org>2009-02-10 22:09:34 +0000
committerTomas Chvatal <scarabeus@gentoo.org>2009-02-10 22:09:34 +0000
commitfaca60f2a465dcebdbdaae93147499eb96bf16c5 (patch)
tree63a5b103f676b2b20d214aa72cfdad8e73e0e80b /media-sound/amarok
parentcinelerra updated snapshot (diff)
downloadgentoo-2-faca60f2a465dcebdbdaae93147499eb96bf16c5.tar.gz
gentoo-2-faca60f2a465dcebdbdaae93147499eb96bf16c5.tar.bz2
gentoo-2-faca60f2a465dcebdbdaae93147499eb96bf16c5.zip
Fix ipod issue with amarok 2.0. Per bug #255730.
(Portage version: 2.2_rc23/cvs/Linux x86_64)
Diffstat (limited to 'media-sound/amarok')
-rw-r--r--media-sound/amarok/ChangeLog6
-rw-r--r--media-sound/amarok/amarok-2.0.1.1.ebuild6
-rw-r--r--media-sound/amarok/files/2.0.1.1-ipod.patch175
3 files changed, 184 insertions, 3 deletions
diff --git a/media-sound/amarok/ChangeLog b/media-sound/amarok/ChangeLog
index afba39e7c87c..7ceb14d5d55e 100644
--- a/media-sound/amarok/ChangeLog
+++ b/media-sound/amarok/ChangeLog
@@ -1,6 +1,10 @@
# ChangeLog for media-sound/amarok
# Copyright 2000-2009 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/media-sound/amarok/ChangeLog,v 1.301 2009/01/30 15:35:30 carlo Exp $
+# $Header: /var/cvsroot/gentoo-x86/media-sound/amarok/ChangeLog,v 1.302 2009/02/10 22:09:34 scarabeus Exp $
+
+ 10 Feb 2009; Tomas Chvatal <scarabeus@gentoo.org>
+ +files/2.0.1.1-ipod.patch, amarok-2.0.1.1.ebuild:
+ Fix ipod issue with amarok 2.0. Per bug #255730.
*amarok-1.4.10_p20090130-r1 (30 Jan 2009)
*amarok-1.4.10_p20090130 (30 Jan 2009)
diff --git a/media-sound/amarok/amarok-2.0.1.1.ebuild b/media-sound/amarok/amarok-2.0.1.1.ebuild
index 44a768fb0477..10b7ca65cf06 100644
--- a/media-sound/amarok/amarok-2.0.1.1.ebuild
+++ b/media-sound/amarok/amarok-2.0.1.1.ebuild
@@ -1,6 +1,6 @@
# Copyright 1999-2009 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/media-sound/amarok/amarok-2.0.1.1.ebuild,v 1.7 2009/01/25 22:17:57 jokey Exp $
+# $Header: /var/cvsroot/gentoo-x86/media-sound/amarok/amarok-2.0.1.1.ebuild,v 1.8 2009/02/10 22:09:34 scarabeus Exp $
EAPI="2"
@@ -30,7 +30,7 @@ DEPEND=">=app-misc/strigi-0.5.7
>=kde-base/plasma-workspace-${KDE_MINIMAL}
x11-libs/qt-webkit:4
ifp? ( media-libs/libifp )
- ipod? ( >=media-libs/libgpod-0.4.2 )
+ ipod? ( >=media-libs/libgpod-0.7.0 )
mp3tunes? (
dev-libs/libxml2
dev-libs/openssl
@@ -46,6 +46,8 @@ RDEPEND="${DEPEND}
app-arch/unzip
daap? ( www-servers/mongrel )"
+PATCHES=( "${FILESDIR}/${PV}-ipod.patch" )
+
pkg_setup() {
if use amd64 ; then
ewarn
diff --git a/media-sound/amarok/files/2.0.1.1-ipod.patch b/media-sound/amarok/files/2.0.1.1-ipod.patch
new file mode 100644
index 000000000000..2e4300ed514f
--- /dev/null
+++ b/media-sound/amarok/files/2.0.1.1-ipod.patch
@@ -0,0 +1,175 @@
+diff -urN amarok-2.0.1.1.old/cmake/modules/FindIpod.cmake amarok-2.0.1.1/cmake/modules/FindIpod.cmake
+--- amarok-2.0.1.1.old/cmake/modules/FindIpod.cmake 2009-01-06 13:48:28.000000000 +0100
++++ amarok-2.0.1.1/cmake/modules/FindIpod.cmake 2009-02-10 18:18:23.000000000 +0100
+@@ -2,45 +2,35 @@
+ # Once done this will define
+ #
+ # IPOD_FOUND - system has libgpod
+-# IPOD_INCLUDE_DIR - the libgpod include directory
++# IPOD_INCLUDE_DIRS - the libgpod include directory
+ # IPOD_LIBRARIES - Link these to use libgpod
+-# IPOD_DEFINITIONS - Compiler switches required for using libgpod
++# IPOD_CFLAGS - Compiler switches required for using libgpod
++# IPOD_VERSION - Version number of libgpod
+ #
+
+-if (IPOD_INCLUDE_DIR AND IPOD_LIBRARIES)
++if (IPOD_INCLUDE_DIRS AND IPOD_LIBRARIES)
+
+ # in cache already
+ SET(IPOD_FOUND TRUE)
+
+-else (IPOD_INCLUDE_DIR AND IPOD_LIBRARIES)
++else (IPOD_INCLUDE_DIRS AND IPOD_LIBRARIES)
+ if(NOT WIN32)
+ # use pkg-config to get the directories and then use these values
+ # in the FIND_PATH() and FIND_LIBRARY() calls
+- INCLUDE(UsePkgConfig)
+-
+- PKGCONFIG(libgpod-1.0 _IPODIncDir _IPODLinkDir _IPODLinkFlags _IPODCflags)
+-
+- set(IPOD_DEFINITIONS ${_IPODCflags})
++ find_package(PkgConfig)
++ PKG_SEARCH_MODULE(IPOD libgpod-1.0)
++
+ endif(NOT WIN32)
++ IF (IPOD_FOUND)
++ IF (NOT IPOD_FIND_QUIETLY)
++ MESSAGE(STATUS "Found libgpod-1 ${IPOD_VERSION}")
++ ENDIF (NOT IPOD_FIND_QUIETLY)
++ ELSE (IPOD_FOUND)
++ IF (IPOD_FIND_REQUIRED)
++ MESSAGE(FATAL_ERROR "Could NOT find libgpod-1, check FindPkgConfig output above!")
++ ENDIF (IPOD_FIND_REQUIRED)
++ ENDIF (IPOD_FOUND)
++
++ MARK_AS_ADVANCED(IPOD_INCLUDE_DIRS)
+
+- FIND_PATH(IPOD_INCLUDE_DIR gpod/itdb.h /usr/include/gpod-1.0
+- ${_IPODIncDir}
+- )
+-
+- FIND_LIBRARY(IPOD_LIBRARIES NAMES gpod
+- PATHS
+- ${_IPODLinkDir}
+- )
+-
+- if (IPOD_INCLUDE_DIR AND IPOD_LIBRARIES)
+- SET(IPOD_FOUND TRUE)
+- else (IPOD_INCLUDE_DIR AND IPOD_LIBRARIES)
+- SET(IPOD_FOUND_FALSE)
+- endif (IPOD_INCLUDE_DIR AND IPOD_LIBRARIES)
+-
+- include(FindPackageHandleStandardArgs)
+- FIND_PACKAGE_HANDLE_STANDARD_ARGS(Ipod DEFAULT_MSG IPOD_INCLUDE_DIR IPOD_LIBRARIES )
+-
+- MARK_AS_ADVANCED(IPOD_INCLUDE_DIR IPOD_LIBRARIES)
+-
+-endif (IPOD_INCLUDE_DIR AND IPOD_LIBRARIES)
++endif (IPOD_INCLUDE_DIRS AND IPOD_LIBRARIES)
+diff -urN amarok-2.0.1.1.old/CMakeLists.txt amarok-2.0.1.1/CMakeLists.txt
+--- amarok-2.0.1.1.old/CMakeLists.txt 2009-01-06 14:12:50.000000000 +0100
++++ amarok-2.0.1.1/CMakeLists.txt 2009-02-10 18:22:23.000000000 +0100
+@@ -56,7 +56,10 @@
+ macro_log_feature( GDK_FOUND "Gdk" "Support for artwork on iPod audio devices via GdkPixbuf" "http://developer.gnome.org/arch/imaging/gdkpixbuf.html" FALSE "2.0.x" "" )
+
+ macro_optional_find_package(Ipod)
+-macro_log_feature( IPOD_FOUND "libgpod" "Support Apple iPod audio devices" "http://sourceforge.net/projects/gtkpod/" FALSE "0.6.0" "" )
++if(IPOD_FOUND)
++ macro_ensure_version("0.7.0" ${IPOD_VERSION} IPOD_0_7)
++endif(IPOD_FOUND)
++macro_log_feature( IPOD_FOUND "libgpod" "Support Apple iPod audio devices" "http://sourceforge.net/projects/gtkpod/" FALSE "0.7.0" "" )
+
+ #macro_optional_find_package(MySQL)
+ #macro_log_feature( MYSQL_FOUND "mysql" "Store Collection in a mysql database instead of a sqlite one" "http://www.mysql.com" FALSE "4.1.0" "" )
+diff -urN amarok-2.0.1.1.old/src/collection/ipodcollection/CMakeLists.txt amarok-2.0.1.1/src/collection/ipodcollection/CMakeLists.txt
+--- amarok-2.0.1.1.old/src/collection/ipodcollection/CMakeLists.txt 2009-01-06 13:49:32.000000000 +0100
++++ amarok-2.0.1.1/src/collection/ipodcollection/CMakeLists.txt 2009-02-10 22:22:01.000000000 +0100
+@@ -17,7 +17,7 @@
+ handler
+ ${GLIB2_INCLUDE_DIR}
+ ${GDK_INCLUDE_DIR}
+- ${IPOD_INCLUDE_DIR}
++ ${IPOD_INCLUDE_DIRS}
+ ${CMAKE_CURRENT_BINARY_DIR}/../..
+ ${AMAROK_COLLECTION_SUPPORT_DIR}
+ ${KDE4_INCLUDE_DIR}
+diff -urN amarok-2.0.1.1.old/src/collection/ipodcollection/handler/IpodHandler.cpp amarok-2.0.1.1/src/collection/ipodcollection/handler/IpodHandler.cpp
+--- amarok-2.0.1.1.old/src/collection/ipodcollection/handler/IpodHandler.cpp 2009-01-06 13:49:32.000000000 +0100
++++ amarok-2.0.1.1/src/collection/ipodcollection/handler/IpodHandler.cpp 2009-02-10 18:00:09.000000000 +0100
+@@ -1339,73 +1339,12 @@
+ QFileInfo tempImageFileInfo( tempImageFile ); // get info for path
+ QString tempImagePath = tempImageFileInfo.absoluteFilePath(); // path
+
+- Itdb_Thumb *thumb = NULL;
+ GdkPixbuf *gpixbuf = NULL;
+- QString thumbPath;
+
+ // pull image out of ipod
+
+- if( ipodtrack->has_artwork == 0x01 )
+- {
+- // try small first
+-
+- thumb = itdb_artwork_get_thumb_by_type ( ipodtrack->artwork, ITDB_THUMB_COVER_SMALL );
+-
+- // then large if needed
+- if( thumb == NULL)
+- {
+- thumb = itdb_artwork_get_thumb_by_type ( ipodtrack->artwork, ITDB_THUMB_COVER_LARGE );
+- }
+-
+- if( thumb != NULL)
+- {
+- gpixbuf = (GdkPixbuf*) itdb_thumb_get_gdk_pixbuf( m_device, thumb );
+- }
+- else
+- {
+- GList *thumbs = ipodtrack->artwork->thumbnails;
+-
+- for(; thumbs; thumbs = thumbs->next)
+- {
+- Itdb_Thumb *curThumb = ( Itdb_Thumb * )thumbs->data;
+- if( curThumb == NULL)
+- continue;
+-
+- switch( curThumb->type )
+- {
+- case ITDB_THUMB_PHOTO_SMALL:
+- break;
+- case ITDB_THUMB_PHOTO_LARGE:
+- break;
+- case ITDB_THUMB_PHOTO_FULL_SCREEN:
+- break;
+- case ITDB_THUMB_PHOTO_TV_SCREEN:
+- break;
+- case ITDB_THUMB_COVER_XLARGE:
+- break;
+- case ITDB_THUMB_COVER_MEDIUM:
+- break;
+- case ITDB_THUMB_COVER_SMEDIUM:
+- break;
+- case ITDB_THUMB_COVER_XSMALL:
+- break;
+-
+- default:
+- break;
+- }
+-
+- thumb = curThumb;
+- break;
+-
+- }
+-
+- if( thumb != NULL)
+- {
+- thumbPath = QString::fromUtf8( itdb_thumb_get_filename( m_device, thumb ) );
+- gpixbuf = (GdkPixbuf*) itdb_thumb_get_gdk_pixbuf( m_device, thumb );
+- }
+- }
+- }
++ if( ipodtrack->has_artwork == 0x01 ) // 0x01 = true ; 0x02 = false
++ gpixbuf = (GdkPixbuf*) itdb_artwork_get_pixbuf( m_device, ipodtrack->artwork, 50, 50 );
+
+ if(gpixbuf != NULL)
+ {