Update.
[glibc.git] / sysdeps / mach / Makefile
blob1f09076e293270ca24a2df826ef557b36ad39d95
1 # Copyright (C) 1993, 1994, 1996, 1997 Free Software Foundation, Inc.
2 # This file is part of the GNU C Library.
4 # The GNU C Library is free software; you can redistribute it and/or
5 # modify it under the terms of the GNU Library General Public License
6 # as published by the Free Software Foundation; either version 2 of
7 # the License, or (at your option) any later version.
9 # The GNU C Library is distributed in the hope that it will be useful,
10 # but WITHOUT ANY WARRANTY; without even the implied warranty of
11 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12 # Library General Public License for more details.
14 # You should have received a copy of the GNU Library General Public
15 # License along with the GNU C Library; see the file COPYING.LIB. If not,
16 # write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
17 # Boston, MA 02111-1307, USA.
19 ifdef in-Makerules
21 # Look for header files in mach/ under the top-level library source directory.
22 # Look for generated header files where they get created.
23 includes += -I$(..)mach -I$(common-objpfx)mach/
25 ifneq (mach,$(subdir))
26 # Subdirectories other than mach/ might use the generated Mach headers.
27 # So make sure we get a chance to run in mach/ to make them before all else.
29 mach-objpfx = $(common-objpfx)mach/
31 # These are all the generated files that <mach.h> includes.
32 mach-before-compile := $(mach-objpfx)mach-shortcuts.h \
33 $(patsubst %,$(mach-objpfx)mach/mach_%.h,\
34 interface port host)
36 # This patsubst generates patterns like `m%h-shortcuts.h', which are damn
37 # likely to match just the corresponding particular file we want.
38 $(patsubst mach%,m\%h%,$(mach-before-compile)): # Run only if doesn't exist.
39 $(MAKE) -C $(..)mach generated no_deps=t
41 before-compile += $(mach-before-compile)
42 endif
44 endif # in-Makerules