diff mbox series

[1/1] package/p7zip: add 7za support

Message ID 20211013192038.1876922-1-fontaine.fabrice@gmail.com
State Superseded
Headers show
Series [1/1] package/p7zip: add 7za support | expand

Commit Message

Fabrice Fontaine Oct. 13, 2021, 7:20 p.m. UTC
Add 7za stand-alone executable as 7zr is a "light-version" of 7za that
only handles 7z archives and cannot handle encrypted archives.

Fixes:
 - https://bugs.buildroot.org/show_bug.cgi?id=14266

Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
---
 package/p7zip/p7zip.mk | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

Comments

Arnout Vandecappelle Oct. 25, 2021, 6:52 p.m. UTC | #1
On 13/10/2021 21:20, Fabrice Fontaine wrote:
> Add 7za stand-alone executable as 7zr is a "light-version" of 7za that
> only handles 7z archives and cannot handle encrypted archives.
> 
> Fixes:
>   - https://bugs.buildroot.org/show_bug.cgi?id=14266
> 
> Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
> ---
>   package/p7zip/p7zip.mk | 3 ++-
>   1 file changed, 2 insertions(+), 1 deletion(-)
> 
> diff --git a/package/p7zip/p7zip.mk b/package/p7zip/p7zip.mk
> index f94b55ecd2..a363a2ac1d 100644
> --- a/package/p7zip/p7zip.mk
> +++ b/package/p7zip/p7zip.mk
> @@ -17,10 +17,11 @@ define P7ZIP_BUILD_CMDS
>   	$(TARGET_MAKE_ENV) $(MAKE) CC="$(TARGET_CC)" ALLFLAGS_C="$(TARGET_CFLAGS)" \
>   		CXX="$(TARGET_CXX)" ALLFLAGS_CPP="$(TARGET_CXXFLAGS)" \
>   		LDFLAGS="$(TARGET_LDFLAGS)" \
> -		-C $(@D) 7zr
> +		-C $(@D) 7za 7zr
>   endef
>   
>   define P7ZIP_INSTALL_TARGET_CMDS
> +	$(INSTALL) -D -m 0755 $(@D)/bin/7za $(TARGET_DIR)/usr/bin/7za
>   	$(INSTALL) -D -m 0755 $(@D)/bin/7zr $(TARGET_DIR)/usr/bin/7zr

  I did a build for aarch64; 7za is 2.6MB, 7zr is 800K. I think that difference 
is big enough to warrant making the build/install of 7za optional.

  Also, apparently 7zr is a subset of 7za, so does it ever make sense to install 
them both?

  Regards,
  Arnout

>   endef
>   
>
diff mbox series

Patch

diff --git a/package/p7zip/p7zip.mk b/package/p7zip/p7zip.mk
index f94b55ecd2..a363a2ac1d 100644
--- a/package/p7zip/p7zip.mk
+++ b/package/p7zip/p7zip.mk
@@ -17,10 +17,11 @@  define P7ZIP_BUILD_CMDS
 	$(TARGET_MAKE_ENV) $(MAKE) CC="$(TARGET_CC)" ALLFLAGS_C="$(TARGET_CFLAGS)" \
 		CXX="$(TARGET_CXX)" ALLFLAGS_CPP="$(TARGET_CXXFLAGS)" \
 		LDFLAGS="$(TARGET_LDFLAGS)" \
-		-C $(@D) 7zr
+		-C $(@D) 7za 7zr
 endef
 
 define P7ZIP_INSTALL_TARGET_CMDS
+	$(INSTALL) -D -m 0755 $(@D)/bin/7za $(TARGET_DIR)/usr/bin/7za
 	$(INSTALL) -D -m 0755 $(@D)/bin/7zr $(TARGET_DIR)/usr/bin/7zr
 endef