diff --git a/README.html b/README.html
index 50f2f5c..74a78a2 100644
--- a/README.html
+++ b/README.html
@@ -257,10 +257,16 @@ libplist 2.0 or later. (This means Debian 10 “Buster” based systems
(e.g, Ubuntu 18.04) or newer; on Debian 10 systems “libplist” is an
older version, you need “libplist3”.) If it does not, you may need to
build and install these from source (see instructions at the end of this
-README). If you have a non-standard OpenSSL installation, you may need
-to set the environment variable OPENSSL_ROOT_DIR (e.g. ,
+README).
+If you have a non-standard OpenSSL installation, you may need to set
+the environment variable OPENSSL_ROOT_DIR (e.g. ,
“export OPENSSL_ROOT_DIR=/usr/local/lib64” if that is where
-it is installed).
+it is installed). Similarly, for non-standard (or multiple) GStreamer
+installations, set the environment variable GSTREAMER_ROOT_DIR to the
+directory that contains the “…/gstreamer-1.0/” directory of the
+gstreamer installation that UxPlay should use (if this is e.g.
+“~/my_gstreamer/lib/gstreamer-1.0/”, set this location with
+“export GSTREAMER_ROOT_DIR=$HOME/my_gstreamer/lib”).
- Most users will use the GStreamer supplied by their distribution,
but a few (in particular users of Raspberry Pi OS Lite Legacy (Buster)
diff --git a/README.md b/README.md
index a12b6cf..f4f1576 100644
--- a/README.md
+++ b/README.md
@@ -210,9 +210,16 @@ Make sure that your distribution provides OpenSSL 1.1.1 or later, and
libplist 2.0 or later. (This means Debian 10 "Buster" based systems (e.g, Ubuntu 18.04) or newer;
on Debian 10 systems "libplist" is an older version, you need "libplist3".) If it does
not, you may need to build and install these from
-source (see instructions at the end of this README). If you have a non-standard OpenSSL
+source (see instructions at the end of this README).
+
+If you have a non-standard OpenSSL
installation, you may need to set the environment variable OPENSSL_ROOT_DIR
(_e.g._ , "`export OPENSSL_ROOT_DIR=/usr/local/lib64`" if that is where it is installed).
+Similarly, for non-standard (or multiple) GStreamer installations, set the
+environment variable GSTREAMER_ROOT_DIR to the directory that contains the
+".../gstreamer-1.0/" directory of the gstreamer installation that UxPlay should use
+(if this is _e.g._ "~/my_gstreamer/lib/gstreamer-1.0/", set this location
+with "`export GSTREAMER_ROOT_DIR=$HOME/my_gstreamer/lib`").
* Most users will use the GStreamer supplied by their distribution, but a few (in particular users
of Raspberry Pi OS Lite Legacy (Buster) on a Raspberry Pi model 4B who wish to stay on that
diff --git a/README.txt b/README.txt
index b619edb..8320e8e 100644
--- a/README.txt
+++ b/README.txt
@@ -257,10 +257,17 @@ libplist 2.0 or later. (This means Debian 10 "Buster" based systems
(e.g, Ubuntu 18.04) or newer; on Debian 10 systems "libplist" is an
older version, you need "libplist3".) If it does not, you may need to
build and install these from source (see instructions at the end of this
-README). If you have a non-standard OpenSSL installation, you may need
-to set the environment variable OPENSSL_ROOT_DIR (*e.g.* ,
+README).
+
+If you have a non-standard OpenSSL installation, you may need to set the
+environment variable OPENSSL_ROOT_DIR (*e.g.* ,
"`export OPENSSL_ROOT_DIR=/usr/local/lib64`" if that is where it is
-installed).
+installed). Similarly, for non-standard (or multiple) GStreamer
+installations, set the environment variable GSTREAMER_ROOT_DIR to the
+directory that contains the ".../gstreamer-1.0/" directory of the
+gstreamer installation that UxPlay should use (if this is *e.g.*
+"\~/my_gstreamer/lib/gstreamer-1.0/", set this location with
+"`export GSTREAMER_ROOT_DIR=$HOME/my_gstreamer/lib`").
- Most users will use the GStreamer supplied by their distribution,
but a few (in particular users of Raspberry Pi OS Lite Legacy
diff --git a/renderers/CMakeLists.txt b/renderers/CMakeLists.txt
index 72c73d3..97cf992 100644
--- a/renderers/CMakeLists.txt
+++ b/renderers/CMakeLists.txt
@@ -9,6 +9,12 @@ if (APPLE )
find_program( PKG_CONFIG_EXECUTABLE pkg-config PATHS /Library/FrameWorks/GStreamer.framework/Commands )
set(PKG_CONFIG_EXECUTABLE ${PKG_CONFIG_EXECUTABLE} --define-prefix )
else()
+ if ( DEFINED ENV{GSTREAMER_ROOT_DIR} )
+ if ( EXISTS "$ENV{GSTREAMER_ROOT_DIR}/pkgconfig" )
+ message ( STATUS "*** Using GSTREAMER_ROOT_DIR = " $ENV{GSTREAMER_ROOT_DIR} )
+ set( ENV{PKG_CONFIG_PATH} "$ENV{GSTREAMER_ROOT_DIR}/pkgconfig:$ENV{PKG_CONFIG_PATH}" )
+ endif()
+ endif()
set( ENV{PKG_CONFIG_PATH} "$ENV{PKG_CONFIG_PATH}:/usr/local/lib/pkgconfig" ) # standard location for self-installed gstreamer
endif()