Initial OpenBSD toolchain modelled after the FreeBSD one
with several changes. Lightly tested with static/dynamic
binaries on i386 and amd64.
Defines required things like __OpenBSD__ which lets a kernel
Several additional attributes such as __bounded__, __sentinel__
and warnings/semantics as described in
are highly desirable as well, but are not included for now.
This diff requires the llvm Triple changes comitted earlier today
obsd_toolchain.diff (14.2 KB)
One question on the patch though, is it really true that gcc always defines
No, that shouldn't have been included, while we use a kprintf format
attribute, __KPRINTF_ATTRIBUTE__ isn't defined by gcc.
Additionally it seems -x assembler-with-cpp doesn't generate
assembly that gas will accept when compiling locore.o.
This appears to be due to the lack of something like gcc's
We don't support "traditional" style preprocessing. This is the really old K&R style, it would be best to update to C89 if possible. It's only 20 years old now