a4c97499d9
and being made more generic.
176 lines
5.6 KiB
Makefile
176 lines
5.6 KiB
Makefile
#
|
|
# This file is part of the program psim.
|
|
#
|
|
# Copyright (C) 1994-1997, Andrew Cagney <cagney@highland.com.au>
|
|
# Copyright (C) 1997, Free Software Foundation, Inc.
|
|
#
|
|
# This program is free software; you can redistribute it and/or modify
|
|
# it under the terms of the GNU General Public License as published by
|
|
# the Free Software Foundation; either version 2 of the License, or
|
|
# (at your option) any later version.
|
|
#
|
|
# This program is distributed in the hope that it will be useful,
|
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
# GNU General Public License for more details.
|
|
#
|
|
# You should have received a copy of the GNU General Public License
|
|
# along with this program; if not, write to the Free Software
|
|
# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
|
|
#
|
|
|
|
default: all
|
|
|
|
VPATH = @srcdir@
|
|
srcdir = @srcdir@
|
|
srcroot = $(srcdir)/../..
|
|
|
|
prefix = @prefix@
|
|
exec_prefix = @exec_prefix@
|
|
|
|
host_alias = @host_alias@
|
|
target_alias = @target_alias@
|
|
program_transform_name = @program_transform_name@
|
|
bindir = @bindir@
|
|
libdir = @libdir@
|
|
tooldir = $(libdir)/$(target_alias)
|
|
|
|
datadir = @datadir@
|
|
mandir = @mandir@
|
|
man1dir = $(mandir)/man1
|
|
man2dir = $(mandir)/man2
|
|
man3dir = $(mandir)/man3
|
|
man4dir = $(mandir)/man4
|
|
man5dir = $(mandir)/man5
|
|
man6dir = $(mandir)/man6
|
|
man7dir = $(mandir)/man7
|
|
man8dir = $(mandir)/man8
|
|
man9dir = $(mandir)/man9
|
|
infodir = @infodir@
|
|
includedir = @includedir@
|
|
|
|
SHELL = /bin/sh
|
|
|
|
INSTALL = $(srcroot)/install.sh -c
|
|
INSTALL_PROGRAM = @INSTALL_PROGRAM@
|
|
INSTALL_DATA = @INSTALL_DATA@
|
|
INSTALL_XFORM = $(INSTALL) -t='$(program_transform_name)'
|
|
INSTALL_XFORM1= $(INSTALL_XFORM) -b=.1
|
|
|
|
AR = @AR@
|
|
AR_FLAGS = rc
|
|
CC = @CC@
|
|
CFLAGS = @CFLAGS@
|
|
CC_FOR_BUILD = @CC_FOR_BUILD@
|
|
BISON = bison
|
|
MAKEINFO = makeinfo
|
|
RANLIB = @RANLIB@
|
|
|
|
STD_CFLAGS = $(CFLAGS) $(INLINE_CFLAGS) $(CONFIG_CFLAGS) $(WARNING_CFLAGS) $(SIM_CFLAGS) $(HDEFINES) $(TDEFINES) $(INCLUDES)
|
|
NOWARN_CFLAGS = $(CFLAGS) $(INLINE_CFLAGS) $(CONFIG_CFLAGS) $(SIM_CFLAGS) $(HDEFINES) $(TDEFINES) $(INCLUDES)
|
|
BUILD_CFLAGS = -g -O $(INCLUDES) $(WARNING_CFLAGS)
|
|
|
|
BUILD_LDFLAGS =
|
|
|
|
.NOEXPORT:
|
|
MAKEOVERRIDES=
|
|
|
|
LIB_INCLUDES = -I$(srcdir)/../../include
|
|
INCLUDES = -I. -I$(srcdir) $(LIB_INCLUDES)
|
|
|
|
LIBIBERTY_LIB = ../../libiberty/libiberty.a
|
|
|
|
|
|
IGENLIB= libigen.a
|
|
|
|
all: igen $(IGENLIB)
|
|
|
|
.c.o:
|
|
$(CC_FOR_BUILD) -c $(STD_CFLAGS) $<
|
|
|
|
filter_filename.o: filter_filename.c filter_filename.h config.h ppc-config.h
|
|
|
|
igen: igen.o $(IGENLIB)
|
|
$(CC_FOR_BUILD) $(BUILD_CFLAGS) $(BUILD_LDFLAGS) -o igen igen.o $(IGENLIB) $(LIBIBERTY_LIB)
|
|
|
|
IGEN_OBJS=\
|
|
table.o \
|
|
lf.o misc.o \
|
|
filter_host.o \
|
|
ld-decode.o \
|
|
ld-cache.o \
|
|
filter.o \
|
|
ld-insn.o \
|
|
gen-model.o \
|
|
gen-itable.o \
|
|
gen-icache.o \
|
|
gen-semantics.o \
|
|
gen-idecode.o \
|
|
gen-support.o \
|
|
gen-engine.o
|
|
|
|
igen.o: igen.c misc.h filter_host.h lf.h table.h ld-decode.h ld-cache.h ld-insn.h filter.h gen-model.h gen-itable.h gen-icache.h gen-idecode.h gen-engine.h gen-semantics.h gen-support.h igen.h
|
|
$(CC_FOR_BUILD) $(BUILD_CFLAGS) -c $(srcdir)/igen.c
|
|
|
|
$(IGENLIB): $(IGEN_OBJS)
|
|
rm -f $(IGENLIB)
|
|
$(AR) $(AR_FLAGS) $(IGENLIB) $(IGEN_OBJS)
|
|
$(RANLIB) $(IGENLIB)
|
|
|
|
|
|
tmp-filter: filter.c misc.h misc.o
|
|
$(CC_FOR_BUILD) $(BUILD_CFLAGS) $(BUILD_LDFLAGS) -o tmp-filter -DMAIN $(srcdir)/filter.c misc.o $(BUILD_LIBS)
|
|
|
|
tmp-ld-decode: ld-decode.o misc.o lf.o table.o filter_host.o
|
|
$(CC_FOR_BUILD) $(BUILD_CFLAGS) $(BUILD_LDFLAGS) -o tmp-ld-decode -DMAIN $(srcdir)/ld-decode.c misc.o lf.o table.o filter_host.o $(BUILD_LIBS)
|
|
|
|
tmp-ld-cache: ld-cache.o misc.o lf.o table.o filter_host.o
|
|
$(CC_FOR_BUILD) $(BUILD_CFLAGS) $(BUILD_LDFLAGS) -o tmp-ld-cache -DMAIN $(srcdir)/ld-cache.c misc.o lf.o table.o filter_host.o $(BUILD_LIBS)
|
|
|
|
tmp-ld-insn: ld-insn.o misc.o lf.o table.o ld-decode.o filter_host.o filter.o
|
|
$(CC_FOR_BUILD) $(BUILD_CFLAGS) $(BUILD_LDFLAGS) -o tmp-ld-insn -DMAIN $(srcdir)/ld-insn.c misc.o lf.o table.o ld-decode.o filter_host.o filter.o $(BUILD_LIBS)
|
|
|
|
filter_host.o: filter_host.c filter_host.h
|
|
table.o: table.c misc.h filter_host.h lf.h table.h
|
|
lf.o: lf.c misc.h filter_host.h lf.h
|
|
filter.o: filter.c misc.h lf.h table.h filter.h
|
|
ld-decode.o: ld-decode.c misc.h lf.h table.h ld-decode.h
|
|
ld-cache.o: ld-cache.c misc.h lf.h table.h ld-cache.h
|
|
ld-insn.o: ld-insn.c misc.h lf.h table.h ld-insn.h ld-decode.h igen.h
|
|
gen-model.o: gen-model.c misc.h lf.h table.h gen-model.h ld-decode.h igen.h ld-insn.h
|
|
gen-itable.o: gen-itable.c misc.h lf.h table.h gen-itable.h ld-decode.h igen.h ld-insn.h igen.h
|
|
gen-icache.o: gen-icache.c misc.h lf.h table.h gen-icache.h ld-decode.h igen.h ld-insn.h gen-semantics.h gen-idecode.h
|
|
gen-semantics.o: gen-semantics.c misc.h lf.h table.h gen-semantics.h ld-decode.h igen.h ld-insn.h
|
|
gen-idecode.o: gen-idecode.c misc.h lf.h table.h gen-idecode.h gen-icache.h gen-semantics.h ld-decode.h igen.h ld-insn.h
|
|
gen-engine.o: gen-engine.c misc.h lf.h table.h gen-idecode.h gen-engine.h gen-icache.h gen-semantics.h ld-decode.h igen.h ld-insn.h
|
|
gen-support.o: gen-support.c misc.h lf.h table.h gen-support.h ld-decode.h igen.h ld-insn.h
|
|
misc.o: misc.c misc.h filter_host.h
|
|
|
|
|
|
tags etags: TAGS
|
|
|
|
TAGS:
|
|
etags $(srcdir)/*.h $(srcdir)/*.c
|
|
|
|
clean mostlyclean:
|
|
rm -f tmp-* *.[oasi] core igen
|
|
|
|
distclean realclean: clean
|
|
rm -f TAGS Makefile config.cache config.status config.h defines.h stamp-h config.log
|
|
|
|
maintainer-clean: distclean
|
|
rm -f *~ *.log ppc-config.h core *.core
|
|
|
|
Makefile: Makefile.in config.status
|
|
CONFIG_FILES=Makefile CONFIG_HEADERS= $(SHELL) ./config.status
|
|
|
|
config.h: stamp-h ; @true
|
|
stamp-h: config.in config.status
|
|
CONFIG_FILES= CONFIG_HEADERS=config.h:config.in $(SHELL) ./config.status
|
|
|
|
config.status: configure
|
|
$(SHELL) ./config.status --recheck
|
|
|
|
install:
|
|
#
|