I added support for x32 back in 2014 but it's been in a state of disrepair ever since, not in the least because it was never a fully supported architecture in upstream V8. V8 dropped x32 support entirely in or around 2018 so the removal from Node's build system is long overdue. Refs: https://github.com/nodejs/node/issues/40576 PR-URL: https://github.com/nodejs/node/pull/41905 Reviewed-By: Richard Lau <rlau@redhat.com> Reviewed-By: Jiawen Geng <technicalcute@gmail.com> Reviewed-By: Gerhard Stöbich <deb2001-github@yahoo.de> Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: Tobias Nießen <tniessen@tnie.de>
166 lines
4.8 KiB
Python
166 lines
4.8 KiB
Python
# Copyright (c) 2009 The Chromium Authors. All rights reserved.
|
|
# Use of this source code is governed by a BSD-style license that can be
|
|
# found in the LICENSE file.
|
|
|
|
{
|
|
'variables': {
|
|
'use_system_zlib%': 0,
|
|
'arm_fpu%': '',
|
|
'llvm_version%': '0.0',
|
|
},
|
|
'conditions': [
|
|
['use_system_zlib==0', {
|
|
'targets': [
|
|
{
|
|
'target_name': 'zlib',
|
|
'type': 'static_library',
|
|
'sources': [
|
|
'adler32.c',
|
|
'compress.c',
|
|
'contrib/optimizations/insert_string.h',
|
|
'crc32.c',
|
|
'crc32.h',
|
|
'deflate.c',
|
|
'deflate.h',
|
|
'gzclose.c',
|
|
'gzguts.h',
|
|
'gzlib.c',
|
|
'gzread.c',
|
|
'gzwrite.c',
|
|
'infback.c',
|
|
'inffast.c',
|
|
'inffast.h',
|
|
'inffixed.h',
|
|
'inflate.h',
|
|
'inftrees.c',
|
|
'inftrees.h',
|
|
'trees.c',
|
|
'trees.h',
|
|
'uncompr.c',
|
|
'x86.h',
|
|
'zconf.h',
|
|
'zlib.h',
|
|
'zutil.c',
|
|
'zutil.h',
|
|
],
|
|
'include_dirs': [
|
|
'.',
|
|
],
|
|
'direct_dependent_settings': {
|
|
'include_dirs': [
|
|
'.',
|
|
],
|
|
},
|
|
'conditions': [
|
|
['OS!="win"', {
|
|
'cflags!': [ '-ansi' ],
|
|
'cflags': [ '-Wno-implicit-fallthrough' ],
|
|
'defines': [ 'HAVE_HIDDEN' ],
|
|
}],
|
|
['OS=="mac" or OS=="ios" or OS=="freebsd" or OS=="android"', {
|
|
# Mac, Android and the BSDs don't have fopen64, ftello64, or
|
|
# fseeko64. We use fopen, ftell, and fseek instead on these
|
|
# systems.
|
|
'defines': [
|
|
'USE_FILE32API'
|
|
],
|
|
}],
|
|
['(target_arch in "ia32 x64" and OS!="ios") or arm_fpu=="neon"', {
|
|
'sources': [
|
|
'adler32_simd.c',
|
|
'adler32_simd.h',
|
|
'contrib/optimizations/chunkcopy.h',
|
|
'contrib/optimizations/inffast_chunk.c',
|
|
'contrib/optimizations/inffast_chunk.h',
|
|
'contrib/optimizations/inflate.c',
|
|
],
|
|
}, {
|
|
'sources': [ 'inflate.c', ],
|
|
}],
|
|
# Incorporate optimizations where possible
|
|
['target_arch in "ia32 x64" and OS!="ios"', {
|
|
'defines': [
|
|
'ADLER32_SIMD_SSSE3',
|
|
'INFLATE_CHUNK_SIMD_SSE2',
|
|
'CRC32_SIMD_SSE42_PCLMUL',
|
|
],
|
|
'sources': [
|
|
'crc32_simd.c',
|
|
'crc32_simd.h',
|
|
'crc_folding.c',
|
|
'fill_window_sse.c',
|
|
'x86.c',
|
|
],
|
|
'conditions': [
|
|
['target_arch=="x64"', {
|
|
'defines': [ 'INFLATE_CHUNK_READ_64LE' ],
|
|
}],
|
|
],
|
|
}, {
|
|
'sources': [ 'simd_stub.c', ],
|
|
}],
|
|
['arm_fpu=="neon"', {
|
|
'defines': [
|
|
'ADLER32_SIMD_NEON',
|
|
'INFLATE_CHUNK_SIMD_NEON',
|
|
],
|
|
'sources': [
|
|
'contrib/optimizations/slide_hash_neon.h',
|
|
],
|
|
'conditions': [
|
|
['OS!="ios"', {
|
|
'defines': [ 'CRC32_ARMV8_CRC32' ],
|
|
'sources': [
|
|
'arm_features.c',
|
|
'arm_features.h',
|
|
'crc32_simd.c',
|
|
'crc32_simd.h',
|
|
],
|
|
'conditions': [
|
|
['OS=="android"', {
|
|
'defines': [ 'ARMV8_OS_ANDROID' ],
|
|
}],
|
|
['OS=="linux"', {
|
|
'defines': [ 'ARMV8_OS_LINUX' ],
|
|
}],
|
|
['OS=="win"', {
|
|
'defines': [ 'ARMV8_OS_WINDOWS' ],
|
|
}],
|
|
['OS!="android" and OS!="win" and llvm_version=="0.0"', {
|
|
'cflags': [
|
|
'-march=armv8-a+crc',
|
|
],
|
|
}],
|
|
],
|
|
}],
|
|
['target_arch=="arm64"', {
|
|
'defines': [ 'INFLATE_CHUNK_READ_64LE' ],
|
|
}],
|
|
],
|
|
}],
|
|
],
|
|
},
|
|
],
|
|
}, {
|
|
'targets': [
|
|
{
|
|
'target_name': 'zlib',
|
|
'type': 'static_library',
|
|
'direct_dependent_settings': {
|
|
'defines': [
|
|
'USE_SYSTEM_ZLIB',
|
|
],
|
|
},
|
|
'defines': [
|
|
'USE_SYSTEM_ZLIB',
|
|
],
|
|
'link_settings': {
|
|
'libraries': [
|
|
'-lz',
|
|
],
|
|
},
|
|
},
|
|
],
|
|
}],
|
|
],
|
|
}
|