aboutsummaryrefslogtreecommitdiff
path: root/contrib/depends/patches
diff options
context:
space:
mode:
authorDusan Klinec <dusan.klinec@gmail.com>2023-09-29 19:13:37 +0200
committerDusan Klinec <dusan.klinec@gmail.com>2023-09-30 09:01:10 +0200
commitc444a7e002036e834bfb4c68f04a121ce1af5825 (patch)
tree7c4d291132a4b9fc4f8eebcb53c003c82023cb23 /contrib/depends/patches
parentfix chaingen tests (diff)
downloadmonero-c444a7e002036e834bfb4c68f04a121ce1af5825.tar.xz
trezor: support v2.5.2+, add more trezor tests, fix chaingen and tests
- passphrase logic: remove backward compatibility for 2.4.3, code cleanup. - fix LibUSB cmake for static builds on OSX - tests: all tests now work with passphrase logic enabled. Passphrase test added with different passphrase. no_passphrase test added, Trezor pin test added. Testing wallet opening with correct and incorrect passphrase. Trezor test chain revamp, cleanup. Smaller chain, chain file versioning added. - tests: Trezor tests support TEST_MINING_ENABLED, TEST_MINING_TIMEOUT env vars to change mining-related tests behaviour. - requires protobuf@21 on osx for now (c++14), building with unlinked protobuf: `CMAKE_PREFIX_PATH=$(find /opt/homebrew/Cellar/protobuf@21 -maxdepth 1 -type d -name "21.*" -print -quit) \ make debug-test-trezor -j8`
Diffstat (limited to 'contrib/depends/patches')
-rw-r--r--contrib/depends/patches/libusb/fix_osx_avail.patch12
-rw-r--r--contrib/depends/patches/protobuf/visibility.patch159
2 files changed, 12 insertions, 159 deletions
diff --git a/contrib/depends/patches/libusb/fix_osx_avail.patch b/contrib/depends/patches/libusb/fix_osx_avail.patch
new file mode 100644
index 000000000..2474993f5
--- /dev/null
+++ b/contrib/depends/patches/libusb/fix_osx_avail.patch
@@ -0,0 +1,12 @@
+--- a/libusb/os/darwin_usb.h 2023-03-19 12:07:53
++++ b/libusb/os/darwin_usb.h 2023-03-19 12:07:47
+@@ -165,7 +165,8 @@
+ #define __has_builtin(x) 0 // Compatibility with non-clang compilers.
+ #endif
+ #if __has_builtin(__builtin_available)
+- #define HAS_CAPTURE_DEVICE() __builtin_available(macOS 10.10, *)
++// #define HAS_CAPTURE_DEVICE() __builtin_available(macOS 10.10, *)
++ #define HAS_CAPTURE_DEVICE() 0
+ #else
+ #define HAS_CAPTURE_DEVICE() 0
+ #endif
diff --git a/contrib/depends/patches/protobuf/visibility.patch b/contrib/depends/patches/protobuf/visibility.patch
deleted file mode 100644
index e66d5961f..000000000
--- a/contrib/depends/patches/protobuf/visibility.patch
+++ /dev/null
@@ -1,159 +0,0 @@
---- src/google/protobuf/descriptor.cc.O 2018-07-30 22:16:10.000000000 +0000
-+++ src/google/protobuf/descriptor.cc 2022-05-06 13:38:14.827309092 +0000
-@@ -32,6 +32,9 @@
- // Based on original Protocol Buffers design by
- // Sanjay Ghemawat, Jeff Dean, and others.
-
-+#if defined(__APPLE__) && defined(__arm64__)
-+#pragma GCC visibility push(hidden)
-+#endif
- #include <algorithm>
- #include <functional>
- #include <google/protobuf/stubs/hash.h>
-@@ -7274,3 +7277,6 @@
-
- } // namespace protobuf
- } // namespace google
-+#if defined(__APPLE__) && defined(__arm64__)
-+#pragma GCC visibility pop
-+#endif
---- src/google/protobuf/extension_set.cc.O 2018-07-23 20:56:42.000000000 +0000
-+++ src/google/protobuf/extension_set.cc 2022-05-06 14:48:55.369877050 +0000
-@@ -32,6 +32,9 @@
- // Based on original Protocol Buffers design by
- // Sanjay Ghemawat, Jeff Dean, and others.
-
-+#if defined(__APPLE__) && defined(__arm64__)
-+#pragma GCC visibility push(hidden)
-+#endif
- #include <google/protobuf/stubs/hash.h>
- #include <tuple>
- #include <utility>
-@@ -1914,3 +1917,6 @@
- } // namespace internal
- } // namespace protobuf
- } // namespace google
-+#if defined(__APPLE__) && defined(__arm64__)
-+#pragma GCC visibility pop
-+#endif
---- src/google/protobuf/extension_set_heavy.cc.O 2018-07-30 22:16:10.000000000 +0000
-+++ src/google/protobuf/extension_set_heavy.cc 2022-05-06 14:14:27.847320946 +0000
-@@ -35,6 +35,10 @@
- // Contains methods defined in extension_set.h which cannot be part of the
- // lite library because they use descriptors or reflection.
-
-+#if defined(__APPLE__) && defined(__arm64__)
-+#pragma GCC visibility push(hidden)
-+#endif
-+
- #include <google/protobuf/stubs/casts.h>
- #include <google/protobuf/descriptor.pb.h>
- #include <google/protobuf/io/coded_stream.h>
-@@ -814,3 +818,6 @@
- } // namespace internal
- } // namespace protobuf
- } // namespace google
-+#if defined(__APPLE__) && defined(__arm64__)
-+#pragma GCC visibility pop
-+#endif
---- src/google/protobuf/generated_message_reflection.cc.O 2018-07-23 20:56:42.000000000 +0000
-+++ src/google/protobuf/generated_message_reflection.cc 2022-05-06 13:38:49.655540772 +0000
-@@ -32,6 +32,9 @@
- // Based on original Protocol Buffers design by
- // Sanjay Ghemawat, Jeff Dean, and others.
-
-+#if defined(__APPLE__) && defined(__arm64__)
-+#pragma GCC visibility push(hidden)
-+#endif
- #include <algorithm>
- #include <set>
-
-@@ -2420,3 +2423,6 @@
- } // namespace internal
- } // namespace protobuf
- } // namespace google
-+#if defined(__APPLE__) && defined(__arm64__)
-+#pragma GCC visibility pop
-+#endif
---- src/google/protobuf/map_field.cc.O 2018-07-23 20:56:42.000000000 +0000
-+++ src/google/protobuf/map_field.cc 2022-05-06 13:34:44.913905697 +0000
-@@ -28,6 +28,10 @@
- // (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
- // OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-
-+#if defined(__APPLE__) && defined(__arm64__)
-+#pragma GCC visibility push(hidden)
-+#endif
-+
- #include <google/protobuf/map_field.h>
- #include <google/protobuf/map_field_inl.h>
-
-@@ -462,3 +466,6 @@
- } // namespace internal
- } // namespace protobuf
- } // namespace google
-+#if defined(__APPLE__) && defined(__arm64__)
-+#pragma GCC visibility pop
-+#endif
---- src/google/protobuf/text_format.cc.O 2018-07-30 22:16:11.000000000 +0000
-+++ src/google/protobuf/text_format.cc 2022-05-06 13:34:58.881999517 +0000
-@@ -32,6 +32,10 @@
- // Based on original Protocol Buffers design by
- // Sanjay Ghemawat, Jeff Dean, and others.
-
-+#if defined(__APPLE__) && defined(__arm64__)
-+#pragma GCC visibility push(hidden)
-+#endif
-+
- #include <algorithm>
- #include <float.h>
- #include <math.h>
-@@ -2258,3 +2262,6 @@
-
- } // namespace protobuf
- } // namespace google
-+#if defined(__APPLE__) && defined(__arm64__)
-+#pragma GCC visibility pop
-+#endif
---- src/google/protobuf/wire_format.cc.O 2018-07-23 20:56:42.000000000 +0000
-+++ src/google/protobuf/wire_format.cc 2022-05-06 13:06:23.294219228 +0000
-@@ -32,6 +32,10 @@
- // Based on original Protocol Buffers design by
- // Sanjay Ghemawat, Jeff Dean, and others.
-
-+#if defined(__APPLE__) && defined(__arm64__)
-+#pragma GCC visibility push(hidden)
-+#endif
-+
- #include <stack>
- #include <string>
- #include <vector>
-@@ -1445,3 +1449,7 @@
- } // namespace internal
- } // namespace protobuf
- } // namespace google
-+
-+#if defined(__APPLE__) && defined(__arm64__)
-+#pragma GCC visibility pop
-+#endif
---- src/google/protobuf/stubs/status.cc.O 2018-07-23 20:56:42.000000000 +0000
-+++ src/google/protobuf/stubs/status.cc 2022-05-06 15:18:53.393208814 +0000
-@@ -27,6 +27,11 @@
- // THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
- // (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
- // OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-+
-+#if defined(__APPLE__) && defined(__arm64__)
-+#pragma GCC visibility push(hidden)
-+#endif
-+
- #include <google/protobuf/stubs/status.h>
-
- #include <ostream>
-@@ -132,3 +137,6 @@
- } // namespace util
- } // namespace protobuf
- } // namespace google
-+#if defined(__APPLE__) && defined(__arm64__)
-+#pragma GCC visibility pop
-+#endif