build: allow GSTREAMER_ROOT to be set manually

This commit is contained in:
Joshua M. Doe
2017-09-26 09:28:29 -04:00
parent 9ffda399d9
commit 4e24b69eaa
5 changed files with 30 additions and 20 deletions

View File

@@ -28,10 +28,12 @@ IF (NOT WIN32)
SET(GOBJECT_DEFINITIONS ${PKG_GOBJECT2_CFLAGS})
ENDIF (NOT WIN32)
if (CMAKE_SIZEOF_VOID_P MATCHES "8")
set(GSTREAMER_ROOT $ENV{GSTREAMER_1_0_ROOT_X86_64})
else ()
set(GSTREAMER_ROOT $ENV{GSTREAMER_1_0_ROOT_X86})
if (NOT GSTREAMER_ROOT)
if (CMAKE_SIZEOF_VOID_P MATCHES "8")
set(GSTREAMER_ROOT $ENV{GSTREAMER_1_0_ROOT_X86_64})
else ()
set(GSTREAMER_ROOT $ENV{GSTREAMER_1_0_ROOT_X86})
endif ()
endif ()
FIND_PATH(GOBJECT_INCLUDE_DIR gobject/gobject.h