mirror of
https://github.com/Ed94/Odin.git
synced 2026-06-25 15:05:00 -07:00
@@ -18,6 +18,7 @@ enum TargetOsKind : u16 {
|
||||
TargetOs_essence,
|
||||
TargetOs_freebsd,
|
||||
TargetOs_openbsd,
|
||||
TargetOs_netbsd,
|
||||
TargetOs_haiku,
|
||||
|
||||
TargetOs_wasi,
|
||||
@@ -84,6 +85,7 @@ gb_global String target_os_names[TargetOs_COUNT] = {
|
||||
str_lit("essence"),
|
||||
str_lit("freebsd"),
|
||||
str_lit("openbsd"),
|
||||
str_lit("netbsd"),
|
||||
str_lit("haiku"),
|
||||
|
||||
str_lit("wasi"),
|
||||
@@ -1020,6 +1022,13 @@ gb_global TargetMetrics target_openbsd_amd64 = {
|
||||
str_lit("x86_64-unknown-openbsd-elf"),
|
||||
};
|
||||
|
||||
gb_global TargetMetrics target_netbsd_amd64 = {
|
||||
TargetOs_netbsd,
|
||||
TargetArch_amd64,
|
||||
8, 8, AMD64_MAX_ALIGNMENT, 16,
|
||||
str_lit("x86_64-unknown-netbsd-elf"),
|
||||
};
|
||||
|
||||
gb_global TargetMetrics target_haiku_amd64 = {
|
||||
TargetOs_haiku,
|
||||
TargetArch_amd64,
|
||||
@@ -1127,6 +1136,7 @@ gb_global NamedTargetMetrics named_targets[] = {
|
||||
{ str_lit("freebsd_arm64"), &target_freebsd_arm64 },
|
||||
|
||||
{ str_lit("openbsd_amd64"), &target_openbsd_amd64 },
|
||||
{ str_lit("netbsd_amd64"), &target_netbsd_amd64 },
|
||||
{ str_lit("haiku_amd64"), &target_haiku_amd64 },
|
||||
|
||||
{ str_lit("freestanding_wasm32"), &target_freestanding_wasm32 },
|
||||
@@ -1886,6 +1896,8 @@ gb_internal void init_build_context(TargetMetrics *cross_target, Subtarget subta
|
||||
#endif
|
||||
#elif defined(GB_SYSTEM_OPENBSD)
|
||||
metrics = &target_openbsd_amd64;
|
||||
#elif defined(GB_SYSTEM_NETBSD)
|
||||
metrics = &target_netbsd_amd64;
|
||||
#elif defined(GB_SYSTEM_HAIKU)
|
||||
metrics = &target_haiku_amd64;
|
||||
#elif defined(GB_CPU_ARM)
|
||||
@@ -2423,6 +2435,7 @@ gb_internal bool init_build_paths(String init_filename) {
|
||||
case TargetOs_essence:
|
||||
case TargetOs_freebsd:
|
||||
case TargetOs_openbsd:
|
||||
case TargetOs_netbsd:
|
||||
case TargetOs_haiku:
|
||||
gb_printf_err("-no-crt on unix systems requires either -default-to-nil-allocator or -default-to-panic-allocator to also be present because the default allocator requires crt\n");
|
||||
return false;
|
||||
|
||||
Reference in New Issue
Block a user