mirror of
https://github.com/osmarks/ngircd.git
synced 2024-12-12 01:40:27 +00:00
autogen.sh: Prefere automake 1.11 over other releases
GNU automake 1.11 is the last release supporting "de-ANSI-fication" using the included ansi2knr tool. And becuase we _want_ to support old K&R platforms, we try hard to use this release of automake when available to generate our build system.
This commit is contained in:
parent
ccb0cf3170
commit
5f494ec5fe
@ -10,6 +10,11 @@
|
|||||||
|
|
||||||
ngIRCd 27
|
ngIRCd 27
|
||||||
|
|
||||||
|
- autogen.sh: Prefere automake 1.11 over other releases because this is the
|
||||||
|
last release supporting "de-ANSI-fication" using the included ansi2knr tool.
|
||||||
|
And becuase we _want_ to support old K&R platforms, we try hard to use this
|
||||||
|
release of automake when available to generate our build system.
|
||||||
|
Note: This is only relevant for you if you are building from Git sources.
|
||||||
- Autodetect support for IPv6 by default: Until now, IPv6 support was disabled
|
- Autodetect support for IPv6 by default: Until now, IPv6 support was disabled
|
||||||
by default, which seems a bit outdated in 2024. Note: You still can pass
|
by default, which seems a bit outdated in 2024. Note: You still can pass
|
||||||
"--enable-ipv6"/"--disable-ipv6" to the ./configure script to forcefully
|
"--enable-ipv6"/"--disable-ipv6" to the ./configure script to forcefully
|
||||||
|
48
autogen.sh
48
autogen.sh
@ -1,7 +1,7 @@
|
|||||||
#!/bin/sh
|
#!/bin/sh
|
||||||
#
|
#
|
||||||
# ngIRCd -- The Next Generation IRC Daemon
|
# ngIRCd -- The Next Generation IRC Daemon
|
||||||
# Copyright (c)2001-2015 Alexander Barton (alex@barton.de) and Contributors
|
# Copyright (c)2001-2024 Alexander Barton (alex@barton.de) and Contributors
|
||||||
#
|
#
|
||||||
# This program is free software; you can redistribute it and/or modify
|
# 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
|
# it under the terms of the GNU General Public License as published by
|
||||||
@ -60,16 +60,43 @@
|
|||||||
# and runs it with these arguments: "./configure --prefix=$HOME".
|
# and runs it with these arguments: "./configure --prefix=$HOME".
|
||||||
#
|
#
|
||||||
|
|
||||||
|
Check_Tool()
|
||||||
|
{
|
||||||
|
searchlist="$1"
|
||||||
|
major="$2"
|
||||||
|
minor="$3"
|
||||||
|
|
||||||
|
for name in $searchlist; do
|
||||||
|
$EXIST "${name}${major}${minor}" >/dev/null 2>&1
|
||||||
|
if [ $? -eq 0 ]; then
|
||||||
|
echo "${name}${major}${minor}"
|
||||||
|
return 0
|
||||||
|
fi
|
||||||
|
$EXIST "${name}-${major}.${minor}" >/dev/null 2>&1
|
||||||
|
if [ $? -eq 0 ]; then
|
||||||
|
echo "${name}-${major}.${minor}"
|
||||||
|
return 0
|
||||||
|
fi
|
||||||
|
done
|
||||||
|
return 1
|
||||||
|
}
|
||||||
|
|
||||||
Search()
|
Search()
|
||||||
{
|
{
|
||||||
[ $# -eq 2 ] || exit 1
|
[ $# -lt 2 ] && return 1
|
||||||
|
[ $# -gt 3 ] && return 1
|
||||||
|
|
||||||
searchlist="$1"
|
searchlist="$1"
|
||||||
major="$2"
|
major="$2"
|
||||||
|
minor_pref="$3"
|
||||||
minor=99
|
minor=99
|
||||||
|
|
||||||
[ -n "$PREFIX" ] && searchlist="${PREFIX}/$1 ${PREFIX}/bin/$1 $searchlist"
|
[ -n "$PREFIX" ] && searchlist="${PREFIX}/$1 ${PREFIX}/bin/$1 $searchlist"
|
||||||
|
|
||||||
|
if [ -n "$minor_pref" ]; then
|
||||||
|
Check_Tool "$searchlist" "$major" "$minor_pref" && return 0
|
||||||
|
fi
|
||||||
|
|
||||||
for name in $searchlist; do
|
for name in $searchlist; do
|
||||||
$EXIST "${name}" >/dev/null 2>&1
|
$EXIST "${name}" >/dev/null 2>&1
|
||||||
if [ $? -eq 0 ]; then
|
if [ $? -eq 0 ]; then
|
||||||
@ -83,18 +110,7 @@ Search()
|
|||||||
done
|
done
|
||||||
|
|
||||||
while [ $minor -ge 0 ]; do
|
while [ $minor -ge 0 ]; do
|
||||||
for name in $searchlist; do
|
Check_Tool "$searchlist" "$major" "$minor" && return 0
|
||||||
$EXIST "${name}${major}${minor}" >/dev/null 2>&1
|
|
||||||
if [ $? -eq 0 ]; then
|
|
||||||
echo "${name}${major}${minor}"
|
|
||||||
return 0
|
|
||||||
fi
|
|
||||||
$EXIST "${name}-${major}.${minor}" >/dev/null 2>&1
|
|
||||||
if [ $? -eq 0 ]; then
|
|
||||||
echo "${name}-${major}.${minor}"
|
|
||||||
return 0
|
|
||||||
fi
|
|
||||||
done
|
|
||||||
minor=$(expr $minor - 1)
|
minor=$(expr $minor - 1)
|
||||||
done
|
done
|
||||||
return 1
|
return 1
|
||||||
@ -140,11 +156,11 @@ fi
|
|||||||
# Try to detect the needed tools when no environment variable already
|
# Try to detect the needed tools when no environment variable already
|
||||||
# specifies one:
|
# specifies one:
|
||||||
echo "Searching for required tools ..."
|
echo "Searching for required tools ..."
|
||||||
[ -z "$ACLOCAL" ] && ACLOCAL=$(Search aclocal 1)
|
[ -z "$ACLOCAL" ] && ACLOCAL=$(Search aclocal 1 11)
|
||||||
[ "$VERBOSE" = "1" ] && echo " - ACLOCAL=$ACLOCAL"
|
[ "$VERBOSE" = "1" ] && echo " - ACLOCAL=$ACLOCAL"
|
||||||
[ -z "$AUTOHEADER" ] && AUTOHEADER=$(Search autoheader 2)
|
[ -z "$AUTOHEADER" ] && AUTOHEADER=$(Search autoheader 2)
|
||||||
[ "$VERBOSE" = "1" ] && echo " - AUTOHEADER=$AUTOHEADER"
|
[ "$VERBOSE" = "1" ] && echo " - AUTOHEADER=$AUTOHEADER"
|
||||||
[ -z "$AUTOMAKE" ] && AUTOMAKE=$(Search automake 1)
|
[ -z "$AUTOMAKE" ] && AUTOMAKE=$(Search automake 1 11)
|
||||||
[ "$VERBOSE" = "1" ] && echo " - AUTOMAKE=$AUTOMAKE"
|
[ "$VERBOSE" = "1" ] && echo " - AUTOMAKE=$AUTOMAKE"
|
||||||
[ -z "$AUTOCONF" ] && AUTOCONF=$(Search autoconf 2)
|
[ -z "$AUTOCONF" ] && AUTOCONF=$(Search autoconf 2)
|
||||||
[ "$VERBOSE" = "1" ] && echo " - AUTOCONF=$AUTOCONF"
|
[ "$VERBOSE" = "1" ] && echo " - AUTOCONF=$AUTOCONF"
|
||||||
|
Loading…
Reference in New Issue
Block a user