grpc-node
grpc-node copied to clipboard
Can't install grpc m1 Mac
Problem description
Run into a bunch of errors while installing grpc
Reproduction steps
The package.json
of our project contains grpc
. When I run npm install
, this is the full output of the error:
npm ERR! code 1
npm ERR! path /Users/xxx/node_modules/grpc
npm ERR! command failed
npm ERR! command sh -c node-pre-gyp install --fallback-to-build --library=static_library
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/surface/init.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/avl/avl.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/backoff/backoff.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/channel/channel_args.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/channel/channel_stack.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/channel/channel_stack_builder.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/channel/channel_trace.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/channel/channelz.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/channel/channelz_registry.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/channel/connected_channel.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/channel/handshaker.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/channel/handshaker_registry.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/channel/status_util.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/compression/compression.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/compression/compression_internal.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/compression/message_compress.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/compression/stream_compression.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/compression/stream_compression_gzip.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/compression/stream_compression_identity.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/debug/stats.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/debug/stats_data.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/http/format_request.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/http/httpcli.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/http/parser.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/buffer_list.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/call_combiner.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/combiner.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/endpoint.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/endpoint_pair_posix.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/endpoint_pair_uv.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/endpoint_pair_windows.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/error.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/ev_epoll1_linux.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/ev_epollex_linux.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/ev_poll_posix.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/ev_posix.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/ev_windows.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/exec_ctx.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/executor.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/fork_posix.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/fork_windows.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/gethostname_fallback.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/gethostname_host_name_max.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/gethostname_sysconf.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/grpc_if_nametoindex_posix.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/grpc_if_nametoindex_unsupported.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/internal_errqueue.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/iocp_windows.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/iomgr.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/iomgr_custom.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/iomgr_internal.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/iomgr_posix.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/iomgr_uv.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/iomgr_windows.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/is_epollexclusive_available.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/load_file.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/lockfree_event.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/polling_entity.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/pollset.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/pollset_custom.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/pollset_set.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/pollset_set_custom.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/pollset_set_windows.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/pollset_uv.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/pollset_windows.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/resolve_address.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/resolve_address_custom.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/resolve_address_posix.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/resolve_address_windows.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/resource_quota.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/sockaddr_utils.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/socket_factory_posix.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/socket_mutator.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/socket_utils_common_posix.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/socket_utils_linux.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/socket_utils_posix.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/socket_utils_uv.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/socket_utils_windows.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/socket_windows.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/tcp_client.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/tcp_client_custom.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/tcp_client_posix.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/tcp_client_windows.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/tcp_custom.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/tcp_posix.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/tcp_server.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/tcp_server_custom.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/tcp_server_posix.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/tcp_server_utils_posix_common.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/tcp_server_utils_posix_ifaddrs.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/tcp_server_utils_posix_noifaddrs.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/tcp_server_windows.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/tcp_uv.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/tcp_windows.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/time_averaged_stats.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/timer.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/timer_custom.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/timer_generic.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/timer_heap.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/timer_manager.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/timer_uv.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/udp_server.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/unix_sockets_posix.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/unix_sockets_posix_noop.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/wakeup_fd_eventfd.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/wakeup_fd_nospecial.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/wakeup_fd_pipe.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/wakeup_fd_posix.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/json/json.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/json/json_reader.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/json/json_string.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/json/json_writer.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/slice/b64.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/slice/percent_encoding.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/slice/slice.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/slice/slice_buffer.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/slice/slice_intern.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/slice/slice_string_helpers.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/surface/api_trace.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/surface/byte_buffer.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/surface/byte_buffer_reader.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/surface/call.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/surface/call_details.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/surface/call_log_batch.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/surface/channel.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/surface/channel_init.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/surface/channel_ping.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/surface/channel_stack_type.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/surface/completion_queue.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/surface/completion_queue_factory.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/surface/event_string.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/surface/lame_client.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/surface/metadata_array.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/surface/server.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/surface/validate_metadata.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/surface/version.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/transport/bdp_estimator.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/transport/byte_stream.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/transport/connectivity_state.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/transport/error_utils.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/transport/metadata.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/transport/metadata_batch.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/transport/pid_controller.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/transport/static_metadata.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/transport/status_conversion.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/transport/status_metadata.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/transport/timeout_encoding.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/transport/transport.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/transport/transport_op_string.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/uri/uri_parser.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/debug/trace.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/ext/transport/chttp2/server/secure/server_secure_chttp2.o
npm ERR! Failed to execute '/usr/local/bin/node /usr/local/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js build --fallback-to-build --library=static_library --module=/Users/xxx/node_modules/grpc/src/node/extension_binary/node-v83-darwin-x64-unknown/grpc_node.node --module_name=grpc_node --module_path=/Users/xxx/node_modules/grpc/src/node/extension_binary/node-v83-darwin-x64-unknown --napi_version=7 --node_abi_napi=napi --napi_build_version=0 --node_napi_label=node-v83' (1)
npm ERR! node-pre-gyp info it worked if it ends with ok
npm ERR! node-pre-gyp info using [email protected]
npm ERR! node-pre-gyp info using [email protected] | darwin | x64
npm ERR! node-pre-gyp WARN Using request for node-pre-gyp https download
npm ERR! node-pre-gyp info check checked for "/Users/xxx/node_modules/grpc/src/node/extension_binary/node-v83-darwin-x64-unknown/grpc_node.node" (not found)
npm ERR! node-pre-gyp http GET https://node-precompiled-binaries.grpc.io/grpc/v1.20.2/node-v83-darwin-x64-unknown.tar.gz
npm ERR! node-pre-gyp http 404 https://node-precompiled-binaries.grpc.io/grpc/v1.20.2/node-v83-darwin-x64-unknown.tar.gz
npm ERR! node-pre-gyp WARN Tried to download(404): https://node-precompiled-binaries.grpc.io/grpc/v1.20.2/node-v83-darwin-x64-unknown.tar.gz
npm ERR! node-pre-gyp WARN Pre-built binaries not found for [email protected] and [email protected] (node-v83 ABI, unknown) (falling back to source compile with node-gyp)
npm ERR! node-pre-gyp http 404 status code downloading tarball https://node-precompiled-binaries.grpc.io/grpc/v1.20.2/node-v83-darwin-x64-unknown.tar.gz
npm ERR! gyp info it worked if it ends with ok
npm ERR! gyp info using [email protected]
npm ERR! gyp info using [email protected] | darwin | x64
npm ERR! gyp info ok
npm ERR! gyp info it worked if it ends with ok
npm ERR! gyp info using [email protected]
npm ERR! gyp info using [email protected] | darwin | x64
npm ERR! gyp info find Python using Python version 3.9.6 found at "/opt/homebrew/opt/[email protected]/bin/python3.9"
npm ERR! gyp info spawn /opt/homebrew/opt/[email protected]/bin/python3.9
npm ERR! gyp info spawn args [
npm ERR! gyp info spawn args '/usr/local/lib/node_modules/npm/node_modules/node-gyp/gyp/gyp_main.py',
npm ERR! gyp info spawn args 'binding.gyp',
npm ERR! gyp info spawn args '-f',
npm ERR! gyp info spawn args 'make',
npm ERR! gyp info spawn args '-I',
npm ERR! gyp info spawn args '/Users/xxx/node_modules/grpc/build/config.gypi',
npm ERR! gyp info spawn args '-I',
npm ERR! gyp info spawn args '/usr/local/lib/node_modules/npm/node_modules/node-gyp/addon.gypi',
npm ERR! gyp info spawn args '-I',
npm ERR! gyp info spawn args '/Users/xxx/Library/Caches/node-gyp/14.16.0/include/node/common.gypi',
npm ERR! gyp info spawn args '-Dlibrary=shared_library',
npm ERR! gyp info spawn args '-Dvisibility=default',
npm ERR! gyp info spawn args '-Dnode_root_dir=/Users/xxx/Library/Caches/node-gyp/14.16.0',
npm ERR! gyp info spawn args '-Dnode_gyp_dir=/usr/local/lib/node_modules/npm/node_modules/node-gyp',
npm ERR! gyp info spawn args '-Dnode_lib_file=/Users/xxx/Library/Caches/node-gyp/14.16.0/<(target_arch)/node.lib',
npm ERR! gyp info spawn args '-Dmodule_root_dir=/Users/xxx/node_modules/grpc',
npm ERR! gyp info spawn args '-Dnode_engine=v8',
npm ERR! gyp info spawn args '--depth=.',
npm ERR! gyp info spawn args '--no-parallel',
npm ERR! gyp info spawn args '--generator-output',
npm ERR! gyp info spawn args 'build',
npm ERR! gyp info spawn args '-Goutput_dir=.'
npm ERR! gyp info spawn args ]
npm ERR! gyp info ok
npm ERR! gyp info it worked if it ends with ok
npm ERR! gyp info using [email protected]
npm ERR! gyp info using [email protected] | darwin | x64
npm ERR! gyp info spawn make
npm ERR! gyp info spawn args [ 'BUILDTYPE=Release', '-C', 'build' ]
npm ERR! In file included from ../deps/grpc/src/core/ext/transport/chttp2/server/secure/server_secure_chttp2.cc:35:
npm ERR! In file included from ../deps/grpc/src/core/lib/security/context/security_context.h:27:
npm ERR! ../deps/grpc/src/core/lib/security/credentials/credentials.h:155:15: error: anonymous non-C-compatible type given name for linkage purposes by typedef declaration; add a tag name here [-Werror,-Wnon-c-typedef-for-linkage]
npm ERR! typedef struct {
npm ERR! ^
npm ERR! grpc_credentials_mdelem_array
npm ERR! ../deps/grpc/src/core/lib/security/credentials/credentials.h:156:21: note: type is not C-compatible due to this default member initializer
npm ERR! grpc_mdelem* md = nullptr;
npm ERR! ^~~~~~~
npm ERR! ../deps/grpc/src/core/lib/security/credentials/credentials.h:158:3: note: type is given name 'grpc_credentials_mdelem_array' for linkage purposes by this typedef declaration
npm ERR! } grpc_credentials_mdelem_array;
npm ERR! ^
npm ERR! 1 error generated.
npm ERR! make: *** [Release/obj.target/grpc/deps/grpc/src/core/ext/transport/chttp2/server/secure/server_secure_chttp2.o] Error 1
npm ERR! gyp ERR! build error
npm ERR! gyp ERR! stack Error: `make` failed with exit code: 2
npm ERR! gyp ERR! stack at ChildProcess.onExit (/usr/local/lib/node_modules/npm/node_modules/node-gyp/lib/build.js:194:23)
npm ERR! gyp ERR! stack at ChildProcess.emit (events.js:315:20)
npm ERR! gyp ERR! stack at Process.ChildProcess._handle.onexit (internal/child_process.js:277:12)
npm ERR! gyp ERR! System Darwin 20.6.0
npm ERR! gyp ERR! command "/usr/local/bin/node" "/usr/local/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "build" "--fallback-to-build" "--library=static_library" "--module=/Users/xxx/node_modules/grpc/src/node/extension_binary/node-v83-darwin-x64-unknown/grpc_node.node" "--module_name=grpc_node" "--module_path=/Users/xxx/node_modules/grpc/src/node/extension_binary/node-v83-darwin-x64-unknown" "--napi_version=7" "--node_abi_napi=napi" "--napi_build_version=0" "--node_napi_label=node-v83"
npm ERR! gyp ERR! cwd /Users/xxx/node_modules/grpc
npm ERR! gyp ERR! node -v v14.16.0
npm ERR! gyp ERR! node-gyp -v v7.1.2
npm ERR! gyp ERR! not ok
npm ERR! node-pre-gyp ERR! build error
npm ERR! node-pre-gyp ERR! stack Error: Failed to execute '/usr/local/bin/node /usr/local/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js build --fallback-to-build --library=static_library --module=/Users/xxx/node_modules/grpc/src/node/extension_binary/node-v83-darwin-x64-unknown/grpc_node.node --module_name=grpc_node --module_path=/Users/xxx/node_modules/grpc/src/node/extension_binary/node-v83-darwin-x64-unknown --napi_version=7 --node_abi_napi=napi --napi_build_version=0 --node_napi_label=node-v83' (1)
npm ERR! node-pre-gyp ERR! stack at ChildProcess.<anonymous> (/Users/xxx/node_modules/grpc/node_modules/node-pre-gyp/lib/util/compile.js:83:29)
npm ERR! node-pre-gyp ERR! stack at ChildProcess.emit (events.js:315:20)
npm ERR! node-pre-gyp ERR! stack at maybeClose (internal/child_process.js:1048:16)
npm ERR! node-pre-gyp ERR! stack at Process.ChildProcess._handle.onexit (internal/child_process.js:288:5)
npm ERR! node-pre-gyp ERR! System Darwin 20.6.0
npm ERR! node-pre-gyp ERR! command "/usr/local/bin/node" "/Users/xxx/node_modules/grpc/node_modules/.bin/node-pre-gyp" "install" "--fallback-to-build" "--library=static_library"
npm ERR! node-pre-gyp ERR! cwd /Users/xxx/node_modules/grpc
npm ERR! node-pre-gyp ERR! node -v v14.16.0
npm ERR! node-pre-gyp ERR! node-pre-gyp -v v0.13.0
npm ERR! node-pre-gyp ERR! not ok
npm ERR! A complete log of this run can be found in:
npm ERR! /Users/xxx/.npm/_logs/2021-08-11T20_11_18_947Z-debug.log
Environment
- macOS Big Sur, Version 11.5.1 and Apple M1
-
node: v14.16.0
-
npm: 7.16.0
-
gRPC@^1.20.2
Additional context
I have encountered errors with gRPC on this M1 machine with Python as well.
Please update to the newest version of grpc
first. The version you are installing is not compatible with the version of Node that you are using.
I also want to note that the grpc
package is deprecated. We recommend using @grpc/grpc-js
instead.
@murgatroid99 thanks, I also tried npm install @grpc/grpc-js
which failed with this:
npm ERR! code 1
npm ERR! path /Users/sami/Work/tinvoice/node_modules/grpc
npm ERR! command failed
npm ERR! command sh -c node-pre-gyp install --fallback-to-build --library=static_library
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/surface/init.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/avl/avl.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/backoff/backoff.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/channel/channel_args.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/channel/channel_stack.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/channel/channel_stack_builder.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/channel/channel_trace.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/channel/channelz.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/channel/channelz_registry.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/channel/connected_channel.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/channel/handshaker.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/channel/handshaker_registry.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/channel/status_util.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/compression/compression.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/compression/compression_internal.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/compression/message_compress.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/compression/stream_compression.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/compression/stream_compression_gzip.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/compression/stream_compression_identity.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/debug/stats.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/debug/stats_data.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/http/format_request.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/http/httpcli.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/http/parser.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/buffer_list.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/call_combiner.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/combiner.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/endpoint.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/endpoint_pair_posix.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/endpoint_pair_uv.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/endpoint_pair_windows.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/error.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/ev_epoll1_linux.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/ev_epollex_linux.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/ev_poll_posix.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/ev_posix.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/ev_windows.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/exec_ctx.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/executor.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/fork_posix.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/fork_windows.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/gethostname_fallback.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/gethostname_host_name_max.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/gethostname_sysconf.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/grpc_if_nametoindex_posix.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/grpc_if_nametoindex_unsupported.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/internal_errqueue.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/iocp_windows.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/iomgr.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/iomgr_custom.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/iomgr_internal.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/iomgr_posix.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/iomgr_uv.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/iomgr_windows.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/is_epollexclusive_available.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/load_file.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/lockfree_event.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/polling_entity.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/pollset.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/pollset_custom.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/pollset_set.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/pollset_set_custom.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/pollset_set_windows.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/pollset_uv.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/pollset_windows.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/resolve_address.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/resolve_address_custom.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/resolve_address_posix.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/resolve_address_windows.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/resource_quota.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/sockaddr_utils.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/socket_factory_posix.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/socket_mutator.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/socket_utils_common_posix.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/socket_utils_linux.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/socket_utils_posix.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/socket_utils_uv.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/socket_utils_windows.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/socket_windows.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/tcp_client.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/tcp_client_custom.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/tcp_client_posix.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/tcp_client_windows.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/tcp_custom.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/tcp_posix.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/tcp_server.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/tcp_server_custom.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/tcp_server_posix.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/tcp_server_utils_posix_common.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/tcp_server_utils_posix_ifaddrs.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/tcp_server_utils_posix_noifaddrs.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/tcp_server_windows.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/tcp_uv.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/tcp_windows.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/time_averaged_stats.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/timer.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/timer_custom.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/timer_generic.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/timer_heap.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/timer_manager.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/timer_uv.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/udp_server.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/unix_sockets_posix.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/unix_sockets_posix_noop.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/wakeup_fd_eventfd.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/wakeup_fd_nospecial.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/wakeup_fd_pipe.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/iomgr/wakeup_fd_posix.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/json/json.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/json/json_reader.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/json/json_string.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/json/json_writer.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/slice/b64.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/slice/percent_encoding.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/slice/slice.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/slice/slice_buffer.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/slice/slice_intern.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/slice/slice_string_helpers.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/surface/api_trace.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/surface/byte_buffer.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/surface/byte_buffer_reader.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/surface/call.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/surface/call_details.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/surface/call_log_batch.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/surface/channel.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/surface/channel_init.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/surface/channel_ping.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/surface/channel_stack_type.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/surface/completion_queue.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/surface/completion_queue_factory.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/surface/event_string.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/surface/lame_client.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/surface/metadata_array.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/surface/server.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/surface/validate_metadata.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/surface/version.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/transport/bdp_estimator.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/transport/byte_stream.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/transport/connectivity_state.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/transport/error_utils.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/transport/metadata.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/transport/metadata_batch.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/transport/pid_controller.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/transport/static_metadata.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/transport/status_conversion.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/transport/status_metadata.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/transport/timeout_encoding.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/transport/transport.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/transport/transport_op_string.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/uri/uri_parser.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/debug/trace.o
npm ERR! CXX(target) Release/obj.target/grpc/deps/grpc/src/core/ext/transport/chttp2/server/secure/server_secure_chttp2.o
npm ERR! Failed to execute '/usr/local/bin/node /usr/local/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js build --fallback-to-build --library=static_library --module=/Users/sami/Work/tinvoice/node_modules/grpc/src/node/extension_binary/node-v83-darwin-x64-unknown/grpc_node.node --module_name=grpc_node --module_path=/Users/sami/Work/tinvoice/node_modules/grpc/src/node/extension_binary/node-v83-darwin-x64-unknown --napi_version=7 --node_abi_napi=napi --napi_build_version=0 --node_napi_label=node-v83' (1)
npm ERR! node-pre-gyp info it worked if it ends with ok
npm ERR! node-pre-gyp info using [email protected]
npm ERR! node-pre-gyp info using [email protected] | darwin | x64
npm ERR! node-pre-gyp WARN Using request for node-pre-gyp https download
npm ERR! node-pre-gyp info check checked for "/Users/sami/Work/tinvoice/node_modules/grpc/src/node/extension_binary/node-v83-darwin-x64-unknown/grpc_node.node" (not found)
npm ERR! node-pre-gyp http GET https://node-precompiled-binaries.grpc.io/grpc/v1.20.2/node-v83-darwin-x64-unknown.tar.gz
npm ERR! node-pre-gyp http 404 https://node-precompiled-binaries.grpc.io/grpc/v1.20.2/node-v83-darwin-x64-unknown.tar.gz
npm ERR! node-pre-gyp WARN Tried to download(404): https://node-precompiled-binaries.grpc.io/grpc/v1.20.2/node-v83-darwin-x64-unknown.tar.gz
npm ERR! node-pre-gyp WARN Pre-built binaries not found for [email protected] and [email protected] (node-v83 ABI, unknown) (falling back to source compile with node-gyp)
npm ERR! node-pre-gyp http 404 status code downloading tarball https://node-precompiled-binaries.grpc.io/grpc/v1.20.2/node-v83-darwin-x64-unknown.tar.gz
npm ERR! gyp info it worked if it ends with ok
npm ERR! gyp info using [email protected]
npm ERR! gyp info using [email protected] | darwin | x64
npm ERR! gyp info ok
npm ERR! gyp info it worked if it ends with ok
npm ERR! gyp info using [email protected]
npm ERR! gyp info using [email protected] | darwin | x64
npm ERR! gyp info find Python using Python version 3.9.6 found at "/opt/homebrew/opt/[email protected]/bin/python3.9"
npm ERR! gyp info spawn /opt/homebrew/opt/[email protected]/bin/python3.9
npm ERR! gyp info spawn args [
npm ERR! gyp info spawn args '/usr/local/lib/node_modules/npm/node_modules/node-gyp/gyp/gyp_main.py',
npm ERR! gyp info spawn args 'binding.gyp',
npm ERR! gyp info spawn args '-f',
npm ERR! gyp info spawn args 'make',
npm ERR! gyp info spawn args '-I',
npm ERR! gyp info spawn args '/Users/sami/Work/tinvoice/node_modules/grpc/build/config.gypi',
npm ERR! gyp info spawn args '-I',
npm ERR! gyp info spawn args '/usr/local/lib/node_modules/npm/node_modules/node-gyp/addon.gypi',
npm ERR! gyp info spawn args '-I',
npm ERR! gyp info spawn args '/Users/sami/Library/Caches/node-gyp/14.16.0/include/node/common.gypi',
npm ERR! gyp info spawn args '-Dlibrary=shared_library',
npm ERR! gyp info spawn args '-Dvisibility=default',
npm ERR! gyp info spawn args '-Dnode_root_dir=/Users/sami/Library/Caches/node-gyp/14.16.0',
npm ERR! gyp info spawn args '-Dnode_gyp_dir=/usr/local/lib/node_modules/npm/node_modules/node-gyp',
npm ERR! gyp info spawn args '-Dnode_lib_file=/Users/sami/Library/Caches/node-gyp/14.16.0/<(target_arch)/node.lib',
npm ERR! gyp info spawn args '-Dmodule_root_dir=/Users/sami/Work/tinvoice/node_modules/grpc',
npm ERR! gyp info spawn args '-Dnode_engine=v8',
npm ERR! gyp info spawn args '--depth=.',
npm ERR! gyp info spawn args '--no-parallel',
npm ERR! gyp info spawn args '--generator-output',
npm ERR! gyp info spawn args 'build',
npm ERR! gyp info spawn args '-Goutput_dir=.'
npm ERR! gyp info spawn args ]
npm ERR! gyp info ok
npm ERR! gyp info it worked if it ends with ok
npm ERR! gyp info using [email protected]
npm ERR! gyp info using [email protected] | darwin | x64
npm ERR! gyp info spawn make
npm ERR! gyp info spawn args [ 'BUILDTYPE=Release', '-C', 'build' ]
npm ERR! In file included from ../deps/grpc/src/core/ext/transport/chttp2/server/secure/server_secure_chttp2.cc:35:
npm ERR! In file included from ../deps/grpc/src/core/lib/security/context/security_context.h:27:
npm ERR! ../deps/grpc/src/core/lib/security/credentials/credentials.h:155:15: error: anonymous non-C-compatible type given name for linkage purposes by typedef declaration; add a tag name here [-Werror,-Wnon-c-typedef-for-linkage]
npm ERR! typedef struct {
npm ERR! ^
npm ERR! grpc_credentials_mdelem_array
npm ERR! ../deps/grpc/src/core/lib/security/credentials/credentials.h:156:21: note: type is not C-compatible due to this default member initializer
npm ERR! grpc_mdelem* md = nullptr;
npm ERR! ^~~~~~~
npm ERR! ../deps/grpc/src/core/lib/security/credentials/credentials.h:158:3: note: type is given name 'grpc_credentials_mdelem_array' for linkage purposes by this typedef declaration
npm ERR! } grpc_credentials_mdelem_array;
npm ERR! ^
npm ERR! 1 error generated.
npm ERR! make: *** [Release/obj.target/grpc/deps/grpc/src/core/ext/transport/chttp2/server/secure/server_secure_chttp2.o] Error 1
npm ERR! gyp ERR! build error
npm ERR! gyp ERR! stack Error: `make` failed with exit code: 2
npm ERR! gyp ERR! stack at ChildProcess.onExit (/usr/local/lib/node_modules/npm/node_modules/node-gyp/lib/build.js:194:23)
npm ERR! gyp ERR! stack at ChildProcess.emit (events.js:315:20)
npm ERR! gyp ERR! stack at Process.ChildProcess._handle.onexit (internal/child_process.js:277:12)
npm ERR! gyp ERR! System Darwin 20.6.0
npm ERR! gyp ERR! command "/usr/local/bin/node" "/usr/local/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "build" "--fallback-to-build" "--library=static_library" "--module=/Users/sami/Work/tinvoice/node_modules/grpc/src/node/extension_binary/node-v83-darwin-x64-unknown/grpc_node.node" "--module_name=grpc_node" "--module_path=/Users/sami/Work/tinvoice/node_modules/grpc/src/node/extension_binary/node-v83-darwin-x64-unknown" "--napi_version=7" "--node_abi_napi=napi" "--napi_build_version=0" "--node_napi_label=node-v83"
npm ERR! gyp ERR! cwd /Users/sami/Work/tinvoice/node_modules/grpc
npm ERR! gyp ERR! node -v v14.16.0
npm ERR! gyp ERR! node-gyp -v v7.1.2
npm ERR! gyp ERR! not ok
npm ERR! node-pre-gyp ERR! build error
npm ERR! node-pre-gyp ERR! stack Error: Failed to execute '/usr/local/bin/node /usr/local/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js build --fallback-to-build --library=static_library --module=/Users/sami/Work/tinvoice/node_modules/grpc/src/node/extension_binary/node-v83-darwin-x64-unknown/grpc_node.node --module_name=grpc_node --module_path=/Users/sami/Work/tinvoice/node_modules/grpc/src/node/extension_binary/node-v83-darwin-x64-unknown --napi_version=7 --node_abi_napi=napi --napi_build_version=0 --node_napi_label=node-v83' (1)
npm ERR! node-pre-gyp ERR! stack at ChildProcess.<anonymous> (/Users/sami/Work/tinvoice/node_modules/grpc/node_modules/node-pre-gyp/lib/util/compile.js:83:29)
npm ERR! node-pre-gyp ERR! stack at ChildProcess.emit (events.js:315:20)
npm ERR! node-pre-gyp ERR! stack at maybeClose (internal/child_process.js:1048:16)
npm ERR! node-pre-gyp ERR! stack at Process.ChildProcess._handle.onexit (internal/child_process.js:288:5)
npm ERR! node-pre-gyp ERR! System Darwin 20.6.0
npm ERR! node-pre-gyp ERR! command "/usr/local/bin/node" "/Users/sami/Work/tinvoice/node_modules/grpc/node_modules/.bin/node-pre-gyp" "install" "--fallback-to-build" "--library=static_library"
npm ERR! node-pre-gyp ERR! cwd /Users/sami/Work/tinvoice/node_modules/grpc
npm ERR! node-pre-gyp ERR! node -v v14.16.0
npm ERR! node-pre-gyp ERR! node-pre-gyp -v v0.13.0
npm ERR! node-pre-gyp ERR! not ok
That is the exact same error as before because it is still failing at the same thing. It is still trying to install the same version of the grpc
package on the same version of Node. Adding a dependency on @grpc/grpc-js
does not automatically remove the dependency on grpc
.
I can install this on my m1 @grpc/grpc-js with the newest node. I think we can close this issue @murgatroid99 for now.
in my mac
➜ gplayer git:(main) ✗ npm install -g grpc-tools
/Users/mahdizarrintareh/.nvm/versions/node/v14.17.5/bin/grpc_tools_node_protoc -> /Users/mahdizarrintareh/.nvm/versions/node/v14.17.5/lib/node_modules/grpc-tools/bin/protoc.js
/Users/mahdizarrintareh/.nvm/versions/node/v14.17.5/bin/grpc_tools_node_protoc_plugin -> /Users/mahdizarrintareh/.nvm/versions/node/v14.17.5/lib/node_modules/grpc-tools/bin/protoc_plugin.js
> [email protected] install /Users/mahdizarrintareh/.nvm/versions/node/v14.17.5/lib/node_modules/grpc-tools
> node-pre-gyp install
node-pre-gyp ERR! install response status 404 Not Found on https://node-precompiled-binaries.grpc.io/grpc-tools/v1.11.2/darwin-arm64.tar.gz
node-pre-gyp ERR! install error
node-pre-gyp ERR! stack Error: response status 404 Not Found on https://node-precompiled-binaries.grpc.io/grpc-tools/v1.11.2/darwin-arm64.tar.gz
node-pre-gyp ERR! stack at /Users/mahdizarrintareh/.nvm/versions/node/v14.17.5/lib/node_modules/grpc-tools/node_modules/@mapbox/node-pre-gyp/lib/install.js:67:15
node-pre-gyp ERR! stack at processTicksAndRejections (internal/process/task_queues.js:95:5)
node-pre-gyp ERR! System Darwin 21.1.0
node-pre-gyp ERR! command "/Users/mahdizarrintareh/.nvm/versions/node/v14.17.5/bin/node" "/Users/mahdizarrintareh/.nvm/versions/node/v14.17.5/lib/node_modules/grpc-tools/node_modules/.bin/node-pre-gyp" "install"
node-pre-gyp ERR! cwd /Users/mahdizarrintareh/.nvm/versions/node/v14.17.5/lib/node_modules/grpc-tools
node-pre-gyp ERR! node -v v14.17.5
node-pre-gyp ERR! node-pre-gyp -v v1.0.6
node-pre-gyp ERR! not ok
response status 404 Not Found on https://node-precompiled-binaries.grpc.io/grpc-tools/v1.11.2/darwin-arm64.tar.gz
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! [email protected] install: `node-pre-gyp install`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the [email protected] install script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
#1405 tracks the issue of building grpc-tools for M1 Mac. In short, it's blocked on GitHub actions adding support for M1.
+1
I have a project in which grpc
is not listed on package.json but I can see in terminal it's installing grpc. it failed eventually
please help
ERROR MESSAGE
error /Users/xxx/node_modules/grpc: Command failed.
Exit code: 1
Command: node-pre-gyp install --fallback-to-build --library=static_library
Arguments:
Directory: /Users/xxx/node_modules/grpc
Output:
node-pre-gyp info it worked if it ends with ok
node-pre-gyp info using [email protected]
node-pre-gyp info using [email protected] | darwin | arm64
node-pre-gyp WARN Using request for node-pre-gyp https download
node-pre-gyp info check checked for "/Users/xxx/node_modules/grpc/src/node/extension_binary/node-v93-darwin-arm64-unknown/grpc_node.node" (not found)
node-pre-gyp http GET https://node-precompiled-binaries.grpc.io/grpc/v1.20.0/node-v93-darwin-arm64-unknown.tar.gz
node-pre-gyp http 404 https://node-precompiled-binaries.grpc.io/grpc/v1.20.0/node-v93-darwin-arm64-unknown.tar.gz
node-pre-gyp WARN Tried to download(404): https://node-precompiled-binaries.grpc.io/grpc/v1.20.0/node-v93-darwin-arm64-unknown.tar.gz
node-pre-gyp WARN Pre-built binaries not found for [email protected] and [email protected] (node-v93 ABI, unknown) (falling back to source compile with node-gyp)
node-pre-gyp http 404 status code downloading tarball https://node-precompiled-binaries.grpc.io/grpc/v1.20.0/node-v93-darwin-arm64-unknown.tar.gz
gyp info it worked if it ends with ok
gyp info using [email protected]
gyp info using [email protected] | darwin | arm64
gyp info ok
gyp info it worked if it ends with ok
gyp info using [email protected]
gyp info using [email protected] | darwin | arm64
gyp info find Python using Python version 3.9.9 found at "/opt/homebrew/opt/[email protected]/bin/python3.9"
gyp info spawn /opt/homebrew/opt/[email protected]/bin/python3.9
gyp info spawn args [
gyp info spawn args '/usr/local/lib/node_modules/node-gyp/gyp/gyp_main.py',
gyp info spawn args 'binding.gyp',
gyp info spawn args '-f',
gyp info spawn args 'make',
gyp info spawn args '-I',
gyp info spawn args '/Users/xxx/node_modules/grpc/build/config.gypi',
gyp info spawn args '-I',
gyp info spawn args '/usr/local/lib/node_modules/node-gyp/addon.gypi',
gyp info spawn args '-I',
gyp info spawn args '/Users/handika/Library/Caches/node-gyp/16.13.2/include/node/common.gypi',
gyp info spawn args '-Dlibrary=shared_library',
gyp info spawn args '-Dvisibility=default',
gyp info spawn args '-Dnode_root_dir=/Users/handika/Library/Caches/node-gyp/16.13.2',
gyp info spawn args '-Dnode_gyp_dir=/usr/local/lib/node_modules/node-gyp',
gyp info spawn args '-Dnode_lib_file=/Users/handika/Library/Caches/node-gyp/16.13.2/<(target_arch)/node.lib',
gyp info spawn args '-Dmodule_root_dir=/Users/xxx/node_modules/grpc',
gyp info spawn args '-Dnode_engine=v8',
gyp info spawn args '--depth=.',
gyp info spawn args '--no-parallel',
gyp info spawn args '--generator-output',
gyp info spawn args 'build',
gyp info spawn args '-Goutput_dir=.'
gyp info spawn args ]
gyp info ok
gyp info it worked if it ends with ok
gyp info using [email protected]
gyp info using [email protected] | darwin | arm64
gyp info spawn make
gyp info spawn args [ 'BUILDTYPE=Release', '-C', 'build' ]
CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/surface/init.o
CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/avl/avl.o
CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/backoff/backoff.o
CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/channel/channel_args.o
CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/channel/channel_stack.o
CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/channel/channel_stack_builder.o
CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/channel/channel_trace.o
CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/channel/channelz.o
CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/channel/channelz_registry.o
CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/channel/connected_channel.o
CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/channel/handshaker.o
CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/channel/handshaker_registry.o
CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/channel/status_util.o
CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/compression/compression.o
CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/compression/compression_internal.o
CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/compression/message_compress.o
CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/compression/stream_compression.o
CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/compression/stream_compression_gzip.o
CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/compression/stream_compression_identity.o
CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/debug/stats.o
CXX(target) Release/obj.target/grpc/deps/grpc/src/core/lib/debug/stats_data.o
../deps/grpc/src/core/lib/debug/stats_data.cc:284:5: error: suspicious concatenation of string literals in an array initialization; did you mean to separate the elements with a comma? [-Werror,-Wstring-concatenation]
"requested the incoming call",
^
../deps/grpc/src/core/lib/debug/stats_data.cc:283:5: note: place parentheses around the string literal to silence warning
"How many completion queues were checked looking for a CQ that had "
^
1 error generated.
make: *** [Release/obj.target/grpc/deps/grpc/src/core/lib/debug/stats_data.o] Error 1
gyp ERR! build error
gyp ERR! stack Error: `make` failed with exit code: 2
gyp ERR! stack at ChildProcess.onExit (/usr/local/lib/node_modules/node-gyp/lib/build.js:194:23)
gyp ERR! stack at ChildProcess.emit (node:events:390:28)
gyp ERR! stack at Process.ChildProcess._handle.onexit (node:internal/child_process:290:12)
gyp ERR! System Darwin 21.1.0
gyp ERR! command "/usr/local/bin/node" "/usr/local/lib/node_modules/node-gyp/bin/node-gyp.js" "build" "--fallback-to-build" "--library=static_library" "--module=/Users/handika/Sites/vue-cuelist/node_modules/grpc/src/node/extension_binary/node-v93-darwin-arm64-unknown/grpc_node.node" "--module_name=grpc_node" "--module_path=/Users/handika/Sites/vue-cuelist/node_modules/grpc/src/node/extension_binary/node-v93-darwin-arm64-unknown" "--napi_version=8" "--node_abi_napi=napi" "--napi_build_version=0" "--node_napi_label=node-v93"
gyp ERR! cwd /Users/xxx/node_modules/grpc
gyp ERR! node -v v16.13.2
gyp ERR! node-gyp -v v8.4.1
gyp ERR! not ok
node-pre-gyp ERR! build error
node-pre-gyp ERR! stack Error: Failed to execute '/usr/local/bin/node /usr/local/lib/node_modules/node-gyp/bin/node-gyp.js build --fallback-to-build --library=static_library --module=/Users/handika/Sites/vue-cuelist/node_modules/grpc/src/node/extension_binary/node-v93-darwin-arm64-unknown/grpc_node.node --module_name=grpc_node --module_path=/Users/handika/Sites/vue-cuelist/node_modules/grpc/src/node/extension_binary/node-v93-darwin-arm64-unknown --napi_version=8 --node_abi_napi=napi --napi_build_version=0 --node_napi_label=node-v93' (1)
node-pre-gyp ERR! stack at ChildProcess.<anonymous> (/Users/handika/Sites/vue-cuelist/node_modules/node-pre-gyp/lib/util/compile.js:83:29)
node-pre-gyp ERR! stack at ChildProcess.emit (node:events:390:28)
node-pre-gyp ERR! stack at maybeClose (node:internal/child_process:1064:16)
node-pre-gyp ERR! stack at Process.ChildProcess._handle.onexit (node:internal/child_process:301:5)
node-pre-gyp ERR! System Darwin 21.1.0
node-pre-gyp ERR! command "/usr/local/bin/node" "/Users/handika/Sites/vue-cuelist/node_modules/grpc/node_modules/.bin/node-pre-gyp" "install" "--fallback-to-build" "--library=static_library"
node-pre-gyp ERR! cwd /Users/xxx/node_modules/grpc
node-pre-gyp ERR! node -v v16.13.2
node-pre-gyp ERR! node-pre-gyp -v v0.12.0
I'm on the latest stable nodejs (v16.x)
Same issue here but on an intel mac.
+1
I have a project in which
grpc
is not listed on package.json but I can see in terminal it's installing grpc. it failed eventuallyplease help
ERROR MESSAGE I'm on the latest stable nodejs (v16.x)
How did you resolve this issue?
This is apparently now fixed! https://github.com/grpc/grpc-node/issues/1405#issuecomment-1268791265
That issue is about grpc-tools
, which is a different package. The grpc
package does not support Mac M1, and it is deprecated so that will not change. We recommend using @grpc/grpc-js
instead.
That issue is about
grpc-tools
, which is a different package. Thegrpc
package does not support Mac M1, and it is deprecated so that will not change. We recommend using@grpc/grpc-js
instead.
Oops, sorry, thanks for clarifying that
I can't remember what the resolution was. Sorry.
On Sun, Apr 2, 2023 at 12:10 PM Do Nguyen Thanh @.***> wrote:
May I know any updates on this?
— Reply to this email directly, view it on GitHub https://github.com/grpc/grpc-node/issues/1880#issuecomment-1493381420, or unsubscribe https://github.com/notifications/unsubscribe-auth/AA2S7RWCDBRQQ7L7EZZRZJTW7GQHRANCNFSM5B7MGMIA . You are receiving this because you commented.Message ID: @.***>