Reputation: 13
I’m trying to create a meta-package in CentOS 8 that installs vim and nano.
I built rpm-package via spec file. The spec file:
Summary: It's just a test meta_package
Version: 0.1
Release: 1
Group: Applications/Internet
License: GPL
BuildArch: noarch
Requires: nano, vim
%description
A test meta_package.
%prep
%build
%install
%clean
%post
yum install -y nano
yum install -y vim
%files
%defattr(-,root,root)
%changelog
Building
rpmbuild --bb meta_package.spec
Then I launch it like
rpm -I meta_package-0.1-1.noarch.rpm
But packages haven’t been installed. Is there any possible solution to that?
Upvotes: 0
Views: 774
Reputation: 9845
For meta-packages, you must not specify dependencies in the %post
section.
You simply specify them with Requires:
tag. Example:
Requires: nano
Requires: vim-enhanced
Then use a package manager like yum
or dnf
to satisfy dependencies at install time.
Upvotes: 1