source: branches/working-0710/ccl/lisp-kernel/linuxx8664/Makefile @ 7526

Last change on this file since 7526 was 7526, checked in by gb, 13 years ago

Maybe should define HAVE_TLS_BUT_IT_DOESNT_WORK.
Don't define HAVE_TLS in M4FLAGS or CFLAGS.

  • Property svn:eol-style set to native
  • Property svn:keywords set to Author Date Id Revision
File size: 2.4 KB
Line 
1#
2#   Copyright (C) 2005 Clozure Associates
3#   This file is part of OpenMCL. 
4#
5#   OpenMCL is licensed under the terms of the Lisp Lesser GNU Public
6#   License , known as the LLGPL and distributed with OpenMCL as the
7#   file "LICENSE".  The LLGPL consists of a preamble and the LGPL,
8#   which is distributed with OpenMCL as the file "LGPL".  Where these
9#   conflict, the preamble takes precedence. 
10#
11#   OpenMCL is referenced in the preamble as the "LIBRARY."
12#
13#   The LLGPL is also available online at
14#   http://opensource.franz.com/preamble.html
15
16
17VPATH = ../
18RM = /bin/rm
19AS = as
20M4 = m4
21ASFLAGS = --64
22M4FLAGS = -DLINUX -DX86 -DX8664 # -DHAVE_TLS
23CDEFINES = -DLINUX -D_REENTRANT -DX86 -DX8664 -D_GNU_SOURCE # -DHAVE_TLS #-DDISABLE_EGC
24CDEBUG = -g
25COPT = -O2
26
27# If the linker supports a "--hash-style=" option, use traditional
28# SysV hash tables.  (If it doesn't support that option, assume
29# that traditional hash tables will be used by default.)
30ld_has_hash_style = $(shell $(LD) --help | grep "hash-style=")
31ifeq ($(ld_has_hash_style),)
32HASH_STYLE=
33else
34HASH_STYLE="-Wl,--hash-style=sysv"
35endif
36
37
38.s.o:
39        $(M4) $(M4FLAGS) -I../ $< | $(AS)  $(ASFLAGS) -o $@
40.c.o:
41        $(CC) -c $< $(CDEFINES) $(CDEBUG) $(COPT) -m64 -o $@
42
43SPOBJ = pad.o x86-spjump64.o x86-spentry64.o x86-subprims64.o
44ASMOBJ = x86-asmutils64.o imports.o
45
46COBJ  = pmcl-kernel.o x86-gc.o bits.o  x86-exceptions.o \
47        image.o thread_manager.o lisp-debug.o memory.o
48
49DEBUGOBJ = lispdcmd.o plprint.o plsym.o xlbt.o x86_print.o
50KERNELOBJ= $(COBJ) x86-asmutils64.o  imports.o
51
52SPINC = lisp.s m4macros.m4 x86-constants.s x86-macros.s errors.s x86-uuo.s \
53        x86-constants64.s
54
55CHEADERS = area.h bits.h x86-constants.h lisp-errors.h gc.h lisp.h \
56        lisp-exceptions.h lisp_globals.h macros.h memprotect.h image.h \
57        Threads.h x86-constants64.h x86-exceptions.h lisptypes.h
58
59
60KSPOBJ = $(SPOBJ)
61all:    ../../lx86cl64
62
63
64OSLIBS = -ldl -lm -lpthread
65LINK_MAP = ./elf_x86_64.x
66USE_LINK_MAP = # -T ./elf_x86_64.x
67
68../../lx86cl64: $(KSPOBJ) $(KERNELOBJ) $(DEBUGOBJ) Makefile  $(LINK_MAP)
69        $(CC)  -m64 $(CDEBUG)  -Wl,--export-dynamic $(HASH_STYLE) -o $@ $(USE_LINK_MAP) $(KSPOBJ) $(KERNELOBJ) $(DEBUGOBJ) $(OSLIBS)
70
71
72$(SPOBJ): $(SPINC)
73$(ASMOBJ): $(SPINC)
74$(COBJ): $(CHEADERS)
75$(DEBUGOBJ): $(CHEADERS) lispdcmd.h
76
77
78cclean:
79        $(RM) -f $(KERNELOBJ) $(DEBUGOBJ) ../../lx86cl64
80
81clean:  cclean
82        $(RM) -f $(SPOBJ)
83
84strip:  ../../lx86cl64
85        strip -g ../../lx86cl64
Note: See TracBrowser for help on using the repository browser.