Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 631920 - media-libs/fontconfig-2.12.6 - fcobjs.c:33:0: fcobjshash.gperf:28:1: error: conflicting types for 'FcObjectTypeHash'
Summary: media-libs/fontconfig-2.12.6 - fcobjs.c:33:0: fcobjshash.gperf:28:1: error: c...
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: Gentoo Fonts Team
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2017-09-24 10:07 UTC by Erich Seifert
Modified: 2017-11-28 00:59 UTC (History)
7 users (show)

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


Attachments
build.log (media-libs:fontconfig-2.12.6:20170924-095743.log,144.88 KB, text/x-log)
2017-09-24 10:07 UTC, Erich Seifert
Details
>=gperf-3.1 is needed (Bug #631980) (fontconfig-2.12.6-r1.ebuild.patch,827 bytes, patch)
2017-09-25 21:17 UTC, Jiří Moravec
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Erich Seifert 2017-09-24 10:07:26 UTC
Created attachment 496260 [details]
build.log

When updating from media-libs/fontconfig-2.12.4 to media-libs/fontconfig-2.12.6, emerge fails with:

In file included from /var/tmp/portage/media-libs/fontconfig-2.12.6/work/fontconfig-2.12.6/src/fcobjs.c:33:0:
fcobjshash.gperf:28:1: error: conflicting types for 'FcObjectTypeHash'
 "aspect",FC_ASPECT_OBJECT
 ^

This could be related to https://bugs.freedesktop.org/show_bug.cgi?id=101280
Comment 1 Jiří Moravec 2017-09-24 12:24:08 UTC
Same problem:
...
In file included from /var/tmp/portage/media-libs/fontconfig-2.12.6/work/fontconfig-2.12.6/src/fcobjs.c:33:0:
fcobjshash.gperf:28:1: error: conflicting types for ‘FcObjectTypeHash’
 "aspect",FC_ASPECT_OBJECT
 ^~~~~~~~~~~~~~~~
/var/tmp/portage/media-libs/fontconfig-2.12.6/work/fontconfig-2.12.6/src/fcobjs.c:28:1: note: previous declaration of ‘FcObjectTypeHash’ was here
 FcObjectTypeHash (register const char *str, register FC_GPERF_SIZE_T len);
 ^~~~~~~~~~~~~~~~
In file included from /var/tmp/portage/media-libs/fontconfig-2.12.6/work/fontconfig-2.12.6/src/fcobjs.c:33:0:
fcobjshash.gperf:166:1: error: conflicting types for ‘FcObjectTypeLookup’
/var/tmp/portage/media-libs/fontconfig-2.12.6/work/fontconfig-2.12.6/src/fcobjs.c:31:1: note: previous declaration of ‘FcObjectTypeLookup’ was here
 FcObjectTypeLookup (register const char *str, register FC_GPERF_SIZE_T len);
 ^~~~~~~~~~~~~~~~~~
make[3]: *** [Makefile:642: fcobjs.lo] Error 1
...
Comment 2 Fabian Groffen gentoo-dev 2017-09-25 07:49:00 UTC
does it compile if you add this to src_prepare:

rm src/fcobjshash.h src/fcobjshash.gperf

(from the bug you refer to)
Comment 3 Erich Seifert 2017-09-25 08:09:31 UTC
(In reply to Fabian Groffen from comment #2)
> does it compile if you add this to src_prepare:
> 
> rm src/fcobjshash.h src/fcobjshash.gperf
> 
> (from the bug you refer to)

Yes, it does. src/fcobjshash.gperf does not exist, but removing src/fcobjshash.h in src_prepare obviously resolves the issue.
Comment 4 Jiří Moravec 2017-09-25 16:50:55 UTC
It's look like reincarnated https://bugs.freedesktop.org/show_bug.cgi?id=101280
So this rm needs to be unconditional. Just like:

src_prepare() {
        default
        eautoreconf

        # https://bugs.freedesktop.org/show_bug.cgi?id=101280
        rm -f src/fcobjshash.h src/fcobjshash.gperf
}
Comment 5 Jiří Moravec 2017-09-25 21:17:59 UTC
Created attachment 496412 [details, diff]
>=gperf-3.1 is needed (Bug #631980)
Comment 6 Jiří Moravec 2017-09-25 21:21:04 UTC
As was pointed out by Fabian Groffen in https://bugs.gentoo.org/631980#c0
compatible version of gperf (>=3.1) is only one thing necessary for successful compilation of this fontconfig version.
Comment 7 Austin English (RETIRED) gentoo-dev 2017-10-04 18:14:18 UTC
(In reply to Jiří Moravec from comment #6)
> As was pointed out by Fabian Groffen in https://bugs.gentoo.org/631980#c0
> compatible version of gperf (>=3.1) is only one thing necessary for
> successful compilation of this fontconfig version.

I can confirm that. fontconfig-2.12.6 fails to build on my ~amd64 machine, with gperf-3.0 installed (even with the export GPERF=true hack). Upgrading to gperf-3.1 first allows fontconfig-2.12.6 to build.
Comment 8 Fabian Groffen gentoo-dev 2017-10-05 10:49:21 UTC
gperf version mismatch appears to be the problem.
Comment 9 Fabian Groffen gentoo-dev 2017-10-05 12:54:14 UTC
Configure still tries to figure out some characteristics of the gperf installed on the system.  I've added a fix to work around this, and use the declaration as used by the generated sources.

Please check if this fixes the issue for you too.
Comment 10 Austin English (RETIRED) gentoo-dev 2017-11-28 00:59:52 UTC
(In reply to Fabian Groffen from comment #9)
> Configure still tries to figure out some characteristics of the gperf
> installed on the system.  I've added a fix to work around this, and use the
> declaration as used by the generated sources.
> 
> Please check if this fixes the issue for you too.

https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=7c8681b31ece2afde603069c09b5731e5cd70d11 fixes it for me, thanks.