Makefile revision 8026
18013Sbinkertn@umich.edu# Copyright (c) 2005 28013Sbinkertn@umich.edu# The Regents of The University of Michigan 38013Sbinkertn@umich.edu# All Rights Reserved 48012Ssaidi@eecs.umich.edu# 58026Ssaidi@eecs.umich.edu# This code is part of the M5 simulator. 68012Ssaidi@eecs.umich.edu# 78013Sbinkertn@umich.edu# Permission is granted to use, copy, create derivative works and 88013Sbinkertn@umich.edu# redistribute this software and such derivative works for any purpose, 98013Sbinkertn@umich.edu# so long as the copyright notice above, this grant of permission, and 108013Sbinkertn@umich.edu# the disclaimer below appear in all copies made; and so long as the 118013Sbinkertn@umich.edu# name of The University of Michigan is not used in any advertising or 128013Sbinkertn@umich.edu# publicity pertaining to the use or distribution of this software 138013Sbinkertn@umich.edu# without specific, written prior authorization. 148012Ssaidi@eecs.umich.edu# 158013Sbinkertn@umich.edu# THIS SOFTWARE IS PROVIDED AS IS, WITHOUT REPRESENTATION FROM THE 168013Sbinkertn@umich.edu# UNIVERSITY OF MICHIGAN AS TO ITS FITNESS FOR ANY PURPOSE, AND WITHOUT 178013Sbinkertn@umich.edu# WARRANTY BY THE UNIVERSITY OF MICHIGAN OF ANY KIND, EITHER EXPRESS OR 188013Sbinkertn@umich.edu# IMPLIED, INCLUDING WITHOUT LIMITATION THE IMPLIED WARRANTIES OF 198013Sbinkertn@umich.edu# MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE REGENTS OF 208013Sbinkertn@umich.edu# THE UNIVERSITY OF MICHIGAN SHALL NOT BE LIABLE FOR ANY DAMAGES, 218013Sbinkertn@umich.edu# INCLUDING DIRECT, SPECIAL, INDIRECT, INCIDENTAL, OR CONSEQUENTIAL 228013Sbinkertn@umich.edu# DAMAGES, WITH RESPECT TO ANY CLAIM ARISING OUT OF OR IN CONNECTION 238013Sbinkertn@umich.edu# WITH THE USE OF THE SOFTWARE, EVEN IF IT HAS BEEN OR IS HEREAFTER 248013Sbinkertn@umich.edu# ADVISED OF THE POSSIBILITY OF SUCH DAMAGES. 258026Ssaidi@eecs.umich.edu# 268026Ssaidi@eecs.umich.edu# Authors: Nathan L. Binkert 278026Ssaidi@eecs.umich.edu# Ali G. Saidi 287992Ssaidi@eecs.umich.edu 297992Ssaidi@eecs.umich.edu### If we are not compiling on an alpha, we must use cross tools ### 308013Sbinkertn@umich.eduifneq ($(shell uname -m), alpha) 318012Ssaidi@eecs.umich.eduCROSS_COMPILE?=alpha-unknown-linux-gnu- 327992Ssaidi@eecs.umich.eduendif 338012Ssaidi@eecs.umich.eduCC=$(CROSS_COMPILE)gcc 348012Ssaidi@eecs.umich.eduAS=$(CROSS_COMPILE)as 358012Ssaidi@eecs.umich.eduLD=$(CROSS_COMPILE)ld 367992Ssaidi@eecs.umich.edu 378013Sbinkertn@umich.eduDBMENTRY= fffffc0000010000 388024Ssaidi@eecs.umich.eduCFLAGS=-I . -I ../h -I$(M5)/dev -I$(M5)/util/m5/ -fno-builtin -Wa,-m21164 398024Ssaidi@eecs.umich.eduOBJS=dbmentry.o printf.o paljtokern.o paljtoslave.o console.o m5op.o 408008Ssaidi@eecs.umich.edu 417992Ssaidi@eecs.umich.edu### Make sure that the M5 variable is set ### 427992Ssaidi@eecs.umich.eduifndef M5 437992Ssaidi@eecs.umich.edu$(error The M5 variable must be set) 447992Ssaidi@eecs.umich.eduendif 457992Ssaidi@eecs.umich.edu 468015Sbinkertn@umich.eduall: console 477977Shsul@eecs.umich.edu 488024Ssaidi@eecs.umich.edum5op.o: $(M5)/util/m5/m5op.S 498024Ssaidi@eecs.umich.edu $(CC) $(CFLAGS) -nostdinc -o $@ -c $< 508024Ssaidi@eecs.umich.edu 518008Ssaidi@eecs.umich.edu%.o: %.S 528008Ssaidi@eecs.umich.edu $(CC) $(CFLAGS) -nostdinc -o $@ -c $< 537977Shsul@eecs.umich.edu 548015Sbinkertn@umich.edu%.o: %.c 558008Ssaidi@eecs.umich.edu $(CC) -g3 $(CFLAGS) -o $@ -c $< 567977Shsul@eecs.umich.edu 578015Sbinkertn@umich.educonsole: $(OBJS) 588015Sbinkertn@umich.edu $(LD) -o console -N -Ttext $(DBMENTRY) -non_shared $(OBJS) -lc 597977Shsul@eecs.umich.edu 607977Shsul@eecs.umich.educlean: 618015Sbinkertn@umich.edu rm -f *.o console 62