Configure et al: rename all dso_* to module_* in shared-info.pl

Because there are already attributes with the dso_ prefix that are
used instead of the corresponding lib_ attributes rather than in
addition to them, it gets confusing to have similar or exactly the
same attributes working with different semantics on Unix.

So we rename those by changing the prefix dso_ to module_, and having
those work just like the shared_ attributes, but for DSOs.

Reviewed-by: Andy Polyakov <appro@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/5534)
This commit is contained in:
Richard Levitte 2018-03-07 20:31:15 +01:00
parent d420729b9e
commit 48dcca265c
2 changed files with 12 additions and 12 deletions

View File

@ -42,7 +42,7 @@ my %shared_info;
};
},
'darwin-shared' => {
dso_lflags => '-bundle',
module_ldflags => '-bundle',
shared_ldflag => '-dynamiclib -current_version $(SHLIB_VERSION_NUMBER) -compatibility_version $(SHLIB_VERSION_NUMBER)',
shared_sonameflag => '-install_name $(INSTALLTOP)/$(LIBDIR)/',
},
@ -61,7 +61,7 @@ my %shared_info;
'alpha-osf1-shared' => sub {
return $shared_info{'gnu-shared'} if detect_gnu_ld();
return {
dso_lflags => '-shared -Wl,-Bsymbolic',
module_ldflags => '-shared -Wl,-Bsymbolic',
shared_ldflag => '-shared -Wl,-Bsymbolic -set_version $(SHLIB_VERSION_NUMBER)',
};
},

View File

@ -973,9 +973,9 @@ my %target = resolve_config($target);
# Make the flags to build DSOs the same as for shared libraries unless they
# are already defined
$target{dso_cflags} = $target{shared_cflag} unless defined $target{dso_cflags};
$target{dso_cxxflags} = $target{shared_cxxflag} unless defined $target{dso_cxxflags};
$target{dso_lflags} = $target{shared_ldflag} unless defined $target{dso_lflags};
$target{module_cflags} = $target{shared_cflag} unless defined $target{module_cflags};
$target{module_cxxflags} = $target{shared_cxxflag} unless defined $target{module_cxxflags};
$target{module_ldflags} = $target{shared_ldflag} unless defined $target{module_ldflags};
{
my $shared_info_pl =
catfile(dirname($0), "Configurations", "shared-info.pl");
@ -997,10 +997,10 @@ $target{dso_lflags} = $target{shared_ldflag} unless defined $target{dso_lflags};
# Windows and VMS.
if (defined $si) {
# Just as above, copy certain shared_* attributes to the corresponding
# dso_ attribute unless the latter is already defined
$si->{dso_cflags} = $si->{shared_cflag} unless defined $si->{dso_cflags};
$si->{dso_cxxflags} = $si->{shared_cxxflag} unless defined $si->{dso_cxxflags};
$si->{dso_lflags} = $si->{shared_ldflag} unless defined $si->{dso_lflags};
# module_ attribute unless the latter is already defined
$si->{module_cflags} = $si->{shared_cflag} unless defined $si->{module_cflags};
$si->{module_cxxflags} = $si->{shared_cxxflag} unless defined $si->{module_cxxflags};
$si->{module_ldflags} = $si->{shared_ldflag} unless defined $si->{module_ldflags};
foreach (sort keys %$si) {
$target{$_} = defined $target{$_}
? add($si->{$_})->($target{$_})
@ -1275,9 +1275,9 @@ unless ($disabled{"fuzz-libfuzzer"} && $disabled{"fuzz-afl"}
if ($disabled{pic})
{
foreach (qw(shared_cflag shared_cxxflag shared_cppflag
shared_defines shared_includes shared_ldflag
dso_cflags dso_cxxflags dso_cppflags
dso_defines dso_includes dso_lflags))
shared_defines shared_includes shared_ldflag
module_cflags module_cxxflags module_cppflags
module_defines module_includes module_lflags))
{
delete $config{$_};
$target{$_} = "";