From 22fca1de888bb5a50d6a414da0a5079e78abc791 Mon Sep 17 00:00:00 2001 From: WXbet Date: Fri, 16 Oct 2020 13:24:33 +0200 Subject: [PATCH] Add patchelf functionality --- support/functions/_cmd_build | 7 +++++++ support/functions/_gui_build | 10 +++++++++- support/functions/_sys_check | 2 +- 3 files changed, 17 insertions(+), 2 deletions(-) diff --git a/support/functions/_cmd_build b/support/functions/_cmd_build index 6692d20..5039d1a 100644 --- a/support/functions/_cmd_build +++ b/support/functions/_cmd_build @@ -234,6 +234,13 @@ fi #show build time printf "$g_n""\n TIME -------> $bt$re_\n\n" +#patchelf + if [ -n "$_patchelf" ] + then + printf "$w_l"" ENABLE -----> PATCHELF:$y_l $_patchelf...\n" + eval "patchelf "$_patchelf" "$bdir/$oscam_name"" + fi; + #compress cam if [ "${s3cfg_vars[COMPRESS]}" == "1" ] then diff --git a/support/functions/_gui_build b/support/functions/_gui_build index 217dbdd..58321ec 100644 --- a/support/functions/_gui_build +++ b/support/functions/_gui_build @@ -126,9 +126,17 @@ _gui_build(){ then rm "$bdir/$oscam_name.debug" printf "\n $txt_delete $oscam_name.debug\n"|tee -a "$ldir/$log_name" - fi;) | "$gui" "$st_" --colors --title " -[ Build ]- " "$pb_" "$_lines" "$_cols" + fi; sleep 2 +#patchelf + if [ -n "$_patchelf" ] + then + printf "\n patchelf $_patchelf\n"|tee -a "$ldir/$log_name" + eval "patchelf "$_patchelf" "$bdir/$oscam_name"" + fi;) | "$gui" "$st_" --colors --title " -[ Build ]- " "$pb_" "$_lines" "$_cols" + sleep 1 + #COMPRESS if [ ! "$stapi_allowed" == "1" ] then diff --git a/support/functions/_sys_check b/support/functions/_sys_check index 20354cf..077d3be 100644 --- a/support/functions/_sys_check +++ b/support/functions/_sys_check @@ -131,7 +131,7 @@ then fi unset binvars; unset headervars; unset libvars; -[ -z ${3+x} ] && binvars=( dialog grep gawk wget tar bzip2 svn xz upx patch gcc make scp sshpass openssl dos2unix ) || binvars=( $(echo "$3" | tr ' ' '\n') ) +[ -z ${3+x} ] && binvars=( dialog grep gawk wget tar bzip2 svn xz upx patch gcc make scp sshpass openssl dos2unix patchelf) || binvars=( $(echo "$3" | tr ' ' '\n') ) [ -z ${4+x} ] && headervars=( crypto.h libusb.h pcsclite.h pthread.h ) || headervars=( $(echo "$4" | tr ' ' '\n') ) [ -z ${5+x} ] && libvars=( libccidtwin.so ) || libvars=( $(echo "$5" | tr ' ' '\n') ) sanity=1