From 674c900f24a91e1503d5f6f07bbe2f423ef5bf4b Mon Sep 17 00:00:00 2001 From: Joel Sherrill Date: Wed, 10 Dec 1997 16:58:00 +0000 Subject: Modified a lot of files to take a first cut at supporting building from any directory in the build tree. The only variable which must be set before the command "gmake" is invoked is RTEMS_BSP (e.g. RTEMS_BSP=erc32). --- c/Makefile.in | 31 +++++++++++++++++++++---------- 1 file changed, 21 insertions(+), 10 deletions(-) (limited to 'c/Makefile.in') diff --git a/c/Makefile.in b/c/Makefile.in index 4824deb679..3a60093689 100644 --- a/c/Makefile.in +++ b/c/Makefile.in @@ -17,7 +17,10 @@ target = @target@ manext = 1 mandir = @mandir@/man$(manext) program_prefix = @program_prefix@ -VPATH=@srcdir@ +VPATH = @srcdir@ +RTEMS_ROOT = @RTEMS_ROOT@ +PROJECT_ROOT = @PROJECT_ROOT@ +RTEMS_CUSTOM = $(RTEMS_ROOT)/make/custom/$(RTEMS_BSP).cfg include $(RTEMS_CUSTOM) include $(RTEMS_ROOT)/make/directory.cfg @@ -50,10 +53,17 @@ CREATE_DIRS = \ build-tools update-tools # Make all/install must include 'env' +# if something is added to TARGET_VARIANTS, then account for it here all: env -$(TARGET_VARIANTS): env -$(TARGET_VARIANTS:%=%_install): env -$(TARGET_VARIANTS:%=%_all): env +debug: env +profile: env + +install: all install_files +debug_install: env debug install_files +profile_install: env profile install_files + +debug_all: debug +profile_all: profile # top level clean/clobber will delete the install points clean_WRAPUP = $(MAKE) clean_wrapup @@ -63,14 +73,13 @@ clean_wrapup: clean_tools clean_dirs clean_modules .PHONY: dirs clean_wrapup clean_dirs clean_tools clean_modules env install -# XXX The link is temporary while switching to -specs options. dirs: -test -d $(PROJECT_ROOT)/c/src/lib/libhwapi && \ (cd $(PROJECT_ROOT)/c/src/lib/libhwapi ; $(MAKE) mkdirs) -# -$(MKDIR) ${CREATE_DIRS:%=$(PROJECT_ROOT)/$(RTEMS_BSP)/%} - @echo Making directories in build tree ... - -$(foreach dir,$(CREATE_DIRS), \ - $(shell $(MKDIR) $(PROJECT_ROOT)/$(RTEMS_BSP)/$(dir))) + -$(MKDIR) ${CREATE_DIRS:%=$(PROJECT_ROOT)/$(RTEMS_BSP)/%} +# @echo Making directories in build tree ... +# -$(foreach dir,$(CREATE_DIRS), \ +# $(shell $(MKDIR) $(PROJECT_ROOT)/$(RTEMS_BSP)/$(dir))) distclean: clobber @@ -82,7 +91,9 @@ clean_tools: # NOTE: The wildcard on the install should pick up everything except # the tests directory. This significantly minimizes the install size. -install: all + + +install_files: -$(MKDIR) $(prefix)/ -$(MKDIR) $(prefix)/rtems -$(MKDIR) $(prefix)/rtems/make -- cgit v1.2.3