Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 371941 - net-im/licq-1.3.9[ncurses] should call cdk5-config for dev-libs/cdk-5.0.20110517[unicode]
Summary: net-im/licq-1.3.9[ncurses] should call cdk5-config for dev-libs/cdk-5.0.20110...
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: Gentoo Net-im project
URL:
Whiteboard:
Keywords:
: 374917 403465 411287 (view as bug list)
Depends on: 339673
Blocks: 378027
  Show dependency tree
 
Reported: 2011-06-16 17:21 UTC by Martin von Gagern
Modified: 2013-06-20 11:08 UTC (History)
5 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
Modification to configure (gentoo371941a.patch,1.15 KB, patch)
2011-06-16 23:13 UTC, Martin von Gagern
Details | Diff
More modifications to configure (gentoo371941a.patch,2.53 KB, patch)
2011-08-07 09:56 UTC, Martin von Gagern
Details | Diff
cmake fix for licq 1.5.1 (gentoo371941b.patch,2.76 KB, patch)
2011-08-07 12:09 UTC, Martin von Gagern
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Martin von Gagern 2011-06-16 17:21:57 UTC
Currently on my system /usr/lib64/libcdk.so.0.4.1 and symlinks are preserved by portage for net-im/licq-1.3.9. emerge @preserved-rebuild won't help, as licq will always link against the same files. It appears that dev-libs/cdk-5.0.20110517[unicode] now only creates a library called /usr/lib64/libcdkw.so.0.0.0. The canonical way to find the right library to use appears to be a call to the cdk5-config binary. The configure script for the console plugin, otoh, uses AC_CHECK_LIB to look for libcdk. I'm not sure how best to fix this issue.

Addressing bug #364557 would turn this bug here from an emerge loop to a build time failure.
Comment 1 Martin von Gagern 2011-06-16 23:13:12 UTC
Created attachment 277317 [details, diff]
Modification to configure

This patch should theoretically address things in configure. I cannot get it to work, though: if I run eautoreconf in $S/plugins/console, then the build will fail with the following error message:

../libtool: line 481: CDPATH: command not found
libtool: Version mismatch error.  This is libtool 2.4, but the
libtool: definition of this LT_INIT comes from an older release.
libtool: You should recreate aclocal.m4 with macros from libtool 2.4
libtool: and run autoconf again.

Not sure how to address this. If anyone manages that, a patch to the ebuild would probably help. Of course a commit to the portage tree would be just as fine.
Comment 2 Tim Harder gentoo-dev 2011-07-01 16:51:35 UTC
Try running eutoreconf on the base directory instead with that patch.
Comment 3 Tim Harder gentoo-dev 2011-07-01 16:51:58 UTC
And I meant eautoreconf, of course. :)
Comment 4 Martin von Gagern 2011-07-01 20:27:12 UTC
(In reply to comment #2)
> Try running e[a]utoreconf on the base directory instead with that patch.

No luck, it fails to build as the configure script in the subdir isn't recreated.

checking for initCDKScreen in -lcdk... no
configure: error: 

I can't find the cdk library. This is needed if you want
to compile this plugin. Sorry. Try to get it from here:
http://freshmeat.net/projects/libcdk/

As you can see, I've had licq unmerged in the mean time, so the old libcdk is no longer preserved, and I get build errors instead.
Comment 5 Thomas Dickey 2011-07-09 12:27:51 UTC
would it help if cdk5 had a configure option to set the library
name, e.g., changing cdk5w to cdk5 ?
Comment 6 Martin von Gagern 2011-07-10 21:20:35 UTC
I guess it might help. I've never understood why curses was installing two libs; imho there is no reason at all to ever use libcurses when you might just as well use ncursesw. Passing that distinction through even more libs doesn't seem a particularly good idea to me.
Comment 7 Lars Wendler (Polynomial-C) (RETIRED) gentoo-dev 2011-07-12 09:16:06 UTC
*** Bug 374917 has been marked as a duplicate of this bug. ***
Comment 8 Fernando (likewhoa) 2011-08-05 19:07:57 UTC
confirmed here.
Comment 9 Martin von Gagern 2011-08-07 09:56:04 UTC
Created attachment 282391 [details, diff]
More modifications to configure

OK, I finally got licq to compile, using this patch and the following ugly src_prepare function:

src_prepare() {
	if use ncurses; then
		# preserve AM_PATH_LIBXOSD
		awk '/Oron Peled/,/nls.m4/' plugins/osd/aclocal.m4 | head -n-1 \
			>> plugins/osd/acinclude.m4.in

		epatch "${FILESDIR}"/gentoo371941a.patch

		cat acinclude.m4.in admin/acinclude.m4.in > acinclude.m4
		eautoreconf
		local dir
		for dir in "${S}"/plugins/*/configure.ac; do
			pushd "${dir%/*}" >/dev/null || die
			cat acinclude.m4.in admin/acinclude.m4.in > acinclude.m4
			eautoreconf
			popd >/dev/null || die
		done
	fi
}

When configuring only some of the plugin dirs, libtool will complain about a mismatch in the version number of the LT_INIT macro, or something like this.

The previous problem with CDPATH mentioned in comment #1 was due to the fact that libtoolize installed a version of ltmain.sh which relied on the definition of $lt_unset. To make this work, the LT_INIT macro from /usr/share/aclocal/libtool.m4 is needed. The configure.ac contains a call to AC_PROG_LIBTOOL which usually is an alias for it. Unfortunately the acinclude.m4 file contained a different expansion of that macro, which takes precedence over the one from /usr/share/aclocal. That's the reason I overwrote those acinclude.m4 files in all the directories. Hope that was the right thing to do.

The osd plugin uses a macro called AM_PATH_LIBXOSD which was only present in the aclocal.m4 file. Thus the awk script to add it to acinclude.m4.in.

After finally getting the 1.3.9 sources to compile in this fashion, I found that the latest version, 1.5.1, uses cmake instead of autotools. So as an alternative to addressing this bug here, you might want to bump the licq version as requested in bug #339673.
Comment 10 Martin von Gagern 2011-08-07 12:09:35 UTC
Created attachment 282403 [details, diff]
cmake fix for licq 1.5.1

licq-1.5.1 using the ebuild from bug #339673 comment #5 is affected by this issue here as well. This patch takes care of things.
Comment 11 Lars Wendler (Polynomial-C) (RETIRED) gentoo-dev 2011-11-23 09:22:11 UTC
This should be fixed with licq-1.6.0
Comment 12 Diego Elio Pettenò (RETIRED) gentoo-dev 2012-06-21 16:44:49 UTC
*** Bug 403465 has been marked as a duplicate of this bug. ***
Comment 13 Diego Elio Pettenò (RETIRED) gentoo-dev 2012-06-21 16:44:59 UTC
*** Bug 411287 has been marked as a duplicate of this bug. ***
Comment 14 jannis 2013-01-17 11:10:14 UTC
I'd assume this is fixed by the recent bump to 1.7.0 (thank you Lars!) in https://bugs.gentoo.org/show_bug.cgi?id=339673
Comment 15 Lars Wendler (Polynomial-C) (RETIRED) gentoo-dev 2013-06-20 11:08:42 UTC
Indeed this is fixed.