[node-api-headers] add missing compile definitions (#30903)

* [node-api-headers] add missing compile definitions

* add ver

* spelling

* add-ver
This commit is contained in:
Leonid Pospelov 2023-04-18 04:36:48 +06:00 committed by GitHub
parent 902745368f
commit e4c66a59d9
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
4 changed files with 14 additions and 1 deletions

View File

@ -12,11 +12,18 @@ if(NOT TARGET unofficial::node-api-headers::node-api-headers)
)
if(APPLE)
# setting those properties like cmake-js does
# https://github.com/cmake-js/cmake-js/blob/272ec1883bc1207205abae948022eecdea02e225/lib/toolset.js#L126
set_target_properties(unofficial::node-api-headers::node-api-headers PROPERTIES
INTERFACE_LINK_OPTIONS "LINKER:SHELL:-undefined dynamic_lookup"
)
set_target_properties(unofficial::node-api-headers::node-api-headers PROPERTIES
INTERFACE_COMPILE_DEFINITIONS "_DARWIN_USE_64_BIT_INODE=1;_LARGEFILE_SOURCE;_FILE_OFFSET_BITS=64"
)
endif()
set_property(TARGET unofficial::node-api-headers::node-api-headers APPEND PROPERTY INTERFACE_COMPILE_DEFINITIONS "BUILDING_NODE_EXTENSION")
if(WIN32)
find_library(node-api-headers_LIBRARY_RELEASE NAMES node PATHS "${CMAKE_CURRENT_LIST_DIR}/../../lib" NO_DEFAULT_PATH REQUIRED)
set_target_properties(unofficial::node-api-headers::node-api-headers PROPERTIES

View File

@ -1,6 +1,7 @@
{
"name": "node-api-headers",
"version": "0.0.5",
"port-version": 1,
"description": "NodeJS API for writing modules in C++",
"homepage": "https://nodejs.org/api/addons.html",
"license": "MIT",

View File

@ -5566,7 +5566,7 @@
},
"node-api-headers": {
"baseline": "0.0.5",
"port-version": 0
"port-version": 1
},
"nonius": {
"baseline": "2019-04-20",

View File

@ -1,5 +1,10 @@
{
"versions": [
{
"git-tree": "1a4d676ae2409acc29b77934186b1232e3a80408",
"version": "0.0.5",
"port-version": 1
},
{
"git-tree": "d8703d51a9b88c204782885707fc580ab490e9f4",
"version": "0.0.5",