1#   -*-makefile-*-
2#   Master/gswbundle.make
3#
4#   Master Makefile rules to build GNUstep web bundles.
5#
6#   Copyright (C) 1997 Free Software Foundation, Inc.
7#
8#   Author:  Manuel Guesdon <mguesdon@sbuilders.com>
9#   Based on WOBundle.make by Helge Hess, MDlink online service center GmbH.
10#   Based on bundle.make by Ovidiu Predescu <ovidiu@net-community.com>
11#
12#   This file is part of the GNUstep Makefile Package.
13#
14#   This library is free software; you can redistribute it and/or
15#   modify it under the terms of the GNU General Public License
16#   as published by the Free Software Foundation; either version 3
17#   of the License, or (at your option) any later version.
18#
19#   You should have received a copy of the GNU General Public
20#   License along with this library; see the file COPYING.
21#   If not, write to the Free Software Foundation,
22#   51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
23
24ifeq ($(RULES_MAKE_LOADED),)
25include $(GNUSTEP_MAKEFILES)/rules.make
26endif
27
28ifeq ($(strip $(GSWBUNDLE_EXTENSION)),)
29GSWBUNDLE_EXTENSION = .gswbundle
30endif
31
32GSWBUNDLE_NAME := $(strip $(GSWBUNDLE_NAME))
33
34ifeq ($(GNUSTEP_MAKE_PARALLEL_BUILDING), no)
35
36internal-all:: $(GNUSTEP_OBJ_DIR) $(GSWBUNDLE_NAME:=.all.gswbundle.variables)
37
38else
39
40internal-all:: $(GNUSTEP_OBJ_DIR)
41	$(ECHO_NOTHING_RECURSIVE_MAKE)$(MAKE) -f $(MAKEFILE_NAME) --no-print-directory --no-keep-going \
42	internal-master-gswbundle-all \
43	GNUSTEP_BUILD_DIR="$(GNUSTEP_BUILD_DIR)" \
44	_GNUSTEP_MAKE_PARALLEL=yes$(END_ECHO_RECURSIVE_MAKE)
45
46.PHONY: internal-master-gswbundle-all
47
48internal-master-gswbundle-all: $(GSWBUNDLE_NAME:=.all.gswbundle.variables)
49
50endif
51
52internal-install:: $(GSWBUNDLE_NAME:=.install.gswbundle.variables)
53
54internal-uninstall:: $(GSWBUNDLE_NAME:=.uninstall.gswbundle.variables)
55
56internal-clean::
57	(cd $(GNUSTEP_BUILD_DIR); \
58	rm -rf $(addsuffix $(GSWBUNDLE_EXTENSION),$(GSWBUNDLE_NAME)))
59
60internal-distclean::
61
62GSWBUNDLES_WITH_SUBPROJECTS = $(strip $(foreach gswbundle,$(GSWBUNDLE_NAME),$(patsubst %,$(gswbundle),$($(gswbundle)_SUBPROJECTS))))
63ifneq ($(GSWBUNDLES_WITH_SUBPROJECTS),)
64internal-clean:: $(GSWBUNDLES_WITH_SUBPROJECTS:=.clean.gswbundle.subprojects)
65internal-distclean:: $(GSWBUNDLES_WITH_SUBPROJECTS:=.distclean.gswbundle.subprojects)
66endif
67
68internal-all:: $(GSWBUNDLE_NAME:=.all.gswbundle.variables)
69
70$(GSWBUNDLE_NAME): $(GNUSTEP_OBJ_DIR)
71	$(ECHO_NOTHING_RECURSIVE_MAKE)$(MAKE) -f $(MAKEFILE_NAME) --no-print-directory $@.all.gswbundle.variables$(END_ECHO_RECURSIVE_MAKE)
72