Annotation of freem/configure.ac, revision 1.5
1.1 snw 1: #
1.5 ! snw 2: # $Id$
1.1 snw 3: # autoconf rules for FreeM
4: #
5: #
1.4 snw 6: # Author: Serena Willis <jpw@coherent-logic.com>
1.1 snw 7: # Copyright (C) 1998 MUG Deutschland
1.5 ! snw 8: # Copyright (C) 2020, 2025 Coherent Logic Development LLC
1.1 snw 9: #
10: #
11: # This file is part of FreeM.
12: #
13: # FreeM is free software: you can redistribute it and/or modify
14: # it under the terms of the GNU Affero Public License as published by
15: # the Free Software Foundation, either version 3 of the License, or
16: # (at your option) any later version.
17: #
18: # FreeM is distributed in the hope that it will be useful,
19: # but WITHOUT ANY WARRANTY; without even the implied warranty of
20: # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
21: # GNU Affero Public License for more details.
22: #
23: # You should have received a copy of the GNU Affero Public License
24: # along with FreeM. If not, see <https://www.gnu.org/licenses/>.
25: #
1.5 ! snw 26: # $Log$
1.1 snw 27: #
1.5 ! snw 28: # SPDX-FileCopyrightText: (C) 2025 Coherent Logic Development LLC
! 29: # SPDX-License-Identifier: AGPL-3.0-or-later
! 30:
1.1 snw 31:
1.3 snw 32: AC_INIT([freem],[cvs-current],[jpw@coherent-logic.com])
1.1 snw 33: AC_CONFIG_HEADERS([src/config.h])
34: AC_CONFIG_MACRO_DIR([m4])
35:
36: AX_LIB_READLINE
37:
38: # check for libm
39: AC_CHECK_LIB([m], [powf])
40: AC_CHECK_LIB([m], [pow])
41:
42: AC_CANONICAL_HOST
43:
44: # find out if we need to link with -lsocket and/or -lnsl to get
45: # BSD sockets support
46:
47: AU_ALIAS([LIB_SOCKET_NSL], [AX_LIB_SOCKET_NSL])
48:
49: AC_DEFUN([AX_LIB_SOCKET_NSL],
50: [
51: AC_SEARCH_LIBS([gethostbyname], [nsl])
52: AC_SEARCH_LIBS([socket], [socket], [], [
53: AC_CHECK_LIB([socket], [socket], [LIBS="-lsocket -lnsl $LIBS"],
54: [], [-lnsl])])
55: ])
56:
57: AX_LIB_SOCKET_NSL
58:
59: #
60: # check for getopt.h and getopt_long
61: #
62: AC_CHECK_HEADERS(getopt.h)
63: AC_CHECK_FUNCS([getopt_long])
64:
65: #
66: # bring in X11, X Toolkit, and Motif if --enable-mwapi is passed to configure
67: #
68: AC_ARG_ENABLE([mwapi], AS_HELP_STRING([--enable-mwapi], [Enable MWAPI (OSF/Motif) support (EXPERIMENTAL)]))
69:
70: AS_IF([test "x$enable_mwapi" = "xyes"], [
71: AX_LIB_MOTIF
72: ])
73:
74: # check for wiringPi headers and library linkage for
75: # ^$ZRPI ssv on Raspberry Pi SBCs
76: AC_CHECK_HEADERS(wiringPi.h)
77:
78: AC_DEFUN([AX_LIB_WIRINGPI],
79: [
80: AC_SEARCH_LIBS([wiringPiSetup], [wiringPi], [], [
81: AC_CHECK_LIB([wiringPi], [wiringPiSetup], [LIBS="-lwiringPi $LIBS"],
82: [], [-lwiringPi])])
83: ])
84:
85: AX_LIB_WIRINGPI
86:
87: AC_ENABLE_SHARED
88: AC_DISABLE_STATIC
89: LT_INIT
90: AM_INIT_AUTOMAKE
91: AC_CONFIG_FILES(Makefile src/Makefile doc/Makefile)
92: AC_PROG_CC
93: # AC_PATH_XTRA
94: AC_OUTPUT
FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>