1# -*-makefile-*- 2# Master/test-application.make 3# 4# Copyright (C) 1997, 2001, 2002 Free Software Foundation, Inc. 5# 6# Author: Scott Christley <scottc@net-community.com> 7# Author: Nicola Pero <nicola@brainstorm.co.uk> 8# 9# This file is part of the GNUstep Makefile Package. 10# 11# This library is free software; you can redistribute it and/or 12# modify it under the terms of the GNU General Public License 13# as published by the Free Software Foundation; either version 3 14# of the License, or (at your option) any later version. 15# 16# You should have received a copy of the GNU General Public 17# License along with this library; see the file COPYING. 18# If not, write to the Free Software Foundation, 19# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. 20 21TEST_APP_NAME := $(strip $(TEST_APP_NAME)) 22 23ifeq ($(RULES_MAKE_LOADED),) 24include $(GNUSTEP_MAKEFILES)/rules.make 25endif 26 27# Building of test applications works as in application.make, except 28# you can't install them! 29 30ifeq ($(GNUSTEP_MAKE_PARALLEL_BUILDING), no) 31 32internal-all:: $(GNUSTEP_OBJ_DIR) $(TEST_APP_NAME:=.all.test-app.variables) 33 34else 35 36internal-all:: $(GNUSTEP_OBJ_DIR) 37 $(ECHO_NOTHING_RECURSIVE_MAKE)$(MAKE) -f $(MAKEFILE_NAME) --no-print-directory --no-keep-going \ 38 internal-master-test-app-all \ 39 GNUSTEP_BUILD_DIR="$(GNUSTEP_BUILD_DIR)" \ 40 _GNUSTEP_MAKE_PARALLEL=yes$(END_ECHO_RECURSIVE_MAKE) 41 42.PHONY: internal-master-test-app-all 43 44internal-master-test-app-all: $(TEST_APP_NAME:=.all.test-app.variables) 45 46endif 47 48_PSWRAP_C_FILES = $(foreach app,$(TEST_APP_NAME),$($(app)_PSWRAP_FILES:.psw=.c)) 49_PSWRAP_H_FILES = $(foreach app,$(TEST_APP_NAME),$($(app)_PSWRAP_FILES:.psw=.h)) 50 51internal-clean:: 52ifeq ($(GNUSTEP_IS_FLATTENED), no) 53 (cd $(GNUSTEP_BUILD_DIR); \ 54 rm -rf $(_PSWRAP_C_FILES) $(_PSWRAP_H_FILES) *.$(APP_EXTENSION)/$(GNUSTEP_TARGET_LDIR)) 55else 56 (cd $(GNUSTEP_BUILD_DIR); \ 57 rm -rf $(_PSWRAP_C_FILES) $(_PSWRAP_H_FILES) *.$(APP_EXTENSION)) 58endif 59 60internal-distclean:: 61ifeq ($(GNUSTEP_IS_FLATTENED), no) 62 (cd $(GNUSTEP_BUILD_DIR); rm -rf *.$(APP_EXTENSION)) 63endif 64 65TEST_APPS_WITH_SUBPROJECTS = $(strip $(foreach test-app,$(TEST_APP_NAME),$(patsubst %,$(test-app),$($(test-app)_SUBPROJECTS)))) 66ifneq ($(TEST_APPS_WITH_SUBPROJECTS),) 67internal-clean:: $(TEST_APPS_WITH_SUBPROJECTS:=.clean.test-app.subprojects) 68internal-distclean:: $(TEST_APPS_WITH_SUBPROJECTS:=.distclean.test-app.subprojects) 69endif 70 71internal-strings:: $(TEST_APP_NAME:=.strings.test-app.variables) 72 73$(TEST_APP_NAME): $(GNUSTEP_OBJ_DIR) 74 $(ECHO_NOTHING_RECURSIVE_MAKE)$(MAKE) -f $(MAKEFILE_NAME) --no-print-directory $@.all.test-app.variables$(END_ECHO_RECURSIVE_MAKE) 75 76internal-install:: 77 @ echo Skipping installation of test apps... 78 79internal-uninstall:: 80 @ echo Skipping uninstallation of test apps... 81