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 4 votes (vote)
Assignee: Gentoo Toolchain Maintainers
URL: https://wiki.gentoo.org/wiki/Gcc_10_p...
Whiteboard:
Keywords: Tracker
Depends on: 706350 706396 706398 706414 706448 706460 706516 706518 706544 706556 706596 706602 706610 706652 706654 706664 706674 706676 706684 706692 706698 706700 706702 706704 706708 706710 706712 706718 706722 706726 706730 706738 706752 706758 706762 706766 706820 706822 706824 706846 706854 706856 706860 706864 706870 706872 706876 706880 706882 706888 706890 706896 706898 706900 706906 706916 706918 706924 706930 706934 706936 706938 706942 706944 706948 706950 706954 706960 706962 706964 706968 706970 706974 706978 706980 706984 706988 706998 707002 707004 707006 707008 707020 707032 707038 707040 707042 707122 707126 707136 707140 707146 707148 707150 707154 707156 707158 707164 707166 707168 707170 707172 707176 707182 707186 707188 707190 707192 707194 707200 707206 707222 707226 707228 707232 707234 707236 707240 707246 707252 707254 707256 707260 707262 707264 707266 707270 707274 707276 707278 707296 707306 707310 707314 707402 707404 707412 707416 707418 707426 707428 707432 707434 707436 707438 707440 707446 707452 707454 707456 707458 707460 707464 707468 707474 707478 707480 707482 707492 707500 707504 707506 707512 707526 707528 707530 707536 707590 707594 707598 707606 707610 707612 707614 707618 707622 707626 707636 707638 707640 707642 707644 707646 707648 707650 707652 707664 707666 707668 707672 707678 707684 707686 707712 707714 707718 707720 707722 707724 707728 707730 707740 707778 707780 707792 707794 707810 707814 707838 707842 707856 707858 707892 707894 707928 707948 708028 708032 708036 708040 708042 708044 708046 708058 708060 708062 708064 708066 708118 708234 708236 708238 708244 708246 708250 708370 708372 708374 708382 708384 708386 708388 708396 708408 708416 708508 708512 708514 708518 708520 708522 708526 708528 708530 708534 708536 708538 708540 708542 708548 708626 708632 708636 708640 708642 708664 708688 708718 708722 708752 708754 708788 708804 708830 708992 709298 709300 709304 709306 709398 709406 709502 709512 709520 709544 709636 709638 709648 709722 709724 709790 710086 710088 710090 710098 710108 710198 710330 710416 710440 710448 710466 710612 710828 710948 711238 711350 711546 711904 711992 712054 712278 712364 712982 713222 713632 713812 714130 714610 714664 715046 715084 715282 716664 717422 717424 721056 721968 721972 721996 722196 722640 723006 723192 723262 723268 723328 723420 723456 723632 723944 724414 724588 725206 725750 725824 725976 726402 727008 727514 727692 727816 728256 728326 729916 730658 731288 733304 733962 734312 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 706400 706402 706408 706416 706428 706444 706446 706450 706456 706458 706520 706522 706528 706530 706532 706534 706536 706538 706548 706550 706558 706560 706562 706564 706566 706598 706600 706604 706606 706608 706638 706640 706650 706660 706666 706668 706670 706672 706680 706686 706688 706690 706694 706696 706706 706714 706716 706720 706724 706728 706734 706740 706742 706746 706754 706756 706760 706770 706780 706806 706816 706818 706826 706828 706830 706832 706834 706836 706838 706840 706842 706844 706848 706852 706858 706862 706866 706868 706874 706878 706884 706886 706892 706894 706902 706904 706908 706910 706912 706920 706926 706928 706932 706940 706946 706952 706956 706958 706966 706972 706976 706982 706990 706992 706996 707000 707018 707028 707030 707124 707128 707132 707134 707138 707142 707144 707152 707160 707162 707178 707180 707184 707196 707198 707204 707208 707210 707214 707216 707218 707220 707224 707230 707238 707242 707244 707248 707250 707258 707280 707292 707294 707298 707300 707304 707364 707396 707398 707400 707406 707408 707410 707414 707420 707422 707430 707444 707448 707450 707462 707470 707472 707476 707484 707488 707490 707496 707498 707502 707532 707534 707538 707584 707592 707596 707600 707608 707616 707620 707624 707630 707632 707634 707654 707674 707680 707682 707688 707690 707710 707716 707726 707734 707738 707744 707768 707770 707772 707774 707776 707786 707788 707796 707800 707808 707812 707818 707840 707854 707918 707934 707942 707944 707968 707970 708024 708026 708034 708038 708048 708050 708052 708054 708056 708232 708242 708254 708376 708378 708380 708420 708510 708532 708544 708546 708628 708634 708644 708648 708686 708690 708704 708720 708740 708794 708798 708800 708834 708996 709274 709312 709314 709396 709402 709404 709506 709976 710094 710114 710194 710196 710324 710356 710508 710796 710808 710830 710874 710878 710884 710904 710988 710990 711692 711694 711902 711982 712028 712034 712308 712396 712926 713004 713050 713180 713502 713640 713772 713852 713966 714802 715286 716008 716312 716410 716934 719198 719606 719612 719950 720088 720266 720972 720988 721048 721050 721054 721092 721104 721116 721134 721174 721176 721178 721180 721182 721184 721228 721266 721278 721280 721282 721296 721618 721840 721842 721864 721952 721974 722010 722106 722128 722136 722138 722286 722504 722550 722930 723168 723186 723430 724922 725384 725630 726206 726250 726272 726884 727156 728318 730546 734934
Blocks: gcc-10
  Show dependency tree
 
Reported: 2020-01-18 22:40 UTC by Sergei Trofimovich
Modified: 2020-07-31 11:05 UTC (History)
12 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 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 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 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 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 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 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 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.