Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 6 additions & 6 deletions .github/workflows/continuous_integration.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ jobs:
key: ubuntu-22-${{ matrix.cmake_build_type }}-${{ matrix.compiler.cc }}-${{matrix.compiler.cxx}}
- run: ./update_glslang_sources.py
- name: Configure
run: cmake -S . -B build -D CMAKE_BUILD_TYPE=${{ matrix.cmake_build_type }} -DBUILD_WERROR=ON -D GLSLANG_TESTS=ON
run: cmake -S . -B build -D CMAKE_BUILD_TYPE=${{ matrix.cmake_build_type }} -DGLSLANG_BUILD_WERROR=ON -D GLSLANG_TESTS=ON
env:
CC: ${{matrix.compiler.cc}}
CXX: ${{matrix.compiler.cxx}}
Expand Down Expand Up @@ -61,7 +61,7 @@ jobs:
key: ubuntu-22-${{ matrix.cmake_build_type }}-${{ matrix.compiler.cc }}-${{matrix.compiler.cxx}}
- run: ./update_glslang_sources.py
- name: Configure
run: cmake -S . -B build -D CMAKE_BUILD_TYPE=${{ matrix.cmake_build_type }} -DBUILD_WERROR=ON -D GLSLANG_TESTS=ON -DBUILD_SHARED_LIBS=ON
run: cmake -S . -B build -D CMAKE_BUILD_TYPE=${{ matrix.cmake_build_type }} -DGLSLANG_BUILD_WERROR=ON -D GLSLANG_TESTS=ON -DBUILD_SHARED_LIBS=ON
env:
CC: ${{matrix.compiler.cc}}
CXX: ${{matrix.compiler.cxx}}
Expand Down Expand Up @@ -163,7 +163,7 @@ jobs:
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
- uses: lukka/get-cmake@57c20a23a6cac5b90f31864439996e5b206df9dc # v4.0.1
- run: ./update_glslang_sources.py
- run: cmake -S . -B build -D CMAKE_BUILD_TYPE=${{matrix.cmake_build_type}} -G Ninja -DBUILD_WERROR=ON -D GLSLANG_TESTS=ON
- run: cmake -S . -B build -D CMAKE_BUILD_TYPE=${{matrix.cmake_build_type}} -G Ninja -DGLSLANG_BUILD_WERROR=ON -D GLSLANG_TESTS=ON
env:
CC: ${{matrix.compiler.cc}}
CXX: ${{matrix.compiler.cxx}}
Expand All @@ -187,7 +187,7 @@ jobs:
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
- uses: lukka/get-cmake@57c20a23a6cac5b90f31864439996e5b206df9dc # v4.0.1
- run: ./update_glslang_sources.py
- run: cmake -S . -B build -D CMAKE_BUILD_TYPE=${{matrix.cmake_build_type}} -G Ninja -DBUILD_WERROR=ON -D GLSLANG_TESTS=ON -DBUILD_SHARED_LIBS=ON
- run: cmake -S . -B build -D CMAKE_BUILD_TYPE=${{matrix.cmake_build_type}} -G Ninja -DGLSLANG_BUILD_WERROR=ON -D GLSLANG_TESTS=ON -DBUILD_SHARED_LIBS=ON
env:
CC: ${{matrix.compiler.cc}}
CXX: ${{matrix.compiler.cxx}}
Expand All @@ -214,7 +214,7 @@ jobs:
- run: python update_glslang_sources.py
- name: Build
run: |
cmake -S. -Bbuild -G "Visual Studio 16 2019" -A x64 -DCMAKE_INSTALL_PREFIX="$PWD/build/install" -DBUILD_WERROR=ON -D GLSLANG_TESTS=ON
cmake -S. -Bbuild -G "Visual Studio 16 2019" -A x64 -DCMAKE_INSTALL_PREFIX="$PWD/build/install" -DGLSLANG_BUILD_WERROR=ON -D GLSLANG_TESTS=ON
cmake --build build --config ${{matrix.cmake_build_type}} --target install
- name: Test find_package support
run: |
Expand All @@ -238,7 +238,7 @@ jobs:
- run: python update_glslang_sources.py
- name: Build
run: |
cmake -S. -Bbuild -G "Visual Studio 16 2019" -A x64 -DCMAKE_INSTALL_PREFIX="$PWD/build/install" -DBUILD_WERROR=ON -D GLSLANG_TESTS=ON -DBUILD_SHARED_LIBS=ON
cmake -S. -Bbuild -G "Visual Studio 16 2019" -A x64 -DCMAKE_INSTALL_PREFIX="$PWD/build/install" -DGLSLANG_BUILD_WERROR=ON -D GLSLANG_TESTS=ON -DBUILD_SHARED_LIBS=ON
cmake --build build --config ${{matrix.cmake_build_type}} --target install
- name: Test find_package support
run: |
Expand Down
8 changes: 4 additions & 4 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -46,8 +46,8 @@ include(CMakePackageConfigHelpers)
include(CMakeDependentOption)

option(BUILD_SHARED_LIBS "Build Shared Libraries")
option(BUILD_EXTERNAL "Build external dependencies in /External" ON)
option(BUILD_WERROR "Enable warnings as errors (default is OFF)" OFF)
option(GLSLANG_BUILD_EXTERNAL "Build external dependencies in /External" ON)
option(GLSLANG_BUILD_WERROR "Enable warnings as errors (default is OFF)" OFF)

set(LIB_TYPE STATIC)

Expand Down Expand Up @@ -187,7 +187,7 @@ elseif(MSVC)
endif()

# NOTE we could potentially replace this logic with COMPILE_WARNING_AS_ERROR if cmake minimum is bumped to >= 3.24
if (BUILD_WERROR)
if (GLSLANG_BUILD_WERROR)
if (NOT MSVC)
add_compile_options(-Werror)
else()
Expand Down Expand Up @@ -274,7 +274,7 @@ function(glslang_pch target pch)
endif()
endfunction()

if(BUILD_EXTERNAL AND IS_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}/External)
if(GLSLANG_BUILD_EXTERNAL AND IS_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}/External)
# We depend on these for later projects, so they should come first.
add_subdirectory(External)
endif()
Expand Down
Loading