aboutsummaryrefslogtreecommitdiff
path: root/.builds
diff options
context:
space:
mode:
Diffstat (limited to '.builds')
-rw-r--r--.builds/openbsd.diff22
-rw-r--r--.builds/openbsd.yml8
2 files changed, 26 insertions, 4 deletions
diff --git a/.builds/openbsd.diff b/.builds/openbsd.diff
new file mode 100644
index 0000000..8d4e5d2
--- /dev/null
+++ b/.builds/openbsd.diff
@@ -0,0 +1,22 @@
+diff --git endian.h endian.h
+index 3b077cd9295..cb6948d3fec 100644
+--- endian.h
++++ endian.h
+@@ -31,6 +31,8 @@
+ #include <sys/_types.h>
+ #endif
+
++#ifdef __GNUC__
++
+ static __inline __uint16_t
+ __swap16md(__uint16_t _x)
+ {
+@@ -55,6 +57,8 @@ __swap64md(__uint64_t _x)
+ /* Tell sys/endian.h we have MD variants of the swap macros. */
+ #define __HAVE_MD_SWAP
+
++#endif /* __GNUC__ */
++
+ #define _BYTE_ORDER _LITTLE_ENDIAN
+
+ #ifndef __FROM_SYS__ENDIAN
diff --git a/.builds/openbsd.yml b/.builds/openbsd.yml
index 508c8ca..77d0d94 100644
--- a/.builds/openbsd.yml
+++ b/.builds/openbsd.yml
@@ -7,11 +7,11 @@ packages:
environment:
PATH: $HOME/qbe/obj:$PATH
tasks:
+- setup: |
+ # avoid __asm__ on non __GNUC__ compilers
+ patch -d /usr/include/amd64 < cc/.builds/openbsd.diff
- build: |
gmake -C qbe
cd cc
./configure
- make all check
- # OpenBSD support is not quite there (#53), so just build hello world
- ./cc -o hello test/hello.c
- ./hello
+ make all check bootstrap