Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 937969 - sys-devel/gcc-14.1.0: bootstrap-prefix.sh stage3 fails (on Darwin)
Summary: sys-devel/gcc-14.1.0: bootstrap-prefix.sh stage3 fails (on Darwin)
Status: UNCONFIRMED
Alias: None
Product: Gentoo/Alt
Classification: Unclassified
Component: Prefix Support (show other bugs)
Hardware: All Linux
: Normal normal
Assignee: Gentoo Prefix
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2024-08-15 10:39 UTC by APN-Pucky
Modified: 2024-09-30 20:38 UTC (History)
4 users (show)

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


Attachments
build_stage3_STABLE_Darwin_Mac-1723703678884.local_23.6.0_Darwin_Kernel_Version_23.6.0__Mon_Jul_29_21_13_03_PDT_2024;_root_xnu-10063.141.2~1_RELEASE_ARM64_VMAPPLE_arm64_20240815070020.log.xz (build_stage3_STABLE_Darwin_Mac-1723703678884.local_23.6.0_Darwin_Kernel_Version_23.6.0__Mon_Jul_29_21_13_03_PDT_2024;_root_xnu-10063.141.2~1_RELEASE_ARM64_VMAPPLE_arm64_20240815070020.log.xz,68.80 KB, application/x-xz)
2024-08-15 10:39 UTC, APN-Pucky
Details
build log failure (gcc-build-logs.tar.xz,150.95 KB, application/x-xz)
2024-08-19 17:37 UTC, Théophile Cailliau
Details
gcc-14.1.0-build-log (gcc-build-logs.tar.xz,232.14 KB, application/x-xz)
2024-08-19 22:25 UTC, Théophile Cailliau
Details
build_stage3_STABLE_Darwin_Mac-1724566908135.local_23.6.0_Darwin_Kernel_Version_23.6.0__Mon_Jul_29_21_13_03_PDT_2024;_root_xnu-10063.141.2~1_RELEASE_ARM64_VMAPPLE_arm64_20240825065641.log.xz (build_stage3_STABLE_Darwin_Mac-1724566908135.local_23.6.0_Darwin_Kernel_Version_23.6.0__Mon_Jul_29_21_13_03_PDT_2024;_root_xnu-10063.141.2~1_RELEASE_ARM64_VMAPPLE_arm64_20240825065641.log.xz,68.67 KB, application/x-xz)
2024-08-25 10:21 UTC, APN-Pucky
Details
build_stage3_STABLE_Darwin_Mac-1726380708085.local_23.6.0_Darwin_Kernel_Version_23.6.0__Mon_Jul_29_21_13_03_PDT_2024;_root_xnu-10063.141.2~1_RELEASE_ARM64_VMAPPLE_arm64_20240915065926.log.xz (build_stage3_STABLE_Darwin_Mac-1726380708085.local_23.6.0_Darwin_Kernel_Version_23.6.0__Mon_Jul_29_21_13_03_PDT_2024;_root_xnu-10063.141.2~1_RELEASE_ARM64_VMAPPLE_arm64_20240915065926.log.xz,68.56 KB, application/x-xz)
2024-09-15 10:24 UTC, APN-Pucky
Details

Note You need to log in before you can comment on or make changes to this bug.
Description APN-Pucky 2024-08-15 10:39:32 UTC
System:

Darwin_Mac-1723703678884.local_23.6.0_Darwin_Kernel_Version_23.6.0__Mon_Jul_29_21_13_03_PDT_2024;_root_xnu-10063.141.2~1_RELEASE_ARM64_VMAPPLE_arm64 STABLE prefix
Darwin Mac-1723703678884.local 23.6.0 Darwin Kernel Version 23.6.0: Mon Jul 29 21:13:03 PDT 2024; root:xnu-10063.141.2~1/RELEASE_ARM64_VMAPPLE arm64
MD5SUM bootstrap-prefix.sh: MD5 (bootstrap-prefix.sh) = b7188636393e21323a18d33c6293932e

Steps to reproduce the bug:
Run the bootstrap-prefix.sh in mode STABLE (default STABLE) for stage3 (lower ones before)

Error message:
somewhere failed :(  Details might be found in the build log:
  /Users/runner/work/gentoo-prefix-tester/gentoo-prefix-tester/gentoo-prefix/var/tmp/portage/sys-devel/gcc-14.1.0/temp/build.log
I have no clue, really.  Please find friendly folks in #gentoo-prefix on
irc.gentoo.org, gentoo-alt@lists.gentoo.org mailing list, or file a bug
at bugs.gentoo.org under Gentoo/Alt, Prefix Support.  This is most
inconvenient, and it crushed my ego.  Sorry, I give up.
Should you want to give it a try, there is /Users/runner/work/gentoo-prefix-tester/gentoo-prefix-tester/gentoo-prefix/stage3.log

  CHOST:     arm64-apple-darwin23
  IDENT:     arm64-apple-darwin23

Extra info:
https://github.com/APN-Pucky/gentoo-prefix-tester/actions/runs/10399662761
Comment 1 APN-Pucky 2024-08-15 10:39:33 UTC
Created attachment 900212 [details]
build_stage3_STABLE_Darwin_Mac-1723703678884.local_23.6.0_Darwin_Kernel_Version_23.6.0__Mon_Jul_29_21_13_03_PDT_2024;_root_xnu-10063.141.2~1_RELEASE_ARM64_VMAPPLE_arm64_20240815070020.log.xz
Comment 2 Théophile Cailliau 2024-08-19 17:37:53 UTC
Created attachment 900620 [details]
build log failure

I can reproduce this. I've attached the associated logs (2020 M1 macbook pro, Sonoma 14.6.0)
Comment 3 Fabian Groffen gentoo-dev 2024-08-19 21:01:43 UTC
In file included from /Users/fliife/gentoo/var/tmp/portage/sys-devel/gcc-14.1.0/work/gcc-14.1.0/libiberty/floatformat.c:29:
/Users/fliife/gentoo/MacOSX.sdk/usr/include/math.h:54:5: error: #error          "Unsupported value of __FLT_EVAL_METHOD__."
   54 | #   error "Unsupported value of __FLT_EVAL_METHOD__."
      |     ^~~~~
make[3]: *** [Makefile:826: floatformat.o] Error 1


Can you show the output of `ls -la /Library/Developer/CommandLineTools/SDKs/`?

I would expect it to use MacOSX14.sdk but it uses MacOSX.sdk, so I suspect you don't have 14 SDKs installed, and the problem may stem from there.
Comment 4 Théophile Cailliau 2024-08-19 21:17:17 UTC
Here is the directory listing for SDKs:

drwxr-xr-x  7 root  wheel  224 May 31 22:55 .
drwxr-xr-x  5 root  wheel  160 Mar 26 18:33 ..
lrwxr-xr-x  1 root  wheel   14 May 31 22:53 MacOSX.sdk -> MacOSX14.4.sdk
drwxr-xr-x  7 root  wheel  224 May 31 22:55 MacOSX13.3.sdk
lrwxr-xr-x  1 root  wheel   14 May 31 22:52 MacOSX13.sdk -> MacOSX13.3.sdk
drwxr-xr-x  7 root  wheel  224 May 31 22:55 MacOSX14.4.sdk
lrwxr-xr-x  1 root  wheel   14 May 31 22:51 MacOSX14.sdk -> MacOSX14.4.sdk

I use Xcode fairly frequently so I expect this installation to be correct.

In my prefix directory (~/gentoo):

lrwxr-xr-x@  1 fliife  staff      53 May 31 22:07 MacOSX.sdk -> /Library/Developer/CommandLineTools/SDKs/MacOSX14.sdk

So all in all, I'd say this is using the 14.4 SDK.
Comment 5 Fabian Groffen gentoo-dev 2024-08-19 21:18:49 UTC
are you using a recent (the latest) bootstrap-prefix.sh?
Comment 6 Théophile Cailliau 2024-08-19 21:21:44 UTC
This is from May, back then the full install failed because there was an issue with building cmake. Today trying to build the full @system tree failed with gcc. I'll try an install from scratch with the latest bootstrap script and report back.
Comment 7 Théophile Cailliau 2024-08-19 22:25:12 UTC
Created attachment 900726 [details]
gcc-14.1.0-build-log

I'm updating the log for the building failure although I suspect nothing has changed. This is using the latest bootstrap-prefix script, from scratch (I nuked the previous prefix install).

stage1 was successful (although the script did try to download a version of make that isn't available on the distfiles servers, but macOS's make binary was in PATH so all good I guess)

stage2 fails with gcc.
Comment 8 APN-Pucky 2024-08-25 10:21:39 UTC
System:

Darwin_Mac-1724566908135.local_23.6.0_Darwin_Kernel_Version_23.6.0__Mon_Jul_29_21_13_03_PDT_2024;_root_xnu-10063.141.2~1_RELEASE_ARM64_VMAPPLE_arm64 STABLE prefix
Darwin Mac-1724566908135.local 23.6.0 Darwin Kernel Version 23.6.0: Mon Jul 29 21:13:03 PDT 2024; root:xnu-10063.141.2~1/RELEASE_ARM64_VMAPPLE arm64
MD5SUM bootstrap-prefix.sh: MD5 (bootstrap-prefix.sh) = d34be11fb43ea159e21053585becd24f

Steps to reproduce the bug:
Run the bootstrap-prefix.sh in mode STABLE (default STABLE) for stage3 (lower ones before)

Error message:
somewhere failed :(  Details might be found in the build log:
  /Users/runner/work/gentoo-prefix-tester/gentoo-prefix-tester/gentoo-prefix/var/tmp/portage/sys-devel/gcc-14.1.0/temp/build.log
I have no clue, really.  Please find friendly folks in #gentoo-prefix on
irc.gentoo.org, gentoo-alt@lists.gentoo.org mailing list, or file a bug
at bugs.gentoo.org under Gentoo/Alt, Prefix Support.  This is most
inconvenient, and it crushed my ego.  Sorry, I give up.
Should you want to give it a try, there is /Users/runner/work/gentoo-prefix-tester/gentoo-prefix-tester/gentoo-prefix/stage3.log

  CHOST:     arm64-apple-darwin23
  IDENT:     arm64-apple-darwin23

Extra info:
https://github.com/APN-Pucky/gentoo-prefix-tester/actions/runs/10544682107
Comment 9 APN-Pucky 2024-08-25 10:21:40 UTC
Created attachment 901228 [details]
build_stage3_STABLE_Darwin_Mac-1724566908135.local_23.6.0_Darwin_Kernel_Version_23.6.0__Mon_Jul_29_21_13_03_PDT_2024;_root_xnu-10063.141.2~1_RELEASE_ARM64_VMAPPLE_arm64_20240825065641.log.xz
Comment 10 APN-Pucky 2024-09-15 10:24:26 UTC
System:

Darwin_Mac-1726380708085.local_23.6.0_Darwin_Kernel_Version_23.6.0__Mon_Jul_29_21_13_03_PDT_2024;_root_xnu-10063.141.2~1_RELEASE_ARM64_VMAPPLE_arm64 STABLE prefix
Darwin Mac-1726380708085.local 23.6.0 Darwin Kernel Version 23.6.0: Mon Jul 29 21:13:03 PDT 2024; root:xnu-10063.141.2~1/RELEASE_ARM64_VMAPPLE arm64
MD5SUM bootstrap-prefix.sh: MD5 (bootstrap-prefix.sh) = 6d50c676f648c9d403c72bf87d6dc611

Steps to reproduce the bug:
Run the bootstrap-prefix.sh in mode STABLE (default STABLE) for stage3 (lower ones before)

Error message:
somewhere failed :(  Details might be found in the build log:
  /Users/runner/work/gentoo-prefix-tester/gentoo-prefix-tester/gentoo-prefix/var/tmp/portage/sys-devel/gcc-14.1.0/temp/build.log
I have no clue, really.  Please find friendly folks in #gentoo-prefix on
irc.gentoo.org, gentoo-alt@lists.gentoo.org mailing list, or file a bug
at bugs.gentoo.org under Gentoo/Alt, Prefix Support.  This is most
inconvenient, and it crushed my ego.  Sorry, I give up.
Should you want to give it a try, there is /Users/runner/work/gentoo-prefix-tester/gentoo-prefix-tester/gentoo-prefix/stage3.log

  CHOST:     arm64-apple-darwin23
  IDENT:     arm64-apple-darwin23

Extra info:
https://github.com/APN-Pucky/gentoo-prefix-tester/actions/runs/10868701583
Comment 11 APN-Pucky 2024-09-15 10:24:27 UTC
Created attachment 903041 [details]
build_stage3_STABLE_Darwin_Mac-1726380708085.local_23.6.0_Darwin_Kernel_Version_23.6.0__Mon_Jul_29_21_13_03_PDT_2024;_root_xnu-10063.141.2~1_RELEASE_ARM64_VMAPPLE_arm64_20240915065926.log.xz
Comment 12 Pavel Volkovitskiy 2024-09-15 15:09:57 UTC
I had same issue today (M1, Sonoma 14.6.1)

But next time I tried to run
```
env -i /bin/bash --norc --noprofile
```

and also commented out this:
```
        # Update the portage tree.
        estatus "stage3: updating Portage tree"
        treedate=$(date -f "${PORTDIR}"/metadata/timestamp +%s)
        nowdate=$(date +%s)
#       [[ ( ! -e ${PORTDIR}/.unpacked ) && \
#               $((nowdate - (60 * 60 * 24))) -lt ${treedate} ]] || \
#       if [[ ${OFFLINE_MODE} ]]; then
#               # --keep used ${DISTDIR}, which make it easier to download a
#               # snapshot beforehand
#               emerge-webrsync --keep || return 1
#       else
#               emerge --color n --sync || emerge-webrsync || return 1
#       fi
```

After that I was able to successfully bootstrap prefix

Later I was running `emerge --sync` and there was no changes to gcc, so I guess the problem was with some environment variable