Add default Obsoletes: for nodejsXX
This takes its cue from the Python 3.X approach Signed-off-by: Stephen Gallagher <sgallagh@redhat.com>
This commit is contained in:
parent
f57981cf35
commit
b64d26c94a
@ -196,6 +196,17 @@ BuildRequires: unzip
|
||||
|
||||
%if 0%{?nodejs_default}
|
||||
Provides: nodejs = %{nodejs_envr}
|
||||
# To keep the upgrade path clean, we Obsolete nodejsXX from the nodejs
|
||||
# package and nodejsXX-foo from individual subpackages.
|
||||
# Note that using Obsoletes without package version is not standard practice.
|
||||
# Here we assert that *any* version of the system's default interpreter is
|
||||
# preferable to an "extra" interpreter. For example, nodejs-20.5.0 will
|
||||
# replace nodejs20-20.6.0.
|
||||
%define unversioned_obsoletes_of_nodejsXX_if_default() %{expand:\
|
||||
Obsoletes: nodejs%{nodejs_pkg_major}%{?1:-%{1}}\
|
||||
}
|
||||
%else
|
||||
%define unversioned_obsoletes_of_nodejsXX_if_default() %{nil}
|
||||
%endif
|
||||
|
||||
%if %{with bundled}
|
||||
@ -302,6 +313,9 @@ Provides: bundled(histogram) = %{histogram_version}
|
||||
Provides: bundled(ada) = 2.6.0
|
||||
|
||||
|
||||
%unversioned_obsoletes_of_nodejsXX_if_default
|
||||
|
||||
|
||||
%description
|
||||
Node.js is a platform built on Chrome's JavaScript runtime \
|
||||
for easily building fast, scalable network applications. \
|
||||
@ -339,6 +353,7 @@ Requires: libuv-devel%{?_isa}
|
||||
%if 0%{?nodejs_default}
|
||||
Provides: nodejs-devel = %{nodejs_envr}
|
||||
%endif
|
||||
%unversioned_obsoletes_of_nodejsXX_if_default devel
|
||||
|
||||
Provides: nodejs-devel-pkg = %{nodejs_envr}
|
||||
Conflicts: nodejs-devel-pkg
|
||||
@ -368,6 +383,7 @@ Provides: v8%{?_isa} = %{v8_epoch}:%{v8_version}-%{nodejs_release}
|
||||
Obsoletes: v8 < 1:6.7.17-10
|
||||
|
||||
Provides: nodejs-libs = %{nodejs_envr}
|
||||
%unversioned_obsoletes_of_nodejsXX_if_default libs
|
||||
|
||||
%description -n %{pkgname}-libs
|
||||
Libraries to support Node.js and provide stable v8 interfaces.
|
||||
@ -377,6 +393,8 @@ Libraries to support Node.js and provide stable v8 interfaces.
|
||||
Summary: Non-English locale data for Node.js
|
||||
Requires: %{pkgname}%{?_isa} = %{nodejs_envr}
|
||||
|
||||
%unversioned_obsoletes_of_nodejsXX_if_default full-i18n
|
||||
|
||||
|
||||
%description -n %{pkgname}-full-i18n
|
||||
Optional data files to provide full-icu support for Node.js. Remove this
|
||||
@ -425,6 +443,7 @@ Provides: npm = %{npm_envr}
|
||||
# Obsolete the old 'npm' package
|
||||
Obsoletes: npm < 1:9
|
||||
%endif
|
||||
%unversioned_obsoletes_of_nodejsXX_if_default npm
|
||||
|
||||
|
||||
%description -n %{pkgname}-npm
|
||||
@ -439,6 +458,7 @@ BuildArch: noarch
|
||||
Requires(meta): %{pkgname} = %{nodejs_envr}
|
||||
|
||||
Provides: nodejs-docs = %{nodejs_envr}
|
||||
%unversioned_obsoletes_of_nodejsXX_if_default docs
|
||||
|
||||
|
||||
%description -n %{pkgname}-docs
|
||||
|
@ -200,6 +200,17 @@ BuildRequires: systemtap-sdt-devel
|
||||
|
||||
%if 0%{?nodejs_default}
|
||||
Provides: nodejs = %{nodejs_envr}
|
||||
# To keep the upgrade path clean, we Obsolete nodejsXX from the nodejs
|
||||
# package and nodejsXX-foo from individual subpackages.
|
||||
# Note that using Obsoletes without package version is not standard practice.
|
||||
# Here we assert that *any* version of the system's default interpreter is
|
||||
# preferable to an "extra" interpreter. For example, nodejs-20.5.0 will
|
||||
# replace nodejs20-20.6.0.
|
||||
%define unversioned_obsoletes_of_nodejsXX_if_default() %{expand:\
|
||||
Obsoletes: nodejs%{NODEJS_MAJOR}%{?1:-%{1}}\
|
||||
}
|
||||
%else
|
||||
%define unversioned_obsoletes_of_nodejsXX_if_default() %{nil}
|
||||
%endif
|
||||
|
||||
%if %{with bundled}
|
||||
@ -314,6 +325,9 @@ Provides: bundled(histogram) = %{histogram_version}
|
||||
Provides: bundled(ada) = {{ ADA_VERSION }}
|
||||
{% endif %}
|
||||
|
||||
%unversioned_obsoletes_of_nodejsXX_if_default
|
||||
|
||||
|
||||
%description
|
||||
Node.js is a platform built on Chrome's JavaScript runtime \
|
||||
for easily building fast, scalable network applications. \
|
||||
@ -351,6 +365,7 @@ Requires: libuv-devel%{?_isa}
|
||||
%if 0%{?nodejs_default}
|
||||
Provides: nodejs-devel = %{nodejs_envr}
|
||||
%endif
|
||||
%unversioned_obsoletes_of_nodejsXX_if_default devel
|
||||
|
||||
Provides: nodejs-devel-pkg = %{nodejs_envr}
|
||||
Conflicts: nodejs-devel-pkg
|
||||
@ -380,6 +395,7 @@ Provides: v8%{?_isa} = %{v8_epoch}:%{v8_version}-%{nodejs_release}
|
||||
Obsoletes: v8 < 1:6.7.17-10
|
||||
|
||||
Provides: nodejs-libs = %{nodejs_envr}
|
||||
%unversioned_obsoletes_of_nodejsXX_if_default libs
|
||||
|
||||
%description -n %{pkgname}-libs
|
||||
Libraries to support Node.js and provide stable v8 interfaces.
|
||||
@ -389,6 +405,8 @@ Libraries to support Node.js and provide stable v8 interfaces.
|
||||
Summary: Non-English locale data for Node.js
|
||||
Requires: %{pkgname}%{?_isa} = %{nodejs_envr}
|
||||
|
||||
%unversioned_obsoletes_of_nodejsXX_if_default full-i18n
|
||||
|
||||
|
||||
%description -n %{pkgname}-full-i18n
|
||||
Optional data files to provide full-icu support for Node.js. Remove this
|
||||
@ -437,6 +455,7 @@ Provides: npm = %{npm_envr}
|
||||
# Obsolete the old 'npm' package
|
||||
Obsoletes: npm < 1:9
|
||||
%endif
|
||||
%unversioned_obsoletes_of_nodejsXX_if_default npm
|
||||
|
||||
|
||||
%description -n %{pkgname}-npm
|
||||
@ -451,6 +470,7 @@ BuildArch: noarch
|
||||
Requires(meta): %{pkgname} = %{nodejs_envr}
|
||||
|
||||
Provides: nodejs-docs = %{nodejs_envr}
|
||||
%unversioned_obsoletes_of_nodejsXX_if_default docs
|
||||
|
||||
|
||||
%description -n %{pkgname}-docs
|
||||
|
Loading…
Reference in New Issue
Block a user