Print this page
4519 ABI checking needs to adapt to modern times, run by default
Reviewed by: Josef 'Jeff' Sipek <jeffpc@josefsipek.net>
Reviewed by: Yuri Pankov <yuri.pankov@nexenta.com>
Reviewed by: Jens Elkner <jel+illumos@cs.uni-magdeburg.de>
*** 41,52 ****
#
# The types of versions understood by interface_check and interface_cmp
# fall into the following categories:
#
# NUMBERED: A public version that follows the standard numbering
! # convention of a known prefix (e.g. SUNW_), followed
! # by 2 or 3 dot separated numeric values:
#
# <PREFIX>major.minor[.micro]
#
# PLAIN: A public version that may or may not contain
# numeric characters, but for which numeric characters
--- 41,52 ----
#
# The types of versions understood by interface_check and interface_cmp
# fall into the following categories:
#
# NUMBERED: A public version that follows the standard numbering
! # convention of a known prefix (e.g. ILLUMOS_),
! # followed by 2 or 3 dot separated numeric values:
#
# <PREFIX>major.minor[.micro]
#
# PLAIN: A public version that may or may not contain
# numeric characters, but for which numeric characters
*** 99,132 ****
# is omitted.
#
sub Category {
my ($Ver, $Soname) = @_;
! # For Solaris and related products, the SUNW_ prefix is
! # used for numbered public versions.
! if ($Ver =~ /^(SUNW_)(\d+)\.(\d+)(\.(\d+))?/) {
return ('NUMBERED', 3, $1, $2, $3, $5) if defined($5);
return ('NUMBERED', 2, $1, $2, $3);
}
# Well known plain versions. In Solaris, these names were used
# to tag symbols that come from the SVR4 underpinnings to Solaris.
! # Later Sun-specific additions are all tagged SUNW_xxx.
return ('PLAIN')
if (($Ver =~ /^SYSVABI_1.[23]$/) || ($Ver =~ /^SISCD_2.3[ab]*$/));
# The link-editor creates "base" versions using the SONAME of the
# object to contain linker generated symbols (_etext, _edata, etc.).
return ('SONAME')
if ($Ver eq $Soname) && ($Soname ne '');
! # The Solaris convention is to use SUNWprivate to indicate
! # private versions. SUNWprivate can have a numeric suffix, but
! # the number is not significant for ELF versioning other than
! # being part of a unique name.
return ('PRIVATE')
! if ($Ver =~ /^SUNWprivate(_[0-9.]+)?$/);
# Anything else is a version we don't recognize.
return ('UNKNOWN');
}
--- 99,132 ----
# is omitted.
#
sub Category {
my ($Ver, $Soname) = @_;
! # For illumos, the SUNW_ or ILLUMOS_ prefix is used for numbered
! # public versions.
! if ($Ver =~ /^((?:SUNW|ILLUMOS)_)(\d+)\.(\d+)(\.(\d+))?/) {
return ('NUMBERED', 3, $1, $2, $3, $5) if defined($5);
return ('NUMBERED', 2, $1, $2, $3);
}
# Well known plain versions. In Solaris, these names were used
# to tag symbols that come from the SVR4 underpinnings to Solaris.
! # Later additions are all in the NUMBERED form.
return ('PLAIN')
if (($Ver =~ /^SYSVABI_1.[23]$/) || ($Ver =~ /^SISCD_2.3[ab]*$/));
# The link-editor creates "base" versions using the SONAME of the
# object to contain linker generated symbols (_etext, _edata, etc.).
return ('SONAME')
if ($Ver eq $Soname) && ($Soname ne '');
! # The convention is to use SUNWprivate and ILLUMOSprivate to indicate
! # private versions. They may have a numeric suffix, but the
! # number is not significant for ELF versioning other than being part
! # of a unique name.
return ('PRIVATE')
! if ($Ver =~ /^(SUNW|ILLUMOS)private(_[0-9.]+)?$/);
# Anything else is a version we don't recognize.
return ('UNKNOWN');
}