Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!

Bug 417173

Summary: dev-libs/m17n-lib-1.6.3 has an automagic app-i18n/anthy dependency
Product: Gentoo Linux Reporter: Maxim Kammerer <mk>
Component: [OLD] LibraryAssignee: CJK Team <cjk>
Status: RESOLVED FIXED    
Severity: normal    
Priority: Normal    
Version: unspecified   
Hardware: All   
OS: Linux   
Whiteboard:
Package list:
Runtime testing required: ---
Bug Depends on: 424427    
Bug Blocks:    
Attachments: m17n-lib-1.6.3.ebuild.patch
m17n-lib-1.6.3.ebuild.patch
dev-libs:m17n-lib-1.6.3-r1:20120611-115550.log

Description Maxim Kammerer 2012-05-22 20:47:55 UTC
dev-libs/m17n-lib-1.6.3 was built with the following:
USE="-X -gd"

# ldd /usr/lib/m17n/1.0/libmimx-anthy.so
	...
	libanthy.so.0 => /usr/lib/libanthy.so.0 (0xf776a000)
	libanthydic.so.0 => /usr/lib/libanthydic.so.0 (0xf7490000)

As a side node, it would also be nice to have USE=static-libs.
Comment 1 Naohiro Aota gentoo-dev 2012-05-27 18:06:13 UTC
Created attachment 313311 [details, diff]
m17n-lib-1.6.3.ebuild.patch
Comment 2 Naohiro Aota gentoo-dev 2012-05-27 18:11:51 UTC
Created attachment 313313 [details, diff]
m17n-lib-1.6.3.ebuild.patch

m17n-lib's code has fine #ifdef HAVE_FOO .. #endif, however most of them lack --with-foo options. 

This patch add such options to pump dependencies. Maybe some of these flags can be dropped and force its dependencies.
Comment 3 Maxim Kammerer 2012-06-11 12:04:09 UTC
I tested the patches with all USE flags disabled. libmimx-anthy.so is still built, but it doesn't link against anthy:

# ldd /usr/lib/m17n/1.0/libmimx-anthy.so
	linux-gate.so.1 =>  (0xf77da000)
	libc.so.6 => /lib/libc.so.6 (0xf7660000)
	/lib/ld-linux.so.2 (0xf77db000)
Comment 4 Maxim Kammerer 2012-06-11 12:05:08 UTC
Created attachment 314973 [details]
dev-libs:m17n-lib-1.6.3-r1:20120611-115550.log
Comment 5 Naohiro Aota gentoo-dev 2012-06-17 10:55:52 UTC
(In reply to comment #3)
> I tested the patches with all USE flags disabled. libmimx-anthy.so is still
> built, but it doesn't link against anthy:
> 
> # ldd /usr/lib/m17n/1.0/libmimx-anthy.so
> 	linux-gate.so.1 =>  (0xf77da000)
> 	libc.so.6 => /lib/libc.so.6 (0xf7660000)
> 	/lib/ld-linux.so.2 (0xf77db000)

This is expected result. example/mimx-anthy.c has #ifdef HAVE_ANTHY ... #else ... #endif. If HAVE_ANTHY not defined, the functions in the libraries are replaced with just "return NULL;" code.
Comment 6 Naohiro Aota gentoo-dev 2012-07-01 11:53:26 UTC
Patch added to the tree.
Comment 7 Maxim Kammerer 2012-07-02 09:46:21 UTC
There is a typo in the ebuild: "--without-friidi", although it doesn't seem to influence anything with USE=-X.
Comment 8 Naohiro Aota gentoo-dev 2012-07-02 22:50:13 UTC
(In reply to comment #7)
> There is a typo in the ebuild: "--without-friidi", although it doesn't seem
> to influence anything with USE=-X.

Fixed.