Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix moltenvk-1.2.2 package for xcode-15.3 onwards #23866

Open
wants to merge 6 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from 1 commit
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
5 changes: 5 additions & 0 deletions recipes/moltenvk/all/conandata.yml
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,11 @@ sources:
url: "https://github.com/KhronosGroup/MoltenVK/archive/v1.1.0.tar.gz"
sha256: "0538fa1c23ddae495c7f82ccd0db90790a90b7017a258ca7575fbae8021f3058"
patches:
"1.2.2":
- patch_file: "patches/1.2.0-0001-fix-version-number-icd-json.patch"
Twon marked this conversation as resolved.
Show resolved Hide resolved
patch_description: "Fix build errors in Xcode 15.3 beta"
patch_type: "portability"
patch_source: "https://github.com/KhronosGroup/MoltenVK/issues/2156"
"1.2.0":
- patch_file: "patches/1.2.0-0001-fix-version-number-icd-json.patch"
patch_description: "Fix api_version in MoltenVK_icd.json"
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,51 @@
see https://github.com/KhronosGroup/MoltenVK/pull/2157

diff --git a/MoltenVK/MoltenVK/Utility/MVKSmallVector.h b/MoltenVK/MoltenVK/Utility/MVKSmallVector.h
index 93bcb7fc..9649f2b2 100755
--- a/MoltenVK/MoltenVK/Utility/MVKSmallVector.h
+++ b/MoltenVK/MoltenVK/Utility/MVKSmallVector.h
@@ -86,9 +86,9 @@ public:
return *this;
}

- Type *operator->() { return &vector->alc.ptr[index]; }
- Type &operator*() { return vector->alc.ptr[index]; }
- operator Type*() { return &vector->alc.ptr[index]; }
+ Type *operator->() const { return &vector->alc.ptr[index]; }
+ Type &operator*() const { return vector->alc.ptr[index]; }
+ operator Type*() const { return &vector->alc.ptr[index]; }

bool operator==( const iterator &it ) const { return vector == it.vector && index == it.index; }
bool operator!=( const iterator &it ) const { return vector != it.vector || index != it.index; }
@@ -98,20 +98,19 @@ public:
iterator& operator--() { --index; return *this; }
iterator operator--( int ) { auto t = *this; --index; return t; }

- iterator operator+ (const diff_type n) { return iterator( index + n, *vector ); }
- iterator& operator+= (const diff_type n) { index += n; return *this; }
- iterator operator- (const diff_type n) { return iterator( index - n, *vector ); }
- iterator& operator-= (const diff_type n) { index -= n; return *this; }
+ iterator operator+ (const diff_type n) const { return iterator( index + n, *vector ); }
+ iterator& operator+= (const diff_type n) { index += n; return *this; }
+ iterator operator- (const diff_type n) const { return iterator( index - n, *vector ); }
+ iterator& operator-= (const diff_type n) { index -= n; return *this; }

- diff_type operator- (const iterator& it) { return index - it.index; }
+ diff_type operator- (const iterator& it) const { return index - it.index; }

- bool operator< (const iterator& it) { return index < it.index; }
- bool operator<= (const iterator& it) { return index <= it.index; }
- bool operator> (const iterator& it) { return index > it.index; }
- bool operator>= (const iterator& it) { return index >= it.index; }
+ bool operator< (const iterator& it) const { return index < it.index; }
+ bool operator<= (const iterator& it) const { return index <= it.index; }
+ bool operator> (const iterator& it) const { return index > it.index; }
+ bool operator>= (const iterator& it) const { return index >= it.index; }

- const Type &operator[]( const diff_type i ) const { return vector->alc.ptr[index + i]; }
- Type &operator[]( const diff_type i ) { return vector->alc.ptr[index + i]; }
+ Type &operator[]( const diff_type i ) const { return vector->alc.ptr[index + i]; }

bool is_valid() const { return index < vector->alc.size(); }
size_t get_position() const { return index; }
--
Loading