Kaydet (Commit) 2b3d675f authored tarafından Petr Mladek's avatar Petr Mladek

fix dependencies of the obsolete stdlibs package on linux

The old version should get repalced by the ure package. It should also conflict
with the new ure package.

This commit adds support for %incompat epm tag. It produces conflicts in rpm
and deb. It can be defined in setup_native/source/packinfo by
linuxincompat.

This commit also removes obsolete hack for debian dependencies.
libreoffice-bundled conflict is mentioned in the desktop-integration package
these day. The hack in epmfile.pm was not used because no package
used "replace" tag.

Change-Id: I5e9cb89a6108c22c61287fce1ffc6baf3f618d15
Reviewed-on: https://gerrit.libreoffice.org/2260Reviewed-by: 's avatarFridrich Strba <fridrich@documentfoundation.org>
Tested-by: 's avatarFridrich Strba <fridrich@documentfoundation.org>
üst 2d907dcc
...@@ -21,7 +21,8 @@ module = "gid_Module_Root" ...@@ -21,7 +21,8 @@ module = "gid_Module_Root"
solarispackagename = "%SOLSUREPACKAGEPREFIX%BRANDPACKAGEVERSION-ure" solarispackagename = "%SOLSUREPACKAGEPREFIX%BRANDPACKAGEVERSION-ure"
solarisrequires = "SUNWzlibr" solarisrequires = "SUNWzlibr"
solarisprovides = "%SOLSUREPACKAGEPREFIX%BRANDPACKAGEVERSION-stdlibs" solarisprovides = "%SOLSUREPACKAGEPREFIX%BRANDPACKAGEVERSION-stdlibs"
provides = "%UREPACKAGEPREFIX%BRANDPACKAGEVERSION-stdlibs" linuxreplaces = "%UREPACKAGEPREFIX%BRANDPACKAGEVERSION-stdlibs"
linuxincompat = "%UREPACKAGEPREFIX%BRANDPACKAGEVERSION-stdlibs"
packagename = "%UREPACKAGEPREFIX%BRANDPACKAGEVERSION-ure" packagename = "%UREPACKAGEPREFIX%BRANDPACKAGEVERSION-ure"
copyright = "2012 The Document Foundation" copyright = "2012 The Document Foundation"
solariscopyright = "solariscopyrightfile" solariscopyright = "solariscopyrightfile"
...@@ -36,7 +37,8 @@ module = "gid_Module_Root_Ure_Hidden" ...@@ -36,7 +37,8 @@ module = "gid_Module_Root_Ure_Hidden"
solarispackagename = "%SOLSUREPACKAGEPREFIX%BRANDPACKAGEVERSION-ure" solarispackagename = "%SOLSUREPACKAGEPREFIX%BRANDPACKAGEVERSION-ure"
solarisrequires = "SUNWzlibr" solarisrequires = "SUNWzlibr"
solarisprovides = "%SOLSUREPACKAGEPREFIX%BRANDPACKAGEVERSION-stdlibs" solarisprovides = "%SOLSUREPACKAGEPREFIX%BRANDPACKAGEVERSION-stdlibs"
provides = "%UREPACKAGEPREFIX%BRANDPACKAGEVERSION-stdlibs" linuxreplaces = "%UREPACKAGEPREFIX%BRANDPACKAGEVERSION-stdlibs"
linuxincompat = "%UREPACKAGEPREFIX%BRANDPACKAGEVERSION-stdlibs"
packagename = "%UREPACKAGEPREFIX%BRANDPACKAGEVERSION-ure" packagename = "%UREPACKAGEPREFIX%BRANDPACKAGEVERSION-ure"
copyright = "2012 The Document Foundation" copyright = "2012 The Document Foundation"
solariscopyright = "solariscopyrightfile" solariscopyright = "solariscopyrightfile"
......
...@@ -265,6 +265,8 @@ sub create_epm_header ...@@ -265,6 +265,8 @@ sub create_epm_header
# %readme /test/replace/01/README01 # %readme /test/replace/01/README01
# %requires foo # %requires foo
# %provides bar # %provides bar
# %replaces bar
# %incompat bar
# The first language in the languages array determines the language of license and readme file # The first language in the languages array determines the language of license and readme file
...@@ -512,23 +514,38 @@ sub create_epm_header ...@@ -512,23 +514,38 @@ sub create_epm_header
$onereplaces = debian_rewrite($onereplaces); $onereplaces = debian_rewrite($onereplaces);
$line = "%replaces" . " " . $onereplaces . "\n"; $line = "%replaces" . " " . $onereplaces . "\n";
push(@epmheader, $line); push(@epmheader, $line);
}
}
}
# Force the openofficeorg packages to get removed, # including %incompat
# see http://www.debian.org/doc/debian-policy/ch-relationships.html
# 7.5.2 Replacing whole packages, forcing their removal
if ( $installer::globals::debian ) my $incompat = "";
{
$line = "%incompat" . " " . $onereplaces . "\n"; if (( $installer::globals::issolarispkgbuild ) && ( ! $installer::globals::patch ))
push(@epmheader, $line); {
} $incompat = "solarisincompat"; # the name in the packagelist
} }
elsif (( $installer::globals::islinuxbuild ) && ( ! $installer::globals::patch ))
{
$incompat = "linuxincompat"; # the name in the packagelist
}
if (( $incompat ) && ( ! $installer::globals::patch ))
{
if ( $onepackage->{$incompat} )
{
my $incompatstring = $onepackage->{$incompat};
if ( $installer::globals::debian && $variableshashref->{'UNIXPRODUCTNAME'} eq 'libreoffice' ) my $allincompat = installer::converter::convert_stringlist_into_array(\$incompatstring, ",");
for ( my $i = 0; $i <= $#{$allincompat}; $i++ )
{ {
$line = "%provides" . " libreoffice-unbundled\n"; my $oneincompat = ${$allincompat}[$i];
push(@epmheader, $line); $oneincompat =~ s/\s*$//;
$line = "%incompat" . " libreoffice-bundled\n"; installer::packagelist::resolve_packagevariables(\$oneincompat, $variableshashref, 1);
$oneincompat = debian_rewrite($oneincompat);
$line = "%incompat" . " " . $oneincompat . "\n";
push(@epmheader, $line); push(@epmheader, $line);
} }
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment