“‘FILE’ does not name a type” with gcc and -Denable-pch-std=false #410
Labels
No labels
Area/build-packaging
Area/cli
Area/evaluator
Area/flakes
Area/language
Area/profiles
Area/protocol
Area/releng
Area/remote-builds
Area/repl
Area/store
bug
Cross Compilation
devx
docs
Downstream Dependents
E/easy
E/hard
E/help wanted
E/reproducible
E/requires rearchitecture
imported
Needs Langver
OS/Linux
OS/macOS
performance
regression
release-blocker
RFD
stability
Status
blocked
Status
invalid
Status
postponed
Status
wontfix
testing
testing/flakey
ux
No milestone
No project
No assignees
4 participants
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference: lix-project/lix#410
Loading…
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
src/libcmd/repl.cc fails to compile under the default shell, but compiles ok under the native-clangStdenvPackages shell. not sure why this doesn’t happen in ci, which also uses the gcc-based shell.
Steps To Reproduce
nix develop
ornix-shell
just clean
meson setup build --prefix="$PWD/outputs/out" $mesonFlags
(notjust setup
!)just install
nix --version
outputnix (Nix) 2.18.1
Additional context
error below; adding
#include <cstdio>
to the top of the offending file fixes the problem for me.that's very strange. we've never seen this happen even with gcc shells. can you give more details on your setup?
(this looks like it's an editline bug more than a lix bug, perhaps there's some platform weirdness goin on that ci doesn't have?)
could this be covered over somehow by our pch implementation which is disabled in gcc dev shells by default? if so that's busted of course. not saying it is for sure but that's my shot in the dark.
i’m currently on nixos 23.11 (46397778ef1f7) with nix 2.18.1, but my original repro was incorrect, because i retconned it from the manual
meson setup
command we had in hacking.md tojust setup
… but it turns out that no longer passes the$mesonFlags
generated by package.nix, and the error no longer occurs. i’ve updated the repro now.i think so! if i run meson setup with all of the
$mesonFlags
except-Denable-pch-std=false
, the error goes away:“‘FILE’ does not name a type” when building with gcc locallyto “‘FILE’ does not name a type” with gcc and -Denable-pch-std=falsefixed upstream in troglobit/editline#57, but their latest release is still 1.17.1 (and so is nixpkgs)
This issue was mentioned on Gerrit on the following CLs: