By the time we get to the end of the %install section, all the
built binaries have been installed in the build root, so we can
delete the build directory from the source tree. This frees up
about 17GB of disk space on build hosts, which is helpful in
case other processes later in the RPM build need more disk space.
Fixes: https://tracker.ceph.com/issues/55079
Signed-off-by: Tim Serong <tserong@suse.com>
(cherry picked from commit
aa18cb12003e3526c8e8f23dc2335a483fbfa68e)
%py_byte_compile %{__python3} %{buildroot}%{python3_sitelib}
%endif
+# built binaries are no longer necessary at this point,
+# but are consuming ~17GB of disk in the build environment
+rm -rf %{_vpath_builddir}
+
%clean
rm -rf %{buildroot}