summaryrefslogtreecommitdiff
path: root/Makeconf
diff options
context:
space:
mode:
authorMichael I. Bushnell <mib@gnu.org>1993-11-03 16:03:56 +0000
committerMichael I. Bushnell <mib@gnu.org>1993-11-03 16:03:56 +0000
commitb4657e6633cbfa2d5595fef9d48b0b47d6fe8f25 (patch)
treef2e32eec372f7802954e1e58d5fd051a4813f7c4 /Makeconf
parent2041bf7e8318fd85773d08ebb42206ca55ceb95f (diff)
Formerly Makeconf.~2~
Diffstat (limited to 'Makeconf')
-rw-r--r--Makeconf26
1 files changed, 18 insertions, 8 deletions
diff --git a/Makeconf b/Makeconf
index 3a097c59..7ec1779f 100644
--- a/Makeconf
+++ b/Makeconf
@@ -4,22 +4,32 @@
hurdinst := /home/hm1/hurdinst
# Where to find various things for compilation:
-headers := $(HURDINST)/include
-startup := $(HURDINST)/lib/crt0.a
-libc := $(HURDINST)/lib/libc.a
-libthreads := $(HURDINST)/lib/libthreads.a
+headers := $(hurdinst)/include
+startup := $(hurdinst)/lib/crt0.o
+libc := $(hurdinst)/lib/libc.a
+libthreads := $(hurdinst)/lib/libthreads.a
+gccheaders := /usr/local/lib/gcc-lib/i386-compaq-mach/2.4.5/include
# Flags for compilation
-CPPFLAGS := -nostdinc -I$(HEADERS) -I$(GCCHEADERS)
+CPPFLAGS := -nostdinc -I$(headers) -I$(gccheaders)
CFRAGS := -Wall -Wno-parentheses -O -g
# Finding binaries
CC=gcc
MIGCOM=/usr/local/lib/migcom
+CPP=/usr/local/lib/gcc-lib/i386-compaq-mach/2.4.5/cpp
+MIG=mig
-# Finding the GCC headers (you must have GCC version 2.4.5 or later)
-
-GCCHEADERS=$(exec $(CC) -v | head -1 | awk '{print $4}' | sed -e 's/specs/include/')
+# How to do some things:
+ldflags = $(addprefix -Xlinker ,$(LDFLAGS))
+define link
+$(CC) -nostdlib -e__start $(ldflags) -o $@ $(CFLAGS) $(startup) \
+$^ $(libc) -lgcc $(libc)
+endef
+define link-with-threads
+$(CC) -nostdlib -e__start $(ldflags) -o $@ $(CFLAGS) $(startup) \
+$^ $(libthreads) $(libc) -lgcc $(libc)
+endef