[PATCH] rpm2cpio: allow building with rpm disabled

Ron Yorston rmy at pobox.com
Tue Aug 22 09:57:22 UTC 2017


With rpm disabled and rpm2cpio enabled the build fails because the
symbol ARCHIVE_REPLACE_VIA_RENAME isn't defined.

Signed-off-by: Ron Yorston <rmy at pobox.com>
---
 archival/rpm.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/archival/rpm.c b/archival/rpm.c
index c24cfdf41..d779f0d90 100644
--- a/archival/rpm.c
+++ b/archival/rpm.c
@@ -110,7 +110,7 @@ static void extract_cpio(int fd, const char *source_rpm)
 		 * try "rpm -i foo.src.rpm" few times in a row -
 		 * standard rpm will not complain.
 		 */
-		| ARCHIVE_REPLACE_VIA_RENAME;
+		IF_RPM(| ARCHIVE_REPLACE_VIA_RENAME);
 	archive_handle->src_fd = fd;
 	/*archive_handle->offset = 0; - init_handle() did it */
 
-- 
2.13.5



More information about the busybox mailing list