Use the %{buildroot} macro

Signed-off-by: Ondrej Mosnáček <omosnacek@gmail.com>
This commit is contained in:
Ondrej Mosnáček 2023-09-05 12:40:07 +02:00
parent e6ed279ca1
commit bf66d963d8
No known key found for this signature in database
GPG Key ID: BDE08B7A0C57B343

View File

@ -62,28 +62,28 @@ package to grow the root partition on first boot.
%install %install
# Create the target directories # Create the target directories
mkdir -p $RPM_BUILD_ROOT/%{_bindir} mkdir -p %{buildroot}%{_bindir}
mkdir -p $RPM_BUILD_ROOT/%{_mandir}/man1 mkdir -p %{buildroot}%{_mandir}/man1
%if %{BuildMainPackage} %if %{BuildMainPackage}
# Install binaries and manpages # Install binaries and manpages
cp bin/* $RPM_BUILD_ROOT/%{_bindir}/ cp bin/* %{buildroot}%{_bindir}/
cp man/* $RPM_BUILD_ROOT/%{_mandir}/man1/ cp man/* %{buildroot}%{_mandir}/man1/
# Exclude Ubuntu-specific tools # Exclude Ubuntu-specific tools
rm $RPM_BUILD_ROOT/%{_bindir}/*ubuntu* rm %{buildroot}%{_bindir}/*ubuntu*
# Exclude the cloud-run-instances manpage # Exclude the cloud-run-instances manpage
rm -f $RPM_BUILD_ROOT/%{_mandir}/man1/cloud-run-instances.* rm -f %{buildroot}%{_mandir}/man1/cloud-run-instances.*
# Exclude euca2ools wrappers and manpages # Exclude euca2ools wrappers and manpages
rm -f $RPM_BUILD_ROOT/%{_bindir}/cloud-publish-* rm -f %{buildroot}%{_bindir}/cloud-publish-*
rm -f $RPM_BUILD_ROOT/%{_mandir}/man1/cloud-publish-* rm -f %{buildroot}%{_mandir}/man1/cloud-publish-*
%endif %endif
# Install the growpart binary and man page # Install the growpart binary and man page
cp bin/growpart $RPM_BUILD_ROOT/%{_bindir}/ cp bin/growpart %{buildroot}%{_bindir}/
cp man/growpart.* $RPM_BUILD_ROOT/%{_mandir}/man1/ cp man/growpart.* %{buildroot}%{_mandir}/man1/
# Files for the main package # Files for the main package