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