From bf66d963d8781c96eb2da392e6fd2a0397c038b7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ondrej=20Mosn=C3=A1=C4=8Dek?= Date: Tue, 5 Sep 2023 12:40:07 +0200 Subject: [PATCH] Use the %{buildroot} macro MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Ondrej Mosnáček --- cloud-utils.spec | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) diff --git a/cloud-utils.spec b/cloud-utils.spec index bd6f91a..a7800e4 100644 --- a/cloud-utils.spec +++ b/cloud-utils.spec @@ -62,28 +62,28 @@ package to grow the root partition on first boot. %install # Create the target directories -mkdir -p $RPM_BUILD_ROOT/%{_bindir} -mkdir -p $RPM_BUILD_ROOT/%{_mandir}/man1 +mkdir -p %{buildroot}%{_bindir} +mkdir -p %{buildroot}%{_mandir}/man1 %if %{BuildMainPackage} # Install binaries and manpages -cp bin/* $RPM_BUILD_ROOT/%{_bindir}/ -cp man/* $RPM_BUILD_ROOT/%{_mandir}/man1/ +cp bin/* %{buildroot}%{_bindir}/ +cp man/* %{buildroot}%{_mandir}/man1/ # Exclude Ubuntu-specific tools -rm $RPM_BUILD_ROOT/%{_bindir}/*ubuntu* +rm %{buildroot}%{_bindir}/*ubuntu* # 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 -rm -f $RPM_BUILD_ROOT/%{_bindir}/cloud-publish-* -rm -f $RPM_BUILD_ROOT/%{_mandir}/man1/cloud-publish-* +rm -f %{buildroot}%{_bindir}/cloud-publish-* +rm -f %{buildroot}%{_mandir}/man1/cloud-publish-* %endif # Install the growpart binary and man page -cp bin/growpart $RPM_BUILD_ROOT/%{_bindir}/ -cp man/growpart.* $RPM_BUILD_ROOT/%{_mandir}/man1/ +cp bin/growpart %{buildroot}%{_bindir}/ +cp man/growpart.* %{buildroot}%{_mandir}/man1/ # Files for the main package