Created attachment 470442 [details, diff] libhugetlbfs-2.18-gcc5.patch After upgrading to the new stable sys-devel/gcc-5.4.0-r3, sys-libs/libhugetlbfs-2.18 fails to compile: hugeutils.c: In function '__lh_hugetlbfs_setup_env': hugeutils.c:304:40: error: expected identifier or '(' before 'restrict' char *p, *tok, *exe, buf[MAX_EXE+1], restrict[MAX_EXE]; ^ hugeutils.c:309:11: error: expected expression before 'restrict' strncpy(restrict, env, sizeof restrict); ^ hugeutils.c:309:3: error: too few arguments to function 'strncpy' strncpy(restrict, env, sizeof restrict); ^ hugeutils.c:310:11: error: expected identifier or '(' before '[' token restrict[sizeof(restrict)-1] = 0; ^ hugeutils.c:311:12: error: expected expression before 'restrict' for (p = restrict; (tok = strtok(p, ":")) != NULL; p = NULL) { ^ Attached patch renames that variable from "register" to "register_". PS: The ebuild is also missing a call to epatch_user.
(In reply to Jaak Ristioja from comment #0) > Attached patch renames that variable from "register" to "register_". Sry, I meant from "restrict" to "restrict_".
This should be fixed in version 2.20. Do you specifically need version 2.18?
(In reply to Felix Janda from comment #2) > This should be fixed in version 2.20. Do you specifically need version 2.18? I have no idea. I just ran into this bug right after gcc-5.4.0-r3 was stabilized. Maybe you should then consider stabilizing libhugetlbfs-2.20 as well?
No version of sys-libs/libhugetlbfs is stable but you could request the latest version to be stabilized.
(In reply to Felix Janda from comment #4) > No version of sys-libs/libhugetlbfs is stable but you could request the > latest version to be stabilized. Ah ok. My bad for not noticing this. I can confirm that 2.20 emerges properly. So as it turns out this is no longer a big issue. Feel free to resolve this as WONTFIX or however you see fit. Thanks!
Given its getting increasingly unlikely that people will be using GCC < 5.0, it may be smart to consider dropping versions older than 2.20 Maintainers choice though ofc.