"Fossies" - the Fresh Open Source Software Archive

Member "gnuastro-0.8/configure.ac" (20 Dec 2018, 41680 Bytes) of package /linux/privat/gnuastro-0.8.tar.lz:


As a special service "Fossies" has tried to format the requested text file into HTML format (style: standard) with prefixed line numbers. Alternatively you can here view or download the uninterpreted source code file. See also the latest Fossies "Diffs" side-by-side code changes report for "configure.ac": 0.7_vs_0.8.

    1 # Process this file with autoconf to produce a configure script.
    2 #
    3 # Hand written file: used as input into GNU Autotools (autoconf).
    4 # This is part of GNU Astronomy Utilities (gnuastro) package.
    5 #
    6 # We use some macros that are distributed as part of the GNU Autoconf
    7 # Archive here. Those macros are all placed in the bootstrapped/m4/
    8 # directory along with those that were imported from Gnulib. The
    9 # ./bootstrap script includes that directory while its running Autoconf so
   10 # we don't need to explicitly call that directory here.
   11 #
   12 # Original author:
   13 #     Mohammad Akhlaghi <mohammad@akhlaghi.org>
   14 # Contributing author(s):
   15 # Copyright (C) 2015-2018, Free Software Foundation, Inc.
   16 #
   17 # Gnuastro is free software: you can redistribute it and/or modify it
   18 # under the terms of the GNU General Public License as published by
   19 # the Free Software Foundation, either version 3 of the License, or
   20 # (at your option) any later version.
   21 #
   22 # Gnuastro is distributed in the hope that it will be useful, but
   23 # WITHOUT ANY WARRANTY; without even the implied warranty of
   24 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
   25 # General Public License for more details.
   26 #
   27 # You should have received a copy of the GNU General Public License
   28 # along with Gnuastro. If not, see <http://www.gnu.org/licenses/>.
   29 
   30 
   31 
   32 
   33 
   34 # Definitions:
   35 AC_PREREQ([2.69])
   36 AC_INIT([GNU Astronomy Utilities],
   37          m4_esyscmd([bootstrapped/build-aux/git-version-gen    \
   38                         .tarball-version --prefix "gnuastro_v"]),
   39         [bug-gnuastro@gnu.org], [gnuastro],
   40         [http://www.gnu.org/software/gnuastro/])
   41 AC_CONFIG_AUX_DIR([bootstrapped/build-aux])
   42 AM_INIT_AUTOMAKE([-Wall subdir-objects gnu])
   43 AC_CONFIG_SRCDIR([lib/fits.c])
   44 AC_CONFIG_HEADERS([config.h])
   45 AC_CONFIG_MACRO_DIRS([bootstrapped/m4])
   46 
   47 
   48 
   49 
   50 
   51 # Library version, see the GNU Libtool manual ("Library interface versions"
   52 # section for the exact definition of each) for
   53 GAL_CURRENT=6
   54 GAL_REVISION=0
   55 GAL_AGE=0
   56 GAL_LT_VERSION="${GAL_CURRENT}:${GAL_REVISION}:${GAL_AGE}"
   57 AC_SUBST(GAL_LT_VERSION)
   58 
   59 
   60 
   61 
   62 
   63 # Checks for programs.
   64 : ${CFLAGS=""}
   65 : ${CXXFLAGS=""}
   66 AC_PROG_CC
   67 AC_PROG_CXX
   68 gl_EARLY
   69 AM_PROG_AR
   70 LT_INIT
   71 
   72 
   73 
   74 
   75 
   76 # This macro will let the libraries know that we are now in the Gnuastro
   77 # build system, not on the user's system. While we are building Gnuastro,
   78 # we have the important installation information in `config.h'. But in the
   79 # user's own programs, this information is defined in
   80 # `gnuastro/config.h'. With this macro, the installed headers can decide
   81 # if the latter should be included or not. Note that `gnuastro/config.h'
   82 # is only built at installation time and doesn't exist when building
   83 # Gnuastro. Therefore, this macro must not be defined in a user's program.
   84 AC_DEFINE([IN_GNUASTRO_BUILD], [1], [In building, not usage])
   85 
   86 
   87 
   88 
   89 
   90 # See if `make check' should be made with Valgrind. This should be done
   91 # before checking the compilation flags because it can re-write
   92 # `enable-debug').
   93 AC_ARG_ENABLE(check-with-valgrind,
   94               [AS_HELP_STRING([--enable-check-with-valgrind],
   95                               [Run `make check' programs within Valgrind])],
   96               [AS_IF([test "x$enable_check_with_valgrind" != xno],
   97                      [enable_check_with_valgrind=yes])],
   98               [enable_check_with_valgrind=no])
   99 AS_IF([test "x$enable_check_with_valgrind" = "xyes"],
  100       [
  101         enable_debug=yes;
  102         AC_CHECK_PROG(has_valgrind, valgrind, [yes], [no])
  103         AS_IF([test "x$has_valgrind" = "xno"],
  104               [AC_MSG_ERROR([Valgrind not found. Please install it or don't use `--enable-check-with-valgrind'])])
  105       ])
  106 AM_CONDITIONAL([COND_CHECK_WITH_VALGRIND], [test "x$enable_check_with_valgrind" = "xyes"])
  107 
  108 
  109 
  110 
  111 
  112 # Set the compilation flags.
  113 AC_ARG_ENABLE(debug,
  114               [AS_HELP_STRING([--enable-debug],
  115                               [No optimization, debug flags, no shared lib.])],
  116               [AS_IF([test "x$enable_debug" != xno], [enable_debug=yes])],
  117               [enable_debug=no])
  118 AS_IF([test "x$enable_debug" = "xyes"],
  119       [cflags_add="-g -O0"; enable_shared=no],
  120       [cflags_add="-O3"])
  121 CFLAGS="-Wall $cflags_add $CFLAGS"
  122 CXXFLAGS="-Wall $cflags_add $CXXFLAGS"
  123 
  124 
  125 
  126 
  127 
  128 # See if the C++ compiler was present. `CXX' has already been set by
  129 # `AC_PROG_CXX' (above). According to the Autoconf manual: "if none of the
  130 # [AC_PROG_CXX] checks succeed, then as a last resort [it will] set `CXX'
  131 # to `g++'". Therefore, we can't rely on it to see if the compiler
  132 # executable is actually usable. Therefore tests that rely on it will
  133 # fail. Unfortunately some OSs (like Fedora), don't install `g++' with
  134 # `gcc', so it may not always be present. To fix this, here we are just
  135 # using `AC_CHECK_PROG' to see if the `CXX' executable is reachable in the
  136 # search path and if it isn't, we'll disable the C++ check during `make
  137 # check' with an Automake conditional.
  138 AC_CHECK_PROG(has_cxx, $CXX, "yes", "no")
  139 AM_CONDITIONAL([COND_HASCXX], [test "x$has_cxx" = "xyes"])
  140 
  141 
  142 
  143 
  144 
  145 # Check for pthreads and add the appropriate compilation flags. AX_PTHREAD
  146 # comes from the GNU Autoconf Archive's ax_pthread.m4, see there for the
  147 # documentation. Note that
  148 AX_PTHREAD([],[AC_MSG_ERROR([AC_PACKAGE_NAME Needs POSIX Threads (pthread)])])
  149 CXXFLAGS="$CXXFLAGS $PTHREAD_CFLAGS"
  150 CFLAGS="$CFLAGS $PTHREAD_CFLAGS"
  151 LIBS="$PTHREAD_LIBS $LIBS"
  152 CC="$PTHREAD_CC"
  153 
  154 
  155 
  156 
  157 
  158 # See if the C++ compiler understands `-Qunused-arguments'. AX_PTHREAD adds
  159 # puts this option in `PTHREAD_CFLAGS' when the C compiler knows this
  160 # option. We then pass it to CFLAGS and CXXFLAGS above. But as reported in
  161 # bug #52490, it can happen that sometimes, the C++ compiler doesn't
  162 # recognize it. So we need to do a separate check for C++.
  163 cxxflags_tmp=
  164 for flg in $CXXFLAGS; do
  165   AS_IF([test "$flg" = \-Qunused-arguments],
  166         [ AC_LANG(C++)
  167           AX_CHECK_COMPILE_FLAG([-Qunused-arguments],
  168                                 [cxx_Qunused_arguments=yes;
  169                                  cxxflags_tmp="$cxxflags_tmp $flg"],
  170                                 [cxx_Qunused_arguments=no])
  171           AC_LANG(C) ],
  172         [ cxxflags_tmp="$cxxflags_tmp $flg"])
  173 done
  174 CXXFLAGS="$cxxflags_tmp"
  175 
  176 
  177 
  178 
  179 
  180 # Check if `malloc(0)' returns valid pointer
  181 AC_FUNC_MALLOC
  182 
  183 
  184 
  185 
  186 
  187 # Check the size of necessary system specific types.
  188 AC_CHECK_SIZEOF([size_t])
  189 AC_SUBST(SIZEOF_SIZE_T, [$ac_cv_sizeof_size_t])
  190 AC_DEFINE_UNQUOTED([GAL_CONFIG_SIZEOF_SIZE_T], [$ac_cv_sizeof_size_t],
  191                    [On 32bit will be 4, on 64 bit, will be 8])
  192 AC_CHECK_SIZEOF([long])
  193 AC_SUBST(SIZEOF_LONG, [$ac_cv_sizeof_long])
  194 AC_DEFINE_UNQUOTED([GAL_CONFIG_SIZEOF_LONG], [$ac_cv_sizeof_long],
  195                    [On 32bit will be 4, on 64 bit, will be 8])
  196 
  197 
  198 
  199 
  200 
  201 # By default we assume no warnings
  202 anywarnings=no
  203 
  204 
  205 
  206 
  207 
  208 # Remove any occurance of the current directory `./', `.', or the full
  209 # address of the current directory in PATH. The main problem is the
  210 # `libtool' executable which Gnuastro builds internally in the top build
  211 # directory. However, we also need to know if the system has libtool or
  212 # not.
  213 AC_MSG_CHECKING(if PATH contains current directory)
  214 oldPATH=$PATH
  215 currpwd=$(pwd)
  216 
  217 # The first call to SED will remove any occurance of the current directory:
  218 # `./', `.', or the full address.
  219 #
  220 #    NOTE 1: We cannot simply remove all `.'s, because hidden directories
  221 #            (like the `~/.local' that is suggested for local
  222 #            installations) will also be altered.
  223 #
  224 #    NOTE 2: An empty string in the list of strings (separated by `:')
  225 #            means the current directory. This includes cases like: `::',
  226 #            or a leading and trailing `:'. So after all the removals of
  227 #            the current directory, we will remove all such cases.
  228 #
  229 #    NOTE 3: The SED separator can be any character immediately after `s',
  230 #            it doesn't just have to be the commonly used `/'. Since `$pwd'
  231 #            will possibly contain many `/'s, it is much more easier to use
  232 #            a differen separator (`|' in this call to SED).
  233 PATH=$(AS_ECHO([$PATH]) | $SED -e 's|'"$currpwd"'||g' \
  234                                -e 's|\.\.*//*||g'     \
  235                                -e 's|:\.\.*:|:|g'     \
  236                                -e 's|\.*$||'          \
  237                                -e 's|^\.*||'          \
  238                                -e 's|::*|:|g'         \
  239                                -e 's|^:||'            \
  240                                -e 's|:$||' )
  241 AS_IF([test $oldPATH = $PATH],
  242       [ path_warning=no                   ],
  243       [ path_warning=yes; anywarnings=yes ])
  244 AC_MSG_RESULT( $path_warning )
  245 
  246 
  247 
  248 
  249 
  250 # Mandatory dependencies
  251 #
  252 # After each library is found, AC_SEARCH_LIBS adds the -lLIBRARY flag to
  253 # the LIBS variable which is then given to all the Makefiles. Each new flag
  254 # is added to the left of the old one so order matters here. Note that the
  255 # LIBS variable is also used in checking the next libraries, so the linking
  256 # with their dependent libraries is done automatically with this order, and
  257 # we don't have to explicitly set the dependency flags.
  258 has_gsl=yes
  259 has_cmath=yes
  260 has_wcslib=yes
  261 has_cfitsio=yes
  262 has_gslcblas=yes
  263 missing_mandatory=no
  264 missing_optional_lib=no
  265 AC_SEARCH_LIBS(sqrt, m, [],
  266                [missing_mandatory=yes; has_cmath=no])
  267 AC_SEARCH_LIBS([cblas_sdsdot], [gslcblas], [],
  268                [missing_mandatory=yes; has_gslcblas=no])
  269 AC_SEARCH_LIBS([gsl_integration_qng], [gsl], [],
  270                [missing_mandatory=yes; has_gsl=no])
  271 
  272 # Since version 0.42, if `libcurl' is installed, CFITSIO will link with it
  273 # and thus it will be necessary to explicitly link with libcurl also. If it
  274 # doesn't exist on the system, then CFITSIO won't link with it and there is
  275 # no problem for Gnuastro either. So there is no need to stop the configure
  276 # script if libcurl isn't found.
  277 #
  278 # For static builds, linking libcurl (also built in static-only mode) will
  279 # depend on linking with zlib. So we'll need to also search for that
  280 # also. But if libcurl isn't built in static-only mode, then it will have
  281 # undefined symbols for many libraries (for example libpsl, libidn2,
  282 # librtmp, libldap). So if you intend to make Gnuastro statically, then
  283 # build Libcurl in static-only mode so you won't have to check for all
  284 # these extra libraries here.
  285 AC_SEARCH_LIBS([deflateInit_], [z], [], [])
  286 AC_SEARCH_LIBS([curl_global_init], [curl], [], [])
  287 AC_SEARCH_LIBS([ffopen], [cfitsio], [],
  288                [missing_mandatory=yes; has_cfitsio=no])
  289 AC_SEARCH_LIBS([wcspih], [wcs], [],
  290                [missing_mandatory=yes; has_wcslib=no])
  291 
  292 # These are secondary tests for more fine-grained control in libraries that
  293 # have already been checked. We don't need to add them to the LIBS
  294 # variable, so we are using AC_CHECK_LIB for these tests.
  295 AC_CHECK_DECLS(gsl_interp_steffen,
  296                [ gsl_version_old=no                   ],
  297                [ gsl_version_old=yes; anywarnings=yes ],
  298                [[#include <gsl/gsl_interp.h>]])
  299 
  300 # If the CFITSIO library has the `fits_is_reentrant' function (it was added
  301 # since version 3.30 of April 2012).
  302 AC_CHECK_LIB([cfitsio], [fits_is_reentrant], [has_fits_is_reentrant=1],
  303              [has_fits_is_reentrant=0], [-lm])
  304 AC_DEFINE_UNQUOTED([GAL_CONFIG_HAVE_FITS_IS_REENTRANT],
  305                    [$has_fits_is_reentrant],
  306                    [CFITSIO has the fits_is_reentrant function])
  307 AC_SUBST(HAVE_FITS_IS_REENTRANT, [$has_fits_is_reentrant])
  308 
  309 
  310 # If the WCS library has the `wcslib_version' function.
  311 AC_CHECK_LIB([wcs], [wcslib_version], [has_wcslib_version=1],
  312              [has_wcslib_version=0], [-lcfitsio -lm])
  313 AC_DEFINE_UNQUOTED([GAL_CONFIG_HAVE_WCSLIB_VERSION], [$has_wcslib_version],
  314                    [WCSLIB comes with wcslib_version])
  315 AC_SUBST(HAVE_WCSLIB_VERSION, [$has_wcslib_version])
  316 
  317 
  318 # If the pthreads library has `pthread_barrier_wait'.
  319 AC_CHECK_LIB([pthread], [pthread_barrier_wait], [has_pthread_barrier=1],
  320              [has_pthread_barrier=0])
  321 AC_DEFINE_UNQUOTED([GAL_CONFIG_HAVE_PTHREAD_BARRIER], [$has_pthread_barrier],
  322                    [System has pthread_barrier])
  323 AC_SUBST(HAVE_PTHREAD_BARRIER, [$has_pthread_barrier])
  324 
  325 
  326 
  327 
  328 
  329 # To add the help2man:
  330 AC_CHECK_PROG(has_help2man, help2man, [yes], [no])
  331 AM_CONDITIONAL([COND_HASHELP2MAN], [test "x$has_help2man" = "xyes"])
  332 
  333 
  334 
  335 
  336 
  337 # Check libjpeg:
  338 AC_SEARCH_LIBS([jpeg_stdio_dest], [jpeg],
  339                [has_libjpeg=yes], [has_libjpeg=no; missing_optional_lib=yes])
  340 AS_IF([test "x$has_libjpeg" = "xyes"],
  341       [AC_DEFINE([HAVE_LIBJPEG], [], [Has libjpeg])],
  342       [anywarnings=yes])
  343 AM_CONDITIONAL([COND_HASLIBJPEG], [test "x$has_libjpeg" = "xyes"])
  344 
  345 
  346 
  347 
  348 
  349 # Check libtiff: If an LZMA libray (part of the XZ Utils) is present,
  350 # libtiff has probably been built with it. So we'll also need to link with
  351 # the LZMA library. But if libtiff hasn't been linked with it and its
  352 # present, there is no problem, the linker will just pass over it. So we
  353 # don't need to stop the build if this fails.
  354 AC_SEARCH_LIBS([lzma_stream_decoder], [lzma], [], [])
  355 AC_SEARCH_LIBS([TIFFOpen], [tiff],
  356                [has_libtiff=yes], [has_libtiff=no; missing_optional_lib=yes])
  357 AS_IF([test "x$has_libtiff" = "xyes"],
  358       [AC_DEFINE([HAVE_LIBTIFF], [], [Has libtiff])],
  359       [anywarnings=yes])
  360 AM_CONDITIONAL([COND_HASLIBTIFF], [test "x$has_libtiff" = "xyes"])
  361 
  362 
  363 
  364 
  365 
  366 # Check libgit2:
  367 AC_SEARCH_LIBS([git_libgit2_init], [git2],
  368                [has_libgit2=1], [has_libgit2=0; missing_optional_lib=yes])
  369 AC_DEFINE_UNQUOTED([GAL_CONFIG_HAVE_LIBGIT2], [$has_libgit2],
  370                    [libgit2 is installed on the system])
  371 AS_IF([test "x$has_libgit2" = "x1"], [], [anywarnings=yes])
  372 AC_SUBST(HAVE_LIBGIT2, [$has_libgit2])
  373 
  374 
  375 
  376 
  377 
  378 # Check the libtool executable on the system. Note that Gnuastro also ships
  379 # with a version of Libtool. We don't want Gnuastro's Libtool, here we want
  380 # to see if the system has libtool independent of Gnuastro so BuildProgram
  381 # can use it later. We also need to check some shells to run libtool within
  382 # them.
  383 AC_CHECK_PROG(has_libtool, libtool, [yes], [no])
  384 AC_CHECK_PROG(has_bash,    bash,    [yes], [no])
  385 AC_CHECK_PROG(has_zsh,     zsh,     [yes], [no])
  386 
  387 # If Libtool is present, make sure it is GNU Libtool
  388 AS_IF([test "x$has_libtool" = "xyes"],
  389       [ AC_MSG_CHECKING(if libtool executable is GNU)
  390         AS_IF( libtool --version 2> /dev/null | grep GNU 2>&1 > /dev/null,
  391                [has_gnulibtool=yes], [has_gnulibtool=no])
  392         AC_MSG_RESULT( $has_gnulibtool )],
  393       [ has_gnulibtool=no ])
  394 
  395 # When either the `libtool' executable isn't GNU or it doesn't exist, then
  396 # look for `glibtool'.
  397 AS_IF([test "x$has_gnulibtool" = "xyes"],
  398       [ gnulibtool_exec=libtool ],
  399       [ AC_CHECK_PROG(has_glibtool, glibtool, [yes], [no])
  400         AS_IF( [test "x$has_glibtool" = "xyes"],
  401                [has_gnulibtool=yes; gnulibtool_exec=glibtool],
  402                [has_gnulibtool=no; anywarnings=yes] ) ])
  403 
  404 # Older versions of GNU Libtool have problems with the `dash' shell (a
  405 # minimalist shell) and will crash (due to not having the `+=' operator),
  406 # see bug #54430. So we need to check if the system's libtool and shell
  407 # (called by `sh' as in C's `system' function within BuildProgram) can work
  408 # with each other. If not, we need to search for Bash and tell BuildProgram
  409 # to use Bash instead of the default. But older versions of Bash also don't
  410 # support this operator, so we'll have to check with Bash is well.
  411 libtool_shell="none"
  412 AS_IF([test "x$has_gnulibtool" = "xyes"],
  413       [
  414         AC_MSG_CHECKING(for shell to use with libtool)
  415 
  416         # Make a C source file and run Libtool on it with the specified
  417         # shells.
  418         outname=libtool_shell_test
  419         cprog=libtool_shell_test.c
  420         echo "#include <stdio.h>"                                 > $cprog
  421         echo "int main(void){printf(\"success\\n\"); return 0;}" >> $cprog
  422         ltargs="--quiet --tag=CC --mode=link $CC $cprog -O3 -o $outname"
  423         AS_IF( sh -c "$gnulibtool_exec $ltargs" > /dev/null 2>&1,
  424                [libtool_shell="sh"],
  425                [AS_IF([test "x$has_bash" = "xyes"],
  426                       [AS_IF(bash -c "$gnulibtool_exec $ltargs" > /dev/null 2>&1,
  427                              [libtool_shell="bash"]) ],
  428                       [AS_IF([test "x$has_zsh" = "xyes"],
  429                              [AS_IF(zsh -c "$gnulibtool_exec $ltargs" > /dev/null 2>&1,
  430                                     [libtool_shell="zsh"]) ])
  431                        ] )
  432                ] )
  433 
  434         # Clean up: note that no output might have been generated (when no
  435         # proper shell was found). Therefore, for deleting the output file,
  436         # we'll call `rm' with `-f' so it doesn't complain with an error in
  437         # such cases.
  438         rm $cprog
  439         rm -f $outname
  440         AC_MSG_RESULT($libtool_shell)
  441       ])
  442 
  443 # If a good shell to call Libtool could be found, then Libtool is usable
  444 # within a program (BuildProgram in this case).
  445 AS_IF([test "x$libtool_shell" = "xnone"],
  446       [usable_libtool=no; anywarnings=yes],
  447       [
  448         usable_libtool=yes
  449         AC_DEFINE_UNQUOTED([GAL_CONFIG_GNULIBTOOL_SHELL], ["$libtool_shell"],
  450                            [Shell program to use with GNU Libtool])
  451         AC_DEFINE_UNQUOTED([GAL_CONFIG_GNULIBTOOL_EXEC], ["$gnulibtool_exec"],
  452                            [The executable to call GNU Libtool])
  453       ])
  454 
  455 
  456 
  457 
  458 # Check Ghostscript: "-dPDFFitPage" option to Ghostscript, used by the
  459 # library to convert from EPS to PDF, has been introduced in Ghostscript
  460 # 9.10.  Make sure we have at least that version.
  461 #
  462 # Below, only when Ghostscript exists, we check its version and only if its
  463 # version is larger than 9.10, does Gnuastro finally assume the existence
  464 # of Ghostscript. AX_COMPARE_VERSION comes from the GNU Autoconf Archive's
  465 # ax_compare_version.m4.
  466 AC_CHECK_PROG(has_ghostscript, gs, [yes], [no])
  467 AS_IF([test "x$has_ghostscript" = "xyes"],
  468       [AC_MSG_CHECKING(Ghostscript version)
  469        gsversion=$(gs --version)
  470        AX_COMPARE_VERSION([9.10], [gt], [$gsversion], [has_ghostscript=no])
  471        AC_MSG_RESULT( $gsversion )])
  472 # Note: `has_ghostscript' can be set to `no' within the AS_IF above, so
  473 # `anywarnings' cannot be an [RUN-IF-FALSE] argument to the AS_IF above.
  474 AS_IF([test "x$has_ghostscript" = "xno"], [anywarnings=yes])
  475 AM_CONDITIONAL([COND_HASGHOSTSCRIPT], [test "x$has_ghostscript" = "xyes"])
  476 
  477 
  478 
  479 
  480 
  481 # If any necessary dependency is missing inform the user and abort.
  482 AS_IF([test "x$missing_mandatory" = "xyes"],
  483       [
  484         # List missing packages: print the GSL CBLAS message only if GSL is
  485         # present. Otherwise, it is just confusing for the users (CBLAS
  486         # will be installed with GSL). The CBLAS message is only
  487         # interesting if the GSL test has passed.
  488         AS_ECHO([""])
  489         AS_ECHO(["Missing MANDATORY dependencies (necessary to continue):"])
  490         AS_IF([test "x$has_cmath" = "xno"],
  491               [ AS_ECHO([" - C library (math): This may be the cause of all other failures."]) ])
  492         AS_IF([test "x$has_gsl" = "xno"],
  493               [ AS_ECHO([" - GNU Scientific Library (GSL): https://www.gnu.org/software/gsl"]) ],
  494               [ AS_IF([test "x$has_gslcblas" = "xno"],
  495                       [ AS_ECHO([" - The BLAS support of GNU Scientific Library (GSL). This should have"])
  496                         AS_ECHO(["   been installed along with GSL. Try re-installing GSL."]) ]) ])
  497         AS_IF([test "x$has_cfitsio" = "xno"],
  498               [ AS_ECHO([" - CFITSIO: https://heasarc.gsfc.nasa.gov/fitsio"]) ])
  499         AS_IF([test "x$has_wcslib" = "xno"],
  500               [ AS_ECHO([" - WCSLIB: http://www.atnf.csiro.au/people/mcalabre/WCS"]) ])
  501 
  502         # Optional dependencies:
  503         AS_IF([test "x$anywarnings" = xyes],
  504               [
  505                 AS_ECHO([""])
  506                 AS_ECHO(["OPTIONAL warnings/dependencies (for improved functionality):"])
  507                 AS_IF([test "x$gsl_version_old" = "xyes"],
  508                       [ AS_ECHO([" - Old GSL version: https://www.gnu.org/s/gsl"])                ])
  509                 AS_IF([test "x$has_libjpeg" = "xno"],
  510                       [ AS_ECHO([" - Missing Libjpeg (JPEG files): http://ijg.org"])              ])
  511                 AS_IF([test "x$has_libtiff" = "xno"],
  512                       [ AS_ECHO([" - Missing Libtiff (TIFF files): http://libtiff.maptools.org"]) ])
  513                 AS_IF([test "x$has_libgit2" = "x0"],
  514                       [ AS_ECHO([" - Missing Libgit2: https://libgit2.org"])                      ])
  515                 AS_IF([test "x$usable_libtool" = "xno"],
  516                       [ AS_ECHO([" - Unusable GNU Libtool: https://www.gnu.org/s/libtool"])
  517                         AS_IF([test "x$has_gnulibtool" = "xyes"],
  518                               [ AS_ECHO(["  -- GNU Libtool is present, tested shells not supported."])  ])
  519                         AS_IF([test "x$has_libtool" = "xyes"],
  520                               [ AS_ECHO(["  -- A libtool implementation was found, but it isn't GNU."]) ])
  521                       ])
  522                 AS_IF([test "x$has_ghostscript" = "xno"],
  523                       [ AS_ECHO([" - Missing GPL Ghostscript (v9.10 or later): https://www.ghostscript.com"])])
  524               ])
  525 
  526         # Suggestions on fixing the problem.
  527         AS_ECHO([""])
  528         AS_ECHO(["You can use your package manager for easy and fast installation of all"])
  529         AS_ECHO(["dependencies in one command. See the link below:"])
  530         AS_ECHO(["  https://www.gnu.org/s/gnuastro/manual/html_node/Dependencies-from-package-managers.html"])
  531         AS_ECHO([""])
  532         AS_ECHO(["If you have already installed a dependency (for example in \`/install/path'),"])
  533         AS_ECHO(["but this script can't link with it, add the path to the LDFLAGS, CPPFLAGS and"])
  534         AS_ECHO(["LD_LIBRARY_PATH environment variables before running configure. For example"])
  535         AS_ECHO(["with the following commands (just correct the \`/install/path' part)."])
  536         AS_ECHO(["  $ export LDFLAGS=\"\$LDFLAGS -L/install/path/lib\""])
  537         AS_ECHO(["  $ export CPPFLAGS=\"\$CPPFLAGS -I/install/path/include\""])
  538         AS_ECHO(["  $ export LD_LIBRARY_PATH=\"\$LD_LIBRARY_PATH:/install/path/lib\""])
  539         AS_ECHO([""])
  540         AS_ECHO(["[TIP:] Put these commands in your startup file (for example \`~/.bashrc') to"])
  541         AS_ECHO(["avoid similar problems later. See the link below to learn more:"])
  542         AS_ECHO(["  https://www.gnu.org/s/gnuastro/manual/html_node/Installation-directory.html"])
  543         AS_ECHO([""])
  544         AS_ECHO([""])
  545         AC_MSG_ERROR([Mandatory dependency(s) missing, === SEE MESSAGE ABOVE ===.])
  546       ])
  547 
  548 
  549 
  550 
  551 
  552 # Gnulib checks:
  553 gl_INIT
  554 
  555 
  556 
  557 
  558 
  559 # Check if Gnulib tests should be done:
  560 AC_ARG_ENABLE([gnulibcheck],
  561               [AS_HELP_STRING([--enable-gnulibcheck],
  562   	            [In `make check', also test GNU Gnulib.])],
  563 	      [enable_gnulibcheck=yes], [enable_gnulibcheck=no])
  564 AM_CONDITIONAL([COND_GNULIBCHECK], [test $enable_gnulibcheck = yes])
  565 
  566 
  567 
  568 
  569 
  570 # Gnulib checks for the proper name for the C99 equivalent `restrict'
  571 # keyword and puts it in the `ac_cv_c_restrict' variable. If none exists,
  572 # it will put a `no' inside of this variable. As described in the output
  573 # `bootstrapped/m4/gnulib-common.m4', this is only necessary until Autoconf
  574 # 2.70 is released. Afterwards, we can use AC_C_RESTRICT.
  575 AS_IF([test "x$ac_cv_c_restrict" = "xno"],
  576       [gal_restrict_replace=], [gal_restrict_replace=$ac_cv_c_restrict])
  577 AC_SUBST(RESTRICT_REPLACEMENT, [$gal_restrict_replace])
  578 
  579 
  580 
  581 
  582 
  583 # Set the one general parameters:
  584 AC_DEFINE_UNQUOTED([CONF_POSTFIX], [".conf"], [Configuration file post fix.])
  585 AC_DEFINE_UNQUOTED([USERCONFIG_DIR], [".local/etc"], [User data dir.])
  586 AC_DEFINE_UNQUOTED([CONF_SHOWFMT], [" %-20s"],
  587                    [Configuration file name format.])
  588 
  589 
  590 
  591 
  592 
  593 # Read arguments about which programs to install. After checking if
  594 # the argument was actually called, remove any value the user might
  595 # have given by setting them to "yes" if they are not "no". These
  596 # options don't accept arguments.
  597 ayes=false
  598 AC_ARG_ENABLE([arithmetic],
  599               [AS_HELP_STRING([--enable-arithmetic],
  600                     [Install Arithmetic and other enabled programs.])],
  601 	      [AS_IF([test "x$enable_arithmetic" != xno],
  602                      [enable_arithmetic=yes; ayes=true])],
  603               [enable_arithmetic=notset])
  604 AC_ARG_ENABLE([buildprog],
  605               [AS_HELP_STRING([--enable-buildprog],
  606                     [Install BuildProgram and other enabled programs.])],
  607 	      [AS_IF([test "x$enable_buildprog" != xno],
  608                      [enable_buildprog=yes; ayes=true])],
  609               [enable_buildprog=notset])
  610 AC_ARG_ENABLE([convertt],
  611               [AS_HELP_STRING([--enable-convertt],
  612                     [Install ConvertType and other enabled programs.])],
  613 	      [AS_IF([test "x$enable_convertt" != xno],
  614                      [enable_convertt=yes; ayes=true])],
  615               [enable_convertt=notset])
  616 AC_ARG_ENABLE([convolve],
  617               [AS_HELP_STRING([--enable-convolve],
  618                     [Install Convolve and other enabled programs.])],
  619 	      [AS_IF([test "x$enable_convolve" != xno],
  620                      [enable_cognvolve=yes; ayes=true])],
  621               [enable_convolve=notset])
  622 AC_ARG_ENABLE([cosmiccal],
  623               [AS_HELP_STRING([--enable-cosmiccal],
  624                     [Install CosmicCalculator and other enabled programs.])],
  625 	      [AS_IF([test "x$enable_cosmiccal" != xno],
  626                      [enable_cosmiccal=yes; ayes=true])],
  627               [enable_cosmiccal=notset])
  628 AC_ARG_ENABLE([crop],
  629               [AS_HELP_STRING([--enable-crop],
  630                     [Install Crop and other enabled programs.])],
  631 	      [AS_IF([test "x$enable_crop" != xno],
  632                      [enable_crop=yes; ayes=true])],
  633               [enable_crop=notset])
  634 AC_ARG_ENABLE([fits],
  635               [AS_HELP_STRING([--enable-fits],
  636                     [Install Fits and other enabled programs.])],
  637 	      [AS_IF([test "x$enable_fits" != xno],
  638                      [enable_fits=yes; ayes=true])],
  639               [enable_fits=notset])
  640 AC_ARG_ENABLE([match],
  641               [AS_HELP_STRING([--enable-match],
  642                     [Install Match and other enabled programs.])],
  643 	      [AS_IF([test "x$enable_match" != xno],
  644                      [enable_match=yes; ayes=true])],
  645               [enable_match=notset])
  646 AC_ARG_ENABLE([mkcatalog],
  647               [AS_HELP_STRING([--enable-mkcatalog],
  648                     [Install MakeCatalog and other enabled programs.])],
  649 	      [AS_IF([test "x$enable_mkcatalog" != xno],
  650                      [enable_mkcatalog=yes; ayes=true])],
  651               [enable_mkcatalog=notset])
  652 AC_ARG_ENABLE([mknoise],
  653               [AS_HELP_STRING([--enable-mknoise],
  654                     [Install MakeNoise and other enabled programs.])],
  655 	      [AS_IF([test "x$enable_mknoise" != xno],
  656                      [enable_mknoise=yes; ayes=true])],
  657               [enable_mknoise=notset])
  658 AC_ARG_ENABLE([mkprof],
  659               [AS_HELP_STRING([--enable-mkprof],
  660                     [Install MakeProfile and other enabled programs.])],
  661 	      [AS_IF([test "x$enable_mkprof" != xno],
  662                      [enable_mkprof=yes; ayes=true])],
  663               [enable_mkprof=notset])
  664 AC_ARG_ENABLE([noisechisel],
  665               [AS_HELP_STRING([--enable-noisechisel],
  666                     [Install NoiseChisel and other enabled programs.])],
  667 	      [AS_IF([test "x$enable_noisechisel" != xno],
  668                      [enable_noisechisel=yes; ayes=true])],
  669               [enable_noisechisel=notset])
  670 AC_ARG_ENABLE([segment],
  671               [AS_HELP_STRING([--enable-segment],
  672                     [Install Segment and other enabled programs.])],
  673 	      [AS_IF([test "x$enable_segment" != xno],
  674                      [enable_segment=yes; ayes=true])],
  675               [enable_segment=notset])
  676 AC_ARG_ENABLE([statistics],
  677               [AS_HELP_STRING([--enable-statistics],
  678                     [Install Statistics and other enabled programs.])],
  679 	      [AS_IF([test "x$enable_statistics" != xno],
  680                      [enable_statistics=yes; ayes=true])],
  681               [enable_statistics=notset])
  682 AC_ARG_ENABLE([table],
  683               [AS_HELP_STRING([--enable-table],
  684                     [Install Table and other enabled programs.])],
  685 	      [AS_IF([test "x$enable_table" != xno],
  686                      [enable_table=yes; ayes=true])],
  687               [enable_table=notset])
  688 #AC_ARG_ENABLE([TEMPLATE],
  689 #              [AS_HELP_STRING([--enable-TEMPLATE],
  690 #                    [Install TEMPLATE and other enabled packages.])],
  691 #	      [AS_IF([test "x$enable_TEMPLATE" != xno],
  692 #                     [enable_TEMPLATE=yes; ayes=true])],
  693 #              [enable_TEMPLATE=notset])
  694 AC_ARG_ENABLE([warp],
  695               [AS_HELP_STRING([--enable-warp],
  696                     [Install Warp and other enabled programs.])],
  697 	      [AS_IF([test "x$enable_warp" != xno],
  698                      [enable_warp=yes; ayes=true])],
  699               [enable_warp=notset])
  700 
  701 
  702 
  703 
  704 
  705 # If we had a "ayes" variable to be "true" if there was a `yes'. So any
  706 # program that is not explicitly requested must be ignored and vice versa
  707 # (if no programs were explicitly requested, then enable all that weren't
  708 # disabled).
  709 AS_IF([test $ayes = true ],
  710       [
  711        AS_IF([test $enable_arithmetic = notset],  [enable_arithmetic=no])
  712        AS_IF([test $enable_buildprog = notset],   [enable_buildprog=no])
  713        AS_IF([test $enable_convertt = notset],    [enable_convertt=no])
  714        AS_IF([test $enable_convolve = notset],    [enable_convolve=no])
  715        AS_IF([test $enable_cosmiccal = notset],   [enable_cosmiccal=no])
  716        AS_IF([test $enable_crop = notset],        [enable_crop=no])
  717        AS_IF([test $enable_fits = notset],        [enable_fits=no])
  718        AS_IF([test $enable_match = notset],       [enable_match=no])
  719        AS_IF([test $enable_mkcatalog = notset],   [enable_mkcatalog=no])
  720        AS_IF([test $enable_mknoise = notset],     [enable_mknoise=no])
  721        AS_IF([test $enable_mkprof = notset],      [enable_mkprof=no])
  722        AS_IF([test $enable_noisechisel = notset], [enable_noisechisel=no])
  723        AS_IF([test $enable_segment = notset],     [enable_segment=no])
  724        AS_IF([test $enable_statistics = notset],  [enable_statistics=no])
  725        AS_IF([test $enable_table = notset],       [enable_table=no])
  726 #      AS_IF([test $enable_TEMPLATE = notset],    [enable_TEMPLATE=no])
  727        AS_IF([test $enable_warp = notset],        [enable_warp=no])
  728        ],
  729 
  730       [
  731        AS_IF([test $enable_arithmetic = notset],  [enable_arithmetic=yes])
  732        AS_IF([test $enable_buildprog = notset],   [enable_buildprog=yes])
  733        AS_IF([test $enable_convertt = notset],    [enable_convertt=yes])
  734        AS_IF([test $enable_convolve = notset],    [enable_convolve=yes])
  735        AS_IF([test $enable_cosmiccal = notset],   [enable_cosmiccal=yes])
  736        AS_IF([test $enable_crop = notset],        [enable_crop=yes])
  737        AS_IF([test $enable_fits = notset],        [enable_fits=yes])
  738        AS_IF([test $enable_match = notset],       [enable_match=yes])
  739        AS_IF([test $enable_mkcatalog = notset],   [enable_mkcatalog=yes])
  740        AS_IF([test $enable_mknoise = notset],     [enable_mknoise=yes])
  741        AS_IF([test $enable_mkprof = notset],      [enable_mkprof=yes])
  742        AS_IF([test $enable_noisechisel = notset], [enable_noisechisel=yes])
  743        AS_IF([test $enable_segment = notset],     [enable_segment=yes])
  744        AS_IF([test $enable_statistics = notset],  [enable_statistics=yes])
  745        AS_IF([test $enable_table = notset],       [enable_table=yes])
  746 #      AS_IF([test $enable_TEMPLATE = notset],    [enable_TEMPLATE=yes])
  747        AS_IF([test $enable_warp = notset],        [enable_warp=yes])
  748        ]
  749      )
  750 
  751 
  752 
  753 
  754 
  755 # BuildProgram depends on the presence of GNU Libtool, if it isn't present,
  756 # then don't build it.
  757 AS_IF([test "x$usable_libtool" = "xno"], [enable_buildprog=no])
  758 
  759 
  760 
  761 
  762 
  763 # Make the enable_package values available for the Makefile:
  764 AM_CONDITIONAL([COND_ARITHMETIC],  [test $enable_arithmetic = yes])
  765 AM_CONDITIONAL([COND_BUILDPROG],   [test $enable_buildprog = yes])
  766 AM_CONDITIONAL([COND_CONVERTT],    [test $enable_convertt = yes])
  767 AM_CONDITIONAL([COND_CONVOLVE],    [test $enable_convolve = yes])
  768 AM_CONDITIONAL([COND_COSMICCAL],   [test $enable_cosmiccal = yes])
  769 AM_CONDITIONAL([COND_CROP],        [test $enable_crop = yes])
  770 AM_CONDITIONAL([COND_FITS],        [test $enable_fits = yes])
  771 AM_CONDITIONAL([COND_MATCH],       [test $enable_match = yes])
  772 AM_CONDITIONAL([COND_MKCATALOG],   [test $enable_mkcatalog = yes])
  773 AM_CONDITIONAL([COND_MKNOISE],     [test $enable_mknoise = yes])
  774 AM_CONDITIONAL([COND_MKPROF],      [test $enable_mkprof = yes])
  775 AM_CONDITIONAL([COND_NOISECHISEL], [test $enable_noisechisel = yes])
  776 AM_CONDITIONAL([COND_SEGMENT],     [test $enable_segment = yes])
  777 AM_CONDITIONAL([COND_STATISTICS],  [test $enable_statistics = yes])
  778 AM_CONDITIONAL([COND_TABLE],       [test $enable_table = yes])
  779 #AM_CONDITIONAL([COND_TEMPLATE],   [test $enable_TEMPLATE = yes])
  780 AM_CONDITIONAL([COND_WARP],        [test $enable_warp = yes])
  781 
  782 
  783 
  784 
  785 
  786 # Tell autoconf what to work on: TEMPLATE cannot be put and then
  787 # commented here like the cases above, so don't forget to add your new
  788 # utility name here.
  789 AC_CONFIG_FILES([Makefile
  790                  doc/Makefile
  791                  lib/Makefile
  792 		 tests/Makefile
  793                  bin/crop/Makefile
  794                  bin/fits/Makefile
  795                  bin/warp/Makefile
  796                  bin/table/Makefile
  797                  bin/match/Makefile
  798                  bin/mkprof/Makefile
  799                  bin/mknoise/Makefile
  800                  bin/segment/Makefile
  801                  bin/convertt/Makefile
  802                  bin/convolve/Makefile
  803                  bin/buildprog/Makefile
  804                  bin/cosmiccal/Makefile
  805            	 bin/mkcatalog/Makefile
  806                  bin/arithmetic/Makefile
  807            	 bin/statistics/Makefile
  808                  bin/noisechisel/Makefile
  809                  bootstrapped/lib/Makefile
  810                  bootstrapped/tests/Makefile
  811                  ])
  812 
  813 
  814 
  815 
  816 
  817 # Printing guiding messages. Autoconf will make the variable
  818 # enable_guide_message from the first argument to AC_ARG_ENABLE. It will
  819 # also give it a value. From the Autoconf manual, we see that
  820 # `--disable-guide-message' is equivalent to a value of `no', while with no
  821 # argument, the value will default to `yes'. In the last argument to
  822 # AC_ARG_ENABLE, we also specify the default behavior (when it isn't given
  823 # at all), here we want the default to be `yes'.
  824 AC_ARG_ENABLE([guide-message],
  825               [AS_HELP_STRING([--disable-guide-message],
  826                    [No messages after each build step.])],
  827 	      [], [enable_guide_message=yes])
  828 AC_SUBST(GUIDEMESSAGE, [$enable_guide_message])
  829 
  830 
  831 
  832 
  833 # Build the man page directory. Note that this is the cleanest and most
  834 # portable way of building this directory. We don't want to do it in any of
  835 # the Makefiles.
  836 AC_CONFIG_COMMANDS([man page directory], [$MKDIR_P doc/man])
  837 
  838 
  839 
  840 
  841 
  842 # Make the Makefiles:
  843 AC_OUTPUT
  844 
  845 
  846 
  847 
  848 
  849 # Print a message if necessary
  850 AS_IF([test x$enable_guide_message = xyes],
  851 [
  852   AS_ECHO([])
  853   AS_ECHO([=======================================================================])
  854   AS_ECHO([=======================================================================])
  855   AS_ECHO(["$PACKAGE_NAME (Gnuastro) $PACKAGE_VERSION is successfully"])
  856   AS_ECHO(["configured for this machine."])
  857   AS_ECHO([])
  858   AS_IF([test "x$anywarnings" = xyes],
  859       [
  860         AS_ECHO(["Configuration warning(s):"])
  861         AS_ECHO([])
  862 
  863         AS_IF([test "x$gsl_version_old" = "xyes"],
  864               [AS_ECHO(["  - GNU Scientific Library (GSL: https://www.gnu.org/s/gsl) version"])
  865                AS_ECHO(["    on this system doesn't have some features that can be useful in"])
  866                AS_ECHO(["    some parts of Gnuastro. This build won't crash, but Gnuastro will"])
  867                AS_ECHO(["    have less functionality afterwards. We thus recommend building"])
  868                AS_ECHO(["    and installing a more recent version of GSL (version >= 2.0,"])
  869                AS_ECHO(["    released in October 2015)."])
  870                AS_ECHO([]) ])
  871 
  872         AS_IF([test "x$has_libjpeg" = "xno"],
  873               [AS_ECHO(["  - libjpeg (http://ijg.org), could not be linked with in your library"])
  874                AS_ECHO(["    search path. If JPEG inputs/outputs are requested, the respective"])
  875                AS_ECHO(["    tool will inform you and abort with an error."])
  876                AS_ECHO([]) ])
  877 
  878         AS_IF([test "x$has_libtiff" = "xno"],
  879               [AS_ECHO(["  - libtiff (http://libtiff.maptools.org), could not be linked with in"])
  880                AS_ECHO(["    your library search path. If TIFF inputs/outputs are requested, the"])
  881                AS_ECHO(["    respective tool will inform you and abort with an error."])
  882                AS_ECHO([]) ])
  883 
  884         AS_IF([test "x$has_libgit2" = "x0"],
  885               [AS_ECHO(["  - libgit2 (https://libgit2.org), could not be linked with in your"])
  886                AS_ECHO(["    library search path. When present, Git's describe output will be"])
  887                AS_ECHO(["    stored in the output files if Gnuastro's programs were called"])
  888                AS_ECHO(["    within a Gitversion controlled directory to help in reproducibility."])
  889                AS_ECHO([]) ])
  890 
  891         AS_IF([test "x$usable_libtool" = "xno"],
  892               [AS_ECHO(["  - GNU Libtool (https://www.gnu.org/s/libtool) can't be used on this"])
  893                AS_ECHO(["    system (see below). Gnuastro's BuildProgram uses GNU libtool to"])
  894                AS_ECHO(["    link your source code with the various libraries (Gnuastro's"])
  895                AS_ECHO(["    dependencies). Therefore BuildProgram will not be built or installed."])
  896                AS_ECHO(["    Please note that not having GNU libtool in your search path will not"])
  897                AS_ECHO(["    harm the rest of Gnuastro's building and installation. Gnuastro has"])
  898                AS_ECHO(["    its own internal implementation of GNU Libtool to build its self. This"])
  899                AS_ECHO(["    warning is only to let you know that BuildProgram will not be"])
  900                AS_ECHO(["    part of this build. The executable names searched were \`libtool'"])
  901                AS_ECHO(["    and \`glibtool'. The shells searched were \`sh', \`bash' and \`zsh'."])
  902                AS_ECHO([])
  903                AS_IF([test "x$has_gnulibtool" = "xyes"],
  904                      [AS_ECHO(["    -- GNU Libtool is present, but couldn't be run in tested shells."])
  905                       AS_ECHO([])],
  906                      [AS_IF([test "x$has_libtool" = "xyes"],
  907                             [AS_ECHO(["    -- A libtool implementation was found, but it isn't GNU."])
  908                              AS_ECHO([]) ]) ])
  909               ])
  910 
  911         AS_IF([test "x$has_ghostscript" = "xno"],
  912               [AS_ECHO(["  - GPL GhostScript (https://www.ghostscript.com) version 9.10 or later,"])
  913                AS_ECHO(["    with the executable name \`gs', was not found in your PATH environment"])
  914                AS_ECHO(["    variable. If PDF outputs are desired, the respective tool it will abort"])
  915                AS_ECHO(["    with an EPS output which you can convert to PDF by other means."])
  916                AS_ECHO([]) ])
  917 
  918         # The last two scenarios described below are taken from
  919         # https://unix.stackexchange.com/questions/65700/is-it-safe-to-add-to-my-path-how-come
  920         AS_IF([test "x$path_warning" = "xyes"],
  921               [AS_ECHO(["  - Your PATH contains the current directory. This does not affect"])
  922                AS_ECHO(["    this build and installation of Gnuastro in any way, it is just to"])
  923                AS_ECHO(["    to remind you that this is a security risk."])
  924                AS_ECHO(["      It is a very serious security risk if it is closer to the start"])
  925                AS_ECHO(["    of your PATH: a malicious/wrong program might be run instead of"])
  926                AS_ECHO(["    a desired program, someone might find out you frequently mistype"])
  927                AS_ECHO(["    a command and install a matching one, someone might install a"])
  928                AS_ECHO(["    fake command with the name of one that is not installed. You can"])
  929                AS_ECHO(["    always run a program in the current directory by explicity adding"])
  930                AS_ECHO(["    a \`./' before it's name. Run the following command after"])
  931                AS_ECHO(["    installing Gnuastro to learn more about PATH:"])
  932                AS_ECHO(["        $ info gnuastro \"Installation directory\""])
  933                AS_ECHO([]) ])
  934 
  935         # Notice on obtaining all the packages.
  936         AS_ECHO(["  You can use your package manager for easy and fast installation of all"])
  937         AS_ECHO(["  the mandatory and optional dependencies in one command. See the link"])
  938         AS_ECHO(["  below:"])
  939         AS_ECHO(["    https://www.gnu.org/s/gnuastro/manual/html_node/Dependencies-from-package-managers.html"])
  940         AS_ECHO([])
  941 
  942         # Inform the user on skipped tests.
  943         AS_ECHO(["  All checks related to the warning(s) above will be skipped."])
  944         AS_ECHO([])
  945       ]
  946      )
  947   AS_ECHO(["To build Gnuastro $PACKAGE_VERSION, please run:"])
  948   AS_ECHO([])
  949   AS_ECHO(["    make -j8"])
  950   AS_ECHO([])
  951   AS_ECHO(["(You can change the 8 to the number of CPU threads available.)"])
  952   AS_ECHO(["(Configure with '--disable-guide-message' for no messages.)"])
  953   AS_ECHO(["(Please be patient, some libraries can take a few minutes to compile.)"])
  954   AS_ECHO([=======================================================================])
  955   AS_ECHO([=======================================================================])
  956   AS_ECHO([])
  957 ])