Makefile revision 8012:2f71125bf413
12SN/A#Copyright (c) 2005 
213575Sciro.santilli@arm.com#The Regents of The University of Michigan
313575Sciro.santilli@arm.com#All Rights Reserved
413575Sciro.santilli@arm.com#
513575Sciro.santilli@arm.com#This code is part of the M5 simulator, developed by Nathan Binkert,
613575Sciro.santilli@arm.com#Erik Hallnor, Steve Raasch, and Steve Reinhardt, with contributions
713575Sciro.santilli@arm.com#from Ron Dreslinski, Dave Greene, Lisa Hsu, Ali Saidi, and Andrew
813575Sciro.santilli@arm.com#Schultz.
913575Sciro.santilli@arm.com#
1013575Sciro.santilli@arm.com#Permission is granted to use, copy, create derivative works and
1113575Sciro.santilli@arm.com#redistribute this software and such derivative works for any purpose,
1213575Sciro.santilli@arm.com#so long as the copyright notice above, this grant of permission, and
1311274Sshingarov@labware.com#the disclaimer below appear in all copies made; and so long as the
1410595Sgabeblack@google.com#name of The University of Michigan is not used in any advertising or
151762SN/A#publicity pertaining to the use or distribution of this software
162SN/A#without specific, written prior authorization.
172SN/A#
182SN/A#THIS SOFTWARE IS PROVIDED AS IS, WITHOUT REPRESENTATION FROM THE
192SN/A#UNIVERSITY OF MICHIGAN AS TO ITS FITNESS FOR ANY PURPOSE, AND WITHOUT
202SN/A#WARRANTY BY THE UNIVERSITY OF MICHIGAN OF ANY KIND, EITHER EXPRESS OR
212SN/A#IMPLIED, INCLUDING WITHOUT LIMITATION THE IMPLIED WARRANTIES OF
222SN/A#MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE REGENTS OF
232SN/A#THE UNIVERSITY OF MICHIGAN SHALL NOT BE LIABLE FOR ANY DAMAGES,
242SN/A#INCLUDING DIRECT, SPECIAL, INDIRECT, INCIDENTAL, OR CONSEQUENTIAL
252SN/A#DAMAGES, WITH RESPECT TO ANY CLAIM ARISING OUT OF OR IN CONNECTION
262SN/A#WITH THE USE OF THE SOFTWARE, EVEN IF IT HAS BEEN OR IS HEREAFTER
272SN/A#ADVISED OF THE POSSIBILITY OF SUCH DAMAGES.
282SN/A
292SN/ADBMENTRY	= fffffc0000010000
302SN/ACFLAGS=-I . -I ../h -I$(M5)/dev -nostdinc++ -Wa,-m21164
312SN/A
322SN/AARCHNAME=$(shell uname -m)
332SN/A
342SN/A### If we are not compiling on an alpha, we must use cross tools ###    
352SN/Aifneq ($(ARCHNAME), alpha)
362SN/ACROSS_COMPILE?=alpha-unknown-linux-gnu-
372SN/Aendif
382SN/ACC=$(CROSS_COMPILE)gcc
392SN/AAS=$(CROSS_COMPILE)as
402665Ssaidi@eecs.umich.eduLD=$(CROSS_COMPILE)ld
412665Ssaidi@eecs.umich.edu
4211274Sshingarov@labware.comOBJS=dbmentry.o printf.o paljtokern.o paljtoslave.o
432SN/ATLOBJS+=$(OBJS) console_tl.o
442SN/ATSOBJS+=$(OBJS) console_ts.o
452SN/A
462SN/A### Make sure that the M5 variable is set ###
472SN/Aifndef M5
483960Sgblack@eecs.umich.edu$(error The M5 variable must be set)
4977SN/Aendif
5012031Sgabeblack@google.com
518229Snate@binkert.orgall: console_tl console_ts
5212031Sgabeblack@google.com
538229Snate@binkert.org%.o: %.S
542986Sgblack@eecs.umich.edu	$(CC) $(CFLAGS) -nostdinc -o $@ -c $<
5510595Sgabeblack@google.com
5656SN/Aconsole_ts.o: console.c
5756SN/A	$(CC)  -g3 $(CFLAGS) -D _TIME_T -D TSUNAMI -o $@ -c $<
588229Snate@binkert.org
592SN/Aconsole_tl.o: console.c
602SN/A	$(CC)  -g3 $(CFLAGS) -D _TIME_T -D TLASER  -o $@ -c $< 
612680Sktlim@umich.edu
622SN/Aprintf.o: printf.c 
6312449Sgabeblack@google.com	$(CC)  -g3 $(CFLAGS) -o $@ -c $<
6412449Sgabeblack@google.com
653536Sgblack@eecs.umich.educonsole_ts: $(TSOBJS)
6612449Sgabeblack@google.com	$(LD) -o console_ts  -N -Ttext $(DBMENTRY) -non_shared $(TSOBJS) -lc
6712449Sgabeblack@google.com
6812449Sgabeblack@google.comconsole_tl: $(TLOBJS)
6912449Sgabeblack@google.com	$(LD) -o console_tl  -N -Ttext $(DBMENTRY) -non_shared $(TLOBJS) -lc
7012449Sgabeblack@google.com
7112449Sgabeblack@google.comclean:
7212449Sgabeblack@google.com	rm -f *.o console_t?
7312449Sgabeblack@google.com