node-sword-interface 1.0.90 → 1.0.92

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/binding.gyp CHANGED
@@ -1,13 +1,13 @@
1
1
  {
2
2
  "variables": {
3
3
  # 1. Detect if we are on iOS
4
- "is_ios%": "<!(python3 -c \"import os; sdk = os.environ.get('SDKROOT', ''); print(1 if 'iPhone' in sdk or os.environ.get('PLATFORM') == 'ios' else 0)\")",
4
+ "is_ios%": "<!(node -e \"console.log(process.env.SDKROOT?.includes('iPhone') || process.env.PLATFORM === 'ios' ? 1 : 0)\")",
5
5
 
6
6
  # 2. Get the deployment target (e.g., '15.0') from env, default to '13.0'
7
- "ios_ver%": "<!(python3 -c \"import os; print(os.environ.get('IPHONEOS_DEPLOYMENT_TARGET', '13.0'))\")",
7
+ "ios_ver%": "<!(node -e \"console.log(process.env.IPHONEOS_DEPLOYMENT_TARGET || '13.0')\")",
8
8
 
9
9
  # 3. Detect the SDK to use (iphoneos or iphonesimulator)
10
- "ios_sdk": "<!(python3 -c \"import os; print('iphonesimulator' if 'iPhoneSimulator' in os.environ.get('SDKROOT', '') else 'iphoneos')\")"
10
+ "ios_sdk": "<!(node -e \"console.log(process.env.SDKROOT?.includes('iPhoneSimulator') ? 'iphonesimulator' : 'iphoneos')\")"
11
11
  },
12
12
  "targets": [
13
13
  {
@@ -192,8 +192,7 @@
192
192
  '-lNormaliz.lib'
193
193
  ],
194
194
  "dependencies": [
195
- 'sword',
196
- "<!(node -p \"require('node-addon-api').gyp\")"
195
+ 'sword'
197
196
  ],
198
197
  'defines': [ 'SWUSINGDLL' ]
199
198
  }]
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "node-sword-interface",
3
- "version": "1.0.90",
3
+ "version": "1.0.92",
4
4
  "description": "Javascript (N-API) interface to SWORD library",
5
5
  "keywords": [
6
6
  "C++",
@@ -117,10 +117,19 @@ else
117
117
  # macOS & Linux
118
118
 
119
119
  cd sword_build
120
- cmake -DLIBSWORD_LIBRARY_TYPE=Static -DCMAKE_CXX_STANDARD=11 \
121
- -DCMAKE_BUILD_TYPE=$SWORD_BUILD_TYPE \
122
- -DCMAKE_DISABLE_FIND_PACKAGE_ICU=TRUE \
123
- ../sword
120
+
121
+ if [ "$(uname -s)" = "Darwin" ]; then
122
+ cmake -DLIBSWORD_LIBRARY_TYPE=Static -DCMAKE_CXX_STANDARD=11 \
123
+ -DCMAKE_BUILD_TYPE=$SWORD_BUILD_TYPE \
124
+ -DCMAKE_DISABLE_FIND_PACKAGE_ICU=TRUE \
125
+ -DCMAKE_OSX_ARCHITECTURES="arm64;x86_64" \
126
+ ../sword
127
+ else
128
+ cmake -DLIBSWORD_LIBRARY_TYPE=Static -DCMAKE_CXX_STANDARD=11 \
129
+ -DCMAKE_BUILD_TYPE=$SWORD_BUILD_TYPE \
130
+ -DCMAKE_DISABLE_FIND_PACKAGE_ICU=TRUE \
131
+ ../sword
132
+ fi
124
133
  fi
125
134
 
126
135
  make -j4 sword_static