From 90d7aed63a750d579540cf84580c3d03b975d769 Mon Sep 17 00:00:00 2001
From: Maxim Cournoyer <maxim.cournoyer@savoirfairelinux.com>
Date: Tue, 9 Mar 2021 11:05:16 -0500
Subject: [PATCH] scripts: Do not hard-code /bin/bash.

Instead, use Bash from PATH.  This approach works universally, even in
environments not strictly adhering to the File Hierarchy
Standard (FHS).

Change-Id: I852c5f4bba3a1bee9b895dcb5da24e5738c4186a
---
 autogen.sh                                   | 2 +-
 bin/jni/make-swig.sh                         | 2 +-
 contrib/src/ffmpeg/windows-configure-make.sh | 4 ++--
 tools/update-copyright                       | 2 +-
 4 files changed, 5 insertions(+), 5 deletions(-)

diff --git a/autogen.sh b/autogen.sh
index b0d9083087..74e170cfe1 100755
--- a/autogen.sh
+++ b/autogen.sh
@@ -1,4 +1,4 @@
-#!/bin/bash
+#!/usr/bin/env bash
 
 AUTORECONF=`which autoreconf`
 if test -z $AUTORECONF; then
diff --git a/bin/jni/make-swig.sh b/bin/jni/make-swig.sh
index 205c86d78b..8392c707fa 100755
--- a/bin/jni/make-swig.sh
+++ b/bin/jni/make-swig.sh
@@ -1,4 +1,4 @@
-#!/bin/bash -
+#!/usr/bin/env bash
 #
 #  Copyright (C) 2004-2021 Savoir-faire Linux Inc.
 #
diff --git a/contrib/src/ffmpeg/windows-configure-make.sh b/contrib/src/ffmpeg/windows-configure-make.sh
index 15fb2ef573..794e1371e0 100644
--- a/contrib/src/ffmpeg/windows-configure-make.sh
+++ b/contrib/src/ffmpeg/windows-configure-make.sh
@@ -1,4 +1,4 @@
-#!/bin/bash
+#!/usr/bin/env bash
 set +x
 set +e
 DIR=$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )
@@ -200,4 +200,4 @@ set -x
 set -e
 ../../../configure $FFMPEGCONF --extra-cflags="${EXTRACFLAGS}" --extra-ldflags="${EXTRALDFLAGS}" --prefix="${PREFIX}"
 make -j8 install
-cd ../../..
\ No newline at end of file
+cd ../../..
diff --git a/tools/update-copyright b/tools/update-copyright
index 0547f2cb17..e4ebcd0b16 100755
--- a/tools/update-copyright
+++ b/tools/update-copyright
@@ -1,4 +1,4 @@
-#!/bin/bash
+#!/usr/bin/env bash
 
 # Copyright (C) 2004-2021 Savoir-faire Linux Inc.
 #
-- 
GitLab