| Mike Marchetti | 230c540 | 2017-09-20 13:43:06 -0400 | [diff] [blame] | 1 | # |
| 2 | # Copyright 2017 Sandvine |
| 3 | # |
| 4 | # Licensed under the Apache License, Version 2.0 (the "License"); |
| 5 | # you may not use this file except in compliance with the License. |
| 6 | # You may obtain a copy of the License at |
| 7 | # |
| 8 | # http://www.apache.org/licenses/LICENSE-2.0 |
| 9 | # |
| 10 | # Unless required by applicable law or agreed to in writing, software |
| 11 | # distributed under the License is distributed on an "AS IS" BASIS, |
| 12 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| 13 | # See the License for the specific language governing permissions and |
| 14 | # limitations under the License. |
| 15 | # |
| 16 | |
| gcalvino | c9ead0f | 2017-11-24 13:48:51 +0100 | [diff] [blame] | 17 | TOPDIR=$(shell readlink -f .|sed -e 's/\/descriptor-packages\/.*//') |
| 18 | TOOLS_DIR := $(TOPDIR)/tools |
| 19 | |
| Mike Marchetti | 230c540 | 2017-09-20 13:43:06 -0400 | [diff] [blame] | 20 | SUBDIRS_CLEAN = $(addsuffix .clean, $(SUBDIRS)) |
| tierno | 04720c7 | 2017-11-23 18:19:34 +0100 | [diff] [blame] | 21 | SUBDIRS_TEST = $(addsuffix .test, $(SUBDIRS)) |
| Mike Marchetti | 230c540 | 2017-09-20 13:43:06 -0400 | [diff] [blame] | 22 | |
| 23 | .PHONY: $(SUBDIRS) $(SUBDIRS_CLEAN) clean |
| 24 | |
| 25 | all: $(SUBDIRS) |
| 26 | |
| 27 | clean: $(SUBDIRS_CLEAN) |
| 28 | |
| tierno | 04720c7 | 2017-11-23 18:19:34 +0100 | [diff] [blame] | 29 | test: $(SUBDIRS_TEST) |
| 30 | |
| Mike Marchetti | 230c540 | 2017-09-20 13:43:06 -0400 | [diff] [blame] | 31 | $(SUBDIRS_CLEAN): %.clean: |
| 32 | @$(MAKE) --no-print-directory -C $* clean |
| 33 | |
| tierno | 04720c7 | 2017-11-23 18:19:34 +0100 | [diff] [blame] | 34 | $(SUBDIRS_TEST): %.test: |
| 35 | @$(MAKE) --no-print-directory -C $* test |
| 36 | |
| Mike Marchetti | 230c540 | 2017-09-20 13:43:06 -0400 | [diff] [blame] | 37 | $(SUBDIRS): |
| 38 | @$(MAKE) --no-print-directory -C $@ |
| gcalvino | c9ead0f | 2017-11-24 13:48:51 +0100 | [diff] [blame] | 39 | |
| 40 | test: |
| 41 | $(TOOLS_DIR)/launch_tests.sh |