mirror of
https://github.com/c3lang/c3c.git
synced 2026-02-27 12:01:16 +00:00
@@ -383,17 +383,24 @@ static const char *find_linux_crt(void)
|
||||
{
|
||||
if (compiler.build.linuxpaths.crt) return compiler.build.linuxpaths.crt;
|
||||
const char *arch_linux_crt1_path = "/usr/lib/crt1.o";
|
||||
const char *arch_linux_64_crt1_path = "/usr/lib64/crt1.o";
|
||||
if (file_exists(arch_linux_crt1_path))
|
||||
{
|
||||
const char *arch_linux_path = "/usr/lib";
|
||||
INFO_LOG("Found crt at %s", arch_linux_path);
|
||||
return arch_linux_path;
|
||||
}
|
||||
if (file_exists(arch_linux_64_crt1_path))
|
||||
{
|
||||
const char* arch_linux_path = "/usr/lib64";
|
||||
INFO_LOG("Found crt at %s", arch_linux_path);
|
||||
return arch_linux_path;
|
||||
}
|
||||
const char *arch_glob_path = get_linux_crt_arch_glob();
|
||||
const char *path = find_arch_glob_path(arch_glob_path, 6);
|
||||
if (!path)
|
||||
{
|
||||
INFO_LOG("No crt in /usr/lib/*/");
|
||||
INFO_LOG("No crt in /usr/{lib,lib64}/*/");
|
||||
return NULL;
|
||||
}
|
||||
INFO_LOG("Found crt at %s", path);
|
||||
|
||||
Reference in New Issue
Block a user