summaryrefslogtreecommitdiff
path: root/m4/ax_lua.m4
diff options
context:
space:
mode:
authorPeter Simons <simons@cryp.to>2013-02-10 14:57:14 +0100
committerPeter Simons <simons@cryp.to>2013-02-10 14:57:14 +0100
commitbee26c1d34cf5c346036436f5028551112dca84e (patch)
tree7752559b11e1dcb265d3785d0ff392c98e7456d1 /m4/ax_lua.m4
parentfcca01e501a1aa2ee6e0234099fead44ea27e651 (diff)
downloadautoconf-archive-bee26c1d34cf5c346036436f5028551112dca84e.tar.gz
AX_LUA: re-format the macro's documentation so that the HTML and Texinfo renderer can deal with it
Diffstat (limited to 'm4/ax_lua.m4')
-rw-r--r--m4/ax_lua.m4114
1 files changed, 46 insertions, 68 deletions
diff --git a/m4/ax_lua.m4 b/m4/ax_lua.m4
index d51e360..c6f5974 100644
--- a/m4/ax_lua.m4
+++ b/m4/ax_lua.m4
@@ -1,11 +1,10 @@
# ===========================================================================
-# ax_lua.m4
+# http://www.gnu.org/software/autoconf-archive/ax_lua.html
# ===========================================================================
#
# SYNOPSIS
#
-# AX_PROG_LUA[([MINIMUM-VERSION], [TOO-BIG-VERSION],
-# [ACTION-IF-FOUND], [ACTION-IF-NOT-FOUND])]
+# AX_PROG_LUA[([MINIMUM-VERSION], [TOO-BIG-VERSION], [ACTION-IF-FOUND], [ACTION-IF-NOT-FOUND])]
# AX_LUA_HEADERS[([ACTION-IF-FOUND], [ACTION-IF-NOT-FOUND])]
# AX_LUA_LIBS[([ACTION-IF-FOUND], [ACTION-IF-NOT-FOUND])]
# AX_LUA_READLINE[([ACTION-IF-FOUND], [ACTION-IF-NOT-FOUND])]
@@ -18,12 +17,11 @@
#
# Also detect Lua headers and libraries. The Lua version contained in the
# header is checked to match the Lua interpreter version exactly. When
-# searching for Lua libraries, the version number is used as a suffix. This
-# is done with the goal of supporting multiple Lua installs (5.1 and 5.2
-# side-by-side).
+# searching for Lua libraries, the version number is used as a suffix.
+# This is done with the goal of supporting multiple Lua installs (5.1 and
+# 5.2 side-by-side).
#
-#
-# *** A note on compatibility with previous versions: This file has been
+# A note on compatibility with previous versions: This file has been
# mostly rewritten for serial 18. Most developers should be able to use
# these macros without needing to modify configure.ac. Care has been taken
# to preserve each macro's behavior, but there are some differences:
@@ -39,24 +37,23 @@
# should instead specify the LUA precious variable on the command line.
# See the AX_PROG_LUA description for details.
#
-# Please read the macro descriptions for more information. ***
-#
+# Please read the macro descriptions below for more information.
#
+# This file was inspired by Andrew Dalke's and James Henstridge's
+# python.m4 and Tom Payne's, Matthieu Moy's, and Reuben Thomas's ax_lua.m4
+# (serial 17). Basically, this file is a mash-up of those two files. I
+# like to think it combines the best of the two!
#
-# AX_PROG_LUA[([MINIMUM-VERSION], [TOO-BIG-VERSION],
-# [ACTION-IF-FOUND], [ACTION-IF-NOT-FOUND])]
-# -------------------------------------------------------
-#
-# Search for the Lua interpreter, and set up important Lua paths.
-# Adds precious variable LUA, which may contain the path of the Lua
+# AX_PROG_LUA: Search for the Lua interpreter, and set up important Lua
+# paths. Adds precious variable LUA, which may contain the path of the Lua
# interpreter. If LUA is blank, the user's path is searched for an
# suitable interpreter.
#
-# If MINIMUM-VERSION is supplied, then only Lua interpreters with a version
-# number greater or equal to MINIMUM-VERSION will be accepted. If TOO-BIG-
-# VERSION is also supplied, then only Lua interpreters with a version
-# number greater or equal to MINIMUM-VERSION and less than TOO-BIG-VERSION
-# will be accepted.
+# If MINIMUM-VERSION is supplied, then only Lua interpreters with a
+# version number greater or equal to MINIMUM-VERSION will be accepted. If
+# TOO-BIG- VERSION is also supplied, then only Lua interpreters with a
+# version number greater or equal to MINIMUM-VERSION and less than
+# TOO-BIG-VERSION will be accepted.
#
# Version comparisons require the AX_COMPARE_VERSION macro, which is
# provided by ax_compare_version.m4 from the Autoconf Archive.
@@ -82,8 +79,8 @@
# luadir Default: $prefix/share/lua/$LUA_VERSION
# luaexecdir Default: $exec_prefix/lib/lua/$LUA_VERSION
#
-# These directories can be used by Automake as install destinations.
-# The variable name minus 'dir' needs to be used as a prefix to the
+# These directories can be used by Automake as install destinations. The
+# variable name minus 'dir' needs to be used as a prefix to the
# appropriate Automake primary, e.g. lua_SCRIPS or luaexec_LIBRARIES.
#
# If an acceptable Lua interpreter is found, then ACTION-IF-FOUND is
@@ -91,23 +88,20 @@
# FOUND is blank, then it will default to printing an error. To prevent
# the default behavior, give ':' as an action.
#
+# AX_LUA_HEADERS: Search for Lua headers. Requires that AX_PROG_LUA be
+# expanded before this macro. Adds precious variable LUA_INCLUDE, which
+# may contain Lua specific include flags, e.g. -I/usr/include/lua5.1. If
+# LUA_INCLUDE is blank, then this macro will attempt to find suitable
+# flags.
#
-# AX_LUA_HEADERS[([ACTION-IF-FOUND], [ACTION-IF-NOT-FOUND])]
-# ----------------------------------------------------------
-#
-# Search for Lua headers. Requires that AX_PROG_LUA be expanded before this
-# macro. Adds precious variable LUA_INCLUDE, which may contain Lua specific
-# include flags, e.g. -I/usr/include/lua5.1. If LUA_INCLUDE is blank, then
-# this macro will attempt to find suitable flags.
-#
-# LUA_INCLUDE can be used by Automake to compile Lua modules or executables
-# with embedded interpreters. The *_CPPFLAGS variables should be used for
-# this purpose, e.g. myprog_CPPFLAGS = $(LUA_INCLUDE).
+# LUA_INCLUDE can be used by Automake to compile Lua modules or
+# executables with embedded interpreters. The *_CPPFLAGS variables should
+# be used for this purpose, e.g. myprog_CPPFLAGS = $(LUA_INCLUDE).
#
# This macro searches for the header lua.h (and others). The search is
# performed with a combination of CPPFLAGS, CPATH, etc, and LUA_INCLUDE.
-# If the search is unsuccessful, then some common directories are tried. If
-# the headers are then found, then LUA_INCLUDE is set accordingly.
+# If the search is unsuccessful, then some common directories are tried.
+# If the headers are then found, then LUA_INCLUDE is set accordingly.
#
# The paths automatically searched are:
#
@@ -125,18 +119,14 @@
# version numbers are not accepted.
#
# If headers are found, then ACTION-IF-FOUND is performed, otherwise
-# ACTION-IF-NOT-FOUND is performed. If ACTION-IF-NOT-FOUND is blank,
-# then it will default to printing an error. To prevent the default
-# behavior, set the action to ':'.
-#
-#
-# AX_LUA_LIBS[([ACTION-IF-FOUND], [ACTION-IF-NOT-FOUND])]
-# -------------------------------------------------------
+# ACTION-IF-NOT-FOUND is performed. If ACTION-IF-NOT-FOUND is blank, then
+# it will default to printing an error. To prevent the default behavior,
+# set the action to ':'.
#
-# Search for Lua libraries. Requires that AX_PROG_LUA be expanded before
-# this macro. Adds precious variable LUA_LIB, which may contain Lua specific
-# linker flags, e.g. -llua5.1. If LUA_LIB is blank, then this macro will
-# attempt to find suitable flags.
+# AX_LUA_LIBS: Search for Lua libraries. Requires that AX_PROG_LUA be
+# expanded before this macro. Adds precious variable LUA_LIB, which may
+# contain Lua specific linker flags, e.g. -llua5.1. If LUA_LIB is blank,
+# then this macro will attempt to find suitable flags.
#
# LUA_LIB can be used by Automake to link Lua modules or executables with
# embedded interpreters. The *_LIBADD and *_LDADD variables should be used
@@ -150,25 +140,21 @@
# flags will be added to LUA_LIB.
#
# If libraries are found, then ACTION-IF-FOUND is performed, otherwise
-# ACTION-IF-NOT-FOUND is performed. If ACTION-IF-NOT-FOUND is blank,
-# then it will default to printing an error. To prevent the default
-# behavior, set the action to ':'.
-#
-#
-# AX_LUA_READLINE[([ACTION-IF-FOUND], [ACTION-IF-NOT-FOUND])]
-# -----------------------------------------------------------
+# ACTION-IF-NOT-FOUND is performed. If ACTION-IF-NOT-FOUND is blank, then
+# it will default to printing an error. To prevent the default behavior,
+# set the action to ':'.
#
-# Search for readline headers and libraries. Requires the AX_LIB_READLINE
-# macro, which is provided by ax_lib_readline.m4 from the Autoconf Archive.
+# AX_LUA_READLINE: Search for readline headers and libraries. Requires the
+# AX_LIB_READLINE macro, which is provided by ax_lib_readline.m4 from the
+# Autoconf Archive.
#
# If a readline compatible library is found, then ACTION-IF-FOUND is
# performed, otherwise ACTION-IF-NOT-FOUND is performed.
#
-#
# LICENSE
#
-# Copyright (C) 2013 Tim Perkins <tprk77@gmail.com>
-# Copyright (C) 2013 Reuben Thomas <rrt@sc3d.org>
+# Copyright (c) 2013 Tim Perkins <tprk77@gmail.com>
+# Copyright (c) 2013 Reuben Thomas <rrt@sc3d.org>
#
# This program is free software: you can redistribute it and/or modify it
# under the terms of the GNU General Public License as published by the
@@ -195,16 +181,8 @@
# Macro released by the Autoconf Archive. When you make and distribute a
# modified version of the Autoconf Macro, you may extend this special
# exception to the GPL to apply to your modified version as well.
-#
-# THANKS
-#
-# This file was inspired by Andrew Dalke's and James Henstridge's python.m4
-# and Tom Payne's, Matthieu Moy's, and Reuben Thomas's ax_lua.m4 (serial
-# 17). Basically, this file is a mash-up of those two files. I like to
-# think it combines the best of the two!
-
-#serial 19
+#serial 20
dnl =========================================================================
dnl AX_PROG_LUA([MINIMUM-VERSION], [TOO-BIG-VERSION],