kentkwu commented on code in PR #4046:
URL: https://github.com/apache/arrow-adbc/pull/4046#discussion_r2886392468


##########
.github/workflows/packaging.yml:
##########
@@ -1096,6 +1096,151 @@ jobs:
           docker compose run python-sdist-test
           popd
 
+  node-binaries:
+    name: "Node.js ${{ matrix.settings.arch }} ${{ matrix.settings.os }}"
+    runs-on: ${{ matrix.settings.host }}
+    needs:
+      - source
+    strategy:
+      fail-fast: false
+      matrix:
+        settings:
+          - host: macos-15-intel
+            target: x86_64-apple-darwin
+            arch: amd64
+            os: macOS
+            build: npx napi build --platform --release --target 
x86_64-apple-darwin
+          - host: macos-latest
+            target: aarch64-apple-darwin
+            arch: arm64
+            os: macOS
+            build: npx napi build --platform --release --target 
aarch64-apple-darwin
+          - host: windows-latest
+            target: x86_64-pc-windows-msvc
+            arch: amd64
+            os: Windows
+            build: npx napi build --platform --release --target 
x86_64-pc-windows-msvc
+          - host: ubuntu-latest
+            target: x86_64-unknown-linux-gnu
+            arch: amd64
+            os: Linux
+            build: npx napi build --platform --release --target 
x86_64-unknown-linux-gnu --use-napi-cross
+          - host: ubuntu-latest
+            target: aarch64-unknown-linux-gnu
+            arch: arm64
+            os: Linux
+            build: npx napi build --platform --release --target 
aarch64-unknown-linux-gnu --use-napi-cross
+    steps:
+      - uses: actions/download-artifact@v6
+        with:
+          name: source
+
+      - name: Extract source archive
+        run: |
+          source_archive=$(echo apache-arrow-adbc-*.tar.gz)
+          VERSION=${source_archive#apache-arrow-adbc-}
+          VERSION=${VERSION%.tar.gz}
+
+          tar xf apache-arrow-adbc-${VERSION}.tar.gz
+          mv apache-arrow-adbc-${VERSION} adbc
+
+      - name: Setup Node
+        uses: actions/setup-node@v4
+        with:
+          node-version: 22
+          cache: 'npm'
+          cache-dependency-path: adbc/javascript/package-lock.json
+
+      - name: Setup Rust
+        uses: dtolnay/rust-toolchain@631a55b12751854ce901bb631d5902ceb48146f7 
# stable
+        with:
+          toolchain: stable
+          targets: ${{ matrix.settings.target }}
+
+      - name: Install Node dependencies
+        working-directory: adbc/javascript
+        run: npm install
+
+      - name: Build Node.js binaries
+        working-directory: adbc/javascript
+        run: ${{ matrix.settings.build }}
+        shell: bash
+
+      - name: Sign binary (macOS)
+        if: runner.os == 'macOS'
+        working-directory: adbc/javascript
+        run: codesign --sign - *.node

Review Comment:
   @zeroshade this ad hoc signing is sufficient for a npm distributed `.node` 
file. Certificate signing is only required for apps (ex. `.dmg`) that will be 
opened by a user. Ad hoc signed binaries can be opened via `dlopen()` without 
issue on macOS.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to