2 # The Regents of The University of Michigan
5 # This code is part of the M5 simulator.
7 # Permission is granted to use, copy, create derivative works and
8 # redistribute this software and such derivative works for any purpose,
9 # so long as the copyright notice above, this grant of permission, and
10 # the disclaimer below appear in all copies made; and so long as the
11 # name of The University of Michigan is not used in any advertising or
12 # publicity pertaining to the use or distribution of this software
13 # without specific, written prior authorization.
15 # THIS SOFTWARE IS PROVIDED AS IS, WITHOUT REPRESENTATION FROM THE
16 # UNIVERSITY OF MICHIGAN AS TO ITS FITNESS FOR ANY PURPOSE, AND WITHOUT
17 # WARRANTY BY THE UNIVERSITY OF MICHIGAN OF ANY KIND, EITHER EXPRESS OR
18 # IMPLIED, INCLUDING WITHOUT LIMITATION THE IMPLIED WARRANTIES OF
19 # MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE REGENTS OF
20 # THE UNIVERSITY OF MICHIGAN SHALL NOT BE LIABLE FOR ANY DAMAGES,
21 # INCLUDING DIRECT, SPECIAL, INDIRECT, INCIDENTAL, OR CONSEQUENTIAL
22 # DAMAGES, WITH RESPECT TO ANY CLAIM ARISING OUT OF OR IN CONNECTION
23 # WITH THE USE OF THE SOFTWARE, EVEN IF IT HAS BEEN OR IS HEREAFTER
24 # ADVISED OF THE POSSIBILITY OF SUCH DAMAGES.
26 # Authors: Nathan L. Binkert
29 ### If we are not compiling on an alpha, we must use cross tools ###
30 ifneq ($(shell uname
-m
), alpha
)
31 CROSS_COMPILE?
=alpha-unknown-linux-gnu-
33 CC
=$(CROSS_COMPILE
)gcc
37 DBMENTRY
= fffffc0000010000
38 CFLAGS
=-I .
-I ..
/h
-I
$(M5
)/src
/dev
-I
$(M5
)/util
/m5
/ -fno-builtin
-Wa
,-m21164
39 OBJS
=dbmentry.o printf.o paljtokern.o paljtoslave.o console.o m5op.o
41 ### Make sure that the M5 variable is set ###
43 $(error The M5 variable must be set
)
48 m5op.o
: $(M5
)/util
/m5
/m5op.S
49 $(CC
) $(CFLAGS
) -nostdinc
-o
$@
-c
$<
52 $(CC
) $(CFLAGS
) -nostdinc
-o
$@
-c
$<
55 $(CC
) -g3
$(CFLAGS
) -o
$@
-c
$<
58 $(LD
) -o console
-N
-Ttext
$(DBMENTRY
) -non_shared
$(OBJS
) -lc