From 9972c1001b44179fb5655ec1bc52fa74a87e7d56 Mon Sep 17 00:00:00 2001 From: Walter Pearce Date: Mon, 27 Nov 2017 10:15:13 -0800 Subject: [PATCH] Fixed: texturev build failed requiring examples-common; moved BGFX_EXAMPLES check to examples instead of globally. Updated: bgfx, bx, bimg to latest Fixed: bx now requires including 3rdparty for build --- CMakeLists.txt | 4 +- bgfx | 2 +- bimg | 2 +- bx | 2 +- cmake/bx.cmake | 2 +- cmake/examples.cmake | 91 +++++++++++++++++++++++--------------------- 6 files changed, 52 insertions(+), 51 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index 6a0e13a..ea83734 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -51,9 +51,7 @@ if( BGFX_BUILD_TOOLS ) include( cmake/tools.cmake ) endif() -if( BGFX_BUILD_EXAMPLES ) - include( cmake/examples.cmake ) -endif() +include( cmake/examples.cmake ) if( BGFX_INSTALL ) # install bx diff --git a/bgfx b/bgfx index cdd658b..b3fcc83 160000 --- a/bgfx +++ b/bgfx @@ -1 +1 @@ -Subproject commit cdd658b44c4f87d6d6d179282f3c17aab206f3f8 +Subproject commit b3fcc8350b742c55ba35ac8be4db841015b96a9f diff --git a/bimg b/bimg index 224aa80..886ba55 160000 --- a/bimg +++ b/bimg @@ -1 +1 @@ -Subproject commit 224aa80d10ae11cd6b98e12651109ebcc979e2f1 +Subproject commit 886ba55a25db213719c96116f9eabb188b946571 diff --git a/bx b/bx index 4b4b3e7..6a1b91c 160000 --- a/bx +++ b/bx @@ -1 +1 @@ -Subproject commit 4b4b3e74db9281c90f5c190a7670444ad523f51b +Subproject commit 6a1b91cbbff154d15d7f3d3cb23de28cf054d387 diff --git a/cmake/bx.cmake b/cmake/bx.cmake index 1c18fe6..257880c 100644 --- a/cmake/bx.cmake +++ b/cmake/bx.cmake @@ -35,7 +35,7 @@ if( WIN32 ) endif() # Add include directory of bx -target_include_directories( bx PUBLIC ${BX_DIR}/include ) +target_include_directories( bx PUBLIC ${BX_DIR}/include ${BX_DIR}/3rdparty ) # Build system specific configurations if( MSVC ) diff --git a/cmake/examples.cmake b/cmake/examples.cmake index 15e7b14..b51aede 100755 --- a/cmake/examples.cmake +++ b/cmake/examples.cmake @@ -156,48 +156,51 @@ add_example( ${BGFX_DIR}/examples/common/ps ) -# Add examples -set( - BGFX_EXAMPLES - 00-helloworld - 01-cubes - 02-metaballs - 03-raymarch - 04-mesh - 05-instancing - 06-bump - 07-callback - 08-update - 09-hdr - 10-font - 11-fontsdf - 12-lod - 13-stencil - 14-shadowvolumes - 15-shadowmaps-simple - 16-shadowmaps - 17-drawstress - 18-ibl - 19-oit - 20-nanovg - 21-deferred - 22-windows - 23-vectordisplay - 24-nbody - 25-c99 - 26-occlusion - 27-terrain - 28-wireframe - 29-debugdraw - 30-picking - 31-rsm - 32-particles - 33-pom - 34-mvs - 35-dynamic - 36-sky -) +# Only add examples if set, otherwise we still need exmaples common for tools +if( BGFX_BUILD_EXAMPLES ) + # Add examples + set( + BGFX_EXAMPLES + 00-helloworld + 01-cubes + 02-metaballs + 03-raymarch + 04-mesh + 05-instancing + 06-bump + 07-callback + 08-update + 09-hdr + 10-font + 11-fontsdf + 12-lod + 13-stencil + 14-shadowvolumes + 15-shadowmaps-simple + 16-shadowmaps + 17-drawstress + 18-ibl + 19-oit + 20-nanovg + 21-deferred + 22-windows + 23-vectordisplay + 24-nbody + 25-c99 + 26-occlusion + 27-terrain + 28-wireframe + 29-debugdraw + 30-picking + 31-rsm + 32-particles + 33-pom + 34-mvs + 35-dynamic + 36-sky + ) -foreach( EXAMPLE ${BGFX_EXAMPLES} ) - add_example( ${EXAMPLE} ) -endforeach() + foreach( EXAMPLE ${BGFX_EXAMPLES} ) + add_example( ${EXAMPLE} ) + endforeach() +endif() \ No newline at end of file