]> git.ipfire.org Git - thirdparty/binutils-gdb.git/blame - sim/Makefile.am
sim: unify -Werror build settings
[thirdparty/binutils-gdb.git] / sim / Makefile.am
CommitLineData
6bddc3e8
MF
1## Process this file with automake to generate Makefile.in
2#
3# Copyright (C) 1993-2021 Free Software Foundation, Inc.
4#
5# This program is free software; you can redistribute it and/or modify
6# it under the terms of the GNU General Public License as published by
7# the Free Software Foundation; either version 3 of the License, or
8# (at your option) any later version.
9#
10# This program is distributed in the hope that it will be useful,
11# but WITHOUT ANY WARRANTY; without even the implied warranty of
12# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13# GNU General Public License for more details.
14#
15# You should have received a copy of the GNU General Public License
16# along with this program. If not, see <http://www.gnu.org/licenses/>.
17
6c57b87f 18AUTOMAKE_OPTIONS = dejagnu foreign no-dist subdir-objects
c2783492 19ACLOCAL_AMFLAGS = -Im4 -I.. -I../config
6bddc3e8
MF
20
21srcroot = $(srcdir)/..
22
23SUBDIRS = @subdirs@
24
a0e674c1
MF
25SIM_PRIMARY_TARGET = @SIM_PRIMARY_TARGET@
26AM_MAKEFLAGS = SIM_PRIMARY_TARGET=$(SIM_PRIMARY_TARGET)
27
b6b1c790
MF
28# We don't set some of these vars here, but we need to define them so they may
29# be used consistently in local.mk files we include below.
a389375f 30check_PROGRAMS =
b6b1c790
MF
31noinst_LIBRARIES =
32EXTRA_PROGRAMS =
33
a389375f
MF
34CLEANFILES =
35DISTCLEANFILES =
6bddc3e8
MF
36MOSTLYCLEANFILES = core
37
47ce766a 38AM_CFLAGS = $(WERROR_CFLAGS) $(WARN_CFLAGS)
a0c4531a
TT
39AM_CPPFLAGS = -I$(srcroot)/include
40
c2783492
MF
41COMPILE_FOR_BUILD = $(CC_FOR_BUILD) $(AM_CPPFLAGS) $(CFLAGS_FOR_BUILD)
42LINK_FOR_BUILD = $(CC_FOR_BUILD) $(CFLAGS_FOR_BUILD) $(LDFLAGS_FOR_BUILD) -o $@
43
5bea0c32
MF
44# Deps to add to the all-recursive target. These are built before descending
45# into any subdirs.
46SIM_ALL_RECURSIVE_DEPS =
47
6bddc3e8
MF
48# Generate nltvals.def for newlib/libgloss using devo and build tree.
49# This file is shipped with distributions so we build in the source dir.
50# Use `make nltvals' to rebuild.
51# Note: If gdb releases begin to contain target header files (not a good idea,
52# but if they did ...), nltvals.def coud be generated at build time.
53# An alternative is to slurp in the tables at runtime.
54.PHONY: nltvals
55nltvals:
56 $(abs_srcdir)/common/gennltvals.py --cpp "$(CPP)" --output nltvals.def --srcroot $(srcroot)
57 $(SHELL) $(srcroot)/move-if-change nltvals.def $(abs_srcdir)/common/nltvals.def
6c57b87f 58
92bc001e
MF
59pkginclude_HEADERS = \
60 $(srcroot)/include/sim/callback.h \
61 $(srcroot)/include/sim/sim.h
62
5bea0c32 63include common/local.mk
b6b1c790
MF
64if SIM_ENABLE_IGEN
65include igen/local.mk
66endif
6c57b87f 67include testsuite/local.mk
5bea0c32
MF
68
69all-recursive: $(SIM_ALL_RECURSIVE_DEPS)