
Magnus Lindberg
Hello! I've tried to install nhc98 on win2000 using Cygwin. However, I get an error message (see the last rows in the first text extract below).
script/nhc98 > -cpp -c ... DErrNo.hs Signal 11
I would guess that Cygwin now includes version 3.x of the gcc compiler. You need to apply patch-1.14-gcc3 from the download page (also copied below), before building nhc98. Regards, Malcolm Index: script/nhc98.inst =================================================================== RCS file: /usr/src/master/nhc/script/nhc98.inst,v retrieving revision 1.40 diff -u -r1.40 nhc98.inst --- script/nhc98.inst 2002/12/22 22:22:44 1.40 +++ script/nhc98.inst 2003/02/05 15:17:48 @@ -539,7 +539,8 @@ then echo $CPPAS $ENDIAN $CPPASFLAGS $CINCDIRS $TMPCPPASFILE -o $TMPASFILE fi - $CPPAS $ENDIAN $CPPASFLAGS $CINCDIRS $TMPCPPASFILE -o $TMPASFILE + $CPPAS $ENDIAN $CPPASFLAGS $CINCDIRS $TMPCPPASFILE -o - | \ + sed -e '/.align 32/s/32/4/' >$TMPASFILE # evil mangler! if test $CSRC -eq 0 then if test $VFLAG -eq 1 Index: src/runtime/Kernel/Makefile =================================================================== RCS file: /usr/src/master/nhc/src/runtime/Kernel/Makefile,v retrieving revision 1.12 diff -u -r1.12 Makefile --- src/runtime/Kernel/Makefile 2002/10/07 13:42:11 1.12 +++ src/runtime/Kernel/Makefile 2003/02/05 15:17:48 @@ -5,7 +5,8 @@ OBJDIR=${BUILDDIR}/${OBJ}/runtime/Kernel OSRCS = mutator.c mutlib.c main.c -ASRCS = haskellInit.c newtables.c dump.c inscount.c newbuiltin.c collector.c mark.c \ +SSRCS = newtables.c newbuiltin.c +ASRCS = haskellInit.c dump.c inscount.c collector.c mark.c \ cdata.c timeUnix.c xlib_debug.c stableptr.c closureval.c ffiexport.c ifneq "${PROFILING}" "" @@ -17,6 +18,7 @@ endif OOBJS = $(patsubst %.c,${OBJDIR}/%.o,${OSRCS}) +SOBJS = $(patsubst %.c,${OBJDIR}/%.o,${SSRCS}) AOBJS = $(patsubst %.c,${OBJDIR}/%.o,${ASRCS}) ifeq "$(CFG)" "" @@ -25,7 +27,7 @@ ARCHIVE=${OBJDIR}/Runtime.${CFG}.a endif -OBJS = ${AOBJS} ${OOBJS} +OBJS = ${AOBJS} ${SOBJS} ${OOBJS} CFLAGS = ${DCFG} ${BUGFIX} ${ENDIAN} ${OPT} -I${INCDIR} \ -DVERSION="\"$(VERSION)\"" #-DBYTECODE_PROF @@ -35,6 +37,9 @@ ${AOBJS} ${OOBJS}: ${OBJDIR}/%.o: %.c ${CC} -c ${CFLAGS} -o $@ $< +${SOBJS}: ${OBJDIR}/%.o: %.c + ${CC} -S ${CFLAGS} -o - $< | sed '/.align 32/s/32/4/' |\ + ${CC} -c -x assembler ${CFLAGS} -o $@ - LINKS = bytecode.h cinterface.h mutlib.h newmacros.h \ node.h runtime.h stableptr.h newbytecode.h bytecode_o.h @@ -51,13 +56,14 @@ ifeq "${TPROF}" "" -${ARCHIVE}: ${AOBJS} - cd ${OBJDIR}; $(AR) $(ARFLAGS) $@ $(patsubst ${OBJDIR}/%,%,${AOBJS}) +${ARCHIVE}: ${AOBJS} ${SOBJS} + cd ${OBJDIR}; \ + $(AR) $(ARFLAGS) $@ $(patsubst ${OBJDIR}/%,%,${AOBJS} ${SOBJS}) else -${ARCHIVE}: ${AOBJS} ${TPLOBJS} +${ARCHIVE}: ${AOBJS} ${SOBJS} ${TPLOBJS} cd ${OBJDIR}; $(AR) $(ARFLAGS) $@ \ - $(patsubst ${OBJDIR}/%,%,${TPLOBJS} ${AOBJS}) + $(patsubst ${OBJDIR}/%,%,${TPLOBJS} ${AOBJS} ${SOBJS}) rm -f ${TPLOBJS} ${TPLOBJS}: