From b3b6f7264367c87eda6a3270d02796072567ecc3 Mon Sep 17 00:00:00 2001 From: Nazar Hussain Date: Fri, 10 Nov 2023 16:51:38 +0300 Subject: [PATCH] Add a new workflow to build nodejs --- .github/workflows/build-debug-node.yml | 54 ++++++++++++++++++++++++++ 1 file changed, 54 insertions(+) create mode 100644 .github/workflows/build-debug-node.yml diff --git a/.github/workflows/build-debug-node.yml b/.github/workflows/build-debug-node.yml new file mode 100644 index 000000000000..24eae6a04c18 --- /dev/null +++ b/.github/workflows/build-debug-node.yml @@ -0,0 +1,54 @@ +name: Build debug node + +on: + workflow_dispatch: + inputs: + version: + required: true + description: 'Node.js version' + +jobs: + build: + name: Build Debug version of Node.js + runs-on: buildjet-4vcpu-ubuntu-2204 + strategy: + fail-fast: false + steps: + - name: Install dependencies + run: apt-get install python3 g++ make python3-pip + + - name: Download Node.js source + uses: actions/checkout@v4 + with: + repository: 'nodejs/node' + ref: 'v${{ github.event.inputs.version }}' + path: 'nodejs' + + - name: Configure nodejs with debug flag + run: ./configure --debug + working-directory: 'nodejs' + + - name: Compile the nodejs + run: make -j4 + working-directory: 'nodejs' + + - name: Verify the build + run: make test-only + working-directory: 'nodejs' + + - name: Create destination folder + run: mkdir -p ${{ github.workspace }}/nodejs-debug-build-${{ github.event.inputs.version }} + + - name: Copy nodejs build + run: make install + working-directory: 'nodejs' + env: + DESTDIR: ${{ github.workspace }}/nodejs-debug-build-${{ github.event.inputs.version }} + + - name: Upload build to artifacts + uses: actions/upload-artifact@v3 + with: + name: nodejs-debug-build-${{ github.event.inputs.version }} + path: nodejs-debug-build-${{ github.event.inputs.version }} + +