forked from lix-project/lix
Fix tests on systems with a non-master git defaultBranch #1
3 changed files with 21 additions and 4 deletions
11
flake.nix
11
flake.nix
|
@ -99,9 +99,10 @@
|
||||||
];
|
];
|
||||||
|
|
||||||
stdenvs = [
|
stdenvs = [
|
||||||
"gccStdenv"
|
# see assertion in package.nix why these two are disabled
|
||||||
|
# "stdenv"
|
||||||
|
# "gccStdenv"
|
||||||
"clangStdenv"
|
"clangStdenv"
|
||||||
"stdenv"
|
|
||||||
"libcxxStdenv"
|
"libcxxStdenv"
|
||||||
"ccacheStdenv"
|
"ccacheStdenv"
|
||||||
];
|
];
|
||||||
|
@ -121,7 +122,11 @@
|
||||||
name = "${stdenvName}Packages";
|
name = "${stdenvName}Packages";
|
||||||
value = f stdenvName;
|
value = f stdenvName;
|
||||||
}) stdenvs
|
}) stdenvs
|
||||||
);
|
)
|
||||||
|
// {
|
||||||
|
# TODO delete this and reënable gcc stdenvs once gcc compiles kj coros correctly
|
||||||
|
stdenvPackages = f "clangStdenv";
|
||||||
|
};
|
||||||
|
|
||||||
# Memoize nixpkgs for different platforms for efficiency.
|
# Memoize nixpkgs for different platforms for efficiency.
|
||||||
nixpkgsFor = forAllSystems (
|
nixpkgsFor = forAllSystems (
|
||||||
|
|
10
meson.build
10
meson.build
|
@ -167,10 +167,18 @@ endif
|
||||||
# frees one would expect when the objects are unique_ptrs. these problems
|
# frees one would expect when the objects are unique_ptrs. these problems
|
||||||
# often show up as memory corruption when nesting generators (since we do
|
# often show up as memory corruption when nesting generators (since we do
|
||||||
# treat generators like owned memory) and will cause inexplicable crashs.
|
# treat generators like owned memory) and will cause inexplicable crashs.
|
||||||
|
#
|
||||||
|
# gcc 13 does not compile capnp coroutine code correctly. a newer version
|
||||||
|
# may fix this. (cf. https://gcc.gnu.org/bugzilla/show_bug.cgi?id=102051)
|
||||||
|
# we allow gcc 13 here anyway because CI uses it for clang-tidy, and when
|
||||||
|
# the compiler crashes outright if won't produce any bad binaries either.
|
||||||
assert(
|
assert(
|
||||||
cxx.get_id() != 'gcc' or cxx.version().version_compare('>=13'),
|
cxx.get_id() != 'gcc' or cxx.version().version_compare('>=13'),
|
||||||
'GCC 12 and earlier are known to miscompile lix coroutines, use GCC 13 or clang.'
|
'GCC is known to miscompile coroutines, use clang.'
|
||||||
)
|
)
|
||||||
|
if cxx.get_id() == 'gcc'
|
||||||
|
warning('GCC is known to crash while building coroutines, use clang.')
|
||||||
|
endif
|
||||||
|
|
||||||
|
|
||||||
# Translate some historical and Mesony CPU names to Lixy CPU names.
|
# Translate some historical and Mesony CPU names to Lixy CPU names.
|
||||||
|
|
|
@ -90,6 +90,10 @@
|
||||||
capnproto-lix = capnproto.overrideAttrs { CXXFLAGS = "-std=c++20"; };
|
capnproto-lix = capnproto.overrideAttrs { CXXFLAGS = "-std=c++20"; };
|
||||||
},
|
},
|
||||||
}:
|
}:
|
||||||
|
|
||||||
|
# gcc miscompiles coroutines at least until 13.2, possibly longer
|
||||||
|
assert stdenv.cc.isClang || lintInsteadOfBuild;
|
||||||
|
|
||||||
let
|
let
|
||||||
inherit (__forDefaults) canRunInstalled;
|
inherit (__forDefaults) canRunInstalled;
|
||||||
inherit (lib) fileset;
|
inherit (lib) fileset;
|
||||||
|
|
Loading…
Reference in a new issue