Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 698534 - sys-devel/gcc-6.4.0-r1 - checking for sys/stat.h... .../work/gcc-6.4.0/libsanitizer/sanitizer_common/sanitizer_platform_limits_posix.cc:153:23: fatal error: sys/ustat.h: No such file or directory
Summary: sys-devel/gcc-6.4.0-r1 - checking for sys/stat.h... .../work/gcc-6.4.0/libsan...
Status: RESOLVED DUPLICATE of bug 685348
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal
Assignee: Gentoo Toolchain Maintainers
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2019-10-25 15:42 UTC by Stephan Litterst
Modified: 2019-10-31 12:08 UTC (History)
1 user (show)

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


Attachments
build.log as bzip2 file (build.log.bz2,337.00 KB, application/x-bzip)
2019-10-25 15:44 UTC, Stephan Litterst
Details
output of emerge --info (emerge.info,7.78 KB, text/plain)
2019-10-25 15:45 UTC, Stephan Litterst
Details
output of emerge -pqv (emerge.pqv,275 bytes, text/plain)
2019-10-25 15:45 UTC, Stephan Litterst
Details
environment (environment.txt,158.23 KB, text/plain)
2019-10-25 15:45 UTC, Stephan Litterst
Details
gcc-build-logs.tar.bz2 (gcc-build-logs.tar.bz2,533.02 KB, application/x-bzip-compressed-tar)
2019-10-25 15:46 UTC, Stephan Litterst
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Stephan Litterst 2019-10-25 15:42:47 UTC
emerge of gcc 6.4.0 failed due to missing ustat.h

I found this in the build.log:
<snip>
checking for sys/stat.h... /var/tmp/portage/sys-devel/gcc-6.4.0-r1/work/gcc-6.4.0/libsanitizer/sanitizer_common/sanitizer_platform_limits_posix.cc:153:23: fatal error: sys/ust
at.h: No such file or directory
 #include <sys/ustat.h>
                       ^
compilation terminated.
make[4]: *** [Makefile:477: sanitizer_platform_limits_posix.lo] Error 1
<snap>

Reproducible: Always

Steps to Reproduce:
1. try to emerge gcc-6.4.0-r1
2.
3.
Comment 1 Stephan Litterst 2019-10-25 15:44:44 UTC
Created attachment 593926 [details]
build.log as bzip2 file
Comment 2 Stephan Litterst 2019-10-25 15:45:14 UTC
Created attachment 593928 [details]
output of emerge --info
Comment 3 Stephan Litterst 2019-10-25 15:45:34 UTC
Created attachment 593930 [details]
output of emerge -pqv
Comment 4 Stephan Litterst 2019-10-25 15:45:50 UTC
Created attachment 593932 [details]
environment
Comment 5 Stephan Litterst 2019-10-25 15:46:21 UTC
Created attachment 593934 [details]
gcc-build-logs.tar.bz2
Comment 6 Sergei Trofimovich (RETIRED) gentoo-dev 2019-10-26 12:34:10 UTC
I think we have fixed it for both 6.4.0-r5 (unstable) and 6.5.0 (stable). Do they not work for you?
Comment 7 Stephan Litterst 2019-10-27 15:14:12 UTC
Hi Sergej,

the bug does not affect gcc 6.5.0 - it affects gcc 6.4.0-r1.

Kind regards,
Stephan
Comment 8 Nuno Silva 2019-10-27 15:20:28 UTC
I can reproduce it with 6.4.0-r1 (I ended up installing 6.5.0). It seems to happen with gcc-4.9.4 as well (4.9.4-r1 builds fine).
Comment 9 Sergei Trofimovich (RETIRED) gentoo-dev 2019-10-27 19:33:13 UTC
(In reply to Stephan Litterst from comment #7)
> Hi Sergej,
> 
> the bug does not affect gcc 6.5.0 - it affects gcc 6.4.0-r1.

Do you need 6.4.0 specifically? It will go away eventually when 6.5.0 is stable on enough platforms.
Comment 10 Stephan Litterst 2019-10-28 05:16:57 UTC
(In reply to Sergei Trofimovich from comment #9)
> (In reply to Stephan Litterst from comment #7)
> > Hi Sergej,
> > 
> > the bug does not affect gcc 6.5.0 - it affects gcc 6.4.0-r1.
> 
> Do you need 6.4.0 specifically? It will go away eventually when 6.5.0 is
> stable on enough platforms.

I had to run an emerge --changed-deps world and run into bug 698188 and now into the bug mentioned in this ticket.

An "equery d sys-devel/gcc-6.4.0-r1" shows me this:

 * These packages depend on sys-devel/gcc-6.4.0-r1:
app-crypt/libb2-0.98.1-r1 (openmp ? >=sys-devel/gcc-4.2[openmp])
app-office/libreoffice-bin-6.2.5.2 (>=sys-devel/gcc-8.3.0)
app-portage/portage-utils-0.80 (openmp ? >=sys-devel/gcc-4.2[openmp])
dev-db/mariadb-10.2.22-r1 (>=sys-devel/gcc-3.4.6)
dev-java/icedtea-bin-3.13.0 (>=sys-devel/gcc-8.3.0[multilib?])
games-puzzle/world-of-goo-1.41-r2 (>=sys-devel/gcc-3.4)
media-libs/libmypaint-1.3.0-r1 (openmp ? sys-devel/gcc[openmp])
media-libs/mesa-19.1.7 (opencl ? >=sys-devel/gcc-4.6)
net-libs/webkit-gtk-2.24.4 (>=sys-devel/gcc-6.0)
sys-devel/llvm-8.0.1 (>=sys-devel/gcc-3.0)
sys-libs/glibc-2.29-r2 (>=sys-devel/gcc-6)

The output of "eselect gcc list":
 [1] x86_64-pc-linux-gnu-6.4.0
 [2] x86_64-pc-linux-gnu-8.3.0 *

Hope this helps.
Comment 11 Sergei Trofimovich (RETIRED) gentoo-dev 2019-10-28 07:25:53 UTC
(In reply to Stephan Litterst from comment #10)
> (In reply to Sergei Trofimovich from comment #9)
> > (In reply to Stephan Litterst from comment #7)
> > > Hi Sergej,
> > > 
> > > the bug does not affect gcc 6.5.0 - it affects gcc 6.4.0-r1.
> > 
> > Do you need 6.4.0 specifically? It will go away eventually when 6.5.0 is
> > stable on enough platforms.
> 
> I had to run an emerge --changed-deps world and run into bug 698188 and now
> into the bug mentioned in this ticket.
> 
> An "equery d sys-devel/gcc-6.4.0-r1" shows me this:
> 
>  * These packages depend on sys-devel/gcc-6.4.0-r1:
> app-crypt/libb2-0.98.1-r1 (openmp ? >=sys-devel/gcc-4.2[openmp])
> app-office/libreoffice-bin-6.2.5.2 (>=sys-devel/gcc-8.3.0)
> app-portage/portage-utils-0.80 (openmp ? >=sys-devel/gcc-4.2[openmp])
> dev-db/mariadb-10.2.22-r1 (>=sys-devel/gcc-3.4.6)
> dev-java/icedtea-bin-3.13.0 (>=sys-devel/gcc-8.3.0[multilib?])
> games-puzzle/world-of-goo-1.41-r2 (>=sys-devel/gcc-3.4)
> media-libs/libmypaint-1.3.0-r1 (openmp ? sys-devel/gcc[openmp])
> media-libs/mesa-19.1.7 (opencl ? >=sys-devel/gcc-4.6)
> net-libs/webkit-gtk-2.24.4 (>=sys-devel/gcc-6.0)
> sys-devel/llvm-8.0.1 (>=sys-devel/gcc-3.0)
> sys-libs/glibc-2.29-r2 (>=sys-devel/gcc-6)
> 
> The output of "eselect gcc list":
>  [1] x86_64-pc-linux-gnu-6.4.0
>  [2] x86_64-pc-linux-gnu-8.3.0 *
> 
> Hope this helps.

If the only reason you have gcc-6 is because portage did not clean it up for you automatically you might want to remove unused deps with 'emerge --depclean'.
Comment 12 Stephan Litterst 2019-10-30 20:16:40 UTC
(In reply to Sergei Trofimovich from comment #11)
> If the only reason you have gcc-6 is because portage did not clean it up for
> you automatically you might want to remove unused deps with 'emerge
> --depclean'.

I always do an emerge --depclean.
Comment 13 Sergei Trofimovich (RETIRED) gentoo-dev 2019-10-30 21:34:50 UTC
(In reply to Stephan Litterst from comment #12)
> (In reply to Sergei Trofimovich from comment #11)
> > If the only reason you have gcc-6 is because portage did not clean it up for
> > you automatically you might want to remove unused deps with 'emerge
> > --depclean'.
> 
> I always do an emerge --depclean.

If 'emerge --depclean' still does not remove gcc-6 you'll need to find what retains it. Probable candidate is a world entry, for example:
    $ fgrep gcc /var/lib/portage/world
Comment 14 josef.95 2019-10-30 22:31:50 UTC
Yes, or try
emerge -av --depclean sys-devel/gcc:6.4.0
it should show the reverse dependencies.
Comment 15 Stephan Litterst 2019-10-31 07:09:59 UTC
I tried both:

fgrep gcc /var/lib/portage/world
sys-devel/gcc
sys-devel/gcc:6.4.0

and:

emerge -av --depclean sys-devel/gcc:6.4.0

Calculating dependencies... done!
>>> Calculating removal order...

>>> These are the packages that would be unmerged:

 sys-devel/gcc
    selected: 6.4.0-r1 
   protected: none 
     omitted: 8.3.0-r1 

All selected packages: =sys-devel/gcc-6.4.0-r1

>>> 'Selected' packages are slated for removal.
>>> 'Protected' and 'omitted' packages will not be removed.

So I removed gcc:6.4.0 and luckily an emerge -uD --changed-deps world does not want to re-emerge it again.

Strangely equery still shows me packages depending on the old gcc:

equery d sys-devel/gcc-6.4.0-r1
 * These packages depend on sys-devel/gcc-6.4.0-r1:
app-crypt/libb2-0.98.1-r1 (openmp ? >=sys-devel/gcc-4.2[openmp])
app-office/libreoffice-bin-6.2.5.2 (>=sys-devel/gcc-8.3.0)
app-portage/portage-utils-0.80 (openmp ? >=sys-devel/gcc-4.2[openmp])
dev-db/mariadb-10.2.22-r1 (>=sys-devel/gcc-3.4.6)
dev-java/icedtea-bin-3.13.0 (>=sys-devel/gcc-8.3.0[multilib?])
games-puzzle/world-of-goo-1.41-r2 (>=sys-devel/gcc-3.4)
media-libs/libmypaint-1.3.0-r1 (openmp ? sys-devel/gcc[openmp])
media-libs/mesa-19.1.7 (opencl ? >=sys-devel/gcc-4.6)
net-libs/webkit-gtk-2.24.4 (>=sys-devel/gcc-6.0)
sys-devel/llvm-8.0.1 (>=sys-devel/gcc-3.0)
sys-libs/glibc-2.29-r2 (>=sys-devel/gcc-6)

Do you know why?
Comment 16 Sergei Trofimovich (RETIRED) gentoo-dev 2019-10-31 07:29:40 UTC
(In reply to Stephan Litterst from comment #15)
> I tried both:
> 
> fgrep gcc /var/lib/portage/world
> sys-devel/gcc
> sys-devel/gcc:6.4.0



> Strangely equery still shows me packages depending on the old gcc:
> 
> equery d sys-devel/gcc-6.4.0-r1
>  * These packages depend on sys-devel/gcc-6.4.0-r1:
> app-crypt/libb2-0.98.1-r1 (openmp ? >=sys-devel/gcc-4.2[openmp])
> app-office/libreoffice-bin-6.2.5.2 (>=sys-devel/gcc-8.3.0)
> app-portage/portage-utils-0.80 (openmp ? >=sys-devel/gcc-4.2[openmp])
> dev-db/mariadb-10.2.22-r1 (>=sys-devel/gcc-3.4.6)
> dev-java/icedtea-bin-3.13.0 (>=sys-devel/gcc-8.3.0[multilib?])
> games-puzzle/world-of-goo-1.41-r2 (>=sys-devel/gcc-3.4)
> media-libs/libmypaint-1.3.0-r1 (openmp ? sys-devel/gcc[openmp])
> media-libs/mesa-19.1.7 (opencl ? >=sys-devel/gcc-4.6)
> net-libs/webkit-gtk-2.24.4 (>=sys-devel/gcc-6.0)
> sys-devel/llvm-8.0.1 (>=sys-devel/gcc-3.0)
> sys-libs/glibc-2.29-r2 (>=sys-devel/gcc-6)
> 
> Do you know why?

equery does not tell you that. If we look at glibc as an example:

    sys-libs/glibc-2.29-r2 (>=sys-devel/gcc-6)

it says that glibc depends on any >=gcc-6 be it gcc-6,7 or 8. sys-devel/gcc-6.4.0-r1 happens to match >=gcc-6 as well. equery does not do more thant that. There is no redundancy checks against multislot installs.

*** This bug has been marked as a duplicate of bug 685348 ***
Comment 17 Stephan Litterst 2019-10-31 08:34:42 UTC
(In reply to Sergei Trofimovich from comment #16)
> 
> equery does not tell you that. If we look at glibc as an example:
> 
>     sys-libs/glibc-2.29-r2 (>=sys-devel/gcc-6)
> 
> it says that glibc depends on any >=gcc-6 be it gcc-6,7 or 8.
> sys-devel/gcc-6.4.0-r1 happens to match >=gcc-6 as well. equery does not do
> more thant that. There is no redundancy checks against multislot installs.
> 

Good to know :-)
Thanks a lot for your help!