head 1.1;
branch 1.1.1;
access;
symbols
netbsd-11-0-RC7:1.1.1.1
libevent-2-1-13-stable:1.1.1.2
netbsd-11-0-RC6:1.1.1.1
netbsd-11-0-RC5:1.1.1.1
netbsd-11-0-RC4:1.1.1.1
netbsd-11-0-RC3:1.1.1.1
netbsd-11-0-RC2:1.1.1.1
netbsd-11-0-RC1:1.1.1.1
perseant-exfatfs-base-20250801:1.1.1.1
netbsd-11:1.1.1.1.0.10
netbsd-11-base:1.1.1.1
netbsd-10-1-RELEASE:1.1.1.1
perseant-exfatfs-base-20240630:1.1.1.1
perseant-exfatfs:1.1.1.1.0.8
perseant-exfatfs-base:1.1.1.1
netbsd-10-0-RELEASE:1.1.1.1
netbsd-10-0-RC6:1.1.1.1
netbsd-10-0-RC5:1.1.1.1
netbsd-10-0-RC4:1.1.1.1
netbsd-10-0-RC3:1.1.1.1
netbsd-10-0-RC2:1.1.1.1
netbsd-10-0-RC1:1.1.1.1
netbsd-10:1.1.1.1.0.6
netbsd-10-base:1.1.1.1
cjep_sun2x-base1:1.1.1.1
cjep_sun2x:1.1.1.1.0.4
cjep_sun2x-base:1.1.1.1
cjep_staticlib_x-base1:1.1.1.1
cjep_staticlib_x:1.1.1.1.0.2
cjep_staticlib_x-base:1.1.1.1
libevent-2-1-12-stable:1.1.1.1
LIBEVENT:1.1.1;
locks; strict;
comment @# @;
1.1
date 2021.04.07.02.43.15; author christos; state Exp;
branches
1.1.1.1;
next ;
commitid JESDViJ2Ehst2jOC;
1.1.1.1
date 2021.04.07.02.43.15; author christos; state Exp;
branches;
next 1.1.1.2;
commitid JESDViJ2Ehst2jOC;
1.1.1.2
date 2026.07.08.13.23.36; author christos; state Exp;
branches;
next ;
commitid Di8fqKN0qA9TVQMG;
desc
@@
1.1
log
@Initial revision
@
text
@#! /bin/sh
# Configuration validation subroutine script.
# Copyright 1992-2020 Free Software Foundation, Inc.
timestamp='2020-01-01'
# This file is free software; you can redistribute it and/or modify it
# under the terms of the GNU General Public License as published by
# the Free Software Foundation; either version 3 of the License, or
# (at your option) any later version.
#
# This program is distributed in the hope that it will be useful, but
# WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
# General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program; if not, see .
#
# As a special exception to the GNU General Public License, if you
# distribute this file as part of a program that contains a
# configuration script generated by Autoconf, you may include it under
# the same distribution terms that you use for the rest of that
# program. This Exception is an additional permission under section 7
# of the GNU General Public License, version 3 ("GPLv3").
# Please send patches to .
#
# Configuration subroutine to validate and canonicalize a configuration type.
# Supply the specified configuration type as an argument.
# If it is invalid, we print an error message on stderr and exit with code 1.
# Otherwise, we print the canonical config type on stdout and succeed.
# You can get the latest version of this script from:
# https://git.savannah.gnu.org/gitweb/?p=config.git;a=blob_plain;f=config.sub
# This file is supposed to be the same for all GNU packages
# and recognize all the CPU types, system types and aliases
# that are meaningful with *any* GNU software.
# Each package is responsible for reporting which valid configurations
# it does not support. The user should be able to distinguish
# a failure to support a valid configuration from a meaningless
# configuration.
# The goal of this file is to map all the various variations of a given
# machine specification into a single specification in the form:
# CPU_TYPE-MANUFACTURER-OPERATING_SYSTEM
# or in some cases, the newer four-part form:
# CPU_TYPE-MANUFACTURER-KERNEL-OPERATING_SYSTEM
# It is wrong to echo any other type of specification.
me=`echo "$0" | sed -e 's,.*/,,'`
usage="\
Usage: $0 [OPTION] CPU-MFR-OPSYS or ALIAS
Canonicalize a configuration name.
Options:
-h, --help print this help, then exit
-t, --time-stamp print date of last modification, then exit
-v, --version print version number, then exit
Report bugs and patches to ."
version="\
GNU config.sub ($timestamp)
Copyright 1992-2020 Free Software Foundation, Inc.
This is free software; see the source for copying conditions. There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE."
help="
Try \`$me --help' for more information."
# Parse command line
while test $# -gt 0 ; do
case $1 in
--time-stamp | --time* | -t )
echo "$timestamp" ; exit ;;
--version | -v )
echo "$version" ; exit ;;
--help | --h* | -h )
echo "$usage"; exit ;;
-- ) # Stop option processing
shift; break ;;
- ) # Use stdin as input.
break ;;
-* )
echo "$me: invalid option $1$help" >&2
exit 1 ;;
*local*)
# First pass through any local machine types.
echo "$1"
exit ;;
* )
break ;;
esac
done
case $# in
0) echo "$me: missing argument$help" >&2
exit 1;;
1) ;;
*) echo "$me: too many arguments$help" >&2
exit 1;;
esac
# Split fields of configuration type
# shellcheck disable=SC2162
IFS="-" read field1 field2 field3 field4 <&2
exit 1
;;
*-*-*-*)
basic_machine=$field1-$field2
os=$field3-$field4
;;
*-*-*)
# Ambiguous whether COMPANY is present, or skipped and KERNEL-OS is two
# parts
maybe_os=$field2-$field3
case $maybe_os in
nto-qnx* | linux-gnu* | linux-android* | linux-dietlibc \
| linux-newlib* | linux-musl* | linux-uclibc* | uclinux-uclibc* \
| uclinux-gnu* | kfreebsd*-gnu* | knetbsd*-gnu* | netbsd*-gnu* \
| netbsd*-eabi* | kopensolaris*-gnu* | cloudabi*-eabi* \
| storm-chaos* | os2-emx* | rtmk-nova*)
basic_machine=$field1
os=$maybe_os
;;
android-linux)
basic_machine=$field1-unknown
os=linux-android
;;
*)
basic_machine=$field1-$field2
os=$field3
;;
esac
;;
*-*)
# A lone config we happen to match not fitting any pattern
case $field1-$field2 in
decstation-3100)
basic_machine=mips-dec
os=
;;
*-*)
# Second component is usually, but not always the OS
case $field2 in
# Prevent following clause from handling this valid os
sun*os*)
basic_machine=$field1
os=$field2
;;
# Manufacturers
dec* | mips* | sequent* | encore* | pc533* | sgi* | sony* \
| att* | 7300* | 3300* | delta* | motorola* | sun[234]* \
| unicom* | ibm* | next | hp | isi* | apollo | altos* \
| convergent* | ncr* | news | 32* | 3600* | 3100* \
| hitachi* | c[123]* | convex* | sun | crds | omron* | dg \
| ultra | tti* | harris | dolphin | highlevel | gould \
| cbm | ns | masscomp | apple | axis | knuth | cray \
| microblaze* | sim | cisco \
| oki | wec | wrs | winbond)
basic_machine=$field1-$field2
os=
;;
*)
basic_machine=$field1
os=$field2
;;
esac
;;
esac
;;
*)
# Convert single-component short-hands not valid as part of
# multi-component configurations.
case $field1 in
386bsd)
basic_machine=i386-pc
os=bsd
;;
a29khif)
basic_machine=a29k-amd
os=udi
;;
adobe68k)
basic_machine=m68010-adobe
os=scout
;;
alliant)
basic_machine=fx80-alliant
os=
;;
altos | altos3068)
basic_machine=m68k-altos
os=
;;
am29k)
basic_machine=a29k-none
os=bsd
;;
amdahl)
basic_machine=580-amdahl
os=sysv
;;
amiga)
basic_machine=m68k-unknown
os=
;;
amigaos | amigados)
basic_machine=m68k-unknown
os=amigaos
;;
amigaunix | amix)
basic_machine=m68k-unknown
os=sysv4
;;
apollo68)
basic_machine=m68k-apollo
os=sysv
;;
apollo68bsd)
basic_machine=m68k-apollo
os=bsd
;;
aros)
basic_machine=i386-pc
os=aros
;;
aux)
basic_machine=m68k-apple
os=aux
;;
balance)
basic_machine=ns32k-sequent
os=dynix
;;
blackfin)
basic_machine=bfin-unknown
os=linux
;;
cegcc)
basic_machine=arm-unknown
os=cegcc
;;
convex-c1)
basic_machine=c1-convex
os=bsd
;;
convex-c2)
basic_machine=c2-convex
os=bsd
;;
convex-c32)
basic_machine=c32-convex
os=bsd
;;
convex-c34)
basic_machine=c34-convex
os=bsd
;;
convex-c38)
basic_machine=c38-convex
os=bsd
;;
cray)
basic_machine=j90-cray
os=unicos
;;
crds | unos)
basic_machine=m68k-crds
os=
;;
da30)
basic_machine=m68k-da30
os=
;;
decstation | pmax | pmin | dec3100 | decstatn)
basic_machine=mips-dec
os=
;;
delta88)
basic_machine=m88k-motorola
os=sysv3
;;
dicos)
basic_machine=i686-pc
os=dicos
;;
djgpp)
basic_machine=i586-pc
os=msdosdjgpp
;;
ebmon29k)
basic_machine=a29k-amd
os=ebmon
;;
es1800 | OSE68k | ose68k | ose | OSE)
basic_machine=m68k-ericsson
os=ose
;;
gmicro)
basic_machine=tron-gmicro
os=sysv
;;
go32)
basic_machine=i386-pc
os=go32
;;
h8300hms)
basic_machine=h8300-hitachi
os=hms
;;
h8300xray)
basic_machine=h8300-hitachi
os=xray
;;
h8500hms)
basic_machine=h8500-hitachi
os=hms
;;
harris)
basic_machine=m88k-harris
os=sysv3
;;
hp300 | hp300hpux)
basic_machine=m68k-hp
os=hpux
;;
hp300bsd)
basic_machine=m68k-hp
os=bsd
;;
hppaosf)
basic_machine=hppa1.1-hp
os=osf
;;
hppro)
basic_machine=hppa1.1-hp
os=proelf
;;
i386mach)
basic_machine=i386-mach
os=mach
;;
isi68 | isi)
basic_machine=m68k-isi
os=sysv
;;
m68knommu)
basic_machine=m68k-unknown
os=linux
;;
magnum | m3230)
basic_machine=mips-mips
os=sysv
;;
merlin)
basic_machine=ns32k-utek
os=sysv
;;
mingw64)
basic_machine=x86_64-pc
os=mingw64
;;
mingw32)
basic_machine=i686-pc
os=mingw32
;;
mingw32ce)
basic_machine=arm-unknown
os=mingw32ce
;;
monitor)
basic_machine=m68k-rom68k
os=coff
;;
morphos)
basic_machine=powerpc-unknown
os=morphos
;;
moxiebox)
basic_machine=moxie-unknown
os=moxiebox
;;
msdos)
basic_machine=i386-pc
os=msdos
;;
msys)
basic_machine=i686-pc
os=msys
;;
mvs)
basic_machine=i370-ibm
os=mvs
;;
nacl)
basic_machine=le32-unknown
os=nacl
;;
ncr3000)
basic_machine=i486-ncr
os=sysv4
;;
netbsd386)
basic_machine=i386-pc
os=netbsd
;;
netwinder)
basic_machine=armv4l-rebel
os=linux
;;
news | news700 | news800 | news900)
basic_machine=m68k-sony
os=newsos
;;
news1000)
basic_machine=m68030-sony
os=newsos
;;
necv70)
basic_machine=v70-nec
os=sysv
;;
nh3000)
basic_machine=m68k-harris
os=cxux
;;
nh[45]000)
basic_machine=m88k-harris
os=cxux
;;
nindy960)
basic_machine=i960-intel
os=nindy
;;
mon960)
basic_machine=i960-intel
os=mon960
;;
nonstopux)
basic_machine=mips-compaq
os=nonstopux
;;
os400)
basic_machine=powerpc-ibm
os=os400
;;
OSE68000 | ose68000)
basic_machine=m68000-ericsson
os=ose
;;
os68k)
basic_machine=m68k-none
os=os68k
;;
paragon)
basic_machine=i860-intel
os=osf
;;
parisc)
basic_machine=hppa-unknown
os=linux
;;
pw32)
basic_machine=i586-unknown
os=pw32
;;
rdos | rdos64)
basic_machine=x86_64-pc
os=rdos
;;
rdos32)
basic_machine=i386-pc
os=rdos
;;
rom68k)
basic_machine=m68k-rom68k
os=coff
;;
sa29200)
basic_machine=a29k-amd
os=udi
;;
sei)
basic_machine=mips-sei
os=seiux
;;
sequent)
basic_machine=i386-sequent
os=
;;
sps7)
basic_machine=m68k-bull
os=sysv2
;;
st2000)
basic_machine=m68k-tandem
os=
;;
stratus)
basic_machine=i860-stratus
os=sysv4
;;
sun2)
basic_machine=m68000-sun
os=
;;
sun2os3)
basic_machine=m68000-sun
os=sunos3
;;
sun2os4)
basic_machine=m68000-sun
os=sunos4
;;
sun3)
basic_machine=m68k-sun
os=
;;
sun3os3)
basic_machine=m68k-sun
os=sunos3
;;
sun3os4)
basic_machine=m68k-sun
os=sunos4
;;
sun4)
basic_machine=sparc-sun
os=
;;
sun4os3)
basic_machine=sparc-sun
os=sunos3
;;
sun4os4)
basic_machine=sparc-sun
os=sunos4
;;
sun4sol2)
basic_machine=sparc-sun
os=solaris2
;;
sun386 | sun386i | roadrunner)
basic_machine=i386-sun
os=
;;
sv1)
basic_machine=sv1-cray
os=unicos
;;
symmetry)
basic_machine=i386-sequent
os=dynix
;;
t3e)
basic_machine=alphaev5-cray
os=unicos
;;
t90)
basic_machine=t90-cray
os=unicos
;;
toad1)
basic_machine=pdp10-xkl
os=tops20
;;
tpf)
basic_machine=s390x-ibm
os=tpf
;;
udi29k)
basic_machine=a29k-amd
os=udi
;;
ultra3)
basic_machine=a29k-nyu
os=sym1
;;
v810 | necv810)
basic_machine=v810-nec
os=none
;;
vaxv)
basic_machine=vax-dec
os=sysv
;;
vms)
basic_machine=vax-dec
os=vms
;;
vsta)
basic_machine=i386-pc
os=vsta
;;
vxworks960)
basic_machine=i960-wrs
os=vxworks
;;
vxworks68)
basic_machine=m68k-wrs
os=vxworks
;;
vxworks29k)
basic_machine=a29k-wrs
os=vxworks
;;
xbox)
basic_machine=i686-pc
os=mingw32
;;
ymp)
basic_machine=ymp-cray
os=unicos
;;
*)
basic_machine=$1
os=
;;
esac
;;
esac
# Decode 1-component or ad-hoc basic machines
case $basic_machine in
# Here we handle the default manufacturer of certain CPU types. It is in
# some cases the only manufacturer, in others, it is the most popular.
w89k)
cpu=hppa1.1
vendor=winbond
;;
op50n)
cpu=hppa1.1
vendor=oki
;;
op60c)
cpu=hppa1.1
vendor=oki
;;
ibm*)
cpu=i370
vendor=ibm
;;
orion105)
cpu=clipper
vendor=highlevel
;;
mac | mpw | mac-mpw)
cpu=m68k
vendor=apple
;;
pmac | pmac-mpw)
cpu=powerpc
vendor=apple
;;
# Recognize the various machine names and aliases which stand
# for a CPU type and a company and sometimes even an OS.
3b1 | 7300 | 7300-att | att-7300 | pc7300 | safari | unixpc)
cpu=m68000
vendor=att
;;
3b*)
cpu=we32k
vendor=att
;;
bluegene*)
cpu=powerpc
vendor=ibm
os=cnk
;;
decsystem10* | dec10*)
cpu=pdp10
vendor=dec
os=tops10
;;
decsystem20* | dec20*)
cpu=pdp10
vendor=dec
os=tops20
;;
delta | 3300 | motorola-3300 | motorola-delta \
| 3300-motorola | delta-motorola)
cpu=m68k
vendor=motorola
;;
dpx2*)
cpu=m68k
vendor=bull
os=sysv3
;;
encore | umax | mmax)
cpu=ns32k
vendor=encore
;;
elxsi)
cpu=elxsi
vendor=elxsi
os=${os:-bsd}
;;
fx2800)
cpu=i860
vendor=alliant
;;
genix)
cpu=ns32k
vendor=ns
;;
h3050r* | hiux*)
cpu=hppa1.1
vendor=hitachi
os=hiuxwe2
;;
hp3k9[0-9][0-9] | hp9[0-9][0-9])
cpu=hppa1.0
vendor=hp
;;
hp9k2[0-9][0-9] | hp9k31[0-9])
cpu=m68000
vendor=hp
;;
hp9k3[2-9][0-9])
cpu=m68k
vendor=hp
;;
hp9k6[0-9][0-9] | hp6[0-9][0-9])
cpu=hppa1.0
vendor=hp
;;
hp9k7[0-79][0-9] | hp7[0-79][0-9])
cpu=hppa1.1
vendor=hp
;;
hp9k78[0-9] | hp78[0-9])
# FIXME: really hppa2.0-hp
cpu=hppa1.1
vendor=hp
;;
hp9k8[67]1 | hp8[67]1 | hp9k80[24] | hp80[24] | hp9k8[78]9 | hp8[78]9 | hp9k893 | hp893)
# FIXME: really hppa2.0-hp
cpu=hppa1.1
vendor=hp
;;
hp9k8[0-9][13679] | hp8[0-9][13679])
cpu=hppa1.1
vendor=hp
;;
hp9k8[0-9][0-9] | hp8[0-9][0-9])
cpu=hppa1.0
vendor=hp
;;
i*86v32)
cpu=`echo "$1" | sed -e 's/86.*/86/'`
vendor=pc
os=sysv32
;;
i*86v4*)
cpu=`echo "$1" | sed -e 's/86.*/86/'`
vendor=pc
os=sysv4
;;
i*86v)
cpu=`echo "$1" | sed -e 's/86.*/86/'`
vendor=pc
os=sysv
;;
i*86sol2)
cpu=`echo "$1" | sed -e 's/86.*/86/'`
vendor=pc
os=solaris2
;;
j90 | j90-cray)
cpu=j90
vendor=cray
os=${os:-unicos}
;;
iris | iris4d)
cpu=mips
vendor=sgi
case $os in
irix*)
;;
*)
os=irix4
;;
esac
;;
miniframe)
cpu=m68000
vendor=convergent
;;
*mint | mint[0-9]* | *MiNT | *MiNT[0-9]*)
cpu=m68k
vendor=atari
os=mint
;;
news-3600 | risc-news)
cpu=mips
vendor=sony
os=newsos
;;
next | m*-next)
cpu=m68k
vendor=next
case $os in
openstep*)
;;
nextstep*)
;;
ns2*)
os=nextstep2
;;
*)
os=nextstep3
;;
esac
;;
np1)
cpu=np1
vendor=gould
;;
op50n-* | op60c-*)
cpu=hppa1.1
vendor=oki
os=proelf
;;
pa-hitachi)
cpu=hppa1.1
vendor=hitachi
os=hiuxwe2
;;
pbd)
cpu=sparc
vendor=tti
;;
pbb)
cpu=m68k
vendor=tti
;;
pc532)
cpu=ns32k
vendor=pc532
;;
pn)
cpu=pn
vendor=gould
;;
power)
cpu=power
vendor=ibm
;;
ps2)
cpu=i386
vendor=ibm
;;
rm[46]00)
cpu=mips
vendor=siemens
;;
rtpc | rtpc-*)
cpu=romp
vendor=ibm
;;
sde)
cpu=mipsisa32
vendor=sde
os=${os:-elf}
;;
simso-wrs)
cpu=sparclite
vendor=wrs
os=vxworks
;;
tower | tower-32)
cpu=m68k
vendor=ncr
;;
vpp*|vx|vx-*)
cpu=f301
vendor=fujitsu
;;
w65)
cpu=w65
vendor=wdc
;;
w89k-*)
cpu=hppa1.1
vendor=winbond
os=proelf
;;
none)
cpu=none
vendor=none
;;
leon|leon[3-9])
cpu=sparc
vendor=$basic_machine
;;
leon-*|leon[3-9]-*)
cpu=sparc
vendor=`echo "$basic_machine" | sed 's/-.*//'`
;;
*-*)
# shellcheck disable=SC2162
IFS="-" read cpu vendor <&2
exit 1
;;
esac
;;
esac
# Here we canonicalize certain aliases for manufacturers.
case $vendor in
digital*)
vendor=dec
;;
commodore*)
vendor=cbm
;;
*)
;;
esac
# Decode manufacturer-specific aliases for certain operating systems.
if [ x$os != x ]
then
case $os in
# First match some system type aliases that might get confused
# with valid system types.
# solaris* is a basic system type, with this one exception.
auroraux)
os=auroraux
;;
bluegene*)
os=cnk
;;
solaris1 | solaris1.*)
os=`echo $os | sed -e 's|solaris1|sunos4|'`
;;
solaris)
os=solaris2
;;
unixware*)
os=sysv4.2uw
;;
gnu/linux*)
os=`echo $os | sed -e 's|gnu/linux|linux-gnu|'`
;;
# es1800 is here to avoid being matched by es* (a different OS)
es1800*)
os=ose
;;
# Some version numbers need modification
chorusos*)
os=chorusos
;;
isc)
os=isc2.2
;;
sco6)
os=sco5v6
;;
sco5)
os=sco3.2v5
;;
sco4)
os=sco3.2v4
;;
sco3.2.[4-9]*)
os=`echo $os | sed -e 's/sco3.2./sco3.2v/'`
;;
sco3.2v[4-9]* | sco5v6*)
# Don't forget version if it is 3.2v4 or newer.
;;
scout)
# Don't match below
;;
sco*)
os=sco3.2v2
;;
psos*)
os=psos
;;
# Now accept the basic system types.
# The portable systems comes first.
# Each alternative MUST end in a * to match a version number.
# sysv* is not here because it comes later, after sysvr4.
gnu* | bsd* | mach* | minix* | genix* | ultrix* | irix* \
| *vms* | esix* | aix* | cnk* | sunos | sunos[34]*\
| hpux* | unos* | osf* | luna* | dgux* | auroraux* | solaris* \
| sym* | kopensolaris* | plan9* \
| amigaos* | amigados* | msdos* | newsos* | unicos* | aof* \
| aos* | aros* | cloudabi* | sortix* | twizzler* \
| nindy* | vxsim* | vxworks* | ebmon* | hms* | mvs* \
| clix* | riscos* | uniplus* | iris* | isc* | rtu* | xenix* \
| knetbsd* | mirbsd* | netbsd* \
| bitrig* | openbsd* | solidbsd* | libertybsd* | os108* \
| ekkobsd* | kfreebsd* | freebsd* | riscix* | lynxos* \
| bosx* | nextstep* | cxux* | aout* | elf* | oabi* \
| ptx* | coff* | ecoff* | winnt* | domain* | vsta* \
| udi* | eabi* | lites* | ieee* | go32* | aux* | hcos* \
| chorusrdb* | cegcc* | glidix* \
| cygwin* | msys* | pe* | moss* | proelf* | rtems* \
| midipix* | mingw32* | mingw64* | linux-gnu* | linux-android* \
| linux-newlib* | linux-musl* | linux-uclibc* \
| uxpv* | beos* | mpeix* | udk* | moxiebox* \
| interix* | uwin* | mks* | rhapsody* | darwin* \
| openstep* | oskit* | conix* | pw32* | nonstopux* \
| storm-chaos* | tops10* | tenex* | tops20* | its* \
| os2* | vos* | palmos* | uclinux* | nucleus* \
| morphos* | superux* | rtmk* | windiss* \
| powermax* | dnix* | nx6 | nx7 | sei* | dragonfly* \
| skyos* | haiku* | rdos* | toppers* | drops* | es* \
| onefs* | tirtos* | phoenix* | fuchsia* | redox* | bme* \
| midnightbsd* | amdhsa* | unleashed* | emscripten* | wasi* \
| nsk* | powerunix)
# Remember, each alternative MUST END IN *, to match a version number.
;;
qnx*)
case $cpu in
x86 | i*86)
;;
*)
os=nto-$os
;;
esac
;;
hiux*)
os=hiuxwe2
;;
nto-qnx*)
;;
nto*)
os=`echo $os | sed -e 's|nto|nto-qnx|'`
;;
sim | xray | os68k* | v88r* \
| windows* | osx | abug | netware* | os9* \
| macos* | mpw* | magic* | mmixware* | mon960* | lnews*)
;;
linux-dietlibc)
os=linux-dietlibc
;;
linux*)
os=`echo $os | sed -e 's|linux|linux-gnu|'`
;;
lynx*178)
os=lynxos178
;;
lynx*5)
os=lynxos5
;;
lynx*)
os=lynxos
;;
mac*)
os=`echo "$os" | sed -e 's|mac|macos|'`
;;
opened*)
os=openedition
;;
os400*)
os=os400
;;
sunos5*)
os=`echo "$os" | sed -e 's|sunos5|solaris2|'`
;;
sunos6*)
os=`echo "$os" | sed -e 's|sunos6|solaris3|'`
;;
wince*)
os=wince
;;
utek*)
os=bsd
;;
dynix*)
os=bsd
;;
acis*)
os=aos
;;
atheos*)
os=atheos
;;
syllable*)
os=syllable
;;
386bsd)
os=bsd
;;
ctix* | uts*)
os=sysv
;;
nova*)
os=rtmk-nova
;;
ns2)
os=nextstep2
;;
# Preserve the version number of sinix5.
sinix5.*)
os=`echo $os | sed -e 's|sinix|sysv|'`
;;
sinix*)
os=sysv4
;;
tpf*)
os=tpf
;;
triton*)
os=sysv3
;;
oss*)
os=sysv3
;;
svr4*)
os=sysv4
;;
svr3)
os=sysv3
;;
sysvr4)
os=sysv4
;;
# This must come after sysvr4.
sysv*)
;;
ose*)
os=ose
;;
*mint | mint[0-9]* | *MiNT | MiNT[0-9]*)
os=mint
;;
zvmoe)
os=zvmoe
;;
dicos*)
os=dicos
;;
pikeos*)
# Until real need of OS specific support for
# particular features comes up, bare metal
# configurations are quite functional.
case $cpu in
arm*)
os=eabi
;;
*)
os=elf
;;
esac
;;
nacl*)
;;
ios)
;;
none)
;;
*-eabi)
;;
*)
echo Invalid configuration \`"$1"\': system \`"$os"\' not recognized 1>&2
exit 1
;;
esac
else
# Here we handle the default operating systems that come with various machines.
# The value should be what the vendor currently ships out the door with their
# machine or put another way, the most popular os provided with the machine.
# Note that if you're going to try to match "-MANUFACTURER" here (say,
# "-sun"), then you have to tell the case statement up towards the top
# that MANUFACTURER isn't an operating system. Otherwise, code above
# will signal an error saying that MANUFACTURER isn't an operating
# system, and we'll never get to this point.
case $cpu-$vendor in
score-*)
os=elf
;;
spu-*)
os=elf
;;
*-acorn)
os=riscix1.2
;;
arm*-rebel)
os=linux
;;
arm*-semi)
os=aout
;;
c4x-* | tic4x-*)
os=coff
;;
c8051-*)
os=elf
;;
clipper-intergraph)
os=clix
;;
hexagon-*)
os=elf
;;
tic54x-*)
os=coff
;;
tic55x-*)
os=coff
;;
tic6x-*)
os=coff
;;
# This must come before the *-dec entry.
pdp10-*)
os=tops20
;;
pdp11-*)
os=none
;;
*-dec | vax-*)
os=ultrix4.2
;;
m68*-apollo)
os=domain
;;
i386-sun)
os=sunos4.0.2
;;
m68000-sun)
os=sunos3
;;
m68*-cisco)
os=aout
;;
mep-*)
os=elf
;;
mips*-cisco)
os=elf
;;
mips*-*)
os=elf
;;
or32-*)
os=coff
;;
*-tti) # must be before sparc entry or we get the wrong os.
os=sysv3
;;
sparc-* | *-sun)
os=sunos4.1.1
;;
pru-*)
os=elf
;;
*-be)
os=beos
;;
*-ibm)
os=aix
;;
*-knuth)
os=mmixware
;;
*-wec)
os=proelf
;;
*-winbond)
os=proelf
;;
*-oki)
os=proelf
;;
*-hp)
os=hpux
;;
*-hitachi)
os=hiux
;;
i860-* | *-att | *-ncr | *-altos | *-motorola | *-convergent)
os=sysv
;;
*-cbm)
os=amigaos
;;
*-dg)
os=dgux
;;
*-dolphin)
os=sysv3
;;
m68k-ccur)
os=rtu
;;
m88k-omron*)
os=luna
;;
*-next)
os=nextstep
;;
*-sequent)
os=ptx
;;
*-crds)
os=unos
;;
*-ns)
os=genix
;;
i370-*)
os=mvs
;;
*-gould)
os=sysv
;;
*-highlevel)
os=bsd
;;
*-encore)
os=bsd
;;
*-sgi)
os=irix
;;
*-siemens)
os=sysv4
;;
*-masscomp)
os=rtu
;;
f30[01]-fujitsu | f700-fujitsu)
os=uxpv
;;
*-rom68k)
os=coff
;;
*-*bug)
os=coff
;;
*-apple)
os=macos
;;
*-atari*)
os=mint
;;
*-wrs)
os=vxworks
;;
*)
os=none
;;
esac
fi
# Here we handle the case where we know the os, and the CPU type, but not the
# manufacturer. We pick the logical manufacturer.
case $vendor in
unknown)
case $os in
riscix*)
vendor=acorn
;;
sunos*)
vendor=sun
;;
cnk*|-aix*)
vendor=ibm
;;
beos*)
vendor=be
;;
hpux*)
vendor=hp
;;
mpeix*)
vendor=hp
;;
hiux*)
vendor=hitachi
;;
unos*)
vendor=crds
;;
dgux*)
vendor=dg
;;
luna*)
vendor=omron
;;
genix*)
vendor=ns
;;
clix*)
vendor=intergraph
;;
mvs* | opened*)
vendor=ibm
;;
os400*)
vendor=ibm
;;
ptx*)
vendor=sequent
;;
tpf*)
vendor=ibm
;;
vxsim* | vxworks* | windiss*)
vendor=wrs
;;
aux*)
vendor=apple
;;
hms*)
vendor=hitachi
;;
mpw* | macos*)
vendor=apple
;;
*mint | mint[0-9]* | *MiNT | MiNT[0-9]*)
vendor=atari
;;
vos*)
vendor=stratus
;;
esac
;;
esac
echo "$cpu-$vendor-$os"
exit
# Local variables:
# eval: (add-hook 'before-save-hook 'time-stamp)
# time-stamp-start: "timestamp='"
# time-stamp-format: "%:y-%02m-%02d"
# time-stamp-end: "'"
# End:
@
1.1.1.1
log
@Changes in version 2.1.12-stable (05 Jul 2020)
This release contains mostly bug fixes (I decided not to port some features
that can be ported even without ABI breakage, if you cannot find feature that
you are interested in, please give us a note!)
Since 2.1.12 libevent will use github actions as main CI, since
it recommends itself better then travis/appveyor (and had been removed from
upstream).
Look carefully at "slightly touches the behaviour" section.
Below you will find some of changes (this list has been cleaned up from the
patches that touches only tests and similar):
CI:
o Backport github actions to 2.1 (be3acd7c Azat Khuzhin)
o Merge branch 'event_rpcgen.py-cleanup' (f0ded5f3, 48e04887 Enji Cooper)
o Add API/ABI checker (using LVC) (709210d4, 2af1f6cc yuangongji)
test:
o tinytest: support timeout on Windows (794e8f75 yuangongji)
o Merge branch 'osx-clock' (e85afbe3 Azat Khuzhin)
o test-ratelim: calculate timers bias (for slow CPUs) to avoid false-positive (8ad26d0b Azat Khuzhin)
fixes:
o buffer: do not pass NULL to memcpy() from evbuffer_pullup() (5b063049 Azat Khuzhin)
o http: fix undefined-shift in EVUTIL_IS*_ helpers (6b8d02a7 Azat Khuzhin)
o Check error code of evhttp_add_header_internal() in evhttp_parse_query_impl() (97e28f09 Azat Khuzhin)
o http: fix EVHTTP_CON_AUTOFREE in case of timeout (and some else) (1be25938 Azat Khuzhin)
o evdns: Add additional validation for values of dns options (c2972453 ayuseleznev)
o There is typo in GetAdaptersAddresses windows library. It should be iphlpapi.dll (891adda9 Aleksandr-Melnikov)
o Merge branch 'EV_CLOSED-and-EV_ET-fixes' (db2efdf5 Azat Khuzhin)
o Fix memory corruption in EV_CLOSURE_EVENT_FINALIZE with debug enabled (8ccd8f56 Jan Kasiak)
o increase segment refcnt only if evbuffer_add_file_segment() succeeds (30662a3c yuangongji)
o evdns: fix a crash when evdns_base with waiting requests is freed (6f8e0e97 ayuseleznev)
o event_base_once: fix potential null pointer threat (2e9ceb16 chenguolong)
o http: do not assume body for CONNECT (1b42270b Azat Khuzhin)
o evbuffer_add_file: fix freeing of segment in the error path (5f017bde Azat Khuzhin)
o Fix checking return value of the evdns_base_resolv_conf_parse() (fc51bf2c Azat Khuzhin)
o Merge branch 'fix-signal-leak' (poll/select now needs reinit) (1c9cc07b Azat Khuzhin)
improvements:
o evutil_time: improve evutil_gettimeofday on Windows (a8219143 Nick Grifka)
o Support EV_CLOSED on linux for poll(2) (2530e7c6 Azat Khuzhin)
o Parse IPv6 scope IDs. (f602211f Philip Homburg)
o evutil_time: Implements usleep() using wait funtion on Windows (d42240d1 yuangongji)
o evutil_time: detect and use _gmtime64_s()/_gmtime64() (f4a6152c yuangongji)
slightly touches the behaviour:
o bufferevent: allow setting priority on socket and openssl type (4dd3acdd Nicolas J. Bouliane)
o Fix EV_CLOSED detection/reporting (epoll only) (1df324d4 Azat Khuzhin) (XXX)
o Revert "Warn if forked from the event loop during event_reinit()" (71f5c0d3 Azat Khuzhin)
samples:
o https-client: load certificates from the system cert store on Windows (e9478640 yuangongji)
build fixes:
o Do not use sysctl.h on linux (it had been deprecated) (d2871a37 Azat Khuzhin)
o cmake: avoid problems from use of CMAKE_USE_PTHREADS_INIT (a62ec765 Paul Osborne)
o Update list of cmake files for autotools dist archive (2016f017 Azat Khuzhin)
o LibeventConfig.cmake: restore CMAKE_FIND_LIBRARY_SUFFIXES and LIBEVENT_STATIC_LINK default (640f9cf6 Mario Emmenlauer)
o cmake: fix getaddrinfo checking error (dea51c2e yuangongji)
o autoconf: fix getaddrinfo checking errors on mingw (b9bf7fa7 yuangongji)
o Do not use shared global structures on CYGWIN (8a9b5655 Azat Khuzhin)
o Added uninstall target check to cmakelists (3f1fb1f9 Dimo Markov)
o Fix compilation without OPENSSL_API_COMPAT (921bdcdd Azat Khuzhin)
o cmake: improve package config file (1c047618, baec84f2 yuangongji)
o Link with iphlpapi only on windows (976f7d34 Azat Khuzhin)
o autotools: fails build when need but can not find openssl (93174bb5 yuangongji)
o Merge branch 'http-connect' (e2424229 Azat Khuzhin)
o Fix compat with NetBSD >= 10 (5febb4e1 Kamil Rytarowski)
o cmake: fix getrandom() detection (e0e5f3bd Azat Khuzhin)
o arc4random: replace sysctl() with getrandom (on linux) (66ec78fd Azat Khuzhin)
o Upgrade autoconf (after upgrading minimum required to 2.67) (45da7d9d yuangongji)
o eliminate some C4267 warnings in Windows (9e468c77 yuangongji)
o autotools: attach doxygen target into all target (5d1e8570 yuangongji)
o cmake: attach doxygen target into all target (7a85300a yuangongji)
o Change the minimum version of automake to 1.13 and autoconf to 2.67 (fdb8fb66 ygj6)
o Add Uninstall.cmake.in into dist archive (877f2355 Azat Khuzhin)
Changes in version 2.1.11-stable (01 Aug 2019)
This release contains one ABI breakage fix (that had been introduced in
2.1.10, and strictly speaking this release breaks ABI again to make it
compatible with 2.1.9 and less, please take a look at 18104973 for more
details). Apart from that it contains some bug fixes, that grouped below.
And even though the return value for evbuffer_setcb() had been changed it
should ABI compatible (anyway that function is in -compat.h header).
There is also one patch that introduce new functionality, this is 546a366c,
to tune SO_RCVBUF/SO_SNDBUF in evdns, but one can count it as a bug-fix on
the application level, since before you cannot tune this settings and hence
you could stumble on problems.
ABI breakage:
o Protect min_heap_push_ against integer overflow. (8c899768 Tobias Stoeckmann)
o Revert "Protect min_heap_push_ against integer overflow." (18104973 Azat Khuzhin)
functionality:
o evdns: add new options -- so-rcvbuf/so-sndbuf (546a366c Azat Khuzhin)
build:
o Change autoconf version to 2.62 and automake version to 1.11.2 (2a333008 yuangongji)
o cmake: install shared library only if it was requested (596855f7 Azat Khuzhin)
o Missing on win7/MinGW(MINGW32_NT-6.1)/MSYS (9559349c yuangongji)
o cmake: set library names to be the same as with autotools (305251b9 yuangongji)
o Enable _GNU_SOURCE for Android (f013fc7d Keith Smiley)
o Enable kqueue for APPLE targets (3aa68a82 Keith Smiley)
o autotools: do not install bufferevent_ssl.h under --disable-openssl (5349a07e Azat Khuzhin)
o cmake: link against shell32.lib/advapi32.lib (c9ce638c Azat Khuzhin)
o Add README.md into dist archive (3660a4cc Azat Khuzhin)
o cmake: add missing autotools targets (doxygen, uninstall, event_rpcgen.py) (2d65071c yuangongji)
o m4/libevent_openssl.m4: fix detection of openssl (d4056e59 Fabrice Fontaine)
o Fix detection of the __has_attribute() for apple clang [ci skip] (7fd7c5ef Azat Khuzhin)
lib:
o buffer: fix possible NULL dereference in evbuffer_setcb() on ENOMEM (598f247d Azat Khuzhin)
o Warn if forked from the event loop during event_reinit() (b75922ae Azat Khuzhin)
o evutil: set the have_checked_interfaces in evutil_check_interfaces()
(ef498aa2, a09265ac jeremyerb)
samples:
o https-client: correction error checking (a8a04565 wenyg)
Changes in version 2.1.10-stable (26 May 2019)
This release contains mostly fixes (some evbuffer oddity, AF_UNIX handling in
http server, some UB fixes and others) but also some new functionality
(without ABI breakage as usual) and now dist archive can be used for building
on windows (getopt had been added into it).
Above you will find changelog for this particular release (but with some
trivial fixes pruned out from it - to make it a little bit more informative).
To view full changelog please use git:
git log --format=' o %s (%h %aN)' release-2.1.9-beta...release-2.1.10-stable
dist:
o Add getopt into dist archive (7042ff24 Azat Khuzhin)
functionality:
o evdns: add DNS_OPTION_NAMESERVERS_NO_DEFAULT/EVDNS_BASE_NAMESERVERS_NO_DEFAULT
(58e81106 Azat Khuzhin)
o Add support for EV_TIMEOUT to event_base_active_by_fd (3f893f0a John Ohl)
fixes:
o Merge branch 'evbuffer-fixes-806-v2' (2fea04b3 Azat Khuzhin)
o Merge branch 'issue-807-accept4-getnameinfo-AF_UNIX' (7c4da937, e2790a7f
Azat Khuzhin)
o kqueue: Avoid undefined behaviour. (e70e18e9 Tobias Stoeckmann)
o Prevent integer overflow in kq_build_changes_list. (43a55a23 Tobias Stoeckmann)
o evdns: fix lock/unlock mismatch in evdns_close_server_port() (54103883 zhuizhuhaomeng)
o Merge remote-tracking branch 'official/pr/804' -- Enforce limit of NSIG
signals (87fa93a8 Tobias Stoeckmann)
o Protect min_heap_push_ against integer overflow. (0b46bb8c Tobias Stoeckmann)
o le-proxy: initiate use of the Winsock DLL (2a1e1530 linxiaohui)
o Fix leaks in error path of the bufferevent_init_common_() (bb0f8fe7 Azat Khuzhin)
o buffer: make evbuffer_prepend() of zero-length array no-op (61fa7b7d Azat Khuzhin)
o Merge branch 'evbuffer-empty-chain-handling' (6a3dd717 Azat Khuzhin)
o Don't loose top error in SSL (3d1a7a1d Yury Korzhetsky)
o Remove needless check for arc4_seeded_ok (6602a97d Seong-Joong Kim)
o Merge pull request #769 from sungjungk/fix-return-handling (91084140 Nathan French)
build:
o Define `_GNU_SOURCE` properly/consistently per autoconf (00ba9fa2 Enji Cooper)
o signal: guard __cdecl definition with #ifdef (d89045a6 Azat Khuzhin)
o Link test/regress with event_core/event_extra over event (22380996 Azat Khuzhin)
tests:
o Use kill() over raise() for raising the signal (fixes osx 10.14 with
kqueue) (3db5296b, a45f6733 Azat Khuzhin)
o tinytest: implement per-test timeout (via alarm() under !win32 only)
(b64dbfb6, 75d7e1ff Azat Khuzhin)
Changes in version 2.1.9-beta (10 February 2019)
This changelog will differs from other releases in the next few clauses:
- contains only highlighted changes (so now it will not contains a lot of
patches that fixes some stuff in regression tests, typos, leaks fixes in
samples and so forth)
- no authors (since merge commits breaks them anyway, but AUTHORS sections in
README will be kept up to date)
- group name trimmed from commit subjects trimmed
- it's been 2 years since the previoius release, so it is pretty huge
And I think that this is more useful, so from now on it will always has the
same look (until there will too many objections of course).
To view full changelog please use git:
git log --format=' o %s (%h %aN)' release-2.1.8-stable...release-2.1.9-beta
dist archive:
o Add cmake rules into dist archive (bf3a67cf)
o Add missing print-winsock-errors.c into dist archive (822d6462)
o Include openssl-compat.h into dist archive (08658136)
core:
o Merge branch 'check-O_NONBLOCK-in-debug' (a39898f3, a8155c62)
o Merge branch 'event-ET-#636-v2' (ca4b6404)
o Fix visibility issues under (mostly on win32)
(349081e1g, 802be13ag, a1f28e2f)
o Define __EXT_POSIX2 for QNX (a2176f2c)
o Cleanup __func__ detection (b3af7bdd)
o Add convenience macros for user-triggered events (06ec5de6)
o Notify event base if there are no more events, so it can exit without delay (d9d1c09e)
o Fix base unlocking in event_del() if event_base_set() runned in another thread (4f0f40e3)
o If precise_time is false, we should not set EVENT_BASE_FLAG_PRECISE_TIMER (27dee54d)
o Fix race in access to ev_res from event loop with event_active() (43d92a6d)
o Return from event_del() after the last event callback termination (876c7ac7)
http:
o Merge branch 'http-EVHTTP_CON_READ_ON_WRITE_ERROR-fixes-v2' (eb7b472b)
o Preserve socket error from listen across closesocket cleanup (2ccd00a6)
o fix connection retries when there more then one request for connection (d30e7bba)
o improve error path for bufferevent_{setfd,enable,disable}() (a8cc449e)
o Fix conceivable UAF of the bufferevent in evhttp_connection_free() (6ac2ec25)
o Merge branch 'http-request-line-parsing' (cdcfbafe)
o Fix evhttp_connection_get_addr() fox incomming http connections (4215c003)
o fix leaks in evhttp_uriencode() (123362e9)
o CONNECT method only takes an authority (7d1ffe64)
o Allow bodies for GET/DELETE/OPTIONS/CONNECT (23eb38b9)
o Do not crash when evhttp_send_reply_start() is called after a timeout. (826f1134)
o Fix crashing http server when callback do not reply in place (5b40744d, b2581380)
o fix handling of close_notify (ssl) in http with openssl bufferevents (7e91622b)
evrpc:
o use *_new_with_arg() to match function prototype (a95cc9e3)
o avoid NULL dereference on request is not EVHTTP_REQ_POST (e05136c7)
regression tests:
o Merge branch 'TT_RETRIABLE' (6ea1ec68, f9b592aa)
bufferevent:
o Merge branch 'iocp-fixes' (6bfac964)
o Merge branch 'be-wm-overrun-v2' (3f692fff)
o bufferevent_socket_connect{,_hostname}() missing event callback and use ret code (1dde74ef)
o don't fail be_null_filter if bytes are copied (b92b0792)
o Call underlying bev ctrl GET_FD on filtered bufferevents (ebfac517)
bufferevent_openssl/openssl:
o Merge branch 'ssl_bufferevent_wm_filter-fix' (30020a35)
o be_openssl: avoid leaking of SSL structure (e86ccfe5)
o Fix build with LibreSSL 2.7 (894ca48a)
o Add missing includes into openssl-compat.h (01bc36c1)
o Explicitly call SSL_clear when reseting the fd. (29b7a516)
o Unbreak build with LibreSSL after openssl 1.1 support added (230af9f0)
samples:
o Merge branch 'sample-http-server' (b6309bcc)
o sample/https-client: use host SSL certificate store by default (5c0132f3)
listener:
o ipv6only socket bind support (ba148796)
o Merge branch 'listener-immediate-close' (df2ed13f)
o Merge branch 'evconnlistener-do-not-close-client-fd' (42e851bb)
evdns:
o evdns: handle NULL filename explicitly (0033f5cc)
o Merge branch 'evdns_getaddrinfo-race-fix' (3237d697)
o Generating evdns_base_config_windows_nameservers docs on all platforms (3bd2ce43)
utils:
o Merge branch 'evutil_found_ifaddr-dev' (b07e43e6)
o Avoid possible SEGVs in select() (in unit tests) (8818c86c)
o Port `event_rpcgen.py` and `test/check-dumpevents.py` to Python 3. (532a8cc3)
buffer:
o Fix assert() condition in evbuffer_drain() for IOCP (d6326104)
o fix incorrect unlock of the buffer mutex (for deferred callbacks) (2b4d127d)
o Fix wrong assert in evbuffer_drain() (9f4d0dce)
cmake:
o fix checking of devpoll backend (like in autotools, by devpoll.h existence) (7f161902)
o support static runtime (MSVC) (c8b3ec17, 61fb055a)
o do not build both (SHARED and STATIC) for MSVC/win32 (bc7f2fd9)
o introduce EVENT__LIBRARY_TYPE option (eb10a738)
o ensure windows dll's are installed as well as lib files (29590718)
o Fix generation of LibeventConfig.cmake for the installation tree (7fa08c4b)
o fix pkgconfig generation (copy-paste typo) (cc554d87)
o Merge branch 'cmake-missing-bits' (9806b126)
o Fix detection of timerfd_create() in CMake. (e50af331)
o Merge branch 'cmake-configure-fixes-v2' (a0bfe2c4)
o Do not add epoll_sub (syscall wrappers) for epoll in cmake (cea61de6)
o Fix RPATH for APPLE (45b1f379)
autotools:
o include win32 specific headers for socklen_t detection on win32/mingw (d7579fb9)
o Ignore evconfig-private.h for autotools (37423849)
o config.h can't be prefixed unconditionally (63a054f8)
o Merge branch 'pull-628' (7e56c8b2)
o Provide Makefile variables LIBEVENT_{CFLAGS,CPPFLAGS,LDFLAGS} (2f060c5f)
o confirm openssl is working before using (b39ccf8e)
o pass $(OPENSSL_INCS) for samples (FTBFS macOS) (c2495265)
o Add configure check for midipix (d433201e)
o Fix tests with detached builds (c46ff439)
build:
o Fix arc4random_addrandom() detecting and fallback (regression) (303d6d77)
o Merge branch 'win32-fixes' (ebd12e6d)
o Merge branch 'fix-openssl-linking' (e7bd9e03)
o Merge branch 'fix-struct-linger' (8567f2f5)
CI:
o travis-ci/appveyor now uses fast_finish+allow_failures
(5e97b6e6, dd472e7d, dfb5fc167)
o Merge branch 'travis-ci-osx-fixes' (9f02b39c)
o Merge branch 'win64-fixes' (aee0fcd5)
@
text
@@
1.1.1.2
log
@import libevent-2.1.13 (previous was 2.1.12)
Changes in version 2.1.13-stable (01 July 2026)
This release contains several security fixes, affecting users of the
following modules: evbuffer, bufferevent, evtag, evrpc, evdns, evhttp.
If you have a program that uses one of those modules,
or if you distribute libevent, you should upgrade.
Additionally, this release backports some small modernizations to
the libevent codebase, to aid in compiling with the compilers
released over the last few years.
Security Fixes (evtag, evrpc):
- Fix an out-of-bounds read in decode_tag_internal.
(Found by @@Brubbish. GHSA-fj29-64w6-73h6)
- Fix an integer overflow in evtag_unmarshal_header.
(Found by @@Brubbish. GHSA-45c6-qx49-89m8)
Security Fixes (evhttp):
- Discard HTTP trailers, to prevent header smuggling attacks.
(Found by @@sebastianosrt. GHSA-2gmv-p5m7-98p6)
- Restrict HTTP header parsing to prevent request smuggling.
(Originally reported by @@xclow3n; and then by @@kodareef5,
@@nstaller0490, @@AsafMeizneer, and @@yaotushaozhu.
GHSA-q39v-w2g7-gr8j.)
- Treat CRLF and %00 more strictly in HTTP headers, to prevent
parser mismatch attacks.
(Reported by @@xclow3n and @@AsafMeizner. See GHSA-q39v-w2g7-gr8j,
GHSA-jcwh-pvf2-73p2.)
- Fix a heap out-of-bound write that could occur when using
AF_UNIX sockets and compiling libevent with -DNDEBUG.
(Found by @@mat-mo. GHSA-cvq5-vrvr-j338)
Security fixes (evbuffer, bufferevent):
- Fixed a dangling pointer in evbuffer_add_reference.
(Found by @@DarkaMaul. GHSA-c2pj-cg4r-88c8)
Security fixes (evdns):
- Fix an out-of-bounds write in dnsname_to_labels
when building a DNS response of 2^16 bytes.
(Found by @@sectroyer. GHSA-58rx-7448-jw47)
Security fixes (example code):
- Avoid using strcpy() in sample/http-server.c.
(Reported by @@sectroyer. GHSA-5rgj-2c58-7jrc.)
Other fixes:
- Backport fixes for numerous compiler warnings.
- Backport fixes for compilation with openssl 3 and later.
@
text
@d1 1
a1 1
#!/usr/bin/sh
d3 1
a3 1
# Copyright 1992-2024 Free Software Foundation, Inc.
d5 1
a5 3
# shellcheck disable=SC2006,SC2268,SC2162 # see below for rationale
timestamp='2024-05-27'
d9 1
a9 1
# the Free Software Foundation, either version 3 of the License, or
d36 1
a36 1
# https://git.savannah.gnu.org/cgit/config.git/plain/config.sub
a52 7
# The "shellcheck disable" line above the timestamp inhibits complaints
# about features and limitations of the classic Bourne shell that were
# superseded or lifted in POSIX. However, this script identifies a wide
# variety of pre-POSIX systems that do not have POSIX shells at all, and
# even some reasonably current systems (Solaris 10 as case-in-point) still
# have a pre-POSIX /bin/sh.
d70 1
a70 1
Copyright 1992-2024 Free Software Foundation, Inc.
d76 1
a76 1
Try '$me --help' for more information."
d114 1
a114 1
saved_IFS=$IFS
a117 1
IFS=$saved_IFS
d122 1
a122 1
echo "Invalid configuration '$1': more than four components" >&2
d127 1
a127 1
basic_os=$field3-$field4
d134 5
a138 15
cloudabi*-eabi* \
| kfreebsd*-gnu* \
| knetbsd*-gnu* \
| kopensolaris*-gnu* \
| linux-* \
| managarm-* \
| netbsd*-eabi* \
| netbsd*-gnu* \
| nto-qnx* \
| os2-emx* \
| rtmk-nova* \
| storm-chaos* \
| uclinux-gnu* \
| uclinux-uclibc* \
| windows-* )
d140 1
a140 1
basic_os=$maybe_os
d144 1
a144 1
basic_os=linux-android
d148 1
a148 1
basic_os=$field3
d153 1
a154 5
# Shorthands that happen to contain a single dash
convex-c[12] | convex-c3[248])
basic_machine=$field2-convex
basic_os=
;;
d157 1
a157 1
basic_os=
d162 1
a162 1
# Do not treat sunos as a manufacturer
d165 1
a165 1
basic_os=$field2
d168 9
a176 69
3100* \
| 32* \
| 3300* \
| 3600* \
| 7300* \
| acorn \
| altos* \
| apollo \
| apple \
| atari \
| att* \
| axis \
| be \
| bull \
| cbm \
| ccur \
| cisco \
| commodore \
| convergent* \
| convex* \
| cray \
| crds \
| dec* \
| delta* \
| dg \
| digital \
| dolphin \
| encore* \
| gould \
| harris \
| highlevel \
| hitachi* \
| hp \
| ibm* \
| intergraph \
| isi* \
| knuth \
| masscomp \
| microblaze* \
| mips* \
| motorola* \
| ncr* \
| news \
| next \
| ns \
| oki \
| omron* \
| pc533* \
| rebel \
| rom68k \
| rombug \
| semi \
| sequent* \
| siemens \
| sgi* \
| siemens \
| sim \
| sni \
| sony* \
| stratus \
| sun \
| sun[234]* \
| tektronix \
| tti* \
| ultra \
| unicom* \
| wec \
| winbond \
| wrs)
d178 1
a178 5
basic_os=
;;
zephyr*)
basic_machine=$field1-unknown
basic_os=$field2
d182 1
a182 1
basic_os=$field2
d194 1
a194 1
basic_os=bsd
d198 1
a198 1
basic_os=udi
d202 1
a202 1
basic_os=scout
d206 1
a206 1
basic_os=
d210 1
a210 1
basic_os=
d214 1
a214 1
basic_os=bsd
d218 1
a218 1
basic_os=sysv
d222 1
a222 1
basic_os=
d226 1
a226 1
basic_os=amigaos
d230 1
a230 1
basic_os=sysv4
d234 1
a234 1
basic_os=sysv
d238 1
a238 1
basic_os=bsd
d242 1
a242 1
basic_os=aros
d246 1
a246 1
basic_os=aux
d250 1
a250 1
basic_os=dynix
d254 1
a254 1
basic_os=linux
d258 21
a278 1
basic_os=cegcc
d282 1
a282 1
basic_os=unicos
d286 1
a286 1
basic_os=
d290 1
a290 1
basic_os=
d294 1
a294 1
basic_os=
d298 1
a298 1
basic_os=sysv3
d302 1
a302 1
basic_os=dicos
d306 1
a306 1
basic_os=msdosdjgpp
d310 1
a310 1
basic_os=ebmon
d314 1
a314 1
basic_os=ose
d318 1
a318 1
basic_os=sysv
d322 1
a322 1
basic_os=go32
d326 1
a326 1
basic_os=hms
d330 1
a330 1
basic_os=xray
d334 1
a334 1
basic_os=hms
d338 1
a338 1
basic_os=sysv3
d342 1
a342 1
basic_os=hpux
d346 1
a346 1
basic_os=bsd
d350 1
a350 1
basic_os=osf
d354 1
a354 1
basic_os=proelf
d358 1
a358 1
basic_os=mach
d362 1
a362 1
basic_os=sysv
d366 1
a366 1
basic_os=linux
d370 1
a370 1
basic_os=sysv
d374 1
a374 1
basic_os=sysv
d378 1
a378 1
basic_os=mingw64
d382 1
a382 1
basic_os=mingw32
d386 1
a386 1
basic_os=mingw32ce
d390 1
a390 1
basic_os=coff
d394 1
a394 1
basic_os=morphos
d398 1
a398 1
basic_os=moxiebox
d402 1
a402 1
basic_os=msdos
d406 1
a406 1
basic_os=msys
d410 1
a410 1
basic_os=mvs
d414 1
a414 1
basic_os=nacl
d418 1
a418 1
basic_os=sysv4
d422 1
a422 1
basic_os=netbsd
d426 1
a426 1
basic_os=linux
d430 1
a430 1
basic_os=newsos
d434 1
a434 1
basic_os=newsos
d438 1
a438 1
basic_os=sysv
d442 1
a442 1
basic_os=cxux
d446 1
a446 1
basic_os=cxux
d450 1
a450 1
basic_os=nindy
d454 1
a454 1
basic_os=mon960
d458 1
a458 1
basic_os=nonstopux
d462 1
a462 1
basic_os=os400
d466 1
a466 1
basic_os=ose
d470 1
a470 1
basic_os=os68k
d474 1
a474 1
basic_os=osf
d478 1
a478 5
basic_os=linux
;;
psp)
basic_machine=mipsallegrexel-sony
basic_os=psp
d482 1
a482 1
basic_os=pw32
d486 1
a486 1
basic_os=rdos
d490 1
a490 1
basic_os=rdos
d494 1
a494 1
basic_os=coff
d498 1
a498 1
basic_os=udi
d502 1
a502 1
basic_os=seiux
d506 1
a506 1
basic_os=
d510 1
a510 1
basic_os=sysv2
d514 1
a514 1
basic_os=
d518 1
a518 1
basic_os=sysv4
d522 1
a522 1
basic_os=
d526 1
a526 1
basic_os=sunos3
d530 1
a530 1
basic_os=sunos4
d534 1
a534 1
basic_os=
d538 1
a538 1
basic_os=sunos3
d542 1
a542 1
basic_os=sunos4
d546 1
a546 1
basic_os=
d550 1
a550 1
basic_os=sunos3
d554 1
a554 1
basic_os=sunos4
d558 1
a558 1
basic_os=solaris2
d562 1
a562 1
basic_os=
d566 1
a566 1
basic_os=unicos
d570 1
a570 1
basic_os=dynix
d574 1
a574 1
basic_os=unicos
d578 1
a578 1
basic_os=unicos
d582 1
a582 1
basic_os=tops20
d586 1
a586 1
basic_os=tpf
d590 1
a590 1
basic_os=udi
d594 1
a594 1
basic_os=sym1
d598 1
a598 1
basic_os=none
d602 1
a602 1
basic_os=sysv
d606 1
a606 1
basic_os=vms
d610 1
a610 1
basic_os=vsta
d614 1
a614 1
basic_os=vxworks
d618 1
a618 1
basic_os=vxworks
d622 1
a622 1
basic_os=vxworks
d626 1
a626 1
basic_os=mingw32
d630 1
a630 1
basic_os=unicos
d634 1
a634 1
basic_os=
d686 1
a686 1
basic_os=cnk
d691 1
a691 1
basic_os=tops10
d696 1
a696 1
basic_os=tops20
d698 2
a699 1
delta | 3300 | delta-motorola | 3300-motorola | motorola-delta | motorola-3300)
d703 1
a703 6
# This used to be dpx2*, but that gets the RS6000-based
# DPX/20 and the x86-based DPX/2-100 wrong. See
# https://oldskool.silicium.org/stations/bull_dpx20.htm
# https://www.feb-patrimoine.com/english/bull_dpx2.htm
# https://www.feb-patrimoine.com/english/unix_and_bull.htm
dpx2 | dpx2[23]00 | dpx2[23]xx)
d706 1
a706 8
;;
dpx2100 | dpx21xx)
cpu=i386
vendor=bull
;;
dpx20)
cpu=rs6000
vendor=bull
d715 1
a715 1
basic_os=${basic_os:-bsd}
d728 1
a728 1
basic_os=hiuxwe2
d771 1
a771 1
basic_os=sysv32
d776 1
a776 1
basic_os=sysv4
d781 1
a781 1
basic_os=sysv
d786 1
a786 1
basic_os=solaris2
d791 1
a791 1
basic_os=${basic_os:-unicos}
d796 1
a796 1
case $basic_os in
d800 1
a800 1
basic_os=irix4
d811 1
a811 1
basic_os=mint
d816 1
a816 1
basic_os=newsos
d821 12
d841 1
a841 1
basic_os=proelf
d846 1
a846 1
basic_os=hiuxwe2
d883 1
a883 1
basic_os=${basic_os:-elf}
d888 1
a888 1
basic_os=vxworks
d905 1
a905 1
basic_os=proelf
d921 1
a921 1
saved_IFS=$IFS
a924 1
IFS=$saved_IFS
d926 1
a926 1
# We use 'pc' rather than 'unknown'
d954 2
a955 6
# Here we handle the default manufacturer of certain CPU types in canonical form.
# It is in some cases the only manufacturer, in others, it is the most popular.
c[12]-convex | c[12]-unknown | c3[248]-convex | c3[248]-unknown)
vendor=convex
basic_os=${basic_os:-bsd}
;;
d958 1
a958 1
basic_os=${basic_os:-unicosmp}
d962 1
a962 1
basic_os=${basic_os:-unicos}
d1003 4
a1006 27
armh-unknown | armh-alt)
cpu=armv7l
vendor=alt
basic_os=${basic_os:-linux-gnueabihf}
;;
# Normalized CPU+vendor pairs that imply an OS, if not otherwise specified
m68k-isi)
basic_os=${basic_os:-sysv}
;;
m68k-sony)
basic_os=${basic_os:-newsos}
;;
m68k-tektronix)
basic_os=${basic_os:-bsd}
;;
m88k-harris)
basic_os=${basic_os:-sysv3}
;;
i386-bull | m68k-bull)
basic_os=${basic_os:-sysv3}
;;
rs6000-bull)
basic_os=${basic_os:-bosx}
;;
mips-sni)
basic_os=${basic_os:-sysv4}
d1015 1
a1015 1
basic_os=${basic_os:-linux}
d1028 1
a1028 1
basic_os=${basic_os}"spe"
d1038 1
a1038 1
basic_os=${basic_os:-linux}
d1048 1
a1048 1
basic_os=${basic_os:-linux}
d1053 1
a1053 1
pentiumpro-* | p6-* | 6x86-* | athlon-* | athlon_*-*)
d1062 3
d1098 3
a1103 3
arm64-* | aarch64le-*)
cpu=aarch64
;;
d1108 1
a1108 1
basic_os=${basic_os:-elf}
d1119 1
a1119 1
basic_os=${basic_os:-elf}
d1141 7
a1147 3
mipsallegrexel-sony)
cpu=mipsallegrexel
vendor=sony
d1150 1
a1150 1
basic_os=${basic_os:-linux-gnu}
d1157 1
a1157 3
1750a \
| 580 \
| [cjt]90 \
d1159 1
a1159 3
| aarch64 \
| aarch64_be \
| aarch64c \
d1161 3
a1163 10
| alpha \
| alpha64 \
| alpha64ev56 \
| alpha64ev6[78] \
| alpha64ev[4-8] \
| alpha64pca5[67] \
| alphaev56 \
| alphaev6[78] \
| alphaev[4-8] \
| alphapca5[67] \
d1166 3
a1168 10
| arc \
| arc32 \
| arc64 \
| arceb \
| arm \
| arm64e \
| arm64ec \
| arm[lb]e \
| arme[lb] \
| armv* \
a1169 2
| avr \
| avr32 \
d1171 9
a1179 29
| be32 \
| be64 \
| bfin \
| bpf \
| bs2000 \
| c30 \
| c4x \
| c8051 \
| c[123]* \
| clipper \
| craynv \
| csky \
| cydra \
| d10v \
| d30v \
| dlx \
| dsp16xx \
| e2k \
| elxsi \
| epiphany \
| f30[01] \
| f700 \
| fido \
| fr30 \
| frv \
| ft32 \
| fx80 \
| h8300 \
| h8500 \
d1181 2
a1182 14
| hppa \
| hppa1.[01] \
| hppa2.0 \
| hppa2.0[nw] \
| hppa64 \
| i*86 \
| i370 \
| i860 \
| i960 \
| ia16 \
| ia64 \
| ip2k \
| iq2000 \
| javascript \
d1184 1
a1184 3
| kvx \
| le32 \
| le64 \
d1186 26
a1211 26
| loongarch32 \
| loongarch64 \
| m32c \
| m32r \
| m32rle \
| m5200 \
| m68000 \
| m680[012346]0 \
| m6811 \
| m6812 \
| m68360 \
| m683?2 \
| m68hc11 \
| m68hc12 \
| m68hcs12x \
| m68k \
| m88110 \
| m88k \
| maxq \
| mb \
| mcore \
| mep \
| metag \
| microblaze \
| microblazeel \
| mips* \
d1213 1
a1213 2
| mn10200 \
| mn10300 \
d1215 1
d1217 1
a1217 5
| mt \
| nanomips* \
| nds32 \
| nds32be \
| nds32le \
d1219 2
a1220 9
| nios \
| nios2 \
| nios2eb \
| nios2el \
| none \
| np1 \
| ns16k \
| ns32k \
| nvptx \
a1224 2
| pdp10 \
| pdp11 \
d1226 2
a1227 9
| pj \
| pjl \
| pn \
| power \
| powerpc \
| powerpc64 \
| powerpc64le \
| powerpcle \
| powerpcspe \
d1230 2
a1231 11
| riscv \
| riscv32 \
| riscv32be \
| riscv64 \
| riscv64be \
| rl78 \
| romp \
| rs6000 \
| rx \
| s390 \
| s390x \
d1233 4
a1236 19
| sh \
| sh64 \
| sh64le \
| sh[12345][lb]e \
| sh[1234] \
| sh[1234]e[lb] \
| sh[23]e \
| sh[23]ele \
| sh[24]a \
| sh[24]ae[lb] \
| sh[lb]e \
| she[lb] \
| shl \
| sparc \
| sparc64 \
| sparc64b \
| sparc64v \
| sparc86x \
| sparclet \
d1238 1
a1238 4
| sparcv8 \
| sparcv9 \
| sparcv9b \
| sparcv9v \
a1239 2
| sv1 \
| sx* \
d1241 1
a1241 7
| thumbv7* \
| tic30 \
| tic4x \
| tic54x \
| tic55x \
| tic6x \
| tic80 \
d1244 1
a1244 8
| v70 \
| v810 \
| v850 \
| v850e \
| v850e1 \
| v850e2 \
| v850e2v3 \
| v850es \
a1245 1
| vc4 \
d1248 1
a1248 2
| wasm32 \
| wasm64 \
d1250 2
a1251 7
| x86 \
| x86_64 \
| xc16x \
| xgate \
| xps100 \
| xstormy16 \
| xtensa* \
d1253 1
a1253 2
| z80 \
| z8k)
d1257 1
a1257 1
echo "Invalid configuration '$1': machine '$cpu-$vendor' not recognized" 1>&2
d1278 1
a1278 1
if test x"$basic_os" != x
a1279 45
# First recognize some ad-hoc cases, or perhaps split kernel-os, or else just
# set os.
obj=
case $basic_os in
gnu/linux*)
kernel=linux
os=`echo "$basic_os" | sed -e 's|gnu/linux|gnu|'`
;;
os2-emx)
kernel=os2
os=`echo "$basic_os" | sed -e 's|os2-emx|emx|'`
;;
nto-qnx*)
kernel=nto
os=`echo "$basic_os" | sed -e 's|nto-qnx|qnx|'`
;;
*-*)
saved_IFS=$IFS
IFS="-" read kernel os <&2
fi
;;
*)
echo "Invalid configuration '$1': OS '$os' not recognized" 1>&2
exit 1
;;
esac
case $obj in
aout* | coff* | elf* | pe*)
;;
'')
# empty is fine
;;
*)
echo "Invalid configuration '$1': Machine code format '$obj' not recognized" 1>&2
exit 1
;;
esac
# Here we handle the constraint that a (synthetic) cpu and os are
# valid only in combination with each other and nowhere else.
case $cpu-$os in
# The "javascript-unknown-ghcjs" triple is used by GHC; we
# accept it here in order to tolerate that, but reject any
# variations.
javascript-ghcjs)
;;
javascript-* | *-ghcjs)
echo "Invalid configuration '$1': cpu '$cpu' is not valid with os '$os$obj'" 1>&2
exit 1
;;
esac
# As a final step for OS-related things, validate the OS-kernel combination
# (given a valid OS), if there is a kernel.
case $kernel-$os-$obj in
linux-gnu*- | linux-android*- | linux-dietlibc*- | linux-llvm*- \
| linux-mlibc*- | linux-musl*- | linux-newlib*- \
| linux-relibc*- | linux-uclibc*- | linux-ohos*- )
;;
uclinux-uclibc*- | uclinux-gnu*- )
;;
managarm-mlibc*- | managarm-kernel*- )
;;
windows*-msvc*-)
;;
-dietlibc*- | -llvm*- | -mlibc*- | -musl*- | -newlib*- | -relibc*- \
| -uclibc*- )
# These are just libc implementations, not actual OSes, and thus
# require a kernel.
echo "Invalid configuration '$1': libc '$os' needs explicit kernel." 1>&2
exit 1
;;
-kernel*- )
echo "Invalid configuration '$1': '$os' needs explicit kernel." 1>&2
exit 1
;;
*-kernel*- )
echo "Invalid configuration '$1': '$kernel' does not support '$os'." 1>&2
exit 1
;;
*-msvc*- )
echo "Invalid configuration '$1': '$os' needs 'windows'." 1>&2
exit 1
;;
kfreebsd*-gnu*- | knetbsd*-gnu*- | netbsd*-gnu*- | kopensolaris*-gnu*-)
;;
vxworks-simlinux- | vxworks-simwindows- | vxworks-spe-)
;;
nto-qnx*-)
;;
os2-emx-)
;;
rtmk-nova-)
;;
*-eabi*- | *-gnueabi*-)
;;
none--*)
# None (no kernel, i.e. freestanding / bare metal),
# can be paired with an machine code file format
;;
-*-)
# Blank kernel with real OS is always fine.
;;
--*)
# Blank kernel and OS with real machine code file format is always fine.
;;
*-*-*)
echo "Invalid configuration '$1': Kernel '$kernel' not known to work with OS '$os'." 1>&2
exit 1
;;
esac
d1714 2
a1715 2
case $cpu-$os in
*-riscix*)
d1718 1
a1718 1
*-sunos* | *-solaris*)
d1721 1
a1721 1
*-cnk* | *-aix*)
d1724 1
a1724 1
*-beos*)
d1727 1
a1727 1
*-hpux*)
d1730 1
a1730 1
*-mpeix*)
d1733 1
a1733 1
*-hiux*)
d1736 1
a1736 1
*-unos*)
d1739 1
a1739 1
*-dgux*)
d1742 1
a1742 1
*-luna*)
d1745 1
a1745 1
*-genix*)
d1748 1
a1748 1
*-clix*)
d1751 1
a1751 4
*-mvs* | *-opened*)
vendor=ibm
;;
*-os400*)
d1754 1
a1754 1
s390-* | s390x-*)
d1757 1
a1757 1
*-ptx*)
d1760 1
a1760 1
*-tpf*)
d1763 1
a1763 1
*-vxsim* | *-vxworks* | *-windiss*)
d1766 1
a1766 1
*-aux*)
d1769 1
a1769 1
*-hms*)
d1772 1
a1772 1
*-mpw* | *-macos*)
d1775 1
a1775 1
*-*mint | *-mint[0-9]* | *-*MiNT | *-MiNT[0-9]*)
d1778 1
a1778 1
*-vos*)
d1785 1
a1785 1
echo "$cpu-$vendor${kernel:+-$kernel}${os:+-$os}${obj:+-$obj}"
@