diff options
-rw-r--r-- | Makefile.am | 5 | ||||
-rw-r--r-- | configure.ac | 9 |
2 files changed, 14 insertions, 0 deletions
diff --git a/Makefile.am b/Makefile.am index d69dd3a82..f2b48b358 100644 --- a/Makefile.am +++ b/Makefile.am | |||
@@ -38,3 +38,8 @@ docdir = $(datadir)/doc/gnunet/ | |||
38 | doc_DATA = COPYING README | 38 | doc_DATA = COPYING README |
39 | 39 | ||
40 | ACLOCAL_AMFLAGS = -I m4 | 40 | ACLOCAL_AMFLAGS = -I m4 |
41 | |||
42 | if HAVE_UNCRUSTIFY | ||
43 | pretty: | ||
44 | find $(top_srcdir) -type f ! -path '*/.*' ! -path '*/_*' -name '*.c' -name '*.h' -print0 | xargs -0 uncrustify -c $(top_srcdir) --replace --no-backup 2>&1 || true | ||
45 | endif | ||
diff --git a/configure.ac b/configure.ac index 7af7e83df..e486a893d 100644 --- a/configure.ac +++ b/configure.ac | |||
@@ -313,6 +313,15 @@ AS_IF([test x"$VAR_UPNPC_BINARY" != x"false"], | |||
313 | [AC_DEFINE_UNQUOTED([UPNPC], "$VAR_UPNPC_BINARY", [Path to upnpc binary])], | 313 | [AC_DEFINE_UNQUOTED([UPNPC], "$VAR_UPNPC_BINARY", [Path to upnpc binary])], |
314 | [AC_MSG_WARN([warning: 'upnpc' binary not found.])]) | 314 | [AC_MSG_WARN([warning: 'upnpc' binary not found.])]) |
315 | 315 | ||
316 | |||
317 | # uncrustify | ||
318 | AC_PATH_TARGET_TOOL(VAR_UNCRUSTIFY_BINARY, uncrustify, false) | ||
319 | |||
320 | AS_IF([test x"$VAR_UNCRUSTIFY_BINARY" != x"false"], | ||
321 | [AC_DEFINE_UNQUOTED([HAVE_UNCRUSTIFY], "$VAR_UNCRUSTIFY_BINARY", [Path to uncrustify binary])], | ||
322 | [AC_MSG_WARN([warning: 'uncrustify' binary not found.])]) | ||
323 | |||
324 | |||
316 | AC_CHECK_MEMBER(struct tm.tm_gmtoff, | 325 | AC_CHECK_MEMBER(struct tm.tm_gmtoff, |
317 | [AC_DEFINE(HAVE_TM_GMTOFF, 1, | 326 | [AC_DEFINE(HAVE_TM_GMTOFF, 1, |
318 | [Define if struct tm has the tm_gmtoff member.])], | 327 | [Define if struct tm has the tm_gmtoff member.])], |