Implement gst-wrapper to the patcher

This commit is contained in:
AlexPresso
2022-06-01 20:06:47 +02:00
parent 883454ad5b
commit 87da46d3cd
3 changed files with 8 additions and 3 deletions

View File

@@ -23,7 +23,7 @@ function info() {
}
function handle_error() {
log "ERROR" "Error on line $(caller) for command "
log "ERROR" "Error on line $(caller)"
endprocess
}

View File

@@ -23,7 +23,7 @@ function info() {
}
function handle_error() {
log "ERROR" "Error on line $(caller)}"
log "ERROR" "Error on line $(caller) "
endprocess
}

View File

@@ -84,6 +84,11 @@ function patch() {
ln -s -f "$vs_path/bin/ffmpeg" "$cp_bin_path/$filename"
fi
done
info "Patching CodecPack's gst-launch-1.0"
mv -n "$cp_bin_path/gst-launch-1.0" "$cp_bin_path/gst-launch-1.0.orig"
wget -q -O - "$repo_base_url/blob/$branch/gst-wrapper.sh?raw=true" > "$cp_bin_path/gst-launch-1.0"
chmod a+xr "$cp_bin_path/gst-launch-1.0"
fi
info "Saving current libsynovte.so as libsynovte.so.orig"
@@ -109,7 +114,7 @@ function unpatch() {
mv -f "$vs_path/bin/ffmpeg.orig" "$vs_path/bin/ffmpeg"
if [[ -d $cp_bin_path ]]; then
find $cp_bin_path -type f -name "ffmpeg*.orig" | while read filename; do
find $cp_bin_path -type f -name "*.orig" | while read filename; do
info "Restoring CodecPack's $filename"
mv -T -f "$filename" "${filename::-5}"
done