aboutsummaryrefslogtreecommitdiffstats
path: root/Maintenance/makefile
blob: db06616c74f1c2b27419e39a90ec4bab9d62f2e8 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
#
#             LUFA Library
#     Copyright (C) Dean Camera, 2012.
#
#  dean [at] fourwalledcubicle [dot] com
#           www.lufa-lib.org
#

# Maintenance scripts not required by general LUFA users, used for project development purposes.


# Path to the root of the LUFA tree
LUFA_ROOT = ../

all:

# Update all Doxygen configuration files to the latest Doxygen version - force Markdown support to be disabled
upgrade-doxygen:
	@echo Upgrading Doxygen.conf files...
	@for doxygen_conf in `find $(LUFA_ROOT) -name Doxygen.conf`; do \
	  doxygen -u $$doxygen_conf; \
	  sed "s/MARKDOWN_SUPPORT *= *YES/MARKDOWN_SUPPORT       = NO/1" $$doxygen_conf > $$doxygen_conf.new; \
	  sed "s/DISABLE_INDEX *= *NO/DISABLE_INDEX       = YES/1" $$doxygen_conf.new > $$doxygen_conf.new2; \
	  mv -u $$doxygen_conf.new2 $$doxygen_conf; \
	  rm $$doxygen_conf.new; \
	done;
	@echo Doxygen configuration update complete.

# Check the working branch documentation, ensure no placeholder values
check-documentation-placeholders:
	@echo Checking for release suitability...
	@if ( grep "XXXXXX" $(LUFA_ROOT)/LUFA/DoxygenPages/*.txt > /dev/null ;); then \
	  echo "  ERROR: Doxygen documentation has not been updated for release!"; \
	  exit 1; \
	fi;
	@if ( grep "000000" $(LUFA_ROOT)/LUFA/Version.h > /dev/null ;); then \
	  echo "  ERROR: Version header has not been updated for release!"; \
	  exit 1; \
	fi;
	@echo Done.

# Validate the working branch - compile all documentation, demos/projects/examples and run build tests
validate-branch:
	make -s -C $(LUFA_ROOT) doxygen
	make -s -C $(LUFA_ROOT) all
	make -s -C $(LUFA_ROOT)/BuildTests all

# Validate the working branch for general release, check for placeholder documentation then build and test everything
validate-release: check-documentation-placeholders validate-branch