Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 462232 - x11-libs/motif-2.3.4-r1 fails with USE xft: error: undefined reference to 'FcPatternCreate'
Summary: x11-libs/motif-2.3.4-r1 fails with USE xft: error: undefined reference to 'Fc...
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: AMD64 Linux
: Normal normal (vote)
Assignee: Ulrich Müller
URL:
Whiteboard:
Keywords:
Depends on:
Blocks: underlinking
  Show dependency tree
 
Reported: 2013-03-18 17:03 UTC by Adrian Bassett
Modified: 2013-03-18 21:48 UTC (History)
1 user (show)

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


Attachments
build log for failing motif-2.3.4-r1 (x11-libs:motif-2.3.4-r1:20130316-115954.log,458.20 KB, text/plain)
2013-03-18 17:41 UTC, Adrian Bassett
Details
emerge --info (emerge_info,10.15 KB, text/plain)
2013-03-18 17:43 UTC, Adrian Bassett
Details
motif-2.3.4-fontconfig-config.patch (fontconfig-config.patch,438 bytes, patch)
2013-03-18 20:04 UTC, Ulrich Müller
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Adrian Bassett 2013-03-18 17:03:58 UTC
x11-libs/motif build now fails at linking stage unless USE="xft" is changed to USE="-xft".  This is while upgrading to 2.3.4-r1 although the previously successful version, 2.3.4, also now fails with USE="xft" (I haven't tested that version of the ebuild with -xft):

libtool: link: x86_64-pc-linux-gnu-gcc -O2 -march=core2 -mtune=core2 -mmmx -msse -msse2 -msse3 -mssse3 -msse4.1 -mfpmath=sse -pipe -frecord-gcc-switches -fno-strict-aliasing -Wall -g -fno-strict-aliasing -Wno-unused -Wno-comment -fno-tree-ter -I/usr/include/freetype2 -Wl,-O1 -o .libs/wmldbcreate wmldbcreate.o  -Wl,--as-needed ../../lib/Xm/.libs/libXm.so -lXmu -lXt -lXext -lX11 -lXp -lXft -ljpeg -lpng
../../lib/Xm/.libs/libXm.so: error: undefined reference to 'FcPatternDestroy'
../../lib/Xm/.libs/libXm.so: 

error: undefined reference to 'FcPatternCreate'
../../lib/Xm/.libs/libXm.so: error: undefined reference to 'FcPatternAddString'
../../lib/Xm/.libs/libXm.so: error: undefined reference to 'FcPatternAddInteger'
collect2: error: ld returned 1 exit status

There is a change in the xft dependency between the two motif ebuilds from:

xft? ( x11-libs/libXft )

to

xft? ( x11-libs/libXft[${MULTILIB_USEDEP}] )

which is presumably the reason for my problem in that I now have ABI_X86="64 32" set in make.conf on ~amd64, where app-emulation/emul-linux-x86-xlibs-20130224-r1 is unmasked and the various packages (including libXft) which have had multilib functionality enabled have been rebuilt accordingly.  

I am also seeing the same problem on ~x86 where by analogy make.conf has ABI_X86="32".  (Not sure how necessary that is in a non-multilib environment but commenting it doesn't solve the current problem.)


Reproducible: Always
Comment 1 Adrian Bassett 2013-03-18 17:07:52 UTC
(In reply to comment #0)

The output from the build log appears to have got corrupted somehow.  Should read:

libtool: link: x86_64-pc-linux-gnu-gcc -O2 -march=core2 -mtune=core2 -mmmx -msse -msse2 -msse3 -mssse3 -msse4.1 -mfpmath=sse -pipe -frecord-gcc-switches -fno-strict-aliasing -Wall -g -fno-strict-aliasing -Wno-unused -Wno-comment -fno-tree-ter -I/usr/include/freetype2 -Wl,-O1 -o .libs/wmldbcreate wmldbcreate.o  -Wl,--as-needed ../../lib/Xm/.libs/libXm.so -lXmu -lXt -lXext -lX11 -lXp -lXft -ljpeg -lpng
../../lib/Xm/.libs/libXm.so: error: undefined reference to 'FcPatternDestroy'
../../lib/Xm/.libs/libXm.so: error: undefined reference to 'FcPatternCreate'
../../lib/Xm/.libs/libXm.so: error: undefined reference to 'FcPatternAddString'
../../lib/Xm/.libs/libXm.so: error: undefined reference to 'FcPatternAddInteger'
collect2: error: ld returned 1 exit status
Comment 2 Ulrich Müller gentoo-dev 2013-03-18 17:24:11 UTC
Please attach the full build.log and emerge --info.
Comment 3 Adrian Bassett 2013-03-18 17:41:19 UTC
Created attachment 342564 [details]
build log for failing motif-2.3.4-r1
Comment 4 Adrian Bassett 2013-03-18 17:43:37 UTC
Created attachment 342566 [details]
emerge --info
Comment 5 Ulrich Müller gentoo-dev 2013-03-18 19:54:52 UTC
(In reply to comment #0)
> [...] the previously successful version, 2.3.4, also now fails with
> USE="xft" [...]

motif-2.3.4 (-r0) isn't multilib-enabled, so it's unlikely that this is a multilib issue.

However, the telltale sign is found in the emerge --info:

   ld GNU gold (GNU Binutils 2.23.1) 1.11

It is known that the gold linker is picky about underlinking. The missing Fc* symbols are from libfontconfig which isn't explicitly specified, but only indirectly via libXft.

In fact, the problem is much earlier, in configure:

   checking for fontconfig-config... no
   checking fontconfig/fontconfig.h usability... yes
   checking fontconfig/fontconfig.h presence... yes
   checking for fontconfig/fontconfig.h... yes
   checking for FcInit... no

The fontconfig-config program doesn't exist any more. "pkg-config fontconfig" should be used instead.
Comment 6 Ulrich Müller gentoo-dev 2013-03-18 20:04:48 UTC
Created attachment 342574 [details, diff]
motif-2.3.4-fontconfig-config.patch

Please test if attached patch fixes the problem.

The ebuild uses epatch_user, so if you save the patch in /etc/portage/patches/x11-libs/motif-2.3.4/fontconfig-config.patch it should be picked up from there.
Comment 7 Adrian Bassett 2013-03-18 20:19:42 UTC
(In reply to comment #6)

> Please test if attached patch fixes the problem.
> 
> The ebuild uses epatch_user, so if you save the patch in
> /etc/portage/patches/x11-libs/motif-2.3.4/fontconfig-config.patch it should
> be picked up from there.

Patch installed as suggested.  x11-libs/motif-2.3.4-r1 now installs OK with USE="xft".  Thanks.
Comment 8 Ulrich Müller gentoo-dev 2013-03-18 21:42:12 UTC
Reported upstream: http://bugs.motifzone.net/show_bug.cgi?id=1593
Comment 9 Ulrich Müller gentoo-dev 2013-03-18 21:48:04 UTC
Fixed without revbump.
Thank you for reporting!