freebsd.libcompiler_rt: init

This commit is contained in:
Artemis Tosini
2026-07-14 14:42:01 -04:00
parent 3ab97ded40
commit a1a36bfe71
@@ -0,0 +1,31 @@
{
stdenv,
lib,
mkDerivation,
include,
}:
mkDerivation {
path = "lib/libcompiler_rt";
extraPaths = [
"contrib/llvm-project/compiler-rt"
];
buildInputs = [
include
];
# The build system is importing source files from another directory,
# then trying to put the objects in lib/libcompiler_rt
# It does not create subdirectories in the lib/libcompiler_rt directory.
preBuild = ''
mkdir cpu_model
''
+ lib.optionalString stdenv.hostPlatform.isx86_64 ''
mkdir i386
'';
noLibc = true;
alwaysKeepStatic = true;
}