Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 705764 (-fno-common) - [TRACKER] Packages failing with -fno-common
Summary: [TRACKER] Packages failing with -fno-common
Status: CONFIRMED
Alias: -fno-common
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal with 3 votes (vote)
Assignee: Gentoo Toolchain Maintainers
URL: https://wiki.gentoo.org/wiki/Gcc_10_p...
Whiteboard:
Keywords: Tracker
Depends on: 755533 786663 790425 830101 835640 705730 705834 705836 705840 705868 705870 705878 705880 705882 705884 705896 705898 705900 705902 705904 706000 706098 706130 706132 706196 706232 706234 706256 706258 706286 706288 706312 706314 706316 706320 706348 706356 706358 706366 706390 706392 706394 706396 706398 706400 706402 706408 706414 706416 706428 706444 706446 706448 706450 706456 706458 706460 706516 706518 706520 706522 706528 706530 706532 706534 706536 706538 706544 706548 706550 706558 706560 706562 706564 706566 706596 706598 706600 706602 706604 706606 706608 706610 706638 706640 706650 706652 706654 706660 706664 706666 706668 706670 706672 706674 706676 706680 706684 706686 706688 706690 706692 706694 706696 706698 706700 706704 706706 706708 706710 706712 706714 706716 706718 706720 706722 706724 706726 706728 706730 706734 706738 706740 706742 706746 706752 706754 706756 706758 706760 706762 706766 706770 706780 706806 706816 706818 706820 706822 706824 706826 706828 706830 706832 706834 706836 706838 706840 706842 706844 706846 706848 706852 706854 706856 706858 706860 706862 706864 706866 706868 706870 706872 706874 706876 706878 706880 706882 706884 706886 706888 706890 706892 706894 706896 706898 706900 706902 706904 706906 706908 706910 706912 706916 706918 706920 706924 706926 706928 706930 706932 706934 706936 706938 706940 706942 706944 706946 706948 706950 706952 706954 706956 706958 706960 706962 706964 706966 706968 706970 706972 706974 706976 706978 706980 706982 706984 706988 706990 706992 706996 706998 707000 707002 707004 707006 707008 707018 707020 707028 707030 707032 707038 707040 707042 707122 707124 707126 707128 707132 707134 707136 707138 707140 707142 707144 707146 707148 707150 707152 707154 707156 707158 707160 707162 707164 707166 707168 707170 707172 707176 707178 707180 707182 707184 707186 707188 707190 707192 707194 707196 707198 707200 707204 707206 707208 707210 707214 707216 707218 707220 707222 707224 707226 707228 707230 707232 707234 707236 707238 707240 707242 707244 707246 707248 707250 707252 707254 707256 707258 707260 707262 707264 707266 707270 707274 707276 707278 707280 707292 707294 707296 707298 707300 707304 707306 707310 707314 707364 707396 707398 707400 707402 707404 707406 707408 707410 707412 707414 707416 707418 707420 707422 707426 707428 707430 707432 707434 707436 707438 707440 707444 707446 707448 707450 707452 707454 707456 707458 707460 707462 707464 707468 707470 707472 707474 707476 707478 707480 707482 707484 707488 707490 707492 707496 707498 707500 707502 707504 707506 707512 707526 707528 707530 707532 707534 707536 707538 707584 707590 707592 707594 707596 707598 707600 707606 707608 707610 707612 707614 707616 707618 707620 707622 707624 707626 707630 707632 707634 707636 707638 707640 707642 707644 707646 707648 707650 707652 707654 707664 707666 707668 707672 707674 707678 707680 707682 707684 707686 707688 707690 707710 707712 707714 707716 707718 707720 707722 707724 707726 707728 707730 707734 707738 707740 707744 707768 707770 707772 707774 707776 707778 707780 707786 707788 707792 707794 707796 707800 707808 707810 707812 707814 707818 707838 707840 707842 707854 707856 707858 707892 707894 707918 707928 707934 707942 707944 707948 707968 707970 708024 708026 708028 708032 708034 708036 708038 708040 708042 708044 708046 708048 708050 708052 708054 708056 708058 708060 708062 708064 708066 708118 708232 708234 708236 708238 708242 708244 708246 708250 708254 708370 708372 708374 708376 708378 708380 708382 708384 708386 708388 708396 708408 708416 708420 708508 708510 708512 708514 708518 708520 708522 708526 708528 708530 708532 708534 708536 708538 708540 708542 708544 708546 708548 708626 708628 708632 708634 708636 708640 708642 708644 708648 708664 708686 708688 708690 708704 708718 708720 708722 708740 708752 708754 708788 708794 708798 708800 708804 708830 708834 708992 708996 709274 709298 709300 709304 709306 709312 709314 709396 709398 709402 709404 709406 709502 709506 709512 709520 709544 709636 709638 709648 709722 709724 709790 709976 710086 710088 710090 710094 710098 710108 710114 710194 710196 710198 710324 710330 710356 710416 710440 710448 710466 710508 710612 710796 710808 710828 710830 710874 710878 710884 710904 710948 710988 710990 711238 711350 711546 711692 711694 711902 711904 711982 711992 712028 712034 712054 712278 712308 712364 712396 712926 712982 713004 713050 713180 713222 713502 713632 713640 713772 713812 713852 713966 714130 714610 714664 714802 715046 715084 715282 715286 716008 716312 716410 716664 716934 717422 717424 719198 719606 719612 719950 720088 720266 720972 720988 721048 721050 721054 721056 721092 721104 721116 721134 721174 721176 721178 721180 721182 721184 721228 721266 721278 721280 721282 721296 721618 721840 721842 721864 721952 721968 721972 721974 721996 722010 722106 722128 722136 722138 722196 722286 722504 722550 722618 722626 722640 722730 722930 723006 723168 723186 723192 723262 723268 723328 723420 723430 723456 723632 723944 724414 724588 724922 725384 725630 725750 725824 725976 725988 726206 726250 726272 726402 726560 726884 727008 727156 727514 727692 727816 728256 728318 728326 729916 730546 730658 731288 733304 733962 734312 734934 735274 737538 737694 738186 738272 738402 738614 739160 740382 740874 742407 744154 744475 744745 746347 746488 750401 750404 751259 751718 751877 752006 753032 755092 755311 755374 755539 755566 755764 755770 755773 755779 755785 756172 756235 756820 756847 756901 759322 759409 760387 760830 761343 762038 762745 764077 766306 770352 770442 771030 771093 771582 774333 775134 775314 776571 776775 776781 777381 777540 777582 777843 778419 778572 779016 779694 781929 782388 782823 787842 791091 795069 795078 818280 829144 830473 835379 855986 880665 889698 899452
Blocks: gcc-10
  Show dependency tree
 
Reported: 2020-01-18 22:40 UTC by Sergei Trofimovich (RETIRED)
Modified: 2024-02-19 13:20 UTC (History)
14 users (show)

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


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Sergei Trofimovich (RETIRED) gentoo-dev 2020-01-18 22:40:36 UTC
gcc-10 and above flipped a default from -fcommon to -fno-common: https://gcc.gnu.org/PR85678

A few packages will need to adapt. Usually all it takes is to add a few 'extern' declarations and move definitions from header files to modules.

More details are at https://wiki.gentoo.org/wiki/Gcc_10_porting_notes/fno_common
Comment 1 Martin Väth 2020-01-19 14:15:04 UTC
A rather exhaustive list of failing packages is here:
https://github.com/vaeth/portage-env-mv/blob/master/package.cflags/checks
Comment 2 Sergei Trofimovich (RETIRED) gentoo-dev 2020-01-19 14:39:03 UTC
(In reply to Martin Väth from comment #1)
> A rather exhaustive list of failing packages is here:
> https://github.com/vaeth/portage-env-mv/blob/master/package.cflags/checks

To ease fixing them I suggest filing upstream bugs (and/or gentoo downstream bugs) for packages instead of just linking them here.
Comment 3 Sergei Trofimovich (RETIRED) gentoo-dev 2020-01-19 20:19:59 UTC
SUSE also found a bunch of failures: https://bugzilla.suse.com/show_bug.cgi?id=1160244
Comment 4 Sergei Trofimovich (RETIRED) gentoo-dev 2020-01-19 23:03:37 UTC
Posted heads up to https://archives.gentoo.org/gentoo-dev/message/086ce3c09dda598aa3bdee3fe55a3dca
Comment 5 Shane Peelar 2020-05-07 18:08:21 UTC
FYI: GentooLTO also has a list of `-fno-common` workarounds too: 

https://github.com/InBetweenNames/gentooLTO/blob/05965d113f5da37fc5428de658fb3c25016bf3c9/sys-config/ltoize/files/package.cflags/ltoworkarounds.conf#L272

A few users in the overlay have been running `-fno-common` for quite some time now.
Comment 6 Sergei Trofimovich (RETIRED) gentoo-dev 2020-05-08 20:47:11 UTC
(In reply to Shane Peelar from comment #5)
> FYI: GentooLTO also has a list of `-fno-common` workarounds too: 
> 
> https://github.com/InBetweenNames/gentooLTO/blob/
> 05965d113f5da37fc5428de658fb3c25016bf3c9/sys-config/ltoize/files/package.
> cflags/ltoworkarounds.conf#L272
> 
> A few users in the overlay have been running `-fno-common` for quite some
> time now.

Please report new individual package failures as blockers to this bug.
Comment 7 Shane Peelar 2020-05-10 22:51:18 UTC
(In reply to Sergei Trofimovich from comment #6)
> Please report new individual package failures as blockers to this bug.

Will do.
Comment 8 Shane Peelar 2020-05-10 22:59:48 UTC
It looks like I have about 41 packages to report with `-fcommon` related issues -- is there a convenient way to create bugs for these or will I have to manually enter each individual one?  They're straight from GentooLTO, and they have not been reported here yet.
Comment 9 Sergei Trofimovich (RETIRED) gentoo-dev 2020-05-11 06:34:55 UTC
(In reply to Shane Peelar from comment #8)
> It looks like I have about 41 packages to report with `-fcommon` related
> issues -- is there a convenient way to create bugs for these or will I have
> to manually enter each individual one?  They're straight from GentooLTO, and
> they have not been reported here yet.

Bugs like bug #722286 are not very useful without 'emerge --info' and 'build.log'.

New bugs are easy to create programmatically. An example of pre-filled bugs is https://bugs.gentoo.org/708912#c1. But it's a topic outside of this bug.
Comment 10 Denis Kaganovich 2020-05-17 19:27:06 UTC
FYI: even more bugs in conjunction with "-flto". It affect conftest in libtool configure (global sys-devel/libtool and packaged separately), so variable global_symbol_pipe (in libtool) will be empty.

PS Yes, I know - LTO is not mainstream-supported...
Comment 11 Denis Kaganovich 2020-05-17 20:05:39 UTC
PPS To workaround "-fno-common -flto" problem - simple predefine in make.conf:


lt_cv_sys_global_symbol_pipe='sed -n -e '\''s/^.*[       ]\([ABCDGIRSTW][ABCDGIRSTW]*\)[         ][      ]*\([_A-Za-z][_A-Za-z0-9]*\)$/\1 \2 \2/p'\'' | sed '\''/ __gnu_lto/d'\'''

but better (to avoid copy-paste issues) to take it from here:
https://raw.githubusercontent.com/mahatma-kaganovich/raw/master/profiles/common/_lto/make.defaults
Comment 12 Sergei Trofimovich (RETIRED) gentoo-dev 2020-05-17 21:00:14 UTC
(In reply to Denis Kaganovich from comment #10)
> FYI: even more bugs in conjunction with "-flto". It affect conftest in
> libtool configure (global sys-devel/libtool and packaged separately), so
> variable global_symbol_pipe (in libtool) will be empty.
> 
> PS Yes, I know - LTO is not mainstream-supported...

That is probably a bug #708340. I suggest continuing it there.