Skip to content

Commit e452a97

Browse files
committed
setup for cygwin (compiles but crashes)
1 parent e801373 commit e452a97

File tree

3 files changed

+57
-0
lines changed

3 files changed

+57
-0
lines changed

bin/makefile-cygwin.x86_64-x

Lines changed: 54 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,54 @@
1+
# Options for Linux, Intel x86_64 and X-Window
2+
3+
#CC = gcc -m64 $(GCC_CFLAGS) -fno-omit-frame-pointer -Wall -Wextra -fno-aggressive-loop-optimizations
4+
CC = clang -m64 $(CLANG_CFLAGS)
5+
6+
XFILES = $(OBJECTDIR)xmkicon.o \
7+
$(OBJECTDIR)xbbt.o \
8+
$(OBJECTDIR)dspif.o \
9+
$(OBJECTDIR)xinit.o \
10+
$(OBJECTDIR)xscroll.o \
11+
$(OBJECTDIR)xcursor.o \
12+
$(OBJECTDIR)xlspwin.o \
13+
$(OBJECTDIR)xrdopt.o \
14+
$(OBJECTDIR)xwinman.o
15+
16+
17+
XFLAGS = -DXWINDOW -DNOPIXRECT
18+
19+
# This is to make the %$#@! Apollo cc happy
20+
OEXT = .o
21+
# OPTFLAGS is normally -O2.
22+
OPTFLAGS = -O2 -g3
23+
DISPOPTFLAGS = -O2 -g3
24+
FPFLAGS =
25+
DFLAGS = -DNEW_STORAGE -DLINUX -DAIX -DOLD_CURSOR \
26+
-DBYTESWAP -DFORKCOMM -DNOFORN -DLOGINT $(XFLAGS) \
27+
-DRELEASE=351 -DSYSVSIGNALS -DSYSVONLY \
28+
-D_GNU_SOURCE
29+
30+
LDFLAGS = -L/usr/X11/lib -lX11 -lc -lm -lcrypt
31+
LDELDFLAGS = -L/usr/X11/lib -lX11 -lc -lm -lcrypt
32+
33+
INLINE = # $(SRCDIR)dspSPARC.il
34+
BITBLTFILE = # $(OBJECTDIR)bbtSPARC.o
35+
BYTESWAPFILES = $(OBJECTDIR)byteswap.o
36+
37+
OBJECTDIR = ../$(RELEASENAME)/
38+
39+
default : ../$(OSARCHNAME)/lde
40+
41+
############
42+
#
43+
# SPECIAL xc.o for debugging
44+
#
45+
############
46+
$(OBJECTDIR)xc.o: $(SRCDIR)xc.c $(INCDIR)lispemul.h $(INCDIR)emlglob.h \
47+
$(INCDIR)address.h \
48+
$(INCDIR)adr68k.h $(INCDIR)stack.h $(INCDIR)lspglob.h \
49+
$(INCDIR)lsptypes.h $(INCDIR)lispmap.h $(INCDIR)cell.h \
50+
$(INCDIR)initatms.h $(INCDIR)gcdata.h \
51+
$(INCDIR)arith.h $(INCDIR)stream.h \
52+
$(INCDIR)tos1defs.h $(INCDIR)tosret.h \
53+
$(INCDIR)tosfns.h $(INCDIR)inlineC.h
54+
$(CC) $(DISPRFLAGS) -UOPDISP $(SRCDIR)xc.c -I$(INCDIR) -o $(OBJECTDIR)xc.o

bin/osversion

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@ case "$os" in
99
*-*-linux*) echo linux ;;
1010
*-*-openbsd*) echo openbsd ;;
1111
*-*-freebsd*) echo freebsd ;;
12+
*-*-cygwin*) echo cygwin ;;
1213
esac
1314
### Don't leave the variable set.
1415
unset os

src/timer.c

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -617,13 +617,15 @@ static void int_io_init() {
617617
#ifndef DOS
618618
SIGERRCHK(sigset(SIGIO, getsignaldata), "sigset io");
619619
#ifdef XWINDOW
620+
#ifndef __CYGWIN__
620621
#ifdef LINUX
621622
if (fcntl(ConnectionNumber(currentdsp->display_id), F_SETSIG, 0) < 0)
622623
perror("fcntl on X fd - SETSIG for input handling failed");
623624
#else
624625
if (ioctl(ConnectionNumber(currentdsp->display_id), I_SETSIG, S_INPUT) < 0)
625626
perror("ioctl on X fd - SETSIG for input handling failed");
626627
#endif
628+
#endif /* __CYGWIN__ */
627629
#endif /* XWINDOW */
628630

629631
#ifdef USE_DLPI

0 commit comments

Comments
 (0)