# $Id$ ## @file # # Top-Level Makefile. # This is not a standard kBuild makefile, the footer is not included. # # Copyright (c) 2005-2007 knut st. osmundsen # # # This file is part of kNIX. # # kNIX 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. # # kNIX 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 kNIX; if not, write to the Free Software # Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA # # DEPTH = . include $(PATH_KBUILD)/header.kmk ## SUBDIRS # The subdirectories to traverse depth first. # (This is bootstrap order.) SUBDIRS = \ baselayout \ essentials/app-arch/gzip \ essentials/sys-apps/gawk \ essentials/sys-apps/diffutils \ yacc \ bsdmisc \ essentials/sys-apps/coreutils \ essentials/sys-apps/sed \ essentials/sys-devel/flex \ essentials/sys-devel/m4 \ essentials/sys-apps/grep \ ash \ essentials ## Skip these for now: # libc \ # emx \ ## @todo # binutils \ # gcc \ ## def_do_subdir # Generate rules to do one subdirectory. # @remark This is evaluated twice. define def_do_subdir # build and install subdir_$(subdir)_all: +$$(MAKE) -C $(subdir) # install subdir_$(subdir)_install: +$$(MAKE) -C $(subdir) install # packing subdir_$(subdir)_packing: +$$(MAKE) -C $(subdir) packing .NOTPARALLEL: subdir_$(subdir)_all subdir_$(subdir)_install subdir_$(subdir)_packing endef $(foreach subdir,$(SUBDIRS),$(eval $(def_do_subdir))) # # A pass # all_subdirs: | $(foreach subdir,$(SUBDIRS), subdir_$(subdir)_all) .NOTPARALLEL: all_subdirs # # The default rule. # all_recursive: | all_subdirs .NOTPARALLEL: all_recursive