From John.Velman@HSC.com Fri May 11 00:58:30 2001
Received: from slb-smtpout-01.boeing.com (slb-smtpout-01.boeing.com [12.13.237.21])
	by swi.psy.uva.nl (8.11.2/8.11.2) with ESMTP id f4AMwS324343
	for <prolog@swi.psy.uva.nl>; Fri, 11 May 2001 00:58:29 +0200 (MET DST)
Received: from smtp1.hughes.com (smtp1-nat.HUGHES.COM [128.152.20.81])
	by slb-smtpout-01.boeing.com (8.9.2/8.8.5-M2) with ESMTP id PAA10940
	for <prolog@swi.psy.uva.nl>; Thu, 10 May 2001 15:58:23 -0700 (PDT)
From: John.Velman@HSC.com
Received: from ishs01.hsc.com (ishs01.hsc.com [147.20.2.20])
	by smtp1.hughes.com (8.10.2/8.9.1) with ESMTP id f4AMvul02784
	for <prolog@swi.psy.uva.nl>; Thu, 10 May 2001 15:57:56 -0700 (PDT)
Received: from es-s25-mta5.hughes.com (es-s25-mta5.HUGHES.COM [147.20.30.24])
	by ishs01.hsc.com (8.10.2/8.9.1) with ESMTP id f4AMvtg14006
	for <prolog@swi.psy.uva.nl>; Thu, 10 May 2001 15:57:55 -0700 (PDT)
To: prolog@swi.psy.uva.nl
Date: Thu, 10 May 2001 15:57:53 -0700
Message-ID: <OF023914CE.F34D9DEC-ON88256A48.007D3524@hughes.com>
X-MIMETrack: Serialize by Router on MTA00/HUGHES(Release 5.0.5 |September 22, 2000) at
 05/10/2001 03:57:55 PM
MIME-Version: 1.0
Content-type: text/plain; charset=us-ascii
Subject: [SWIPL] compile SWI Prolog on cygwin?

I've attempted to compile pl-4.0.4 under cygwin 1.3.1-1
(the most recent).

Readline gave me a problem, namely, the last part of
the make output was:


----
gcc  -o pl -Lrc pl-atom.o pl-wam.o pl-stream.o pl-error.o pl-arith.o
pl-bag.o pl
-comp.o pl-rc.o pl-dwim.o pl-ext.o pl-file.o pl-flag.o pl-fmt.o pl-funct.o
pl-gc
.o pl-glob.o pl-itf.o pl-list.o pl-load.o pl-modul.o pl-op.o pl-os.o
pl-prims.o
pl-pro.o pl-proc.o pl-prof.o pl-read.o pl-rec.o pl-rl.o pl-setup.o pl-sys.o
pl-t
able.o pl-trace.o pl-util.o pl-wic.o pl-write.o pl-term.o pl-buffer.o
pl-thread.
o pl-xterm.o pl-feature.o pl-ctype.o pl-main.o pl-extend.o frame.o -lrc
-lreadli
ne -lncurses -lm
pl-rl.o(.text+0x1c1):pl-rl.c: undefined reference to `rl_event_hook'
pl-rl.o(.text+0x1ce):pl-rl.c: undefined reference to `rl_event_hook'
collect2: ld returned 1 exit status
make: *** [pl] Error 1

----

This is beyond my depth.  I got it to go past this by monkeying with
the declaration of rl_event_hook, but since I didn't know what I was
doing, I restored the original pl-rl.c, did a make clean, removed
config.cache, and started over with ./configure -disable-readline.

Now I get:

---
ar x `gcc -print-libgcc-file-name` frame.o
gcc  -o pl -Lrc pl-atom.o pl-wam.o pl-stream.o pl-error.o pl-arith.o pl-bag.o pl
-comp.o pl-rc.o pl-dwim.o pl-ext.o pl-file.o pl-flag.o pl-fmt.o pl-funct.o pl-gc
.o pl-glob.o pl-itf.o pl-list.o pl-load.o pl-modul.o pl-op.o pl-os.o pl-prims.o
pl-pro.o pl-proc.o pl-prof.o pl-read.o pl-rec.o pl-rl.o pl-setup.o pl-sys.o pl-t
able.o pl-trace.o pl-util.o pl-wic.o pl-write.o pl-term.o pl-buffer.o pl-thread.
o pl-xterm.o pl-feature.o pl-ctype.o pl-main.o pl-extend.o frame.o -lrc -lncurse
s -lm
./pl -O -o pl.prc -b ../boot/init.pl
[FATAL ERROR:
        mprotect() failed at 0x502d000 for 16384 bytes: Permission denied
]
make: *** [pl.prc] Error 2

---

Any ideas?

By the way, SWI prolog is very impressive.  I always liked it, but
stopped using it sometime ago for reasons I won't try to explain
now :-)

Best regards,

John Velman
john.velman@hsc.com



