b6ee93324bf3fff4f1c3a22032c141fa454e29b4
[routino] / Makefile
1 # $Header: /home/amb/routino/RCS/Makefile,v 1.3 2010/05/31 12:44:43 amb Exp $
2 #
3 # Makefile
4 #
5 # Part of the Routino routing software.
6 #
7 # This file Copyright 2009-2010 Andrew M. Bishop
8 #
9 # This program is free software: you can redistribute it and/or modify
10 # it under the terms of the GNU Affero General Public License as published by
11 # the Free Software Foundation, either version 3 of the License, or
12 # (at your option) any later version.
13 #
14 # This program is distributed in the hope that it will be useful,
15 # but WITHOUT ANY WARRANTY; without even the implied warranty of
16 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
17 # GNU Affero General Public License for more details.
18 #
19 # You should have received a copy of the GNU Affero General Public License
20 # along with this program.  If not, see <http://www.gnu.org/licenses/>.
21 #
22
23 FILES=$(wildcard */Makefile)
24 DIRS=$(foreach f,$(FILES),$(dir $f))
25
26 ########
27
28 all:
29         for dir in $(DIRS); do \
30            ( cd $$dir && $(MAKE) $@ ); \
31         done
32
33 ########
34
35 clean:
36         for dir in $(DIRS); do \
37            ( cd $$dir && $(MAKE) $@ ); \
38         done
39
40 ########
41
42 distclean: clean
43         for dir in $(DIRS); do \
44            ( cd $$dir && $(MAKE) $@ ); \
45         done