mirror of
https://github.com/KhronosGroup/Vulkan-Hpp.git
synced 2025-08-03 03:17:16 -04:00
Remove outdated flag VULKAN_HPP_TESTS_BUILD_ONLY_DYNAMIC (#2228)
This commit is contained in:
parent
7dfe7d3ad9
commit
167bb6afe0
1
.github/workflows/ci-macos.yml
vendored
1
.github/workflows/ci-macos.yml
vendored
@ -36,7 +36,6 @@ jobs:
|
||||
-DVULKAN_HPP_SAMPLES_BUILD=ON \
|
||||
-DVULKAN_HPP_SAMPLES_BUILD_ONLY_DYNAMIC=ON \
|
||||
-DVULKAN_HPP_TESTS_BUILD=ON \
|
||||
-DVULKAN_HPP_TESTS_BUILD_ONLY_DYNAMIC=ON \
|
||||
-DVULKAN_HPP_BUILD_WITH_LOCAL_VULKAN_HPP=ON \
|
||||
-DVULKAN_HPP_PRECOMPILE=OFF \
|
||||
-DVULKAN_HPP_RUN_GENERATOR=ON \
|
||||
|
1
.github/workflows/ci-ubuntu-22.yml
vendored
1
.github/workflows/ci-ubuntu-22.yml
vendored
@ -41,7 +41,6 @@ jobs:
|
||||
-DVULKAN_HPP_SAMPLES_BUILD=ON \
|
||||
-DVULKAN_HPP_SAMPLES_BUILD_ONLY_DYNAMIC=ON \
|
||||
-DVULKAN_HPP_TESTS_BUILD=ON \
|
||||
-DVULKAN_HPP_TESTS_BUILD_ONLY_DYNAMIC=ON \
|
||||
-DVULKAN_HPP_BUILD_WITH_LOCAL_VULKAN_HPP=ON \
|
||||
-DVULKAN_HPP_PRECOMPILE=OFF \
|
||||
-DVULKAN_HPP_RUN_GENERATOR=ON \
|
||||
|
1
.github/workflows/ci-ubuntu-24.yml
vendored
1
.github/workflows/ci-ubuntu-24.yml
vendored
@ -42,7 +42,6 @@ jobs:
|
||||
-DVULKAN_HPP_SAMPLES_BUILD=ON \
|
||||
-DVULKAN_HPP_SAMPLES_BUILD_ONLY_DYNAMIC=ON \
|
||||
-DVULKAN_HPP_TESTS_BUILD=ON \
|
||||
-DVULKAN_HPP_TESTS_BUILD_ONLY_DYNAMIC=ON \
|
||||
-DVULKAN_HPP_ENABLE_CPP20_MODULES=$modules_flag \
|
||||
-DVULKAN_HPP_DISPATCH_LOADER_DYNAMIC=ON \
|
||||
-DVULKAN_HPP_BUILD_WITH_LOCAL_VULKAN_HPP=ON \
|
||||
|
1
.github/workflows/ci-windows.yml
vendored
1
.github/workflows/ci-windows.yml
vendored
@ -37,7 +37,6 @@ jobs:
|
||||
-DVULKAN_HPP_SAMPLES_BUILD=ON \
|
||||
-DVULKAN_HPP_SAMPLES_BUILD_ONLY_DYNAMIC=ON \
|
||||
-DVULKAN_HPP_TESTS_BUILD=ON \
|
||||
-DVULKAN_HPP_TESTS_BUILD_ONLY_DYNAMIC=ON \
|
||||
-DVULKAN_HPP_ENABLE_CPP20_MODULES=$modules_flag \
|
||||
-DVULKAN_HPP_DISPATCH_LOADER_DYNAMIC=ON \
|
||||
-DVULKAN_HPP_BUILD_WITH_LOCAL_VULKAN_HPP=ON \
|
||||
|
@ -43,7 +43,6 @@ option( VULKAN_HPP_GENERATOR_BUILD "Build the HPP generator" ${PROJECT_IS_TOP_LE
|
||||
option( VULKAN_HPP_SAMPLES_BUILD "Build samples" OFF )
|
||||
option( VULKAN_HPP_TESTS_BUILD "Build tests" OFF )
|
||||
option( VULKAN_HPP_SAMPLES_BUILD_ONLY_DYNAMIC "Build only dynamic. Required in case the Vulkan SDK is not available" OFF )
|
||||
option( VULKAN_HPP_TESTS_BUILD_ONLY_DYNAMIC "Build only dynamic" OFF )
|
||||
option( VULKAN_HPP_BUILD_WITH_LOCAL_VULKAN_HPP "Build with local Vulkan headers" ON )
|
||||
option( VULKAN_HPP_ENABLE_CPP20_MODULES "Build Vulkan-Hpp as C++20 module; requires minimum CMake version 3.28" OFF )
|
||||
option( VULKAN_HPP_ENABLE_STD_MODULE "Build Vulkan-Hpp with import std; requires minimum CMake version 3.30" OFF )
|
||||
@ -530,7 +529,7 @@ function( vulkan_hpp__setup_test )
|
||||
set( multiValueArgs LIBRARIES )
|
||||
cmake_parse_arguments( TARGET "${options}" "${oneValueArgs}" "${multiValueArgs}" ${ARGN} )
|
||||
|
||||
if( NOT (VULKAN_HPP_TESTS_BUILD_ONLY_DYNAMIC AND VULKAN_HPP_BUILD_WITH_LOCAL_VULKAN_HPP) )
|
||||
if( NOT VULKAN_HPP_BUILD_WITH_LOCAL_VULKAN_HPP )
|
||||
find_package( Vulkan REQUIRED )
|
||||
endif()
|
||||
|
||||
|
@ -12,6 +12,4 @@
|
||||
# See the License for the specific language governing permissions and
|
||||
# limitations under the License.
|
||||
|
||||
if( NOT VULKAN_HPP_TESTS_BUILD_ONLY_DYNAMIC )
|
||||
vulkan_hpp__setup_test( NAME ArrayProxy )
|
||||
endif()
|
||||
vulkan_hpp__setup_test( NAME ArrayProxy )
|
||||
|
@ -69,16 +69,6 @@ std::vector<int> const getConstVector()
|
||||
return { 1, 2 };
|
||||
}
|
||||
|
||||
std::initializer_list<int> getInitializerList()
|
||||
{
|
||||
return { 1, 2 };
|
||||
}
|
||||
|
||||
std::initializer_list<int> const getConstInitializerList()
|
||||
{
|
||||
return { 1, 2 };
|
||||
}
|
||||
|
||||
int main( int /*argc*/, char ** /*argv*/ )
|
||||
{
|
||||
try
|
||||
@ -233,50 +223,10 @@ int main( int /*argc*/, char ** /*argv*/ )
|
||||
// fct( { a, b } ); // not supported: cannot convert argument 1 from 'initializer list' to 'vk::ArrayProxyNoTemporaries<int>'
|
||||
// fctc( { a, b } ); // not supported: cannot convert argument 1 from 'initializer list' to 'vk::ArrayProxyNoTemporaries<const int32_t>'
|
||||
|
||||
auto il0 = { 0, 1 }; // -> std::initializer_list<int>
|
||||
// fct( il0 ); // not supported: cannot convert from 'const int *' to 'int *'
|
||||
fctc( il0 );
|
||||
|
||||
std::initializer_list<int> il1 = { 0, 1 };
|
||||
// fct( il1 ); // not supported: cannot convert argument 1 from 'std::initializer_list<_Ty>' to 'vk::ArrayProxyNoTemporaries<int>'
|
||||
fctc( il1 );
|
||||
|
||||
std::initializer_list<const int> il2 = { 0, 1 };
|
||||
// fct( il2 ); // not supported: cannot convert argument 1 from 'std::initializer_list<const int>' to 'vk::ArrayProxyNoTemporaries<int>'
|
||||
fctc( il2 );
|
||||
|
||||
std::initializer_list<int> const il3 = { 0, 1 };
|
||||
// fct( il3 ); // not supported: cannot convert argument 1 from 'const std::initializer_list<_Ty>' to 'vk::ArrayProxyNoTemporaries<int>'
|
||||
fctc( il3 );
|
||||
|
||||
std::initializer_list<const int> const il4 = { 0, 1 };
|
||||
// fct( il4 ); // not supported: cannot convert argument 1 from 'const std::initializer_list<const int>' to 'vk::ArrayProxyNoTemporaries<int>'
|
||||
fctc( il4 );
|
||||
|
||||
// getInitializerList
|
||||
// fct( getConstInitializerList() ); // not supported: cannot convert argument 1 from 'const std::initializer_list<_Ty>' to 'vk::ArrayProxyNoTemporaries<int>'
|
||||
// fctc( getConstInitializerList() ); // not supported: cannot convert argument 1 from 'const std::initializer_list<_Ty>' to 'vk::ArrayProxyNoTemporaries<const int32_t>'
|
||||
// fct( getInitializerList() ); // not supported: cannot convert argument 1 from 'std::initializer_list<_Ty>' to 'vk::ArrayProxyNoTemporaries<int>'
|
||||
// fctc( getInitializerList() ); // not supported: cannot convert argument 1 from 'std::initializer_list<_Ty>' to 'vk::ArrayProxyNoTemporaries<const int32_t>'
|
||||
|
||||
// vk::ArrayProxyNoTemporaries<int> apnt22 = il1; // not supported: cannot convert from 'std::initializer_list<_Ty>' to 'vk::ArrayProxyNoTemporaries<int>'
|
||||
// vk::ArrayProxyNoTemporaries<int> apnt23 = il2; // not supported: cannot convert from 'std::initializer_list<const int>' to 'vk::ArrayProxyNoTemporaries<int>'
|
||||
// vk::ArrayProxyNoTemporaries<int> apnt24 = il3; // not supported: cannot convert from 'const std::initializer_list<_Ty>' to 'vk::ArrayProxyNoTemporaries<int>'
|
||||
// vk::ArrayProxyNoTemporaries<int> apnt25 = il4; // not supported: cannot convert from 'const std::initializer_list<const int>' to 'vk::ArrayProxyNoTemporaries<int>'
|
||||
|
||||
vk::ArrayProxyNoTemporaries<const int> apnt26 = {};
|
||||
assert( apnt26.size() == 0 );
|
||||
vk::ArrayProxyNoTemporaries<const int> apnt22 = {};
|
||||
assert( apnt22.size() == 0 );
|
||||
|
||||
// vk::ArrayProxyNoTemporaries<const int> apnt27 = { 0, 1 }; // not supported: cannot convert from 'initializer list' to 'vk::ArrayProxyNoTemporaries<const int32_t>'
|
||||
|
||||
vk::ArrayProxyNoTemporaries<const int> apnt28 = il1;
|
||||
assert( apnt28.size() == 2 );
|
||||
vk::ArrayProxyNoTemporaries<const int> apnt29 = il2;
|
||||
assert( apnt29.size() == 2 );
|
||||
vk::ArrayProxyNoTemporaries<const int> apnt30 = il3;
|
||||
assert( apnt30.size() == 2 );
|
||||
vk::ArrayProxyNoTemporaries<const int> apnt31 = il4;
|
||||
assert( apnt31.size() == 2 );
|
||||
}
|
||||
catch ( vk::SystemError const & err )
|
||||
{
|
||||
|
@ -12,6 +12,4 @@
|
||||
# See the License for the specific language governing permissions and
|
||||
# limitations under the License.
|
||||
|
||||
if( NOT VULKAN_HPP_TESTS_BUILD_ONLY_DYNAMIC )
|
||||
vulkan_hpp__setup_test( NAME ArrayProxyNoTemporaries NO_UTILS )
|
||||
endif()
|
||||
vulkan_hpp__setup_test( NAME ArrayProxyNoTemporaries NO_UTILS )
|
||||
|
@ -12,6 +12,4 @@
|
||||
# See the License for the specific language governing permissions and
|
||||
# limitations under the License.
|
||||
|
||||
if( NOT VULKAN_HPP_TESTS_BUILD_ONLY_DYNAMIC )
|
||||
vulkan_hpp__setup_test( NAME ArrayWrapper )
|
||||
endif()
|
||||
vulkan_hpp__setup_test( NAME ArrayWrapper )
|
||||
|
@ -12,6 +12,4 @@
|
||||
# See the License for the specific language governing permissions and
|
||||
# limitations under the License.
|
||||
|
||||
if( NOT VULKAN_HPP_TESTS_BUILD_ONLY_DYNAMIC )
|
||||
vulkan_hpp__setup_test( NAME CppType )
|
||||
endif()
|
||||
vulkan_hpp__setup_test( NAME CppType )
|
||||
|
@ -12,6 +12,4 @@
|
||||
# See the License for the specific language governing permissions and
|
||||
# limitations under the License.
|
||||
|
||||
if( NOT VULKAN_HPP_TESTS_BUILD_ONLY_DYNAMIC )
|
||||
vulkan_hpp__setup_test( NAME DesignatedInitializers CXX_STANDARD 20 )
|
||||
endif()
|
||||
vulkan_hpp__setup_test( NAME DesignatedInitializers CXX_STANDARD 20 )
|
||||
|
@ -12,8 +12,7 @@
|
||||
# See the License for the specific language governing permissions and
|
||||
# limitations under the License.
|
||||
|
||||
if( NOT VULKAN_HPP_TESTS_BUILD_ONLY_DYNAMIC )
|
||||
find_package( Vulkan REQUIRED )
|
||||
|
||||
find_package( Vulkan QUIET )
|
||||
if ( Vulkan_FOUND )
|
||||
vulkan_hpp__setup_test( NAME DeviceFunctions LIBRARIES ${Vulkan_LIBRARIES} )
|
||||
endif()
|
||||
endif()
|
||||
|
@ -12,14 +12,11 @@
|
||||
# See the License for the specific language governing permissions and
|
||||
# limitations under the License.
|
||||
|
||||
if( NOT VULKAN_HPP_TESTS_BUILD_ONLY_DYNAMIC )
|
||||
find_package( Vulkan REQUIRED )
|
||||
|
||||
vulkan_hpp__setup_test(
|
||||
NAME DispatchLoaderStatic
|
||||
LIBRARIES ${Vulkan_LIBRARIES} )
|
||||
find_package( Vulkan QUIET )
|
||||
if ( Vulkan_FOUND )
|
||||
vulkan_hpp__setup_test( NAME DispatchLoaderStatic LIBRARIES ${Vulkan_LIBRARIES} )
|
||||
|
||||
if( UNIX )
|
||||
target_link_libraries( DispatchLoaderStatic PRIVATE ${CMAKE_DL_LIBS} )
|
||||
endif()
|
||||
endif()
|
||||
endif()
|
||||
|
@ -15,16 +15,24 @@
|
||||
// VulkanHpp Tests : EnableBetaExtensions
|
||||
// Compile test with VK_ENABLE_BETA_EXTENSIONS defined
|
||||
|
||||
// ignore warning 4189: local variable is initialized but not referenced
|
||||
#if defined( _MSC_VER )
|
||||
# pragma warning( disable : 4189 )
|
||||
#elif defined( __GNUC__ )
|
||||
# pragma GCC diagnostic ignored "-Wunused-but-set-variable"
|
||||
# pragma GCC diagnostic ignored "-Wunused-variable"
|
||||
#else
|
||||
// unknow compiler... just ignore the warnings for yourselves ;)
|
||||
#endif
|
||||
|
||||
#define VK_ENABLE_BETA_EXTENSIONS
|
||||
#include <vulkan/vulkan.hpp>
|
||||
|
||||
int main( int /*argc*/, char ** /*argv*/ )
|
||||
{
|
||||
vk::Device device;
|
||||
vk::PhysicalDevice physicalDevice;
|
||||
|
||||
vk::VideoEncodeSessionParametersGetInfoKHR videoSessionParametersInfo;
|
||||
auto stuff = device.getEncodedVideoSessionParametersKHR<vk::VideoEncodeSessionParametersFeedbackInfoKHR,
|
||||
vk::VideoEncodeH264SessionParametersFeedbackInfoEXT,
|
||||
vk::VideoEncodeH265SessionParametersFeedbackInfoEXT>( videoSessionParametersInfo );
|
||||
auto features = physicalDevice.getFeatures2<vk::PhysicalDeviceFeatures2, vk::PhysicalDevicePortabilitySubsetFeaturesKHR>();
|
||||
auto properties = physicalDevice.getProperties2<vk::PhysicalDeviceProperties2, vk::PhysicalDevicePortabilitySubsetPropertiesKHR>();
|
||||
return 0;
|
||||
}
|
||||
|
@ -12,8 +12,7 @@
|
||||
# See the License for the specific language governing permissions and
|
||||
# limitations under the License.
|
||||
|
||||
if( NOT VULKAN_HPP_TESTS_BUILD_ONLY_DYNAMIC )
|
||||
find_package( Vulkan REQUIRED )
|
||||
|
||||
find_package( Vulkan QUIET )
|
||||
if ( Vulkan_FOUND )
|
||||
vulkan_hpp__setup_test( NAME Handles LIBRARIES ${Vulkan_LIBRARIES} )
|
||||
endif()
|
||||
endif()
|
||||
|
@ -62,12 +62,6 @@ int main( int /*argc*/, char ** /*argv*/ )
|
||||
std::cout << "hoho";
|
||||
}
|
||||
|
||||
vk::PhysicalDevice physicalDevice;
|
||||
if (physicalDevice == instance )
|
||||
{
|
||||
std::cout << "hoho";
|
||||
}
|
||||
|
||||
instance.destroy();
|
||||
instance2.destroy();
|
||||
|
||||
|
@ -12,8 +12,7 @@
|
||||
# See the License for the specific language governing permissions and
|
||||
# limitations under the License.
|
||||
|
||||
if( NOT VULKAN_HPP_TESTS_BUILD_ONLY_DYNAMIC )
|
||||
find_package( Vulkan REQUIRED )
|
||||
|
||||
find_package( Vulkan QUIET )
|
||||
if ( Vulkan_FOUND )
|
||||
vulkan_hpp__setup_test( NAME HandlesMoveExchange LIBRARIES ${Vulkan_LIBRARIES} )
|
||||
endif()
|
||||
|
@ -12,6 +12,4 @@
|
||||
# See the License for the specific language governing permissions and
|
||||
# limitations under the License.
|
||||
|
||||
if( NOT VULKAN_HPP_TESTS_BUILD_ONLY_DYNAMIC )
|
||||
vulkan_hpp__setup_test( NAME Hash )
|
||||
endif()
|
||||
vulkan_hpp__setup_test( NAME Hash )
|
||||
|
@ -12,6 +12,4 @@
|
||||
# See the License for the specific language governing permissions and
|
||||
# limitations under the License.
|
||||
|
||||
if( NOT VULKAN_HPP_TESTS_BUILD_ONLY_DYNAMIC )
|
||||
vulkan_hpp__setup_test( NAME StridedArrayProxy )
|
||||
endif()
|
||||
vulkan_hpp__setup_test( NAME StridedArrayProxy )
|
||||
|
@ -472,7 +472,7 @@ namespace VULKAN_HPP_NAMESPACE
|
||||
typename std::enable_if<std::is_convertible<decltype( std::declval<V>().begin() ), T *>::value &&
|
||||
std::is_convertible<decltype( std::declval<V>().size() ), std::size_t>::value && std::is_lvalue_reference<V>::value,
|
||||
int>::type = 0>
|
||||
ArrayProxyNoTemporaries( V && v ) VULKAN_HPP_NOEXCEPT
|
||||
ArrayProxyNoTemporaries( V & v ) VULKAN_HPP_NOEXCEPT
|
||||
: m_count( static_cast<uint32_t>( v.size() ) )
|
||||
, m_ptr( v.begin() )
|
||||
{
|
||||
|
Loading…
x
Reference in New Issue
Block a user