From 3fda9360b312d9544719bde0e07a35be68a50d86 Mon Sep 17 00:00:00 2001 From: Enno Boland Date: Wed, 19 Aug 2015 15:55:29 +0200 Subject: [PATCH] nodejs: add missing patch --- srcpkgs/nodejs/patches/arm.patch | 69 ++++++++++++++++++++++++++++++++ srcpkgs/nodejs/template | 2 +- 2 files changed, 70 insertions(+), 1 deletion(-) create mode 100644 srcpkgs/nodejs/patches/arm.patch diff --git a/srcpkgs/nodejs/patches/arm.patch b/srcpkgs/nodejs/patches/arm.patch new file mode 100644 index 00000000000..e971f44e8d9 --- /dev/null +++ b/srcpkgs/nodejs/patches/arm.patch @@ -0,0 +1,69 @@ +diff --git deps/v8/build/toolchain.gypi deps/v8/build/toolchain.gypi +index 1d47360..9c2e376 100644 +--- deps/v8/build/toolchain.gypi ++++ deps/v8/build/toolchain.gypi +@@ -159,7 +159,7 @@ + }], + [ 'arm_version==7 or arm_version=="default"', { + 'conditions': [ +- [ 'arm_fpu!="default"', { ++ [ 'arm_fpu!="default" and arm_fpu!=""', { + 'cflags': ['-mfpu=<(arm_fpu)',], + }], + ], +@@ -202,7 +202,7 @@ + }], + [ 'arm_version==7 or arm_version=="default"', { + 'conditions': [ +- [ 'arm_fpu!="default"', { ++ [ 'arm_fpu!="default" and arm_fpu!=""', { + 'cflags': ['-mfpu=<(arm_fpu)',], + }], + ], +diff --git deps/v8/src/base/cpu.cc deps/v8/src/base/cpu.cc +index adce69d..3f35a08 100644 +--- deps/v8/src/base/cpu.cc ++++ deps/v8/src/base/cpu.cc +@@ -365,7 +365,7 @@ CPU::CPU() : stepping_(0), + // + // See http://code.google.com/p/android/issues/detail?id=10812 + // +- // We try to correct this by looking at the 'elf_format' ++ // We try to correct this by looking at the 'elf_platform' + // field reported by the 'Processor' field, which is of the + // form of "(v7l)" for an ARMv7-based CPU, and "(v6l)" for + // an ARMv6-one. For example, the Raspberry Pi is one popular +@@ -377,6 +377,17 @@ CPU::CPU() : stepping_(0), + } + delete[] processor; + } ++ ++ // elf_platform moved to the model name field in Linux v3.8. ++ if (architecture_ == 7) { ++ char* processor = cpu_info.ExtractField("model name"); ++ if (HasListItem(processor, "(v6l)")) { ++ architecture_ = 6; ++ } else if (HasListItem(processor, "(v5t)")) { ++ architecture_ = 5; ++ } ++ delete[] processor; ++ } + } + + // Try to extract the list of CPU features from ELF hwcaps. +@@ -427,6 +438,15 @@ CPU::CPU() : stepping_(0), + architecture_ = 6; + } + ++ if (architecture_ < 6) { ++ architecture_ = 5; ++ has_thumb2_ = false; ++ has_vfp_ = false; ++ has_vfp3_ = false; ++ has_vfp3_d32_ = false; ++ has_neon_ = false; ++ } ++ + // We don't support any FPUs other than VFP. + has_fpu_ = has_vfp_; + diff --git a/srcpkgs/nodejs/template b/srcpkgs/nodejs/template index 59ac0e9a334..d7551d6f76e 100644 --- a/srcpkgs/nodejs/template +++ b/srcpkgs/nodejs/template @@ -1,7 +1,7 @@ # Template file for 'nodejs' pkgname=nodejs version=0.12.7 -revision=3 +revision=4 wrksrc=node-v${version} hostmakedepends="pkg-config python" makedepends="zlib-devel python-devel