make with no arguments now does "make World" first time thru
Brought to you by:
johnston
|
From: <ivt...@li...> - 2000-02-11 18:32:50
|
Patch: ivtools-000211-johnston-019 For: ivtools-0.8 Author: joh...@us... This is an intermediate patch to ivtools-0.8. To apply, cd to the top-level directory of the ivtools source tree (the directory with src and config subdirs), and apply like this: patch -p0 <ThisFile Summary of Changes: - change the default behavior of make with no arguments to be the same as "make World" the first time it used. So now ivtools can build out of the box with ubiquitous "./configure;make" Index: top_ivtools/Imakefile diff -c top_ivtools/Imakefile:1.1 top_ivtools/Imakefile:1.2 *** top_ivtools/Imakefile:1.1 Tue Jan 18 03:06:44 2000 --- ./Imakefile Fri Feb 11 22:23:45 2000 *************** *** 1,16 **** XCOMM ! XCOMM "make CPU" prints the name you should assign to CPU. ! XCOMM "make World" builds everything. XCOMM "make install" installs everything. XCOMM PACKAGE = top_ivtools ! WORLDOPTS = -k SUBDIRS = src config MakeCPU() MakeWorld($(WORLDOPTS)) ! MakeInSubdirs($(SUBDIRS)) --- 1,21 ---- XCOMM ! XCOMM "make CPU" prints the CPU name used for machine-specific subdirectories. ! XCOMM "make" builds everything. XCOMM "make install" installs everything. XCOMM PACKAGE = top_ivtools ! WORLDOPTS = SUBDIRS = src config MakeCPU() MakeWorld($(WORLDOPTS)) ! MakeWorld2($(WORLDOPTS)) ! MakeInSubdirsTop($(SUBDIRS)) ! ! clean:: ! @$(RM_CMD) make.makefile make.makefiles make.depend make.make ! Index: config_ivtools/rules.def diff -c config_ivtools/rules.def:1.1 config_ivtools/rules.def:1.2 *** config_ivtools/rules.def:1.1 Tue Jan 18 03:14:42 2000 --- config/rules.def Fri Feb 11 22:24:25 2000 *************** *** 33,46 **** @echo "Building $(RELEASE) on `date`" @@\ @echo "" @@\ $(MAKE) Makefile CONFIGSRC=$(CONFIGSRC) XCONFIGDIR=$(XCONFIGDIR)@@\ ! @echo "twice to propogate new toplevel pathname" @@\ $(MAKE) Makefile @@\ @echo "" @@\ $(MAKE) Makefiles @@\ @echo "" @@\ $(MAKE) depend @@\ @echo "" @@\ ! $(MAKE) flags all @@\ @echo "" @@\ @echo "$(RELEASE) build completed on `date`" @@\ @echo "" --- 33,46 ---- @echo "Building $(RELEASE) on `date`" @@\ @echo "" @@\ $(MAKE) Makefile CONFIGSRC=$(CONFIGSRC) XCONFIGDIR=$(XCONFIGDIR)@@\ ! @echo "twice to propogate new toplevel pathname" @@\ $(MAKE) Makefile @@\ @echo "" @@\ $(MAKE) Makefiles @@\ @echo "" @@\ $(MAKE) depend @@\ @echo "" @@\ ! $(MAKE) flags subdirs @@\ @echo "" @@\ @echo "$(RELEASE) build completed on `date`" @@\ @echo "" *************** *** 81,86 **** --- 81,118 ---- #endif /* + * Make everything by default + */ + #ifndef MakeWorld2 + #define MakeWorld2(flags) @@\ + all:: @@\ + -@if [ ! -f make.makefile ]; then \ @@\ + echo ""; \ @@\ + echo "Building $(RELEASE) on `date`"; \ @@\ + echo ""; \ @@\ + $(MAKE) Makefile CONFIGSRC=$(CONFIGSRC) XCONFIGDIR=$(XCONFIGDIR);\@@\ + echo "twice to propogate new toplevel pathname"; \ @@\ + $(MAKE) Makefile; \ @@\ + touch make.makefile; fi @@\ + -@if [ ! -f make.makefiles ]; then \ @@\ + echo ""; \ @@\ + $(MAKE) Makefiles; \ @@\ + touch make.makefiles; fi @@\ + -@if [ ! -f make.depend ]; then \ @@\ + echo ""; \ @@\ + $(MAKE) depend; \ @@\ + touch make.depend; fi @@\ + -@if [ ! -f make.make ]; then \ @@\ + echo ""; fi @@\ + $(MAKE) flags subdirs @@\ + -@if [ ! -f make.make ]; then \ @@\ + echo ""; \ @@\ + echo "$(RELEASE) build completed on `date`"; \ @@\ + echo ""; \ @@\ + touch make.make; fi + #endif + + /* * Make the Makefile in the current directory. */ #ifndef MakefileTarget *************** *** 178,183 **** --- 210,232 ---- done #endif + /* + * Make the given target in the list of subdirectories. + */ + #ifndef IntoSubdirs2 + #define IntoSubdirs2(name,dirs,verb,target) @@\ + target:: @@\ + -@for i in dirs; \ @@\ + do \ @@\ + if [ -d $$i ]; then ( \ @@\ + echo verb \ @@\ + "for $(ARCH) in $(CURRENT_DIR)/$$i"; \ @@\ + cd $$i; \ @@\ + $(MAKE) $(PASSARCH) name; \ @@\ + ) else continue; fi; \ @@\ + done + #endif + #ifndef DependSubdirs #define DependSubdirs(dirs) @@\ IntoSubdirs(depend,dirs,"depending") *************** *** 188,193 **** --- 237,247 ---- IntoSubdirs(all,dirs,"making all") #endif + #ifndef MakeSubdirsTop + #define MakeSubdirsTop(dirs) @@\ + IntoSubdirs2(all,dirs,"making all",subdirs) + #endif + #ifndef InstallSubdirs #define InstallSubdirs(dirs) @@\ IntoSubdirs(install,dirs,"installing") @@\ *************** *** 283,288 **** --- 337,370 ---- MakefilesSubdirs(dirs) @@\ DependSubdirs(dirs) @@\ MakeSubdirs(dirs) @@\ + InstallSubdirs(dirs) @@\ + CleanSubdirs(dirs) @@\ + SpecialTargets(debug,-DUseDebug) @@\ + IvmkcmTargets($(PACKAGE)) @@\ + IvmkcmSubdirs(dirs) + #endif + #endif + + /* + * Version of MakeInSubdirs for the top-level without the MakeSubdirs + */ + #ifndef MakeInSubdirsTop + #if HasDynamicSharedLibraries + #define MakeInSubdirsTop(dirs) @@\ + MakefilesSubdirs(dirs) @@\ + DependSubdirs(dirs) @@\ + MakeSubdirsTop(dirs) @@\ + InstallSubdirs(dirs) @@\ + CleanSubdirs(dirs) @@\ + SpecialTargets(debug,-DUseDebug) @@\ + SpecialTargets(noshared,-DUseNonShared) @@\ + IvmkcmTargets($(PACKAGE)) @@\ + IvmkcmSubdirs(dirs) + #else + #define MakeInSubdirsTop(dirs) @@\ + MakefilesSubdirs(dirs) @@\ + DependSubdirs(dirs) @@\ + MakeSubdirsTop(dirs) @@\ InstallSubdirs(dirs) @@\ CleanSubdirs(dirs) @@\ SpecialTargets(debug,-DUseDebug) @@\ *** /dev/null Fri Feb 11 22:24:29 PST 2000 --- patches/ivtools-000211-johnston-019 *************** patches/ivtools-000211-johnston-019 *** 0 **** --- 1 ---- + ivtools-000211-johnston-019 |