summaryrefslogtreecommitdiff
path: root/source4
diff options
context:
space:
mode:
authorJelmer Vernooij <jelmer@samba.org>2008-02-16 20:24:47 +0100
committerJelmer Vernooij <jelmer@samba.org>2008-02-16 20:24:47 +0100
commit85ac8dc17ad8cd01bb773383fd30261b9f357292 (patch)
treec004feb8655a5d541a8d1f7cc77fb37ce190b998 /source4
parentf7c8fe62a8506079d6417c149608e49272c0767e (diff)
downloadsamba-85ac8dc17ad8cd01bb773383fd30261b9f357292.tar.gz
samba-85ac8dc17ad8cd01bb773383fd30261b9f357292.tar.bz2
samba-85ac8dc17ad8cd01bb773383fd30261b9f357292.zip
Simpler handling of sonameflag.
(This used to be commit ef532a715e8d05652bc7b320d6d0b88a93599b33)
Diffstat (limited to 'source4')
-rw-r--r--source4/build/smb_build/makefile.pm23
1 files changed, 7 insertions, 16 deletions
diff --git a/source4/build/smb_build/makefile.pm b/source4/build/smb_build/makefile.pm
index 7dc296a639..ecbf554fc7 100644
--- a/source4/build/smb_build/makefile.pm
+++ b/source4/build/smb_build/makefile.pm
@@ -203,21 +203,7 @@ sub SharedLibrary($$)
$self->_prepare_list($ctx, "DEPEND_LIST");
$self->_prepare_list($ctx, "LINK_FLAGS");
- my $soarg = "";
- my $lns = "";
- if ($self->{config}->{SONAMEFLAG} ne "#" and defined($ctx->{LIBRARY_SONAME})) {
- $soarg = "$self->{config}->{SONAMEFLAG}$ctx->{LIBRARY_SONAME}";
- if ($ctx->{LIBRARY_REALNAME} ne $ctx->{LIBRARY_SONAME}) {
- $lns .= "\n\t\@test \$($ctx->{NAME}_VERSION) = \$($ctx->{NAME}_SOVERSION) || ln -fs $ctx->{LIBRARY_REALNAME} $ctx->{SHAREDDIR}/$ctx->{LIBRARY_SONAME}";
- }
- }
-
- $lns .= "\nifdef $ctx->{NAME}_SOVERSION";
- $lns .= "\n\t\@ln -fs $ctx->{LIBRARY_REALNAME} $ctx->{SHAREDDIR}/$ctx->{LIBRARY_DEBUGNAME}";
- $lns .= "\nendif";
-
$self->output(<< "__EOD__"
-#
$ctx->{SHAREDDIR}/$ctx->{LIBRARY_REALNAME}: \$($ctx->{NAME}_DEPEND_LIST) \$($ctx->{NAME}_OBJ_LIST)
\@echo Linking \$\@
@@ -225,10 +211,15 @@ $ctx->{SHAREDDIR}/$ctx->{LIBRARY_REALNAME}: \$($ctx->{NAME}_DEPEND_LIST) \$($ctx
\@\$(SHLD) \$(SHLD_FLAGS) \$(INTERN_LDFLAGS) -o \$\@ \$(INSTALL_LINK_FLAGS) \\
\$($ctx->{NAME}\_OBJ_LIST) \\
\$($ctx->{NAME}_LINK_FLAGS) \\
- $soarg$lns
+ \$(if \$(SONAMEFLAG), \$(SONAMEFLAG)$ctx->{LIBRARY_SONAME})
__EOD__
);
- $self->output("\n");
+ if ($ctx->{LIBRARY_REALNAME} ne $ctx->{LIBRARY_SONAME}) {
+ $self->output("\t\@test \$($ctx->{NAME}_VERSION) = \$($ctx->{NAME}_SOVERSION) || ln -fs $ctx->{LIBRARY_REALNAME} $ctx->{SHAREDDIR}/$ctx->{LIBRARY_SONAME}\n");
+ }
+ $self->output("ifdef $ctx->{NAME}_SOVERSION\n");
+ $self->output("\t\@ln -fs $ctx->{LIBRARY_REALNAME} $ctx->{SHAREDDIR}/$ctx->{LIBRARY_DEBUGNAME}\n");
+ $self->output("endif\n");
}
sub StaticLibraryPrimitives($$)