Ask whether to overwrite the project file when creating a new project
[geany-mirror.git] / m4 / geany-doxygen.m4
blob5c5cbec7e098628e5b670f9d018a6baf13013ae8
1 dnl GEANY_CHECK_DOXYGEN
2 dnl Check for Doxygen availability to generate API docs
3 dnl
4 AC_DEFUN([GEANY_CHECK_DOXYGEN],
6         AC_ARG_ENABLE([api-docs],
7                         [AS_HELP_STRING([--enable-api-docs],
8                                         [generate API documentation using Doxygen [default=no]])],
9                         [geany_with_doxygen="$enableval"],
10                         [geany_with_doxygen="no"])
12         AC_ARG_VAR([DOXYGEN], [Path to Doxygen executable])
14         AS_IF([test "x$geany_with_doxygen" != "xno"],
15         [
16                 AS_IF([test "x$DOXYGEN" != "x"],
17                         [geany_doxygen_path="$DOXYGEN"], [geany_doxygen_path="doxygen"])
18                 AC_PATH_PROG([DOXYGEN], [$geany_doxygen_path], [no])
19                 AS_IF([test "x$DOXYGEN" != "xno"],
20                           [geany_with_doxygen=yes],
21                           [test "x$geany_with_doxygen" = xyes],
22                           [AC_MSG_ERROR([API documentation enabled but doxygen not found])],
23                           [geany_with_doxygen=no])
24         ])
26         AM_CONDITIONAL([WITH_DOXYGEN], [test "x$geany_with_doxygen" != "xno"])
27         GEANY_STATUS_ADD([Build API documentation], [$geany_with_doxygen])