Rework the indent target.
- Check indent is present at ./configure stage; - If gindent(1) is installed, use it instead of indent(1);
This commit is contained in:
parent
2688de6500
commit
67fb1330f8
2 changed files with 14 additions and 2 deletions
|
|
@ -20,6 +20,8 @@ doc : Doxyfile
|
|||
.PHONY: doc
|
||||
endif
|
||||
|
||||
INDENT_CMD = indent -br -brs -ce --line-length120 -nut -i2
|
||||
if HAS_INDENT
|
||||
INDENT_ARGS = -br -brs -ce --line-length120 -nut -i2
|
||||
indent:
|
||||
find $(top_srcdir)/libnfc $(top_srcdir)/include $(top_srcdir)/examples -name "*.[hc]" -exec $(INDENT_CMD) '{}' \;
|
||||
find $(top_srcdir)/libnfc $(top_srcdir)/include $(top_srcdir)/examples -name "*.[hc]" -exec $(INDENT) $(INDENT_ARGS) '{}' ';'
|
||||
endif
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue