summaryrefslogtreecommitdiff
path: root/lang
diff options
context:
space:
mode:
authornia <nia@pkgsrc.org>2022-09-24 07:48:06 +0000
committernia <nia@pkgsrc.org>2022-09-24 07:48:06 +0000
commitf57d3c013a6896b198b8dc657005bc7eb585c8b9 (patch)
treea60bed503c870166223e437dfa710064a1ea07ac /lang
parent0418c12fc3bdbb284aae7a95788692802d64a4a8 (diff)
downloadpkgsrc-f57d3c013a6896b198b8dc657005bc7eb585c8b9.tar.gz
mono: Don't assume <sys/auxv.h> is available on NetBSD/aarch64
Diffstat (limited to 'lang')
-rw-r--r--lang/mono/distinfo3
-rw-r--r--lang/mono/patches/patch-external_boringssl_crypto_cpu-aarch64-linux.c34
2 files changed, 36 insertions, 1 deletions
diff --git a/lang/mono/distinfo b/lang/mono/distinfo
index fcdb0e96d8b..e4e68256951 100644
--- a/lang/mono/distinfo
+++ b/lang/mono/distinfo
@@ -1,4 +1,4 @@
-$NetBSD: distinfo,v 1.117 2022/09/20 15:59:33 he Exp $
+$NetBSD: distinfo,v 1.118 2022/09/24 07:48:06 nia Exp $
BLAKE2s (mono-6.12.0.122.tar.xz) = 0f4ef4106e8974fea9ddc2b61ab1b0ebd2a8182fb9f098ec9c46655b4ac1b867
SHA512 (mono-6.12.0.122.tar.xz) = 0fbd4147498cc81e384933147eb6aa5c559d17a794a308af7ffa43dce51e0faefde24fc75e987ed804dcb161b52756944bc3611100fc0a4adcc260ca97ddaecd
@@ -13,6 +13,7 @@ SHA1 (patch-data_net__4__0_Browsers_Makefile.am) = 0ada5af132816efb41dfbd7ce2ba2
SHA1 (patch-data_net__4__0_Makefile.am) = 7c0fa175047f01a556f61503b2fcfabdedd2c606
SHA1 (patch-data_net__4__5_Browsers_Makefile.am) = 80bd57a2ac3fc95adef18acd9cfd7744ca112b01
SHA1 (patch-data_net__4__5_Makefile.am) = d7591e835bfdd27fa0fba4b669b778924c811be4
+SHA1 (patch-external_boringssl_crypto_cpu-aarch64-linux.c) = 7c876a1e937e21758199a1842bfc15c205069922
SHA1 (patch-external_boringssl_include_openssl_thread.h) = a0855fa36e98111961e58338e7c810c5e0568bfb
SHA1 (patch-external_corert_src_Native_gc_env_gcenv.structs.h) = 91b37d93c1c3aadcdb383c443142fe28f50ad8e6
SHA1 (patch-mcs_class_System_System.Net.NetworkInformation_UnixNetworkInterfaceFactory.cs) = 90cb31154f325c19ae82a9e7dd52b4de0ee7b2d2
diff --git a/lang/mono/patches/patch-external_boringssl_crypto_cpu-aarch64-linux.c b/lang/mono/patches/patch-external_boringssl_crypto_cpu-aarch64-linux.c
new file mode 100644
index 00000000000..e3283da92ca
--- /dev/null
+++ b/lang/mono/patches/patch-external_boringssl_crypto_cpu-aarch64-linux.c
@@ -0,0 +1,34 @@
+$NetBSD: patch-external_boringssl_crypto_cpu-aarch64-linux.c,v 1.1 2022/09/24 07:48:06 nia Exp $
+
+NetBSD does not have sys/auxv.h.
+
+XXX: This needs to be fixed to actually check for AES instructions, etc.
+Perhaps there's a machdep sysctl variable?
+
+--- external/boringssl/crypto/cpu-aarch64-linux.c.orig 2021-02-22 15:51:09.000000000 +0000
++++ external/boringssl/crypto/cpu-aarch64-linux.c
+@@ -16,8 +16,6 @@
+
+ #if defined(OPENSSL_AARCH64) && !defined(OPENSSL_STATIC_ARMCAP)
+
+-#include <sys/auxv.h>
+-
+ #include <openssl/arm_arch.h>
+
+ #include "internal.h"
+@@ -65,8 +63,15 @@ void OPENSSL_cpuid_setup(void) {
+ }
+ }
+
++#elif defined(__NetBSD__)
++
++void OPENSSL_cpuid_setup(void) {
++ OPENSSL_armcap_P |= ARMV7_NEON;
++}
+ #else // linux
+
++#include <sys/auxv.h>
++
+ void OPENSSL_cpuid_setup(void) {
+ unsigned long hwcap = getauxval(AT_HWCAP);
+