Summary: | cannot compile: cannot verify exiv2 version | ||
---|---|---|---|
Product: | [Applications] digikam | Reporter: | Mikolaj Machowski <mikmach> |
Component: | Portability-Compilation | Assignee: | Digikam Developers <digikam-bugs-null> |
Status: | RESOLVED FIXED | ||
Severity: | normal | CC: | anaselli, caulier.gilles, marnold |
Priority: | VHI | ||
Version: | unspecified | ||
Target Milestone: | --- | ||
Platform: | Compiled Sources | ||
OS: | Linux | ||
Latest Commit: | Version Fixed In: | 0.9.0 | |
Sentry Crash Report: | |||
Attachments: |
patch for exiv2 (kipi-plugins)
Patch for exiv2 checks in digikam patch for exiv2 (digikam) configure.in.bot.patch |
Description
Mikolaj Machowski
2006-12-10 11:01:13 UTC
Fixed this morning in svn. Please checkout, cleanup, and try again. Gilles Removed and did checkout of whole extragear/graphics and still the same error exiv2 >= 12 ... no. :r!exiv2-config --version 0.12 :read /usr/local/lib/pkgconfig/exiv2.pc prefix=/usr/local exec_prefix=${prefix} libdir=${exec_prefix}/lib includedir=${prefix}/include Name: exiv2 Description: Exif and IPTC metadata library and tools Version: 0.12 URL: http://www.exiv2.org Libs: -L${libdir} -lexiv2 Libs.private: -lz -lm Cflags: -I${includedir} m. Mikolaj, Are you installed properlly Exiv2 library ? Here, i'm use "./configure --prefix=/usr" under Mandriva... Angelo, What's wrong in .configure.in about Exiv2 version check ? Gilles > Are you installed properlly Exiv2 library ? Here, i'm use "./configure
> --prefix=/usr" under Mandriva...
Yes. I installed properly and as usual programs compiled from sources
are going to /usr/local
Looks like pkg-config has problems with that. Since exiv2-config
supports libs/flags options maybe you should scratch pkg-config and use
exiv2-config instead?
m.
About comment#2 error exiv2 >= 12 ... no. (12?) strange. Anyway it works here (mandriva 2007), did you try to download the srpm from cooker and backporting it? as soon as possible i'll try to provide a backport package for mandriva. Anyway to comment#4 I should say it's not on a conventional directory, mandriva installs all into /usr -i strongly recomend to use srpm anyway- so you should use PKG_CONFIG_PATH in order to provide /usr/local/lib/pkgconfig to compile, in the same way I believe you do with LD_LIBRARY_PATH to provide /usr/local/lib first for share libraries to run your applications. Angelo Mikolaj, Also, if you can compile kipi-plugins, why you cannot do it with digiKam ? kipi-plugins Exiv2 check from .configure.in is the same on both... Gilles > Also, if you can compile kipi-plugins, why you cannot do it with digiKam
I've had an "old" kipi-plugins. Didn't want to recompile them, just went
straight to Digikam.
did you try to use PKG_CONFIG_PATH? To comment #4: Please use pkg-config with exiv2.pc, not exiv2-config. exiv2-config has been marked as deprecated since (I think) 0.10, I don't plan to ship it with the next version anymore. If there is something wrong with exiv2.pc, report it as a bug. -ahu. (Maybe its the same "bug" that Daniel already triggered) Do you have a second version of exiv2 installed? If yes, where are the two exiv2.pc installed? Bye Thorsten Andreas, with that I believe i won't go back on my steps, but, there's always a but, I found this problem using pkg-config alone: #exiv2-config --libs -L/usr/lib -lexiv2 -lz -lm while #pkg-config exiv2 --libs -lexiv2 #pkg-config exiv2 --modversion 0.12 Regards, Angelo That's ok. -lz and -lm are only needed when linking statically: ahuggel@mowgli> pkg-config --libs exiv2 -L/usr/local/lib -lexiv2 ahuggel@mowgli> pkg-config --libs --static exiv2 -L/usr/local/lib -lexiv2 -lz -lm -ahu. > ahuggel mowgli> pkg-config --libs exiv2
> -L/usr/local/lib -lexiv2
[anaselli@proj9 src]$ pkg-config --libs exiv2
-lexiv2
there's no -L/usr/lib but maybe that's ok because it's standard...
Angelo
Angelo, Look like Andreas recommend to use pkg-config with exiv2.pc, not exiv2-config. See comments #9... It's the case actually in .configure script ? Gilles > It's the case actually in .configure script ?
almost, it's a hybrid yet, we use pkg-config to get the module isntalled and
exiv2-config to get [c|ld]flags. I'll change it asap
Angelo, I just tag this file like VHI because it must be fixed before digiKam 0.9.0-final release planed at Christmast... Gilles > Angelo,
>
> I just tag this file like VHI because it must be fixed before digiKam 0.9.0-final release planed at Christmast...
Gilles, I can't see the problem, the reporter doesn't want pkg-config
while Andreas said it's a must. I cannot fix it in the way the reporter wants,
I can only use pkg-config alone instead of a mix. Tell me what to do,
but as far as i can say this bug is invalid, but if the reporter shows
that PKG_CONFIG_PATH doesn't work.
Angelo
P.S. BTW I'm not a digikam developer :p
> P.S. BTW I'm not a digikam developer :p
Sure (:=))), but .configure Exiv2 detection is common on kipi-plugins and digiKam (the same in fact). If something must be fixed into digiKam, the same thing must be done in kipi-plugins.
Gilles
As exiv2-config is marked as deprecated by Andreas, I would suggest to only use pkg-config. IMHO, pkg-config is ok, if there are troubles, it could be because of some scripts using it, but not pkg-config itself... And, this will also solve the problem I mentionned in my email here : http://mail.kde.org/pipermail/digikam-users/2006-December/002628.html << But, in any case, it's true that there's something confusing in the configure script : - first, EXIV2_CFLAGS and LIB_EXIV2 are defined : EXIV2_CFLAGS="`$EXIV2_CONFIG --cflags`" LIB_EXIV2="`$EXIV2_CONFIG --libs`" - then, EXIV2_CFLAGS is redefined and a new EXIV2_LIBS is defined (and not LIB_EXIV2) : EXIV2_CFLAGS=`$PKG_CONFIG --cflags "exiv2 >= 0.12"` EXIV2_LIBS=`$PKG_CONFIG --libs "exiv2 >= 0.12"` I don't know yet which one is the right one, but I guess we shouldn't have both LIB_EXIV2 and EXIV2_LIBS at the same time... >> Created attachment 18912 [details] patch for exiv2 (kipi-plugins) > EXIV2_LIBS You're right i changed EXIV2_LIBS to LIB_EXIV2 to maintain Gilles Makefile.am but I believe this patch should be right and enough ;) Gilles this patch is for kipi-plugins, I haven't digikam here, so I cannot provide one untill tonight. Can you test this one and see if it's ok? Fabien, I'm busy until tomorrow. Can you check if all is ok ? Gilles > I'm busy until tomorrow. Can you check if all is ok ?
Good, I'll provide a digkam pach tonight then...
I just tried and it looks good, at least on my system :) > Gilles, I can't see the problem, the reporter doesn't want pkg-config
> while Andreas said it's a must. I cannot fix it in the way the reporter
Hey, hey, hey. I want it to *work*, I don't want some exact solution.
I suggested getting rid of pkg-config because I know it was causing
problems also in some other programs. If Andreas et al. can make it work
with pkg-config - fine by me :)
Mikolaj, could you check if you have another exiv2 version on your computer ? Please also try to do : pkg-config --debug --exists "exiv2 >= 0.12" OK, I see the problem (at least for Mandriva). Pkg doesn't by default look for alternative locations of .pc files. So, when I've had exiv2.pc in /usr/local/lib/pkgconfig pkg-config couldn't find it there because it was looking only in /usr/lib/pkgconfig. I've had to create $PKG_CONFIG_PATH variable to include /usr/local/lib/pkgconfig directory and now it works. Now, from one side I understand that when someone wants to use sources he makes it on his own risk but this situation doesn't feel good. On the other side not everyone using bleeding edge software needs to know all tricks of system. Please at least add more info for configure output, something like: exiv2 not found. Maybe pkg-config couldn't find data file. Check location of exiv2.pc file and value of $PKG_CONFIG_PATH. This is not complete info, but should give enough info for proper googling - configure output isn't manual. With such info added to configure scripts I can accept closing of this bug (or close it myself). m. Alle 19:40, mercoledì 13 dicembre 2006, Mikolaj Machowski ha scritto: [bugs.kde.org quoted mail] No, it's general. for mandriva 2007 you can get it (by now waiting a Gilles/Andreas answer) here: http://www.linux.it/~anaselli/kipi-plugins/ > I've had to create $PKG_CONFIG_PATH variable to include > /usr/local/lib/pkgconfig directory and now it works. Well that's the way to, I don't know if it's pkg-config or configure or system related, but in linux/unix systems, environment variables changes the behaviour, and that's it. I believe you can find documents on it googling somewhere, I know it's not easy for a user, but compiling sources neither... and who changes the normal behavior of a distro should be aware of what he's doing. I'm in a hurry by now, so i hope not to be misunderstood in what i said. Regards, Angelo Created attachment 18932 [details]
Patch for exiv2 checks in digikam
This is a patch to modify how exiv2 is checked by digikam configure.
It uses the same method as for kipi-plugins (by Angelo).
Ok, I just uploaded a patch for digikam. I tested it, recompiled everything and it looks fine. I may solve as well the problem Mikolaj has. Mikolaj, could you try it against latest svn version ? Am Do Dez 14 2006 schrieb Fabien:
> Ok, I just uploaded a patch for digikam. I tested it, recompiled
> everything and it looks fine.
--- digikam/configure.in.in (revision 613686)
+++ digikam/configure.in.in (working copy)
@@ -215,23 +215,19 @@
[...]
- AC_MSG_WARN([Exiv2 library not found, digiKam will not be compiled.])
- DO_NOT_COMPILE="digikam digikamimageplugins $DO_NOT_COMPILE"
+ AC_MSG_ERROR([Exiv2 library is required by kipi-plugins.])
+ DO_NOT_COMPILE="$DO_NOT_COMPILE kipi-plugins"
fi
^^^^
Is this correct?? IMHO Exiv2 is also required by digikam &
digikamimageplugins.
Bye
Thorsten
> Mikolaj, could you try it against latest svn version ?
OK, with two remarks. First, This text:
Exiv2 library is required by kipi-plugins.
Should mention digikam, digikamimageplugins not kipi-plugins. Second,
I would add mention about pkg-config:
Exiv2 library is required by digikam, digikamimageplugins. Check if
exiv2.pc is in path of pkg-config.
m.
Created attachment 18935 [details]
patch for exiv2 (digikam)
The attached one should work.
about comment #31, can you explain better what you mean with "Check if exiv2.pc is in path of pkg-config"? I mean the check should be consistent: [anaselli@proj9 digikam]$ pkg-config sqlite3 --libs -lsqlite3 [anaselli@proj9 digikam]$ pkg-config sqlite2 --libs Package sqlite2 was not found in the pkg-config search path. Perhaps you should add the directory containing `sqlite2.pc' to the PKG_CONFIG_PATH environment variable No package 'sqlite2' found If xxxx.pc is not in the path the check fails. about the patch (comment #32) there's something i don't like though, if you're compiling under svn all graphics, missing exiv2 or sqlite3 could be ok because digikam is not the only project under. But if you're packaging those checks should make failing configure, a warning message and "$DO_NOT_COMPILE digikam digikamimageplugins" is not enough, I believe. You could have a pretty empty package ;) Gilles please take care of testing and commit it, Angelo >Gilles please take care of testing and commit it
sure...
I'm waiting feedback at this moment. I wil commit that later.
Gilles
About comments #30 and #31 Sorry, next time I'll do a bit more that just copy & paste :) Fabien, never mind thanks for your help anyway (:=)))... Well let's me hear when all will ready to commit on svn... Gilles > (:=)))... Well let's me hear when all will ready to commit on svn...
Gilles, kipi's already released it ;)
I tried it (with checks with and without exiv2) and it works fine. So, I think it's ready and you can commit it... SVN commit 613892 by cgilles: digikam from trunk : patch about Exiv2 0.12 version detection from Angelo. BUG: 138616 M +2 -10 configure.in.in M +1 -1 digikam/Makefile.am M +3 -3 kioslave/Makefile.am M +1 -1 showfoto/Makefile.am --- trunk/extragear/graphics/digikam/configure.in.in #613891:613892 @@ -215,19 +215,11 @@ #------------------------------------------------------------------ have_exiv2='no' -AC_PATH_PROG(EXIV2_CONFIG,exiv2-config) -if test -n "${EXIV2_CONFIG}"; then - EXIV2_CFLAGS="`$EXIV2_CONFIG --cflags`" - AC_SUBST(EXIV2_CFLAGS) - LIB_EXIV2="`$EXIV2_CONFIG --libs`" - AC_SUBST(LIB_EXIV2) - KDE_PKG_CHECK_MODULES(EXIV2, exiv2 >= 0.12, have_exiv2=yes,have_exiv2=no) +if test "$PKGCONFIGFOUND" = "yes" ; then + KDE_PKG_CHECK_MODULES(EXIV2, exiv2 >= 0.12, have_exiv2=yes,have_exiv2=no) fi if test "x$have_exiv2" != "xyes"; then - if test -n "${EXIV2_CONFIG}"; then - AC_MSG_RESULT($have_exiv2) - fi AC_MSG_WARN([Exiv2 library not found, digiKam will not be compiled.]) DO_NOT_COMPILE="digikam digikamimageplugins $DO_NOT_COMPILE" fi --- trunk/extragear/graphics/digikam/digikam/Makefile.am #613891:613892 @@ -91,7 +91,7 @@ upgradedb_sqlite2tosqlite3.cpp libdigikam_la_LIBADD = $(LIB_KIO) $(LIB_SQLITE3) $(LIB_KABC) \ - $(LIBKIPI_LIBS) $(LIB_KUTILS) $(LIB_EXIV2) \ + $(LIBKIPI_LIBS) $(LIB_KUTILS) $(EXIV2_LIBS) \ $(top_builddir)/digikam/sqlite/libsqlite.la \ $(top_builddir)/digikam/libs/thumbbar/libthumbbar.la \ $(top_builddir)/digikam/libs/themeengine/libthemeengine.la \ --- trunk/extragear/graphics/digikam/kioslave/Makefile.am #613891:613892 @@ -21,7 +21,7 @@ kio_digikamthumbnail_la_SOURCES = digikamthumbnail.cpp -kio_digikamthumbnail_la_LIBADD = $(LIB_KIO) $(LIBJPEG) $(LIBPNG) $(LIB_EXIV2) \ +kio_digikamthumbnail_la_LIBADD = $(LIB_KIO) $(LIBJPEG) $(LIBPNG) $(EXIV2_LIBS) \ $(top_builddir)/digikam/libs/dimg/libdimg.la kio_digikamthumbnail_la_LDFLAGS = -module -avoid-version $(KDE_PLUGIN) $(all_libraries) @@ -30,7 +30,7 @@ kio_digikampreview_la_SOURCES = digikampreview.cpp -kio_digikampreview_la_LIBADD = $(LIB_KIO) $(LIB_EXIV2) \ +kio_digikampreview_la_LIBADD = $(LIB_KIO) $(EXIV2_LIBS) \ $(top_builddir)/digikam/libs/dimg/libdimg.la kio_digikampreview_la_LDFLAGS = -module -avoid-version $(KDE_PLUGIN) $(all_libraries) @@ -48,7 +48,7 @@ kio_digikamalbums_la_SOURCES = digikamalbums.cpp sqlitedb.cpp kio_digikamalbums_la_LIBADD = $(top_builddir)/digikam/libs/jpegutils/libjpegutils.la \ - $(LIB_KIO) $(LIB_SQLITE3) $(LIB_EXIV2) \ + $(LIB_KIO) $(LIB_SQLITE3) $(EXIV2_LIBS) \ $(top_builddir)/digikam/libs/dimg/libdimg.la kio_digikamalbums_la_LDFLAGS = -module -avoid-version $(all_libraries) $(KDE_PLUGIN) --- trunk/extragear/graphics/digikam/showfoto/Makefile.am #613891:613892 @@ -32,7 +32,7 @@ $(top_builddir)/digikam/utilities/splashscreen/libsplashscreen.la \ $(top_builddir)/digikam/libs/threadimageio/libthreadimageio.la \ $(LIB_QT) $(LIB_KDECORE) $(LIB_KDEUI) $(LIB_KUTILS) \ - $(LIB_KFILE) $(LIB_KPARTS) $(LIBJPEG) $(LIB_EXIV2) + $(LIB_KFILE) $(LIB_KPARTS) $(LIBJPEG) $(EXIV2_LIBS) showfoto_LDFLAGS = $(KDE_RPATH) $(all_libraries) The error message should be made more clear. I had exiv2 0.11 installed and ./configure kept telling me that I did not have exiv2 installed at all. It should say "Exiv2 library => 0.12 not found". > The error message should be made more clear. I had exiv2 0.11 installed
> and ./configure kept telling me that I did not have exiv2 installed
> at all. It should say "Exiv2 library => 0.12 not found".
Ok I see what you mean, not configure output but the final message,
so it should be configure.in.bot
Can you check the attached patch please?
Created an attachment (id=18971)
configure.in.bot.patch
Works OK for me. One thought. There is plenty of 0.12 there. Maybe some variable for easier future upgrade? > ------- Additional Comments From mikmach wp pl 2006-12-18 22:37 -------
> Works OK for me. One thought. There is plenty of 0.12 there. Maybe some
> variable for easier future upgrade?
Yep I thought to it too, but you saw exiv2, there are libkipi, sqlite, libpng,...
as well.
I believe the problem is due to a missing stable (and working) exiv on most
distro by now, maybe next digikam/kipi-plugins release won't be affected by this
problem...
Angelo
P.S. Gilles wake up and commit ;)
Angelo, I have do it yesterday on both : digiKam and kipi-plugins (:=)))... Gilles Alle 07:41, martedì 19 dicembre 2006, Gilles Caulier ha scritto: [bugs.kde.org quoted mail] yep, i saw it after. I wonder why it didn't svn up it first.... bah. Angelo I'm not a programmer per se, so I'm not sure what to do with that attachment. My comments were directed at the patch for configure.in.in in #41. The error message is "Exiv2 library not found, digiKam will not be compiled." It would be better worded the way it is in the patch in #43. I hope I'm making sense. The long and short of it is that at the end of the ./configure output, it shouldn't say that Exiv2 is not found but rather that Exiv2 => 0.12 is not found. so it is, in svn. Angelo |