From 404af920fefefb85108316ed78aa3e5bfca819be Mon Sep 17 00:00:00 2001 From: Peter Robinson Date: Mar 27 2014 11:06:29 +0000 Subject: Add patch for AArch64. --- diff --git a/aarch64.patch b/aarch64.patch new file mode 100644 index 0000000..19d261d --- /dev/null +++ b/aarch64.patch @@ -0,0 +1,52 @@ +--- a/js/src/Makefile.in ++++ a/js/src/Makefile.in +@@ -382,7 +382,7 @@ CPPSRCS += checks.cc \ + # END enclude sources for V8 dtoa + ############################################# + +-ifeq (,$(filter-out powerpc powerpc64 sparc sparc64 s390 s390x,$(TARGET_CPU))) ++ifeq (,$(filter-out aarch64 powerpc powerpc64 sparc sparc64 s390 s390x,$(TARGET_CPU))) + + VPATH += $(srcdir)/assembler \ + $(srcdir)/assembler/wtf \ +--- a/js/src/assembler/jit/ExecutableAllocator.h ++++ a/js/src/assembler/jit/ExecutableAllocator.h +@@ -391,6 +391,12 @@ public: + { + CacheRangeFlush(code, size, CACHE_SYNC_ALL); + } ++#elif WTF_CPU_AARCH64 && WTF_PLATFORM_LINUX ++ static void cacheFlush(void* code, size_t size) ++ { ++ intptr_t end = reinterpret_cast(code) + size; ++ __builtin___clear_cache(reinterpret_cast(code), reinterpret_cast(end)); ++ } + #else + #error "The cacheFlush support is missing on this platform." + #endif +--- a/js/src/assembler/wtf/Platform.h ++++ a/js/src/assembler/wtf/Platform.h +@@ -292,6 +292,10 @@ + + #endif /* ARM */ + ++/* CPU(AArch64) - 64-bit ARM */ ++#if defined(__aarch64__) ++#define WTF_CPU_AARCH64 1 ++#endif + + + /* Operating systems - low-level dependencies */ +--- a/js/src/configure.in ++++ a/js/src/configure.in +@@ -1534,6 +1534,10 @@ arm*) + CPU_ARCH=arm + ;; + ++aarch64) ++ CPU_ARCH=aarch64 ++ ;; ++ + mips|mipsel) + CPU_ARCH="mips" + ;; diff --git a/js.spec b/js.spec index 9c46dcd..d780d8a 100644 --- a/js.spec +++ b/js.spec @@ -4,7 +4,7 @@ Summary: JavaScript interpreter and libraries Name: js Epoch: 1 Version: 1.8.5 -Release: 15%{?hgdate:.hg%{hgdate}}%{?dist} +Release: 16%{?hgdate:.hg%{hgdate}}%{?dist} License: GPLv2+ or LGPLv2+ or MPLv1.1 Group: Development/Languages URL: http://www.mozilla.org/js/ @@ -16,6 +16,7 @@ Patch3: js-1.8.5-537701.patch Patch4: js185-arm-nosoftfp.patch Patch5: js185-libedit.patch Patch6: 0001-Make-js-config.h-multiarch-compatible.patch +Patch7: aarch64.patch Provides: libjs = %{version}-%{release} BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root Buildrequires: nspr-devel >= 4.7 @@ -56,6 +57,7 @@ you will need to install %{name}-devel. %patch4 -p1 -b .armhfp %patch5 -p1 -b .libedit %patch6 -p1 -b .multiarch +%patch7 -p1 -b .aarch64 cd js # Rm parts with spurios licenses, binaries @@ -137,6 +139,9 @@ rm -rf %{buildroot} %{_includedir}/js %changelog +* Thu Mar 26 2014 Marcin Juszkiewicz - 1:1.8.5-16 +- Add patch for AArch64. + * Mon Mar 17 2014 Colin Walters - 1:1.8.5-15 - Add patch to fix multilib conflict with devel packages I am not aware of anyone who actually needs this, but it checks