gcl-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Gcl-devel] FreeBSD patches, take 2


From: Mark Murray
Subject: [Gcl-devel] FreeBSD patches, take 2
Date: Thu, 13 Nov 2003 21:42:45 +0000

Hiya

I've enclosed my second round of FreeBSD fixes (to GCL HEAD). Included
in them are the usual "remove gmp, remove bfd" stuff that I'm using.
No need to comment on these :-).

I've cleaned up h/FreeBSD.h and h/FreeBSD.defs quite a bit. There are
other bits 'n bobs fixes.

Comments? (These patches build me a GCL that builds Axiom!)

M
--
Mark Murray
iumop ap!sdn w,I idlaH
Index: makedefc.in
===================================================================
RCS file: /cvsroot/gcl/gcl/makedefc.in,v
retrieving revision 1.16
diff -u -d -r1.16 makedefc.in
--- makedefc.in 24 Sep 2003 15:37:30 -0000      1.16
+++ makedefc.in 13 Nov 2003 08:48:40 -0000
@@ -16,13 +16,18 @@
 address@hidden@
 
 # where to place the info files
address@hidden@
address@hidden@/info
+
+# configure has a clever process for figuring out where Emacs
+# really expects to find site-lisp and default.el.  We use
+# these values instead to ensure that building with --prefix=PREFIX
+# will not make changes outside the specified tree. -twp
 
 # where to put emacs lisp files.
address@hidden@
address@hidden@/share/emacs/site-lisp
 
 # the default.el file
address@hidden@
address@hidden@/share/emacs/site-lisp/default.el
 
 # numerous TCL/TK variables culled from the tkConfig.sh and tclConfig.sh
 # if these are found.
@@ -56,8 +61,6 @@
 
 address@hidden@
 address@hidden@
address@hidden@
address@hidden@
 address@hidden@
 address@hidden@
 
Index: h/FreeBSD.defs
===================================================================
RCS file: /cvsroot/gcl/gcl/h/FreeBSD.defs,v
retrieving revision 1.2
diff -u -d -r1.2 FreeBSD.defs
--- h/FreeBSD.defs      1 Nov 2002 04:09:34 -0000       1.2
+++ h/FreeBSD.defs      13 Nov 2003 08:48:44 -0000
@@ -1,26 +1,20 @@
-# Machine dependent makefile definitions for intel 386,486 running 386bsd
+# Machine dependent makefile definitions for 386bsd
 # Ported to FreeBSD 2.0 by Jeffrey Hsu (address@hidden).
 # Hacked September-93 by Paul F. Werkowski for 386BSD 0.1 + Patchkit 0.2.4
+# Hacked September-2003 by Juergen Weiss, Mark Murray for FreeBSD-5 CURRENT
 
-LBINDIR=/usr/local/bin
-
-OFLAG  = -pipe -O2 
-CFLAGS = -fwritable-strings -fomit-frame-pointer -DVOL=volatile -I$(GCLDIR)/o 
-I/usr/local/lib/gcl-2.0/h -fsigned-char -I/usr/local/lib
-LIBS    = -lm -L/usr/local/lib
-ODIR_DEBUG=
-NULLFILE=../h/twelve_null
+LBINDIR=${prefix}/bin
+# OFLAG  = -pipe -O2
+# CFLAGS = @@.CFLAGS@@
+CFLAGS = -O -pipe -mcpu=pentiumpro -I/usr/local/include
+CFLAGS += -I$(GCLDIR)/o -fwritable-strings -fomit-frame-pointer -fsigned-char 
-DVOL=volatile
+# LIBS = @@.LOCALLIBS@@
+LIBS = -L/usr/local/lib -lgmp -lm -lreadline
 
 # This CC string will be used for compilation of the system,
 # and also in the compiler::*cc* variable for later compilation of
 # lisp files.
-
-CC = gcc
-
-LDCC = $(CC) -static
-
-#  Use the mp.s file on 68k machine 
-MPFILES= $(MPDIR)/mpi-386.o $(MPDIR)/libmport.a
-GNULIB1=/usr/lib/libgcc.a
+CC = cc $(CFLAGS)
 
 # Enable the fastloading mechanism which does not use ld -A
 # requires c/rel_.. machine dependent code.
Index: h/FreeBSD.h
===================================================================
RCS file: /cvsroot/gcl/gcl/h/FreeBSD.h,v
retrieving revision 1.2
diff -u -d -r1.2 FreeBSD.h
--- h/FreeBSD.h 1 Nov 2002 04:09:34 -0000       1.2
+++ h/FreeBSD.h 13 Nov 2003 08:48:44 -0000
@@ -1,62 +1,56 @@
 /*
- * FreeBSD.h for gcl 1.1
+ * FreeBSD.h for gcl
  *
- * Ported by Jeffrey Hsu (address@hidden).
+ * Ported by Mark Murray
  *  Looked at previous versions by Hsu, Werkowsksi, Tobin, and Mogart.
  *
  */
 
-#include "bsd.h"
-
-#undef LD_COMMAND
-#define LD_COMMAND(command,main,start,input,ldarg,output) \
-  sprintf(command, "ld -dc -N -x -A %s -T %x %s %s -o %s", \
-            main,start,input,ldarg,output)
-
-#define ADDITIONAL_FEATURES \
-                    ADD_FEATURE("386BSD");\
-                     ADD_FEATURE("FreeBSD");
+#ifndef __ELF__
+#error FreeBSD systems use ELF
+#endif
 
+#include "linux.h"
 
+#if defined(__i386__)
 #define I386
-#define        IEEEFLOAT
-
-/* we don't need to worry about zeroing fp->_base, to prevent what??? */
-#define FCLOSE_SETBUF_OK 
+#endif
 
-#undef HAVE_XDR
+#define ADDITIONAL_FEATURES                                    \
+                    ADD_FEATURE("386BSD");                     \
+                     ADD_FEATURE("FreeBSD");
 
 #define USE_ATT_TIME
 
 #undef LISTEN_FOR_INPUT
-#define LISTEN_FOR_INPUT(fp) \
-do {int c=0;\
-  if ((fp)->_r <=0 && (c=0, ioctl((fp)->_file, FIONREAD, &c), c<=0)) \
-       return(FALSE);} while(0)
+#define LISTEN_FOR_INPUT(fp)                                   \
+do {                                                           \
+       int c = 0;                                              \
+                                                               \
+       if (                                                    \
+               (fp)->_r <= 0 &&                                \
+                   (ioctl((fp)->_file, FIONREAD, &c), c <= 0)  \
+       )                                                       \
+               return(FALSE);                                  \
+} while (0)
 
 #ifdef IN_GBC
 #include <sys/types.h>
 #endif
 
-#define DATA_BEGIN (char *) N_DATADDR(header);
-#define A_TEXT_OFFSET(x) (sizeof (struct exec))
-#define A_TEXT_SEEK(hdr) (N_TXTOFF(hdr) + A_TEXT_OFFSET(hdr))
-#define start_of_data() &etext
-#define start_of_text() ((char *)(sizeof(struct exec) + getpagesize()))
-
-#define UNIXSAVE "unexec.c"
-#ifdef UNIXSAVE 
- extern char etext;
+#if defined(IN_UNIXTIME)
+# include <time.h>
 #endif
 
-#define RELOC_FILE "rel_sun3.c"        /* for SFASL - enabled in bsd.h */
+/*#define UNEXEC_USE_MAP_PRIVATE*/
+#define UNIXSAVE "unexelf.c"
 
 #ifdef CLOCKS_PER_SEC
 #define HZ CLOCKS_PER_SEC
 #else
 #define HZ 128
 #endif
-#define ss_base ss_sp
+/* #define ss_base ss_sp */
 
 /* begin for GC */
 #define PAGEWIDTH 12           /* i386 sees 4096 byte pages */
@@ -64,36 +58,24 @@
 
 #define HAVE_SIGPROCMASK
 #define SIG_STACK_SIZE (SIGSTKSZ/sizeof(double))
-#define SETUP_SIG_STACK \
-{ \
-       static struct sigaltstack estack; \
-       if ((estack.ss_sp = malloc(SIGSTKSZ)) == NULL) \
-         perror("malloc"); \
-       estack.ss_size = SIGSTKSZ; \
-       estack.ss_flags = 0; \
-       if (sigaltstack(&estack, 0) < 0) \
-         perror("sigaltstack"); \
+
+#undef SETUP_SIG_STACK
+#define SETUP_SIG_STACK {                                      \
+       static struct sigaltstack estack;                       \
+       if (estack.ss_sp == NULL &&                             \
+           (estack.ss_sp = malloc(SIGSTKSZ)) == NULL)          \
+               perror("malloc");                               \
+       estack.ss_size = SIGSTKSZ;                              \
+       estack.ss_flags = 0;                                    \
+       if (sigaltstack(&estack, 0) < 0)                        \
+               perror("sigaltstack");                          \
 }
 
-#define INSTALL_SEGMENTATION_CATCHER \
-        (void) gcl_signal(SIGSEGV, segmentation_catcher); \
+#undef INSTALL_SEGMENTATION_CATCHER
+#define INSTALL_SEGMENTATION_CATCHER                           \
+        (void) gcl_signal(SIGSEGV, segmentation_catcher);      \
         (void) gcl_signal(SIGBUS, segmentation_catcher)
 
-#ifdef USE_DLOPEN
-#define SPECIAL_RSYM "rsym_elf.c"
-#define SEPARATE_SFASL_FILE "fasldlsym.c"
-#else
-#ifdef HAVE_LIBBFD
-#define SEPARATE_SFASL_FILE "sfaslbfd.c"
-#else
-#if !defined(__i386__) && !defined(__sparc__)
-#error Can only do non-bfd relocs for i386 and sparc
-#endif
-#define SPECIAL_RSYM "rsym_elf.c"
-#define SEPARATE_SFASL_FILE "sfaslelf.c"
-#endif
-#endif
-
 /*
  * The next two defines are for SGC,
  *     one of which needs to go in cmpinclude.h.
@@ -102,9 +84,4 @@
 
 /* Begin for cmpinclude */
 #define SGC    /* can mprotect pages and so selective gc will work */
-
 /* End for cmpinclude */
-
-#if defined(IN_UNIXTIME)
-# include <time.h>
-#endif
Index: h/bsd.h
===================================================================
RCS file: /cvsroot/gcl/gcl/h/bsd.h,v
retrieving revision 1.4
diff -u -d -r1.4 bsd.h
--- h/bsd.h     20 Jul 2002 07:10:55 -0000      1.4
+++ h/bsd.h     13 Nov 2003 08:48:44 -0000
@@ -1,8 +1,8 @@
-#define BSD 1
+#include <sys/param.h>
+
 #define UNIX
 #define AV
 #define SFASL
-#define HAVE_AOUT <a.out.h>
 
 
 #define MEM_SAVE_LOCALS        \
Index: h/linux.h
===================================================================
RCS file: /cvsroot/gcl/gcl/h/linux.h,v
retrieving revision 1.9
diff -u -d -r1.9 linux.h
--- h/linux.h   10 Sep 2003 19:57:55 -0000      1.9
+++ h/linux.h   13 Nov 2003 08:48:45 -0000
@@ -161,8 +161,6 @@
   sprintf(command, "ld -d -S -N -x -A %s -T %x %s %s -o %s", \
             main,start,input,ldarg,output)
 
-#define SET_SESSION_ID() (setpgrp() ? -1 : 0)
-
 #define CLEANUP_CODE \
   setbuf(stdin,0); \
    setbuf(stdout,0);
Index: h/notcomp.h
===================================================================
RCS file: /cvsroot/gcl/gcl/h/notcomp.h,v
retrieving revision 1.17
diff -u -d -r1.17 notcomp.h
--- h/notcomp.h 6 Nov 2003 16:08:08 -0000       1.17
+++ h/notcomp.h 13 Nov 2003 08:48:45 -0000
@@ -81,8 +81,20 @@
    pack == LISP ? LISP_makefun(string,fname,argd) : \
    error("Bad pack variable in MAKEFUN\n"))
 
+#if defined(__i386__)
+#define __ELF_NATIVE_CLASS 32
+#endif
+#if defined(__alpha__) || defined(__sparc64__) || defined(__ia64__)
+#define __ELF_NATIVE_CLASS 64
+#endif
+
 #define mjoin(a_,b_) a_ ## b_
 #define Mjoin(a_,b_) mjoin(a_,b_)
+
+#if !defined(ElfW)
+#define ElfW(a) Mjoin(Elf,Mjoin(__ELF_NATIVE_CLASS,Mjoin(_,a)))
+#endif
+#define ELFW(a) Mjoin(ELF,Mjoin(__ELF_NATIVE_CLASS,Mjoin(_,a)))
 
 #define SI 0
 #define LISP 1
Index: info/gcl-si.texi
===================================================================
RCS file: /cvsroot/gcl/gcl/info/gcl-si.texi,v
retrieving revision 1.3
diff -u -d -r1.3 gcl-si.texi
--- info/gcl-si.texi    19 Feb 2002 19:21:19 -0000      1.3
+++ info/gcl-si.texi    13 Nov 2003 08:48:45 -0000
@@ -19,6 +19,10 @@
 
 @setchapternewpage odd
 @ifinfo
address@hidden GNU Common Lisp
address@hidden
+* GCL Systems Internals: (gcl-si).     GCL SYSTEM INTERNALS Manual
address@hidden direntry
 This is a Texinfo GCL SYSTEM INTERNALS Manual
 
 Copyright 1994 William F. Schelter
Index: info/makefile
===================================================================
RCS file: /cvsroot/gcl/gcl/info/makefile,v
retrieving revision 1.28
diff -u -d -r1.28 makefile
--- info/makefile       31 Oct 2003 16:26:54 -0000      1.28
+++ info/makefile       13 Nov 2003 08:48:45 -0000
@@ -1,7 +1,7 @@
 .SUFFIXES:
 .SUFFIXES: .info .dvi  .texi
 
-INFO_DIR=/usr/local/lib/info
+INFO_DIR=${prefix}/lib/info
 
 GCL_DVI=gcl-tk.dvi gcl-si.dvi gcl.dvi
 GCL_HTML=gcl-si_toc.html gcl-tk_toc.html gcl_toc.html
@@ -9,12 +9,12 @@
 
 -include ../makedefs
 
-all: gcl-tk.info gcl-si.info gcl.info $(GCL_DVI) $(GCL_HTML)
+all: gcl-tk.info gcl-si.info gcl.info
 
 .texi.info:
-       rm -f $*.*gz
-       -$(MAKEINFO) $*.texi
-       - gzip $*.info-*
+       rm -f $*gz
+       rm -f $*.info
+       -$(MAKEINFO) --no-split $*.texi
 
 GCL_SI= number.texi sequence.texi character.texi list.texi io.texi \
        form.texi compile.texi symbol.texi system.texi structure.texi \
@@ -32,19 +32,16 @@
        TEXINPUTS=.:$$TEXINPUTS tex --interaction nonstopmode gcl-si.texi || 
true
 
 gcl-si.info: ${GCL_SI} gcl-si.texi
-       -$(MAKEINFO) gcl-si.texi        
 
 gcl-tk.dvi: ${GCL_TK} gcl-tk.texi
        TEXINPUTS=.:$$TEXINPUTS tex --interaction nonstopmode gcl-tk.texi || 
true
 
 gcl-tk.info: ${GCL_TK} gcl-tk.texi
-       -$(MAKEINFO) gcl-tk.texi
 
 gcl.dvi: ${GCL_MAN} gcl.texi
        TEXINPUTS=.:$$TEXINPUTS tex --interaction nonstopmode gcl.texi || true
 
 gcl.info: ${GCL_MAN} gcl.texi
-       -$(MAKEINFO) gcl.texi
 
 gcl-si_toc.html: ${GCL_SI} gcl-si.texi
        $(HTML_CMD) gcl-si.texi
@@ -58,7 +55,7 @@
 install-html: gcl-tk_toc.html gcl-si_toc.html gcl_toc.html
        cp *.html /d/www/gcl
 
-install: $(GCL_DVI) $(GCL_HTML)
+install: 
        mkdir -p $(DESTDIR)${INFO_DIR}
        [ -f $(DESTDIR)$(INFO_DIR)dir ] || touch $(DESTDIR)$(INFO_DIR)dir
        grep gcl-si $(DESTDIR)${INFO_DIR}dir >/dev/null 2>&1 || \
@@ -68,13 +65,6 @@
        grep gcl.info $(DESTDIR)${INFO_DIR}dir >/dev/null 2>&1 || \
        echo "* GCL Ansi Doc: (gcl.info).  Ansi Common Lisp Specification." >> 
$(DESTDIR)${INFO_DIR}dir
        -cp *.info* $(DESTDIR)${INFO_DIR}
-       -mkdir -p $(DESTDIR)$(INFO_DIR)../doc/gcl-doc/gcl.html
-       -mkdir -p $(DESTDIR)$(INFO_DIR)../doc/gcl-doc/gcl-si.html
-       -mkdir -p $(DESTDIR)$(INFO_DIR)../doc/gcl-doc/gcl-tk.html
-       -cp gcl*html $(DESTDIR)$(INFO_DIR)../doc/gcl-doc/gcl.html
-       -cp gcl-si*html $(DESTDIR)$(INFO_DIR)../doc/gcl-doc/gcl-si.html
-       -cp gcl-tk*html $(DESTDIR)$(INFO_DIR)../doc/gcl-doc/gcl-tk.html
-       -cp *dvi $(DESTDIR)$(INFO_DIR)../doc/gcl-doc
 
 FILE=gcl-si.texi
 srcs:
@@ -90,4 +80,4 @@
 
 clean:
        rm -f *.info* *.html *.dvi *.cp *.ky *.vr *.tp *.pg *.toc *.aux *.log 
*.fn
-       rm -rf gcl.IC gcl.IE gcl.IG gcl.IP gcl.IR gcl.IT gcl.fu 
\ No newline at end of file
+       rm -rf gcl.IC gcl.IE gcl.IG gcl.IP gcl.IR gcl.IT gcl.fu 
Index: o/gcl_readline.d
===================================================================
RCS file: /cvsroot/gcl/gcl/o/gcl_readline.d,v
retrieving revision 1.3
diff -u -d -r1.3 gcl_readline.d
--- o/gcl_readline.d    6 Nov 2003 16:08:09 -0000       1.3
+++ o/gcl_readline.d    13 Nov 2003 08:48:49 -0000
@@ -94,7 +94,6 @@
    the word to complete.  We can use the entire contents of rl_line_buffer
    in case we want to do some simple parsing.  Return the array of matches,
    or NULL if there aren't any. */
-extern char **completion_matches(char *,char *(*)(char *,int));
 static char **rl_completion(char *text, int start, int end) {
        return completion_matches(text, rl_completion_words);
 }
Index: o/makefile
===================================================================
RCS file: /cvsroot/gcl/gcl/o/makefile,v
retrieving revision 1.29
diff -u -d -r1.29 makefile
--- o/makefile  6 Nov 2003 16:08:09 -0000       1.29
+++ o/makefile  13 Nov 2003 08:48:49 -0000
@@ -79,6 +79,7 @@
        $(OD)makefun.o $(OD)sockets.o $(OD)clxsocket.o  \
        $(OD)init_pari.o $(OD)nsocket.o $(NEW_INIT) $(MPFILES) $(SFASL) 
$(EXTRAS) \
        $(RL_OBJS)
+INI_FILES=$(patsubst %.o,%.ini,${OBJS})
 
 all:  ../bin/dpp${EXE} $(OBJS) new-init $(LIBFILES) new_init.o  $(GCLIB) 
$(LAST_FILE)  $(FIRST_FILE) 
 
@@ -89,10 +90,10 @@
        ${CC} ${DEFS} -o ../bin/dpp${EXE} ../bin/dpp.c
 
 
-new-init: grab_defs
-       $(MAKE) new_init.c decls1 "INI_FILES=`echo ${OBJS} | sed -e 
's:\.o:.ini:g'  -e 's:new_init.o::g' `"
+new-init:
+       $(MAKE) new_init.c decls1
 
-new_init.c: ${INI_FILES}
+new_init.c: grab_defs ${INI_FILES}
        echo '#include "make-init.h"' > new_init.c
        echo 'void NewInit(void){' >> new_init.c
        cat ${INI_FILES} >> new_init.c
@@ -100,10 +101,10 @@
 
 ifneq ($(NIFLAGS),)
 new_init.o: new_init.c
-       $(CC) -c $(NIFLAGS) $(DEFS) $< -o $@
+       $(CC) -c $(NIFLAGS) $(CFLAGS) $(DEFS) $< -o $@
 endif
 
-decls1:
+decls1: grab_defs ${INI_FILES}
        echo '#include "make-decl.h"' > foo.c
        cat ${INI_FILES} >> foo.c
        ${CC} -E -I${HDIR} foo.c | sed -n -e '/#/d' -e '/DO_/d' -e 
'/[a-zA-Z;]/p' > tmpx
Index: o/num_co.c
===================================================================
RCS file: /cvsroot/gcl/gcl/o/num_co.c,v
retrieving revision 1.14
diff -u -d -r1.14 num_co.c
--- o/num_co.c  6 Nov 2003 16:08:09 -0000       1.14
+++ o/num_co.c  13 Nov 2003 08:48:50 -0000
@@ -1337,29 +1337,29 @@
          volatile double rd,dd,td,td1;
          volatile float  rf,df,tf,tf1;
          int i,j;
-#define MAX 500
+#define FL_MAX 500
          
-         for (rf=1.0f,df=0.5f,i=j=0;i<MAX && j<MAX && 
df!=1.0f;i++,df=1.0f-(0.5f*(1.0f-df)))
-           for (tf=rf,tf1=tf+1.0f,j=0;j<MAX && 
tf1!=1.0f;j++,rf=tf,tf*=df,tf1=tf+1.0f);
-         if (i==MAX||j==MAX)
+         for (rf=1.0f,df=0.5f,i=j=0;i<FL_MAX && j<FL_MAX && 
df!=1.0f;i++,df=1.0f-(0.5f*(1.0f-df)))
+           for (tf=rf,tf1=tf+1.0f,j=0;j<FL_MAX && 
tf1!=1.0f;j++,rf=tf,tf*=df,tf1=tf+1.0f);
+         if (i==FL_MAX||j==FL_MAX)
            printf("WARNING, cannot calculate float_epsilon: %d %d %f   %f %f 
%f\n",i,j,rf,df,tf,tf1);
          float_epsilon=rf;
 
-         for (rf=1.0f,df=0.5f,i=j=0;i<MAX && j<MAX && 
df!=1.0f;i++,df=1.0f-(0.5f*(1.0f-df)))
-           for (tf=rf,tf1=1.0f-tf,j=0;j<MAX && 
tf1!=1.0f;j++,rf=tf,tf*=df,tf1=1.0f-tf);
-         if (i==MAX||j==MAX)
+         for (rf=1.0f,df=0.5f,i=j=0;i<FL_MAX && j<FL_MAX && 
df!=1.0f;i++,df=1.0f-(0.5f*(1.0f-df)))
+           for (tf=rf,tf1=1.0f-tf,j=0;j<FL_MAX && 
tf1!=1.0f;j++,rf=tf,tf*=df,tf1=1.0f-tf);
+         if (i==FL_MAX||j==FL_MAX)
            printf("WARNING, cannot calculate float_negative_epsilon: %d %d %f  
 %f %f %f\n",i,j,rf,df,tf,tf1);
          float_negative_epsilon=rf;
          
-         for (rd=1.0,dd=0.5,i=j=0;i<MAX && j<MAX && 
dd!=1.0;i++,dd=1.0-(0.5*(1.0-dd)))
-           for (td=rd,td1=td+1.0,j=0;j<MAX && 
td1!=1.0;j++,rd=td,td*=dd,td1=td+1.0);
-         if (i==MAX||j==MAX)
+         for (rd=1.0,dd=0.5,i=j=0;i<FL_MAX && j<FL_MAX && 
dd!=1.0;i++,dd=1.0-(0.5*(1.0-dd)))
+           for (td=rd,td1=td+1.0,j=0;j<FL_MAX && 
td1!=1.0;j++,rd=td,td*=dd,td1=td+1.0);
+         if (i==FL_MAX||j==FL_MAX)
            printf("WARNING, cannot calculate double_epsilon: %d %d %f   %f %f 
%f\n",i,j,rd,dd,td,td1);
          double_epsilon=rd;
 
-         for (rd=1.0,dd=0.5,i=j=0;i<MAX && j<MAX && 
dd!=1.0;i++,dd=1.0-(0.5*(1.0-dd)))
-           for (td=rd,td1=1.0-td,j=0;j<MAX && 
td1!=1.0;j++,rd=td,td*=dd,td1=1.0-td);
-         if (i==MAX||j==MAX)
+         for (rd=1.0,dd=0.5,i=j=0;i<FL_MAX && j<FL_MAX && 
dd!=1.0;i++,dd=1.0-(0.5*(1.0-dd)))
+           for (td=rd,td1=1.0-td,j=0;j<FL_MAX && 
td1!=1.0;j++,rd=td,td*=dd,td1=1.0-td);
+         if (i==FL_MAX||j==FL_MAX)
            printf("WARNING, cannot calculate double_negative_epsilon: %d %d %f 
  %f %f %f\n",i,j,rd,dd,td,td1);
          double_negative_epsilon=rd;
          
Index: o/sfaslelf.c
===================================================================
RCS file: /cvsroot/gcl/gcl/o/sfaslelf.c,v
retrieving revision 1.8
diff -u -d -r1.8 sfaslelf.c
--- o/sfaslelf.c        24 Jul 2002 19:05:53 -0000      1.8
+++ o/sfaslelf.c        13 Nov 2003 08:48:50 -0000
@@ -23,7 +23,7 @@
  */
 
 
-#ifndef __linux__
+#if !defined(__linux__) && !defined(__FreeBSD__)
 #define ELF_TARGET_SPARC 1
 #endif
 
@@ -83,7 +83,7 @@
  if (!(symin=fopen(symfile,"r")))
    {perror(symfile);exit(1);};
  if(!fread((char *)&tab,sizeof(tab),1,symin))
-   FEerror("No header",0,0);
+   FEerror("No header",0);
  symbols=malloc(tab.tot_leng);
  c_table.alloc_length=( (PTABLE_EXTRA+ tab.n_symbols));
  (c_table.ptable) = (TABL *) malloc(sizeof(struct node) * 
c_table.alloc_length);
@@ -196,7 +196,7 @@
    file = fileno(fp);
 
    if (fstat (file, &stat_buf) == -1)
-     FEerror ("Can't fstat(~a): errno %d\n", 1,faslfile);
+     FEerror ("Can't fstat(~a): errno %d\n", 2,faslfile,0);
 
 
    if (use_mmap) {
@@ -303,7 +303,7 @@
    
    relocate_symbols(symbol_table,nsyms,file_h->e_shnum,&init_address);
    if (init_address < 0)
-     { FEerror(0,"Init address not found ");
+     { FEerror("Init address not found ",0);
      }
 
    { 
@@ -317,7 +317,7 @@
           {
             int index_to_relocate = shp->sh_info;
             if (symtab_index != shp->sh_link)
-              FEerror("unexpected symbol table used");
+              FEerror("unexpected symbol table used",0);
             the_start = start_address + section[index_to_relocate].start;
           }
 /*      else if (shp->sh_type == SHT_REL */
@@ -332,7 +332,7 @@
         else if ( (shp->sh_type == SHT_REL) || (shp->sh_type == SHT_RELA) )
           {  if (get_section_number(".rel.stab") == j)
                 continue;
-            FEerror("unknown rel type");
+            FEerror("unknown rel type",0);
           }
         else
           continue;
@@ -520,7 +520,7 @@
     else if (sh_type == SHT_REL)
       a = 0;
     else {
-      FEerror("relocate() error: unknown sh_type in ELF object");
+      FEerror("relocate() error: unknown sh_type in ELF object",0);
       a=0;
     }
     b = (unsigned int) the_start;
@@ -540,9 +540,9 @@
 /*      do_bfd_reloc(ELF32_R_TYPE(reloc_info->r_info),s+a,(unsigned int 
*)where); */
 /*  #else */
     switch(ELF32_R_TYPE(reloc_info->r_info)){
-#if (defined(__svr4__) || defined(__linux__)) && defined(__i386__)
+#if (defined(__svr4__) || defined(__linux__) || defined(__FreeBSD__)) && 
defined(__i386__)
     case     R_386_NONE:
-      FEerror("Unsupported ELF type R_386_NONE");
+      FEerror("Unsupported ELF type R_386_NONE",0);
       break;
 
     case     R_386_32:
@@ -556,40 +556,40 @@
       break;
 
     case     R_386_GOT32:
-      FEerror("Unsupported ELF type R_386_GOY32");
+      FEerror("Unsupported ELF type R_386_GOY32",0);
       break;
 
     case     R_386_PLT32:
-      FEerror("Unsupported ELF type R_386_PLT32");
+      FEerror("Unsupported ELF type R_386_PLT32",0);
       break;
 
     case     R_386_COPY:
-      FEerror("Unsupported ELF type R_386_COPY");
+      FEerror("Unsupported ELF type R_386_COPY",0);
       break;
 
     case     R_386_GLOB_DAT:
-      FEerror("Unsupported ELF type R_386_GLOB_DAT");
+      FEerror("Unsupported ELF type R_386_GLOB_DAT",0);
       break;
 
     case     R_386_JMP_SLOT:
-      FEerror("Unsupported ELF type R_386_JMP_SLOT");
+      FEerror("Unsupported ELF type R_386_JMP_SLOT",0);
       break;
 
     case     R_386_RELATIVE:
-      FEerror("Unsupported ELF type R_386_RELATIVE");
+      FEerror("Unsupported ELF type R_386_RELATIVE",0);
       break;
 
     case     R_386_GOTOFF:
-      FEerror("Unsupported ELF type R_386_GOTOFF");
+      FEerror("Unsupported ELF type R_386_GOTOFF",0);
       break;
 
     case     R_386_GOTPC:
-      FEerror("Unsupported ELF type R_386_GOTPC");
+      FEerror("Unsupported ELF type R_386_GOTPC",0);
       break;
 
 #ifdef R_386_NUM
     case     R_386_NUM:
-      FEerror("Unsupported ELF type R_386_NUM");
+      FEerror("Unsupported ELF type R_386_NUM",0);
       break;
 #endif
 
@@ -657,7 +657,7 @@
          fflush(stdout);
        }
     }
-  else{FEerror("symbol table not loaded",0,0);}
+  else{FEerror("symbol table not loaded",0);}
 }
 
 static void
Index: o/unixfasl.c
===================================================================
RCS file: /cvsroot/gcl/gcl/o/unixfasl.c,v
retrieving revision 1.7
diff -u -d -r1.7 unixfasl.c
--- o/unixfasl.c        12 Nov 2003 15:45:31 -0000      1.7
+++ o/unixfasl.c        13 Nov 2003 08:48:50 -0000
@@ -282,7 +282,7 @@
 static int
 faslink(object faslfile, object ldargstring)
 {
-#if (defined(__linux__) && defined(__ELF__)) || defined(DARWIN)
+#if ((defined(__linux__) || defined(__FreeBSD__)) && defined(__ELF__)) || 
defined(DARWIN)
   FEerror("faslink() not supported for ELF yet",0);
   return 0;
 #else
Index: unixport/makefile
===================================================================
RCS file: /cvsroot/gcl/gcl/unixport/makefile,v
retrieving revision 1.50
diff -u -d -r1.50 makefile
--- unixport/makefile   12 Nov 2003 15:45:32 -0000      1.50
+++ unixport/makefile   13 Nov 2003 08:48:51 -0000
@@ -24,24 +24,6 @@
        cp $< $@
        ranlib $@
 
-gmpfiles: $(shell find ../$(GMPDIR) -name "*.o" |grep -v '\.lib')
-       rm -rf gmp
-       mkdir gmp
-       a="$^" ; \
-       for i in $^ ; do \
-               cp $$i gmp/$$(echo $$i | sed -e 's,\.\./,,1' -e 's,/,_,g') ; \
-       done
-       touch $@
-
-bfdfiles: $(shell find ../binutils -name "*.o")
-       rm -rf bfd
-       mkdir bfd
-       a="$^" ; \
-       for i in $$a ; do \
-               cp $$i bfd/$$(echo $$i | sed -e 's,\.\./,,1' -e 's,/,_,g') ; \
-       done 
-       touch $@
-
 OOBJS:=$(shell j=$$(ar t $(ODIR)/gcllib.a) ; for i in $$(ls -1 $(ODIR)/*.o) ; 
do if ! echo $$j |grep $$(basename $$i) >/dev/null 2>&1 ; then echo $$i ; fi ; 
done)
 OBJS:=$(OOBJS) $(shell ls -1 $(LSPDIR)/*.o)
 OBJS:=$(OBJS) $(shell ls -1 $(CMPDIR)/*.o | grep -v collectfn.o)
@@ -119,28 +101,28 @@
 $(HDIR)/mdefs.h: $(HDIR)/include.h
        cat $(HDIR)/include.h | sed -e "/include/d" > $(HDIR)/mdefs.h
 
-libgcl.a: $(FIRST_FILE) $(OBJS) sys_gcl.o $(LAST_FILE) gmpfiles bfdfiles
+libgcl.a: $(FIRST_FILE) $(OBJS) sys_gcl.o $(LAST_FILE)
        rm -rf $@
-       $(ARRS) $@ $(filter %.o,$^) $(shell find gmp bfd -name "*.o")
+       $(ARRS) $@ $(filter %.o,$^)
 
-libpre_gcl.a: $(FIRST_FILE) $(OOBJS) sys_pre_gcl.o $(LAST_FILE) gmpfiles 
bfdfiles
+libpre_gcl.a: $(FIRST_FILE) $(OOBJS) sys_pre_gcl.o $(LAST_FILE)
        rm -rf $@
-       $(ARRS) $@ $(filter %.o,$^) $(shell find gmp bfd -name "*.o")
+       $(ARRS) $@ $(filter %.o,$^)
 
-libmod_gcl.a: $(FIRST_FILE) $(OBJS) $(MODOBJS) sys_mod_gcl.o $(LAST_FILE) 
gmpfiles bfdfiles
+libmod_gcl.a: $(FIRST_FILE) $(OBJS) $(MODOBJS) sys_mod_gcl.o $(LAST_FILE)
        rm -rf $@
-       $(ARRS) $@ $(filter %.o,$^) $(shell find gmp bfd -name "*.o")
+       $(ARRS) $@ $(filter %.o,$^)
 
 libxgcl.a: libgcl.a
        ln -snf $< $@
 
-libansi_gcl.a: $(FIRST_FILE) $(OBJS) $(ANSIOBJS) sys_ansi_gcl.o $(LAST_FILE) 
gmpfiles bfdfiles
+libansi_gcl.a: $(FIRST_FILE) $(OBJS) $(ANSIOBJS) sys_ansi_gcl.o $(LAST_FILE)
        rm -rf $@
-       $(ARRS) $@ $(filter %.o,$^) $(shell find gmp bfd -name "*.o")
+       $(ARRS) $@ $(filter %.o,$^)
 
-libpcl_gcl.a: $(FIRST_FILE) $(OBJS) $(PCLOBJS) sys_pcl_gcl.o $(LAST_FILE) 
gmpfiles bfdfiles
+libpcl_gcl.a: $(FIRST_FILE) $(OBJS) $(PCLOBJS) sys_pcl_gcl.o $(LAST_FILE)
        rm -rf $@
-       $(ARRS) $@ $(filter %.o,$^) $(shell find gmp bfd -name "*.o")
+       $(ARRS) $@ $(filter %.o,$^)
 
 raw_%: lib%.a libgclp.a $(SYSTEM_OBJS) $(EXTRAS)
        $(CC) -o raw_$*$(EXE) $(filter %.o,$^) \
@@ -148,8 +130,8 @@
 
 clean:
        rm -rf  saved_*$(EXE) raw_*$(EXE) *.o core a.out $(RSYM) \
-               $(LSPDIR)/auto_new.lsp foo *maxima* init_*.lsp lib*.a gmp* bfd* 
*.lsp.tmp \
+               $(LSPDIR)/auto_new.lsp foo *maxima* init_*.lsp lib*.a *.lsp.tmp 
\
                gazonk*.lsp
 
 .INTERMEDIATE: init_ansi_gcl.lsp.tmp init_gcl.lsp.tmp raw_gcl raw_ansi_gcl
-.PRECIOUS: init_gcl.lsp init_ansi_gcl.lsp
\ No newline at end of file
+.PRECIOUS: init_gcl.lsp init_ansi_gcl.lsp
Index: unixport/rsym_elf.c
===================================================================
RCS file: /cvsroot/gcl/gcl/unixport/rsym_elf.c,v
retrieving revision 1.11
diff -u -d -r1.11 rsym_elf.c
--- unixport/rsym_elf.c 6 Nov 2003 16:08:12 -0000       1.11
+++ unixport/rsym_elf.c 13 Nov 2003 08:48:51 -0000
@@ -136,7 +136,6 @@
        unsigned int i;
        FILE *fp;
        int symsize;
-       extern char *malloc();
        
         
        fp = fopen(filename, RDONLY);
Index: configure-new.ac
===================================================================
RCS file: /cvsroot/gcl/gcl/configure-new.ac,v
retrieving revision 1.2
diff -u -d -r1.2 configure-new.ac
--- configure-new.ac    30 Jul 2002 06:29:35 -0000      1.2
+++ configure-new.ac    13 Nov 2003 08:48:39 -0000
@@ -974,37 +974,7 @@
 
 MP_INLCUDE=""
 if test $use_gmp = yes ; then
- AC_MSG_CHECKING([use_gmp=yes, doing configure in gmp directory])
- case "${canonical}" in
-#   i[[5-9]]86* | pentium* | k6* | athlon*)
-#      (cd gmp ; ./configure --target=i486) ;;
-   *)
-      (cd gmp ; ./configure) ;;
- esac
- [[ "`ls -1 gmp/mpn/add_n.* 2>/dev/null`" != "" ]] || cp gmp/mpn/generic/*.c 
gmp/mpn/
- AC_MSG_CHECKING("for size of gmp limbs")
- AC_TRY_RUN([#include <stdio.h>
-       #include "h/gmp.h"
-       
-       int main() {
-       FILE *fp=fopen("conftest1","w");
-       fprintf(fp,"%u",sizeof(mp_limb_t));
-       fclose(fp);
-       return 0;
-}],mpsize=`cat conftest1`,mpsize=0,mpsize=0)
- if test "$mpsize" = "0" ; then
-       echo "Cannot determine mpsize"
-       exit 1
- fi
- AC_DEFINE_UNQUOTED(MP_LIMB_BYTES,$mpsize)
- AC_MSG_RESULT($mpsize) 
- GMP=1
- AC_DEFINE(GMP)
- AC_SUBST(GMP)
- MP_INCLUDE=h/gmp.h
- echo > makedefsafter
- echo 'MPFILES=${GMP_DIR}libgmp.a' >> makedefsafter
- echo >> makedefsafter
+ MP_INCLUDE=gmp.h
 fi
 AC_SUBST(MP_INCLUDE)
  
Index: configure.in
===================================================================
RCS file: /cvsroot/gcl/gcl/configure.in,v
retrieving revision 1.126
diff -u -d -r1.126 configure.in
--- configure.in        10 Oct 2003 05:32:47 -0000      1.126
+++ configure.in        13 Nov 2003 08:48:40 -0000
@@ -239,7 +239,6 @@
 def_dlopen="no"
 def_statsysbfd="yes"
 def_custreloc="no"
-def_oldgmp="no"
 def_pic="no";
 def_static="no";
 case $use in 
@@ -256,8 +255,6 @@
                        def_dlopen="yes" ; def_statsysbfd="no" ; 
def_static="no" ;;
                hppa*)
                        def_dlopen="yes" ; def_statsysbfd="no" def_pic="yes" ;;
-#              m68k*)
-#                      def_oldgmp="yes" ;;
        esac;;
     *mingw*)
        def_statsysbfd="no" ; def_custreloc="yes" ;;
@@ -287,14 +284,6 @@
        [ --enable-pic builds gcl with -fPIC in CFLAGS ]
        ,,enable_pic="$def_pic")
 
-AC_ARG_ENABLE(oldgmp,
-       [ --enable-oldgmp will link against gmp2 instead of gmp3 ]
-       ,,enable_oldgmp="$def_oldgmp")
-
-AC_ARG_ENABLE(dynsysgmp,
-       [ --enable-dynsysgmp will link against the system libgmp3 overriding 
certain functions with patched versions from the local source ]
-       ,,enable_dynsysgmp="no")
-
 load_opt="0"
 if test "$enable_dlopen" = "yes" ; then
    load_opt=1
@@ -373,7 +362,7 @@
 
 TCFLAGS="-Wall -DVOL=volatile -fsigned-char"
 if test "$GCC" = "yes" ; then
-       TCFLAGS="$TCFLAGS -fwritable-strings -pipe"
+       TCFLAGS="$TCFLAGS -fwritable-strings"
 fi
 
 TO3FLAGS=""
@@ -383,8 +372,8 @@
        # for subconfigurations
        CFLAGS=-g
 else
-       TO3FLAGS="-O3 -fomit-frame-pointer"
-       TO2FLAGS="-O"
+       TO3FLAGS="-fomit-frame-pointer"
+       TO2FLAGS=""
 fi
 
 AC_CHECK_PROGS(AWK,gawk nawk awk,"")
@@ -468,60 +457,7 @@
 MP_INLCUDE=""
 if test $use_gmp = yes ; then
 
- AC_MSG_CHECKING([use_gmp=yes, doing configure in gmp directory])
- echo
- echo "#"
- echo "#"
- echo "# -------------------"
- echo "# Subconfigure of GMP"
- echo "#"
- echo "#"
-
- if test "$enable_oldgmp" = "yes" ; then
-       GMPDIR=gmp
- else
-       GMPDIR=gmp3
- fi
-
- if test "$use_common_binary" = "yes"; then
-   cd $GMPDIR && ./configure --host=$host && cd ..
- else
-   cd $GMPDIR && ./configure && cd ..
- fi
-#MY_SUBDIRS="$MY_SUBDIRS $GMPDIR" 
-
- echo "#"
- echo "#"
- echo "#"
- echo "# Subconfigure of GMP done"
- echo "# ------------------------"
- echo "#"
-
- PATCHED_SYMBOLS=""
- if test "$enable_dynsysgmp" = "yes" ; then
-       AC_CHECK_HEADER(gmp.h,
-               AC_CHECK_LIB(gmp,__gmpz_init,
-                       MPFILES=$GMPDIR/mpn/mul_n.o
-                       PATCHED_SYMBOLS=__gmpn_toom3_mul_n
-                       if test "$use" = "m68k-linux" ; then
-                               MPFILES="$MPFILES $GMPDIR/mpn/lshift.o 
$GMPDIR/mpn/rshift.o"
-                               PATCHED_SYMBOLS="$PATCHED_SYMBOLS __gmpn_lshift 
__gmpn_rshift"
-                       fi
-                       TLIBS="$TLIBS -lgmp"
-                       echo "#include \"gmp.h\"" >foo.c
-                       echo "int main() {return 0;}" >>foo.c
-                       MP_INCLUDE=`cpp foo.c | grep /gmp.h | head -1l | $AWK 
'{print $3}' | tr -d '"'`
-                       rm -f foo.c,
-                       echo "Cannot use dynamic gmp lib" ; exit 1,),
-               echo "Cannot use dynamic gmp lib" ; exit 1,)
-
-else                   
-
-       cp $GMPDIR/gmp.h h/gmp.h
-       MP_INCLUDE=h/gmp.h
-       MPFILES=gmp_all
-
-fi
+ MP_INCLUDE=gmp.h
 
  AC_MSG_CHECKING("for size of gmp limbs")
  AC_TRY_RUN([#include <stdio.h>
@@ -563,11 +499,7 @@
  GMP=1
  AC_DEFINE(GMP)
  AC_SUBST(GMP)
- AC_SUBST(GMPDIR)
- echo > makedefsafter
- echo "MPFILES=$MPFILES" >> makedefsafter
- echo "PATCHED_SYMBOLS=$PATCHED_SYMBOLS" >> makedefsafter
- echo >> makedefsafter
+ TLIBS="$TLIBS -L${prefix}/lib -lgmp"
 fi
 
 
@@ -677,42 +609,6 @@
        fi
 fi
 
-if test "$enable_locbfd" = "yes" ; then
-       echo "#"
-       echo "#"
-       echo "# -------------------------"
-       echo "# Subconfigure of LIBIBERTY"
-       echo "#"
-       echo "#"
-       cd binutils/libiberty && chmod +x configure && ./configure && cd ../..
-#       MY_SUBDIRS="$MY_SUBDIRS binutils/libiberty " 
-       echo "#"
-       echo "#"
-       echo "#"
-       echo "# Subconfigure of LIBIBERTY done"
-       echo "# ------------------------------"
-       echo "#"
-       echo "#"
-       echo "#"
-       echo "# -------------------"
-       echo "# Subconfigure of BFD"
-       echo "#"
-       echo "#"
-       cd binutils/bfd && chmod +x configure && ./configure && cd ../..
-#       MY_SUBDIRS="$MY_SUBDIRS binutils/bfd " 
-       echo "#"
-       echo "#"
-       echo "#"
-       echo "# Subconfigure of BFD done"
-       echo "# ------------------------"
-       echo "#"
-       TLIBS="$TLIBS `pwd`/binutils/bfd/libbfd.a 
`pwd`/binutils/libiberty/libiberty.a"
-       AC_DEFINE(HAVE_LIBBFD)
-       BUILD_BFD="h/bfd.h h/bfdlink.h h/ansidecl.h h/symcat.h"
-       AC_SUBST(BUILD_BFD)
-fi
-
-#AC_CONFIG_SUBDIRS($MY_SUBDIRS)
 
 # Find where Data begins.  This is used by the storage allocation
 # mechanism, in the PAGE macro.  This offset is subtracted from
@@ -1343,30 +1239,30 @@
 
 if test -d ${TK_CONFIG_PREFIX}/tk${TK_VERSION} ; then
   TK_LIBRARY=${TK_CONFIG_PREFIX}/tk${TK_VERSION}
-  else
+else
   if test -d ${TK_CONFIG_PREFIX}/../tk${TK_VERSION} ; then
     TK_LIBRARY=${TK_CONFIG_PREFIX}/../tk${TK_VERSION}
   fi
 fi
 if test -d ${TK_CONFIG_PREFIX}/tcl${TCL_VERSION} ; then
   TCL_LIBRARY=${TK_CONFIG_PREFIX}/tcl${TCL_VERSION}
-  else
+else
   if test -d ${TK_CONFIG_PREFIX}/../tcl${TCL_VERSION} ; then
     TCL_LIBRARY=${TK_CONFIG_PREFIX}/../tcl${TCL_VERSION}
   fi
 fi
 if test -f ${TK_CONFIG_PREFIX}/../include/tk.h ; then
   TK_INCLUDE=-I${TK_CONFIG_PREFIX}/../include
-  else
-  if test -f /usr/include/tcl${TCL_VERSION}/tk.h ; then
-    TK_INCLUDE=-I/usr/include/tcl${TCL_VERSION}
+else
+  if test -f ${TK_CONFIG_PREFIX}/../../include/tk${TK_VERSION}/tk.h ; then
+    TK_INCLUDE=-I${TK_CONFIG_PREFIX}/../../include/tk${TK_VERSION}
   fi   
 fi
 if test -f ${TCL_CONFIG_PREFIX}/../include/tcl.h ; then
   TCL_INCLUDE=-I${TCL_CONFIG_PREFIX}/../include
-  else
-  if test -f /usr/include/tcl${TCL_VERSION}/tcl.h ; then
-    TCL_INCLUDE=-I/usr/include/tcl${TCL_VERSION}
+else
+  if test -f ${TCL_CONFIG_PREFIX}/../../include/tcl${TCL_VERSION}/tcl.h ; then
+    TCL_INCLUDE=-I${TCL_CONFIG_PREFIX}/../../include/tcl${TCL_VERSION}
   fi
 fi
 AC_CHECK_LIB(lieee,main,have_ieee=1,have_ieee=0)
@@ -1482,7 +1378,7 @@
 AC_SUBST(LIBS)
 FINAL_CFLAGS="$TCFLAGS $PROCESSOR_FLAGS"
 AC_SUBST(FINAL_CFLAGS)
-CFLAGS="$TCFLAGS $TO3FLAGS $PROCESSOR_FLAGS -I\$(GCLDIR)/o"
+CFLAGS="$TCFLAGS $TO3FLAGS $PROCESSOR_FLAGS -I${prefix}/include -I\$(GCLDIR)/o"
 AC_SUBST(CFLAGS)
 # Work around bug with gcc on ppc -- CM
 NIFLAGS="$TCFLAGS $TONIFLAGS $PROCESSOR_FLAGS -I\$(GCLDIR)/o"
Index: makefile
===================================================================
RCS file: /cvsroot/gcl/gcl/makefile,v
retrieving revision 1.83
diff -u -d -r1.83 makefile
--- makefile    31 Oct 2003 16:26:54 -0000      1.83
+++ makefile    13 Nov 2003 08:48:40 -0000
@@ -31,27 +31,16 @@
 PCLDIR = pcl
 MPDIR  = mp
 TESTDIR = ansi-tests
-#GMP_DIR = gmp3/
 
-all: $(BUILD_BFD) $(PORTDIR)/$(FLISP) command cmpnew/gcl_collectfn.o 
lsp/gcl_info.o do-gcl-tk do-info
+all: $(PORTDIR)/$(FLISP) command cmpnew/gcl_collectfn.o lsp/gcl_info.o 
do-gcl-tk do-info
 
 xgcl: $(PORTDIR)/saved_xgcl
 
 $(PORTDIR)/saved_xgcl: $(PORTDIR)/saved_gcl
        cd xgcl-2 && $(MAKE)
 
-binutils/bfd/libbfd.a binutils/libiberty/libiberty.a:
-       cd $(@D) && $(MAKE)
-
-h/bfd.h: binutils/bfd/libbfd.a binutils/libiberty/libiberty.a
-       cp $(<D)/$(@F) $@
-
-h/bfdlink.h h/ansidecl.h h/symcat.h: binutils/bfd/libbfd.a 
binutils/libiberty/libiberty.a
-       cp $(<D)/../include/$(@F) $@
-
 $(PORTDIR)/saved_pre_gcl: $(HDIR)cmpinclude.h
        (cd $(BINDIR); $(MAKE) all)
-       $(MAKE) mpfiles
        rm -f o/cmpinclude.h ; cp h/cmpinclude.h o
        (cd $(ODIR); $(MAKE) all)
        $(MAKE) $<
@@ -102,21 +91,9 @@
 do-info:
        cd info && $(MAKE)
 
-mpfiles: $(MPFILES)
-
 $(MPDIR)/libmport.a:
        (cd mp ; $(MAKE) all)
 
-$(GMPDIR)/libgmp.a: $(GMPDIR)/Makefile
-       cd $(GMPDIR) && $(MAKE) && rm -f libgmp.a &&  ar qc libgmp.a *.o */*.o
-
-gmp_all: $(GMPDIR)/Makefile
-       cd $(GMPDIR) && $(MAKE) 
-       touch $@
-
-$(GMPDIR)/mpn/mul_n.o $(GMPDIR)/mpn/lshift.o $(GMPDIR)/mpn/rshift.o: 
$(GMPDIR)/Makefile
-       cd $(@D) && $(MAKE) $(@F)
-
 command:
        rm -f bin/gcl xbin/gcl
        MGCLDIR=`echo $(GCLDIR) | sed -e 'sX^\([a-z]\):X/\1Xg'` ; \
@@ -171,10 +148,11 @@
        mkdir -p $(DESTDIR)$(prefix)/lib 
        mkdir -p $(DESTDIR)$(prefix)/bin
        mkdir -p $(DESTDIR)$(INSTALL_LIB_DIR)
+       mkdir -p $(DESTDIR)$(prefix)/info
        MINSTALL_LIB_DIR=`echo $(INSTALL_LIB_DIR) | sed -e 
'sX^\([a-z]\):X/\1Xg'` ; \
        $(MAKE) install-command "INSTALL_LIB_DIR=$(INSTALL_LIB_DIR)" 
"prefix=$(prefix)" "DESTDIR=$(DESTDIR)" "BINDIR=$$MINSTALL_LIB_DIR/unixport"
        rm -f $(DESTDIR)$(prefix)/bin/gcl.exe
-       tar cf - $(PORTDIR)/$(FLISP)$(EXE) info/*.info* $(LISP_LIB) \
+       tar cf - $(PORTDIR)/$(FLISP)$(EXE) $(LISP_LIB) \
        $(TCL_EXES)  |  (cd $(DESTDIR)$(INSTALL_LIB_DIR) ;tar xf -)
        if gcc --version | grep -i mingw >/dev/null 2>&1 ; then if grep -i 
oncrpc makedefs >/dev/null 2>&1 ; then cp /mingw/bin/oncrpc.dll 
$(DESTDIR)$(INSTALL_LIB_DIR)/$(PORTDIR); fi ; fi
        cd $(DESTDIR)$(INSTALL_LIB_DIR)/$(PORTDIR) && \
@@ -209,16 +187,14 @@
        (cd $(CMPDIR); $(MAKE) clean)
        (cd $(PORTDIR); $(MAKE) clean)
        (cd gcl-tk ; $(MAKE) clean)
-       -(cd $(GMPDIR) ; $(MAKE) distclean)
        cd $(CLCSDIR) && $(MAKE) clean
        cd $(PCLDIR) && $(MAKE) clean
        cd xgcl-2 && $(MAKE) clean
        (cd $(TESTDIR); $(MAKE) clean)
        (cd info ; $(MAKE) clean)
        rm -f foo.tcl config.log makedefs makedefsafter config.cache 
config.status makedefc
-       rm -f h/config.h h/gclincl.h h/cmpinclude.h h/gmp.h
-       rm -rf $(GMPDIR)/.deps $(GMPDIR)/libgmp.a
-       rm -f xbin/gcl foo foo.c bin/gclm.bat gmp_all
+       rm -f h/config.h h/gclincl.h h/cmpinclude.h
+       rm -f xbin/gcl foo foo.c bin/gclm.bat
        rm -f h/*-linux.defs h/bfd.h h/bfdlink.h h/ansidecl.h h/symcat.h
        rm -f windows/gcl.iss bin/gcl.bat windows/gcl.ansi.iss 
windows/install.ansi.lsp \
                windows/install.lsp
@@ -226,8 +202,6 @@
        rm -f ansi-tests/test_results ansi-tests/gazonk* \
                ansi-tests/generated-eval-when-test-file.lisp
        rm -f config.log config.cache config.status
-       -cd binutils/bfd && $(MAKE) distclean
-       -cd binutils/libiberty && $(MAKE) distclean
 
 CMPINCLUDE_FILES=$(HDIR)cmpincl1.h $(HDIR)gclincl.h $(HDIR)compbas.h 
$(HDIR)enum.h $(HDIR)mgmp.h $(HDIR)object.h $(HDIR)vs.h \
        $(HDIR)bds.h $(HDIR)frame.h \
@@ -237,13 +211,16 @@
 
 OTHERS=$(HDIR)notcomp.h $(HDIR)rgbc.h $(HDIR)stacks.h 
 
-$(HDIR)cmpinclude.h: $(CMPINCLUDE_FILES) $(HDIR)config.h
+$(HDIR)cmpinclude.h: $(CMPINCLUDE_FILES) $(HDIR)config.h $(HDIR)new_decl.h
        cat $(HDIR)config.h | sed -e "1,/Begin for cmpincl/d" \
                -e "/End for cmpinclude/,50000d" > tmpx
        cat $(CMPINCLUDE_FILES) >> tmpx
        ./xbin/move-if-changed mv tmpx h/cmpinclude.h
        ./xbin/move-if-changed cp h/cmpinclude.h o/cmpinclude.h
 
+$(HDIR)new_decl.h:
+       (cd $(ODIR); $(MAKE) decls1)
+
 go:
        mkdir go
        (cd go ; cp -s ../o/makefile ../o/*.o ../o/*.c ../o/*.d ../o/*.ini  .)
@@ -261,4 +238,4 @@
        (cd go ; $(MAKE)  "CFLAGS = -I../h -pg  -c -g ")
        (cd unixport ; $(MAKE) gcp)
 
-.INTERMEDIATE: unixport/saved_pcl_gcl
\ No newline at end of file
+.INTERMEDIATE: unixport/saved_pcl_gcl

reply via email to

[Prev in Thread] Current Thread [Next in Thread]