From 3e1ed97187f4e8ac857998865bb3cc4b5e3ff4d3 Mon Sep 17 00:00:00 2001 From: Philip Rideout Date: Mon, 13 May 2019 13:04:02 -0700 Subject: [PATCH] Add QUIET to find_package with embree, etc. --- README.md | 7 ++++++- build/linux/ci-common.sh | 9 +++++++++ libs/gltfio/CMakeLists.txt | 4 +++- 3 files changed, 18 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 30534ada04..71b9709a7c 100644 --- a/README.md +++ b/README.md @@ -127,7 +127,7 @@ and tools. - `filamat`: Material generation library - `filameshio`: Tiny filamesh parsing library (see also `tools/filamesh`) - `geometry`: Mesh-related utilities - - `gltfio`: Loader for glTF 2.0 + - `gltfio`: Loader and optional pipeline for glTF 2.0 - `ibl`: IBL generation tools - `image`: Image filtering and simple transforms - `imageio`: Image file reading / writing, only intended for internal use @@ -170,6 +170,11 @@ To build the Java based components of the project you can optionally install (re Additional dependencies may be required for your operating system. Please refer to the appropriate section below. +Building the light baking pipeline is optional and requires the following packages: + +- embree 3.0+ +- libtbb-dev + To build Filament for Android you must also install the following: - Android Studio 3.3 diff --git a/build/linux/ci-common.sh b/build/linux/ci-common.sh index dc03b6b1f8..a851a54962 100755 --- a/build/linux/ci-common.sh +++ b/build/linux/ci-common.sh @@ -80,6 +80,15 @@ if [[ "$KOKORO_BUILD_ID" ]]; then (cd projects/libcxx && sudo make -j install) (cd projects/libcxxabi && sudo make -j install) + # install embree 3+ to test buildability of the light baking pipeline + sudo apt-get install -y alien libtbb-dev + curl -LO https://github.com/embree/embree/releases/download/v3.5.2/embree-3.5.2.x86_64.rpm.tar.gz + tar xzf embree-3.5.2.x86_64.rpm.tar.gz + sudo alien embree3-devel-3.5.2-1.noarch.rpm + sudo alien embree3-lib-3.5.2-1.x86_64.rpm + sudo dpkg -i embree3-lib_3.5.2-2_amd64.deb + sudo dpkg -i embree3-devel_3.5.2-2_all.deb + cd ../.. export LD_LIBRARY_PATH=/usr/local/lib:$LD_LIBRARY_PATH diff --git a/libs/gltfio/CMakeLists.txt b/libs/gltfio/CMakeLists.txt index 9a412529ec..93dfdf6f66 100644 --- a/libs/gltfio/CMakeLists.txt +++ b/libs/gltfio/CMakeLists.txt @@ -112,10 +112,12 @@ add_library(gltfio_resources ${DUMMY_SRC} ${RESGEN_SOURCE}) # This is an optional dependency and can be installed with homebrew, apt-get, etc. # ================================================================================================== -find_package(embree 3.0) +find_package(embree 3.0 QUIET PATHS /usr/lib64/cmake) if (embree_FOUND) message("Found embree in ${embree_DIR}") add_definitions(-DFILAMENT_HAS_EMBREE) +else() + message("Embree not found, pipeline features are disabled.") endif() # ==================================================================================================