Commit | Line | Data |
---|---|---|
e03d7c66 MJ |
1 | # SPDX-License-Identifier: FSFAP |
2 | # | |
5c5aae82 | 3 | # =========================================================================== |
e465639e | 4 | # https://www.gnu.org/software/autoconf-archive/ax_prog_jar.html |
5c5aae82 CB |
5 | # =========================================================================== |
6 | # | |
7 | # SYNOPSIS | |
8 | # | |
9 | # AX_PROG_JAR | |
10 | # | |
11 | # DESCRIPTION | |
12 | # | |
13 | # AX_PROG_JAR tests for an existing jar program. It uses the environment | |
14 | # variable JAR then tests in sequence various common jar programs. | |
15 | # | |
16 | # If you want to force a specific compiler: | |
17 | # | |
18 | # - at the configure.in level, set JAR=yourcompiler before calling | |
19 | # AX_PROG_JAR | |
20 | # | |
21 | # - at the configure level, setenv JAR | |
22 | # | |
23 | # You can use the JAR variable in your Makefile.in, with @JAR@. | |
24 | # | |
25 | # Note: This macro depends on the autoconf M4 macros for Java programs. It | |
26 | # is VERY IMPORTANT that you download that whole set, some macros depend | |
27 | # on other. Unfortunately, the autoconf archive does not support the | |
28 | # concept of set of macros, so I had to break it for submission. | |
29 | # | |
30 | # The general documentation of those macros, as well as the sample | |
31 | # configure.in, is included in the AX_PROG_JAVA macro. | |
32 | # | |
33 | # LICENSE | |
34 | # | |
35 | # Copyright (c) 2008 Egon Willighagen <e.willighagen@science.ru.nl> | |
36 | # | |
37 | # Copying and distribution of this file, with or without modification, are | |
38 | # permitted in any medium without royalty provided the copyright notice | |
39 | # and this notice are preserved. This file is offered as-is, without any | |
40 | # warranty. | |
41 | ||
e465639e | 42 | #serial 8 |
5c5aae82 CB |
43 | |
44 | AU_ALIAS([AC_PROG_JAR], [AX_PROG_JAR]) | |
45 | AC_DEFUN([AX_PROG_JAR],[ | |
46 | AS_IF([test "x$JAVAPREFIX" = x], | |
47 | [test "x$JAR" = x && AC_CHECK_PROGS([JAR], [jar])], | |
48 | [test "x$JAR" = x && AC_CHECK_PROGS([JAR], [jar], [], [$JAVAPREFIX/bin])]) | |
49 | test "x$JAR" = x && AC_MSG_ERROR([no acceptable jar program found in \$PATH]) | |
50 | AC_PROVIDE([$0])dnl | |
51 | ]) |