summaryrefslogtreecommitdiffhomepage
path: root/ir/be/platform.c
diff options
context:
space:
mode:
authorBrian Callahan <bcallah@openbsd.org>2017-11-06 01:59:24 +0100
committerSebastian Buchwald <Sebastian.Buchwald@kit.edu>2018-05-18 22:42:26 +0200
commit4372cd18aece79fa301f0fddecaf3b54f13cf668 (patch)
treec68fc4e24e9f0ab696f8eb5f8492b5401c5bbe10 /ir/be/platform.c
parenta6d7eb8749303f63ebf72a699cb4a42a663b49e6 (diff)
Add OpenBSD support.
Diffstat (limited to 'ir/be/platform.c')
-rw-r--r--ir/be/platform.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/ir/be/platform.c b/ir/be/platform.c
index f6db414..badc54c 100644
--- a/ir/be/platform.c
+++ b/ir/be/platform.c
@@ -169,6 +169,9 @@ void ir_platform_set(ir_machine_triple_t const *machine,
} else if (strstart(os, "freebsd")) {
ppdef("__FreeBSD__", "");
goto BSD;
+ } else if (strstart(os, "openbsd")) {
+ ppdef1("__OpenBSD__");
+ goto BSD;
} else if (strstr(os, "bsd") != NULL) {
BSD:
object_format = OBJECT_FORMAT_ELF;