1
0
mirror of https://github.com/Interlisp/maiko.git synced 2026-01-26 20:02:37 +00:00

Support building on OpenBSD, x86-64 (#207)

* Support building on OpenBSD, x86-64

* Clean up OpenBSD Makefile

* Add OpenBSD to cmake build

* Use clang as CC for OpenBSD

Co-authored-by: Alex Segura <alex@lispm.dev>
This commit is contained in:
Alex Segura
2021-01-11 18:10:57 -07:00
committed by GitHub
parent fa13cc964c
commit 68d7908ee6
4 changed files with 59 additions and 1 deletions

View File

@@ -20,6 +20,7 @@ case "$os" in
x86_64-apple-darwin15*) echo 386 ;;
x86_64-*) echo x86_64 ;;
powerpc-*) echo ppc ;;
amd64-*) echo x86_64 ;;
esac
### Don't leave the variables set.

View File

@@ -0,0 +1,52 @@
# Options for OpenBSD, Intel x86_64 and X-Window
CC = clang -m64 $(CLANG_CFLAGS)
XFILES = $(OBJECTDIR)xmkicon.o \
$(OBJECTDIR)xbbt.o \
$(OBJECTDIR)dspif.o \
$(OBJECTDIR)xinit.o \
$(OBJECTDIR)xscroll.o \
$(OBJECTDIR)xcursor.o \
$(OBJECTDIR)xlspwin.o \
$(OBJECTDIR)xrdopt.o \
$(OBJECTDIR)xwinman.o
XFLAGS = -I/usr/X11R6/include -DXWINDOW -DNOPIXRECT
# This is to make the %$#@! Apollo cc happy
OEXT = .o
# OPTFLAGS is normally -O2.
OPTFLAGS = -O2 -g3
DISPOPTFLAGS = -O2 -g3
FPFLAGS =
DFLAGS = -DOPENBSD -DAIX -DOLD_CURSOR \
-DBYTESWAP -DFORKCOMM -DNOFORN -DLOGINT $(XFLAGS) \
-DRELEASE=351
LDFLAGS = -L/usr/X11R6/lib -lX11 -lc -lm
LDELDFLAGS = -L/usr/X11R6/lib -lX11 -lc -lm
INLINE = # $(SRCDIR)dspSPARC.il
BITBLTFILE = # $(OBJECTDIR)bbtSPARC.o
BYTESWAPFILES = $(OBJECTDIR)byteswap.o
OBJECTDIR = ../$(RELEASENAME)/
default : ../$(OSARCHNAME)/lde
############
#
# SPECIAL xc.o for debugging
#
############
$(OBJECTDIR)xc.o: $(SRCDIR)xc.c $(INCDIR)lispemul.h $(INCDIR)emlglob.h \
$(INCDIR)address.h \
$(INCDIR)adr68k.h $(INCDIR)stack.h $(INCDIR)lspglob.h \
$(INCDIR)lsptypes.h $(INCDIR)lispmap.h $(INCDIR)cell.h \
$(INCDIR)initatms.h $(INCDIR)gcdata.h \
$(INCDIR)arith.h $(INCDIR)stream.h \
$(INCDIR)tos1defs.h $(INCDIR)tosret.h \
$(INCDIR)tosfns.h $(INCDIR)inlineC.h
$(CC) $(DISPRFLAGS) -UOPDISP $(SRCDIR)xc.c -I$(INCDIR) -o $(OBJECTDIR)xc.o