| 1 | # Braindead Makefile. Feel free to improve. |
|---|
| 2 | # Copyright (c) 2009 Redpill Linpro AS |
|---|
| 3 | # Author: Kristian Lyngstol <kristian@redpill-linpro.com |
|---|
| 4 | # |
|---|
| 5 | # This program is free software; you can redistribute it and/or modify |
|---|
| 6 | # it under the terms of the GNU General Public License as published by |
|---|
| 7 | # the Free Software Foundation; either version 2 of the License, or |
|---|
| 8 | # (at your option) any later version. |
|---|
| 9 | # |
|---|
| 10 | # This program is distributed in the hope that it will be useful, |
|---|
| 11 | # but WITHOUT ANY WARRANTY; without even the implied warranty of |
|---|
| 12 | # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
|---|
| 13 | # GNU General Public License for more details. |
|---|
| 14 | # |
|---|
| 15 | # You should have received a copy of the GNU General Public License along |
|---|
| 16 | # with this program; if not, write to the Free Software Foundation, Inc., |
|---|
| 17 | # 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. |
|---|
| 18 | |
|---|
| 19 | # Basic logic: |
|---|
| 20 | # build/variables.vcl and VARIABLES allows us to do easy testing of |
|---|
| 21 | # whether we properly clean up (aka: check). Ruletest is fairly dirty. |
|---|
| 22 | |
|---|
| 23 | all: build/variables.vcl check |
|---|
| 24 | |
|---|
| 25 | check: |
|---|
| 26 | @../tools/check_variables |
|---|
| 27 | @echo "Check passed: No unknown variables found" |
|---|
| 28 | |
|---|
| 29 | ruletest: |
|---|
| 30 | @../tools/rule_test */*vcl| bash |
|---|
| 31 | |
|---|
| 32 | clean: |
|---|
| 33 | rm -r build |
|---|
| 34 | |
|---|
| 35 | build/variables.vcl: VARIABLES |
|---|
| 36 | @mkdir -p build |
|---|
| 37 | @echo -n "Generating build/variables.vcl: " |
|---|
| 38 | @../tools/generate_variables |
|---|
| 39 | @echo "done" |
|---|
| 40 | |
|---|
| 41 | |
|---|