Index: head/www/node/Makefile =================================================================== --- head/www/node/Makefile (revision 422394) +++ head/www/node/Makefile (revision 422395) @@ -1,107 +1,109 @@ # $FreeBSD$ PORTNAME= node -PORTVERSION= 6.5.0 +PORTVERSION= 6.6.0 DISTVERSIONPREFIX= v CATEGORIES= www MASTER_SITES= http://nodejs.org/dist/v${PORTVERSION}/ MAINTAINER= bradleythughes@fastmail.fm COMMENT= V8 JavaScript for client and server (6.x) LICENSE= MIT LICENSE_FILE= ${WRKSRC}/LICENSE OPTIONS_DEFINE= BUNDLED_SSL DOCS NLS OPTIONS_SUB= yes BUNDLED_SSL_DESC= Use node.js's bundled OpenSSL implementation BUNDLED_SSL_USES_OFF= ssl BUNDLED_SSL_CONFIGURE_OFF+= --shared-openssl NLS_CONFIGURE_ON= --with-intl=system-icu NLS_LIB_DEPENDS= libicui18n.so:devel/icu USES= compiler execinfo gmake python:2,build pkgconfig localbase HAS_CONFIGURE= yes USE_LDCONFIG= yes CONFLICTS_INSTALL= node4-* node-0.[02-9][0-9]* node-devel-0.[0-9]* node010-[0-9]* node012-[0-9]* iojs-[0-9]* ONLY_FOR_ARCHS= i386 amd64 armv6 CONFIGURE_ARGS= --prefix=${PREFIX_RELDEST} \ --without-npm \ --shared-cares \ --shared-libuv \ --shared-zlib PREFIX_RELDEST= ${PREFIX:S,^${DESTDIR},,} REINPLACE_ARGS= -i '' MAKE_ENV+= CC.host=${CC} CXX.host=${CXX} LINK.host=${CXX} LINK.target=${CXX} LIB_DEPENDS+= libcares.so:dns/c-ares\ libuv.so:devel/libuv .include .if empty(PORT_OPTIONS:MBUNDLED_SSL) .if ${OSVERSION} < 1100085 # node.js requires openssl 1.0.2, use the port since base isn't new enough WITH_OPENSSL_PORT= yes .endif .endif .include .if empty(PORT_OPTIONS:MBUNDLED_SSL) .if !empty(SSL_DEFAULT:Mlibressl*) IGNORE= cannot build node.js with LibreSSL. You must enable BUNDLED_SSL .endif .endif .if ${ARCH} == "armv6" CONFIGURE_ARGS= --openssl-no-asm .endif .if ${COMPILER_TYPE} == clang MAKE_ENV+= LINK=clang++ CFLAGS+= -Wno-unused-private-field .if ${COMPILER_VERSION} >= 33 CFLAGS+= -Wno-nested-anon-types -Wno-unused-function .if ${COMPILER_VERSION} >= 34 CFLAGS+= -Wno-unused-const-variable .endif .endif .else MAKE_ARGS+= strictaliasing=off USE_GCC= yes +# GCC does not expose std::snprintf() without this define +CXXFLAGS+= -D_GLIBCXX_USE_C99 .endif post-patch: @${REINPLACE_CMD} -e 's|/usr/local|${LOCALBASE}|' \ ${WRKSRC}/deps/v8/tools/gyp/v8.gyp # So many different ways to run python. Fix them all. @${REINPLACE_CMD} -e 's|/usr/bin/env python|${PYTHON_CMD}|' \ ${WRKSRC}/configure @${FIND} ${WRKSRC} -type f -name '*.gyp*' -print0 \ | ${XARGS} -0 ${REINPLACE_CMD} \ -e "s|'python'|'${PYTHON_CMD}'|" \ -e 's| Index: head/www/node/distinfo =================================================================== --- head/www/node/distinfo (revision 422394) +++ head/www/node/distinfo (revision 422395) @@ -1,3 +1,3 @@ -TIMESTAMP = 1472503520 -SHA256 (node-v6.5.0.tar.gz) = d7742558bb3331e41510d6e6f1f7b13c0527aecc00a63c3e05fcfd44427ff778 -SIZE (node-v6.5.0.tar.gz) = 26355713 +TIMESTAMP = 1474001482 +SHA256 (node-v6.6.0.tar.gz) = 11b957de855a392ceaa8b300ec66236d6f9c6baa184837d00bdaba2da4aefe91 +SIZE (node-v6.6.0.tar.gz) = 26398504 Index: head/www/node/files/patch-deps_v8_src_arm_cpu-arm.cc =================================================================== --- head/www/node/files/patch-deps_v8_src_arm_cpu-arm.cc (revision 422394) +++ head/www/node/files/patch-deps_v8_src_arm_cpu-arm.cc (revision 422395) @@ -1,22 +1,22 @@ ---- deps/v8/src/arm/cpu-arm.cc.orig 2016-06-02 21:53:45 UTC +--- deps/v8/src/arm/cpu-arm.cc.orig 2016-09-14 17:37:01 UTC +++ deps/v8/src/arm/cpu-arm.cc @@ -7,6 +7,9 @@ #ifdef __QNXNTO__ #include // for cache flushing. #undef MAP_TYPE +#elif defined(__FreeBSD__) +#include +#include // for cache flushing. #else #include // for cache flushing. #endif @@ -24,6 +27,9 @@ void CpuFeatures::FlushICache(void* star #if !defined(USE_SIMULATOR) #if V8_OS_QNX msync(start, size, MS_SYNC | MS_INVALIDATE_ICACHE); +#elif defined(__FreeBSD__) + struct arm_sync_icache_args args = { .addr = (uintptr_t)start, .len = size }; + sysarch(ARM_SYNC_ICACHE, (void *)&args); #else register uint32_t beg asm("r0") = reinterpret_cast(start); register uint32_t end asm("r1") = beg + size; Index: head/www/node/files/patch-deps_v8_src_base_atomicops__internals__arm__gcc.h =================================================================== --- head/www/node/files/patch-deps_v8_src_base_atomicops__internals__arm__gcc.h (revision 422394) +++ head/www/node/files/patch-deps_v8_src_base_atomicops__internals__arm__gcc.h (revision 422395) @@ -1,35 +1,35 @@ ---- deps/v8/src/base/atomicops_internals_arm_gcc.h.orig 2016-06-02 21:53:45 UTC +--- deps/v8/src/base/atomicops_internals_arm_gcc.h.orig 2016-09-14 17:37:01 UTC +++ deps/v8/src/base/atomicops_internals_arm_gcc.h @@ -13,6 +13,11 @@ #include #endif +#if defined(__FreeBSD__) +#include +#include +#endif + namespace v8 { namespace base { @@ -48,6 +53,8 @@ inline void MemoryBarrier() { // Note: This is a function call, which is also an implicit compiler barrier. typedef void (*KernelMemoryBarrierFunc)(); ((KernelMemoryBarrierFunc)0xffff0fa0)(); +#elif defined(__FreeBSD__) + sysarch(ARM_DRAIN_WRITEBUF, (void *)0); #elif defined(__QNXNTO__) __cpu_membarrier(); #else -@@ -63,8 +70,9 @@ inline void MemoryBarrier() { +@@ -64,8 +71,9 @@ inline void MemoryBarrier() { defined(__ARM_ARCH_7__) || defined(__ARM_ARCH_7A__) || \ defined(__ARM_ARCH_7R__) || defined(__ARM_ARCH_7M__) || \ defined(__ARM_ARCH_6__) || defined(__ARM_ARCH_6J__) || \ - defined(__ARM_ARCH_6K__) || defined(__ARM_ARCH_6Z__) || \ - defined(__ARM_ARCH_6ZK__) || defined(__ARM_ARCH_6T2__) + defined(__ARM_ARCH_6K__) || defined(__ARM_ARCH_6KZ__) || \ + defined(__ARM_ARCH_6Z__) || defined(__ARM_ARCH_6ZK__) || \ + defined(__ARM_ARCH_6T2__) inline Atomic32 NoBarrier_CompareAndSwap(volatile Atomic32* ptr, Atomic32 old_value, Index: head/www/node/files/patch-deps_v8_src_base_platform_platform-freebsd.cc =================================================================== --- head/www/node/files/patch-deps_v8_src_base_platform_platform-freebsd.cc (revision 422394) +++ head/www/node/files/patch-deps_v8_src_base_platform_platform-freebsd.cc (revision 422395) @@ -1,51 +1,51 @@ ---- deps/v8/src/base/platform/platform-freebsd.cc.orig 2016-06-02 21:53:45 UTC +--- deps/v8/src/base/platform/platform-freebsd.cc.orig 2016-09-14 17:37:01 UTC +++ deps/v8/src/base/platform/platform-freebsd.cc @@ -35,6 +35,48 @@ namespace v8 { namespace base { +#ifdef __arm__ + +bool OS::ArmUsingHardFloat() { + // GCC versions 4.6 and above define __ARM_PCS or __ARM_PCS_VFP to specify + // the Floating Point ABI used (PCS stands for Procedure Call Standard). + // We use these as well as a couple of other defines to statically determine + // what FP ABI used. + // GCC versions 4.4 and below don't support hard-fp. + // GCC versions 4.5 may support hard-fp without defining __ARM_PCS or + // __ARM_PCS_VFP. + +#define GCC_VERSION (__GNUC__ * 10000 \ + + __GNUC_MINOR__ * 100 \ + + __GNUC_PATCHLEVEL__) +#if GCC_VERSION >= 40600 +#if defined(__ARM_PCS_VFP) + return true; +#else + return false; +#endif + +#elif GCC_VERSION < 40500 + return false; + +#else +#if defined(__ARM_PCS_VFP) + return true; +#elif defined(__ARM_PCS) || defined(__SOFTFP__) || defined(__SOFTFP) || \ + !defined(__VFP_FP__) + return false; +#else +#error "Your version of GCC does not report the FP ABI compiled for." \ + "Please report it on this issue" \ + "http://code.google.com/p/v8/issues/detail?id=2140" + +#endif +#endif +#undef GCC_VERSION +} + +#endif // def __arm__ + const char* OS::LocalTimezone(double time, TimezoneCache* cache) { if (std::isnan(time)) return ""; Index: head/www/node/files/patch-deps_v8_src_log-utils.h =================================================================== --- head/www/node/files/patch-deps_v8_src_log-utils.h (revision 422394) +++ head/www/node/files/patch-deps_v8_src_log-utils.h (revision 422395) @@ -1,12 +1,12 @@ ---- deps/v8/src/log-utils.h.orig 2016-06-02 21:53:46 UTC +--- deps/v8/src/log-utils.h.orig 2016-09-14 17:37:03 UTC +++ deps/v8/src/log-utils.h @@ -9,6 +9,9 @@ #include +#include +#include + #include "src/allocation.h" #include "src/base/platform/mutex.h" #include "src/flags.h" Index: head/www/node/files/patch-deps_v8_src_profiler_sampler.cc =================================================================== --- head/www/node/files/patch-deps_v8_src_profiler_sampler.cc (revision 422394) +++ head/www/node/files/patch-deps_v8_src_profiler_sampler.cc (revision 422395) @@ -1,15 +1,15 @@ ---- deps/v8/src/profiler/sampler.cc.orig 2016-06-02 21:53:46 UTC +--- deps/v8/src/profiler/sampler.cc.orig 2016-09-14 17:37:03 UTC +++ deps/v8/src/profiler/sampler.cc -@@ -515,9 +515,9 @@ void SignalHandler::HandleProfilerSignal +@@ -534,9 +534,9 @@ void SignalHandler::HandleProfilerSignal state.sp = reinterpret_cast
(mcontext.mc_rsp); state.fp = reinterpret_cast
(mcontext.mc_rbp); #elif V8_HOST_ARCH_ARM - state.pc = reinterpret_cast
(mcontext.mc_r15); - state.sp = reinterpret_cast
(mcontext.mc_r13); - state.fp = reinterpret_cast
(mcontext.mc_r11); + state.pc = reinterpret_cast
(mcontext.__gregs[_REG_PC]); + state.sp = reinterpret_cast
(mcontext.__gregs[_REG_SP]); + state.fp = reinterpret_cast
(mcontext.__gregs[_REG_FP]); #endif // V8_HOST_ARCH_* #elif V8_OS_NETBSD #if V8_HOST_ARCH_IA32