mirror of
https://gitlab.freedesktop.org/pipewire/wireplumber.git
synced 2026-02-04 13:10:29 +01:00
Add a wp-uninstalled.sh script for easily running programs uninstalled
Similar to pw-uninstalled.sh, but without an interactive shell
This commit is contained in:
parent
c2834ea344
commit
3b144fa9ca
1 changed files with 42 additions and 0 deletions
42
wp-uninstalled.sh
Executable file
42
wp-uninstalled.sh
Executable file
|
|
@ -0,0 +1,42 @@
|
|||
#!/usr/bin/env bash
|
||||
|
||||
set -e
|
||||
|
||||
SCRIPT_DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" >/dev/null 2>&1 && pwd )"
|
||||
BUILDDIR=${SCRIPT_DIR}/build
|
||||
CONFIGDIR=config
|
||||
|
||||
while getopts ":b:c:" opt; do
|
||||
case ${opt} in
|
||||
b)
|
||||
BUILDDIR=${OPTARG}
|
||||
shift 2
|
||||
;;
|
||||
c)
|
||||
CONFIGDIR=${OPTARG}
|
||||
;;
|
||||
\?)
|
||||
echo "Invalid option: -${OPTARG}"
|
||||
exit -1
|
||||
;;
|
||||
:)
|
||||
echo "Option -${OPTARG} requires an argument"
|
||||
exit -1
|
||||
;;
|
||||
esac
|
||||
done
|
||||
|
||||
shift $((OPTIND-1))
|
||||
|
||||
if [ ! -d ${BUILDDIR} ]; then
|
||||
echo "Invalid build directory: ${BUILDDIR}"
|
||||
exit -1
|
||||
fi
|
||||
|
||||
export WIREPLUMBER_MODULE_DIR="${BUILDDIR}/modules"
|
||||
export WIREPLUMBER_CONFIG_DIR="${SCRIPT_DIR}/src/${CONFIGDIR}"
|
||||
export WIREPLUMBER_DATA_DIR="${SCRIPT_DIR}/src"
|
||||
export PATH="${BUILDDIR}/src:${BUILDDIR}/src/tools:$PATH"
|
||||
export LD_LIBRARY_PATH="${BUILDDIR}/lib/wp:$LD_LIBRARY_PATH"
|
||||
|
||||
exec $@
|
||||
Loading…
Add table
Reference in a new issue