aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGriffin Downs <35574547+grdowns@users.noreply.github.com>2019-04-12 02:47:32 -0700
committerGitHub <noreply@github.com>2019-04-12 02:47:32 -0700
commit7f02290c438845098b2b843152bd3bea96081af0 (patch)
treeba12e02181b4958fe83367ab2dd76640edc81f55
parent39ba5b2b30c9f7b49e777a62093cdd49d05b53a9 (diff)
parentbc4703def18a5cd1c0252f368566f2f33a32f3e6 (diff)
downloadvcpkg-7f02290c438845098b2b843152bd3bea96081af0.tar.gz
vcpkg-7f02290c438845098b2b843152bd3bea96081af0.zip
Merge pull request #6033 from tony979/pcre2-arm64
[pcre2] Enable arm64-windows
-rw-r--r--ports/pcre2/CONTROL2
-rw-r--r--ports/pcre2/fix-arm64-config.patch29
-rw-r--r--ports/pcre2/portfile.cmake2
3 files changed, 31 insertions, 2 deletions
diff --git a/ports/pcre2/CONTROL b/ports/pcre2/CONTROL
index 37f3a6da3..c9b3438a6 100644
--- a/ports/pcre2/CONTROL
+++ b/ports/pcre2/CONTROL
@@ -1,3 +1,3 @@
Source: pcre2
-Version: 10.30-3
+Version: 10.30-4
Description: PCRE2 is a re-working of the original Perl Compatible Regular Expressions library
diff --git a/ports/pcre2/fix-arm64-config.patch b/ports/pcre2/fix-arm64-config.patch
new file mode 100644
index 000000000..bba95718a
--- /dev/null
+++ b/ports/pcre2/fix-arm64-config.patch
@@ -0,0 +1,29 @@
+diff --git a/src/sljit/sljitConfigInternal.h b/src/sljit/sljitConfigInternal.h
+index cc0810f..964afe8 100644
+--- a/src/sljit/sljitConfigInternal.h
++++ b/src/sljit/sljitConfigInternal.h
+@@ -151,6 +151,8 @@
+ #define SLJIT_CONFIG_X86_64 1
+ #elif defined(_ARM_)
+ #define SLJIT_CONFIG_ARM_V5 1
++#elif defined(_M_ARM64)
++#define SLJIT_CONFIG_ARM_64 1
+ #else
+ #define SLJIT_CONFIG_X86_32 1
+ #endif
+@@ -324,9 +326,15 @@
+
+ #else
+
++#if defined(__linux__)
+ /* Calls __ARM_NR_cacheflush on ARM-Linux. */
+ #define SLJIT_CACHE_FLUSH(from, to) \
+ __clear_cache((char*)(from), (char*)(to))
++#elif(_WIN32)
++#pragma comment(lib, "kernel32.lib")
++#define SLJIT_CACHE_FLUSH(from, to) \
++ FlushInstructionCache(GetCurrentProcess(), (void*)(from), (uintptr_t)(to - from));
++#endif
+
+ #endif
+
diff --git a/ports/pcre2/portfile.cmake b/ports/pcre2/portfile.cmake
index e2f5a702a..82b9014d1 100644
--- a/ports/pcre2/portfile.cmake
+++ b/ports/pcre2/portfile.cmake
@@ -10,7 +10,7 @@ vcpkg_extract_source_archive_ex(
OUT_SOURCE_PATH SOURCE_PATH
ARCHIVE ${ARCHIVE}
PATCHES fix-space.patch
-)
+ fix-arm64-config.patch)
vcpkg_configure_cmake(
SOURCE_PATH ${SOURCE_PATH}