[arch-commits] Commit in digikam/trunk (PKGBUILD fix-libusb-linkage.patch)
Andrea Scarpino
andrea at archlinux.org
Fri Aug 19 07:59:18 UTC 2011
Date: Friday, August 19, 2011 @ 03:59:18
Author: andrea
Revision: 135835
Fix a crash in digikam (FS#25652)
Added:
digikam/trunk/fix-libusb-linkage.patch
Modified:
digikam/trunk/PKGBUILD
--------------------------+
PKGBUILD | 8 ++
fix-libusb-linkage.patch | 130 +++++++++++++++++++++++++++++++++++++++++++++
2 files changed, 136 insertions(+), 2 deletions(-)
Modified: PKGBUILD
===================================================================
--- PKGBUILD 2011-08-19 07:53:12 UTC (rev 135834)
+++ PKGBUILD 2011-08-19 07:59:18 UTC (rev 135835)
@@ -5,7 +5,7 @@
pkgbase=digikam
pkgname=('digikam' 'kipi-plugins' 'libkface' 'libkgeomap' 'libmediawiki')
pkgver=2.0.0
-pkgrel=2
+pkgrel=3
pkgdesc="Digital photo management application for KDE"
arch=('i686' 'x86_64')
license=('GPL')
@@ -13,10 +13,14 @@
makedepends=('kdepimlibs' 'libkexiv2' 'libkdcraw' 'libkipi' 'libksane' 'liblqr'
'kdeedu-marble' 'opencv' 'boost' 'libgpod' 'qjson' 'hugin'
'cmake' 'automoc4' 'doxygen')
-source=("http://downloads.sourceforge.net/${pkgname}/${pkgname}-${pkgver}.tar.bz2")
+source=("http://downloads.sourceforge.net/${pkgname}/${pkgname}-${pkgver}.tar.bz2"
+ 'fix-libusb-linkage.patch')
md5sums=('7b1ab69fc2fb36a45dc3ca38b01d42d8')
build() {
+ cd "${srcdir}"/${pkgname}-${pkgver}
+ patch -p1 -i "${srcdir}"/fix-libusb-linkage.patch
+
cd "${srcdir}"
mkdir build
cd build
Added: fix-libusb-linkage.patch
===================================================================
--- fix-libusb-linkage.patch (rev 0)
+++ fix-libusb-linkage.patch 2011-08-19 07:59:18 UTC (rev 135835)
@@ -0,0 +1,130 @@
+commit 5c8ae642eb0443b68a14716d3c27d66b3e71b705
+Author: Gilles Caulier <caulier.gilles at gmail.com>
+Date: Thu Jun 16 17:40:04 2011 +0200
+
+ add libusb as linking dependency for gphoto2 library to prevent crash at libgphoto2 init when OpenCV library is linked against libdc1394.
+ BUGS: 268267
+
+diff --git a/CMakeLists.txt b/CMakeLists.txt
+index 0dd8b04..7d21a57 100644
+--- a/CMakeLists.txt
++++ b/CMakeLists.txt
+@@ -205,7 +205,7 @@ IF (ENABLE_INTERNALMYSQL)
+ /opt/mysql/libexec /usr/mysql/bin /opt/mysql/bin ${MYSQL_TOOLS_PATH}
+ ENV MYSQL_TOOLS_PATH )
+ MESSAGE(STATUS "Found MySQL install_db executable at: ${INITCMD_MYSQL}")
+- SET(DATABASESERVERDIR "${CMAKE_CURRENT_SOURCE_DIR}/databaseserver")
++ SET(DATABASESERVERDIR "${CMAKE_CURRENT_SOURCE_DIR}/databaseserver")
+ ELSE (ENABLE_INTERNALMYSQL)
+ SET(DATABASESERVERDIR "")
+ ENDIF (ENABLE_INTERNALMYSQL)
+@@ -238,6 +238,11 @@ ENDIF (KMAP_VERSION)
+ MACRO_OPTIONAL_FIND_PACKAGE(Gphoto2)
+ MACRO_BOOL_TO_01(GPHOTO2_FOUND HAVE_GPHOTO2)
+
++IF (NOT WIN32 AND HAVE_GPHOTO2)
++ # See B.K.O #268267 : digiKam need to be linked to libusb to prevent crash at gphoto2 init if opencv is linked with libdc1394
++ MACRO_OPTIONAL_FIND_PACKAGE(USB)
++ENDIF (NOT WIN32 AND HAVE_GPHOTO2)
++
+ MACRO_OPTIONAL_FIND_PACKAGE(KdepimLibs)
+ MACRO_BOOL_TO_01(KDEPIMLIBS_FOUND HAVE_KDEPIMLIBS)
+
+@@ -340,17 +345,17 @@ IF(GPHOTO2_FOUND)
+ EXEC_PROGRAM(gphoto2-config ARGS --version RETURN_VALUE _return_VALUE OUTPUT_VARIABLE GPHOTO2_VERSION)
+ STRING(REPLACE "libgphoto2" "" GPHOTO2_VERSION "${GPHOTO2_VERSION}")
+ MACRO_ENSURE_VERSION("2.4.0" "${GPHOTO2_VERSION}" VERSION_GPHOTO2)
+- IF(VERSION_GPHOTO2)
++ IF(VERSION_GPHOTO2 AND LIBUSB_FOUND)
+ SET(GPHOTO2_FOUND true)
+- ELSE(VERSION_GPHOTO2)
++ ELSE(VERSION_GPHOTO2 AND LIBUSB_FOUND)
+ SET(GPHOTO2_FOUND false)
+- ENDIF(VERSION_GPHOTO2)
++ ENDIF(VERSION_GPHOTO2 AND LIBUSB_FOUND)
+ ENDIF(GPHOTO2_FOUND)
+
+ IF(GPHOTO2_FOUND)
+- MESSAGE(STATUS " libgphoto2 library found................. YES (optional)")
++ MESSAGE(STATUS " libgphoto2 and libusb libraries found.... YES (optional)")
+ ELSE(GPHOTO2_FOUND)
+- MESSAGE(STATUS " libgphoto2 library found................. NO (optional)")
++ MESSAGE(STATUS " libgphoto2 and libusb libraries found.... NO (optional)")
+ MESSAGE(STATUS "")
+ MESSAGE(STATUS " digiKam will be compiled without GPhoto2 support.")
+ MESSAGE(STATUS "")
+diff --git a/README b/README
+index c362aff..73984c8 100644
+--- a/README
++++ b/README
+@@ -9,7 +9,7 @@ DIGIKAM - MANAGE YOUR PHOTOGRAPHS LIKE A PROFESSIONAL WITH THE POWER OF OPEN SOU
+ and/or delete them.
+
+ The digiKam built-in image editor makes the common photo correction
+- a simple task. The image editor is extensible via plugins and,
++ a simple task. The image editor is extensible via plugins and,
+ since the digikamimageplugins project has been merged to digiKam core
+ since release 0.9.2, all useful image editor plugins are available
+ in the base installation.
+@@ -49,7 +49,7 @@ IRC channel from irc.freenode.org server: #digikam
+ IMPORTANT : the bug reports and wishlist entries are hosted by the KDE bug report
+ system which can be reached from the standard KDE help menu of digiKam.
+ A mail will automatically be sent to the digiKam development mailing list.
+-There is no need to contact directly the digiKam mailing list for a bug report
++There is no need to contact directly the digiKam mailing list for a bug report
+ or a devel wish.
+
+ The current bugs and devel wishes reported to the bugzilla servers can be seen
+@@ -104,8 +104,9 @@ Optional :
+
+ libkdepimlibs >= 4.4.x http://pim.kde.org To support KAddressBook entries.
+ liblensfun >= 0.2.5 http://lensfun.berlios.de To support LensCorrection editor. If no external libray is found, internal version is used instead. plugin.
+-libgphoto2 >= 2.4.0 http://www.gphoto.org To support Gphoto2 Cameras.
+-liblqr-1 >= 0.4.1 http://liblqr.wikidot.com For Liquid Rescale tool. If no external libray is found, internal version is used instead.
++libgphoto2 >= 2.4.0 http://www.gphoto.org To support Gphoto2 Cameras.
++libusb >= 1.0.0 http://www.libusb.org Required by Gphoto2 as linking dependency. See details in B.K.O #268267
++liblqr-1 >= 0.4.1 http://liblqr.wikidot.com For Liquid Rescale tool. If no external libray is found, internal version is used instead.
+
+ Note : all library dependencies require development and binary packages installed on your
+ computer to compile digiKam.
+@@ -119,12 +120,12 @@ Video thumbs support under Linux : please install "mplayerthumbs" package.
+
+ -- INSTALLATION --------------------------------------------------------
+
+-In order to compile, especially when QT3/Qt4 are installed at the same time,
++In order to compile, especially when QT3/Qt4 are installed at the same time,
+ just use something like that:
+
+ # export VERBOSE=1
+ # export QTDIR=/usr/lib/qt4
+-# export PATH=$QTDIR/bin:$PATH
++# export PATH=$QTDIR/bin:$PATH
+ # cmake .
+ # make
+ # sudo make install
+@@ -152,7 +153,7 @@ Note: To know KDE install path on your computer, use 'kde-config --prefix' comma
+
+ -- DONATE MONEY --------------------------------------------------------
+
+-If you love digiKam, you can help developers to buy new photo devices to test
++If you love digiKam, you can help developers to buy new photo devices to test
+ and implement new features. Thanks in advance for your generous donations.
+
+ For more information, look at this url : http://www.digikam.org/?q=donation
+diff --git a/digikam/CMakeLists.txt b/digikam/CMakeLists.txt
+index 80fa0ee..c15f0b2 100644
+--- a/digikam/CMakeLists.txt
++++ b/digikam/CMakeLists.txt
+@@ -281,6 +281,12 @@ TARGET_LINK_LIBRARIES(digikam
+ cameragui
+ )
+
++IF (NOT WIN32 AND GPHOTO2_FOUND)
++ # See B.K.O #268267 : digiKam need to be linked to libusb to prevent crash at gphoto2 init if opencv is linked with libdc1394
++ TARGET_LINK_LIBRARIES(digikam ${LIBUSB_LIBRARIES})
++ENDIF (NOT WIN32 AND GPHOTO2_FOUND)
++
++
+ IF(USE_SCRIPT_IFACE)
+ TARGET_LINK_LIBRARIES(digikam ${QT_QTSCRIPT_LIBRARY})
+ ENDIF(USE_SCRIPT_IFACE)
More information about the arch-commits
mailing list