Skip to content

Commit

Permalink
Merge pull request #85 from binarly-io/enhancement/workflow
Browse files Browse the repository at this point in the history
improve workflow: build and analyse everything with a single job
  • Loading branch information
yeggor authored Dec 20, 2023
2 parents 05a7dd8 + 39b1ab8 commit 1edc232
Show file tree
Hide file tree
Showing 2 changed files with 21 additions and 130 deletions.
105 changes: 18 additions & 87 deletions .github/workflows/ci-build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,84 +3,6 @@ on:
push:
pull_request:
jobs:
build_windows_loader:
runs-on: windows-2019
steps:
- uses: actions/checkout@v3
with:
submodules: true
- name: Dowload IDA SDK
shell: cmd
env:
IDA_SDK: ${{ secrets.DOWNLOAD_LINK_IDA_SDK }}
PASSWORD: ${{ secrets.ZIP_PASSWORD }}
run: |
curl -J -L "%IDA_SDK%" -o idasdk83.zip
unzip -P "%PASSWORD%" idasdk83.zip
- name: Build efiXloader
run: |
cd efiXloader
mkdir build
cd build
cmake .. -DIdaSdk_ROOT_DIR=D:/a/efiXplorer/efiXplorer/idasdk83
cmake --build . --config Release
- uses: actions/upload-artifact@master
with:
name: efiXloader64.dll
path: efiXloader/build/Release/efiXloader64.dll
build_linux_loader:
runs-on: ubuntu-20.04
steps:
- uses: actions/checkout@v3
with:
submodules: true
- name: Dowload IDA SDK
shell: bash
env:
IDA_SDK: ${{ secrets.DOWNLOAD_LINK_IDA_SDK }}
PASSWORD: ${{ secrets.ZIP_PASSWORD }}
run: |
cd ..
curl -J -L "$IDA_SDK" -o idasdk83.zip
unzip -P $PASSWORD idasdk83.zip
- name: Build efiXloader
run: |
git submodule update --init --recursive
cd efiXloader
mkdir build
cd build
cmake .. -DIdaSdk_ROOT_DIR="../../idasdk83"
cmake --build . --config Release
- uses: actions/upload-artifact@master
with:
name: efiXloader64.so
path: efiXloader/build/efiXloader64.so
build_osx_loader:
runs-on: macos-latest
steps:
- uses: actions/checkout@v3
with:
submodules: true
- name: Dowload IDA SDK
shell: bash
env:
IDA_SDK: ${{ secrets.DOWNLOAD_LINK_IDA_SDK }}
PASSWORD: ${{ secrets.ZIP_PASSWORD }}
run: |
cd ..
curl -J -L "$IDA_SDK" -o idasdk83.zip
unzip -P $PASSWORD idasdk83.zip
- name: Build efiXloader
run: |
cd efiXloader
mkdir build
cd build
cmake .. -DIdaSdk_ROOT_DIR="../../idasdk83"
cmake --build . --config Release
- uses: actions/upload-artifact@master
with:
name: efiXloader64.dylib
path: efiXloader/build/efiXloader64.dylib
build_windows:
runs-on: windows-2019
steps:
Expand All @@ -98,19 +20,22 @@ jobs:
unzip -P "%PASSWORD%" idasdk83.zip
- name: Build efiXplorer
run: |
cd efiXplorer
mkdir build
cd build
cmake .. -DIdaSdk_ROOT_DIR="../../idasdk83" -DHexRaysSdk_ROOT_DIR="../../hexrays_sdk"
cmake --build . --config Release
- uses: actions/upload-artifact@master
with:
name: efiXplorer.dll
path: efiXplorer/build/Release/efiXplorer.dll
path: build/efiXplorer/Release/efiXplorer.dll
- uses: actions/upload-artifact@master
with:
name: efiXplorer64.dll
path: efiXplorer/build/Release/efiXplorer64.dll
path: build/efiXplorer/Release/efiXplorer64.dll
- uses: actions/upload-artifact@master
with:
name: efiXloader64.dll
path: build/efiXloader/Release/efiXloader64.dll
build_linux:
runs-on: ubuntu-20.04
steps:
Expand All @@ -128,19 +53,22 @@ jobs:
unzip -P $PASSWORD idasdk83.zip
- name: Build efiXplorer
run: |
cd efiXplorer
mkdir build
cd build
cmake .. -DIdaSdk_ROOT_DIR="../../idasdk83" -DHexRaysSdk_ROOT_DIR="../../hexrays_sdk"
cmake --build . --config Release
- uses: actions/upload-artifact@master
with:
name: efiXplorer.so
path: efiXplorer/build/efiXplorer.so
path: build/efiXplorer/efiXplorer.so
- uses: actions/upload-artifact@master
with:
name: efiXplorer64.so
path: efiXplorer/build/efiXplorer64.so
path: build/efiXplorer/efiXplorer64.so
- uses: actions/upload-artifact@master
with:
name: efiXloader64.so
path: build/efiXloader/efiXloader64.so
build_osx:
runs-on: macos-latest
steps:
Expand All @@ -158,16 +86,19 @@ jobs:
unzip -P $PASSWORD idasdk83.zip
- name: Build efiXplorer
run: |
cd efiXplorer
mkdir build
cd build
cmake .. -DIdaSdk_ROOT_DIR="../../idasdk83" -DHexRaysSdk_ROOT_DIR="../../hexrays_sdk"
cmake --build . --config Release
- uses: actions/upload-artifact@master
with:
name: efiXplorer.dylib
path: efiXplorer/build/efiXplorer.dylib
path: build/efiXplorer/efiXplorer.dylib
- uses: actions/upload-artifact@master
with:
name: efiXplorer64.dylib
path: efiXplorer/build/efiXplorer64.dylib
path: build/efiXplorer/efiXplorer64.dylib
- uses: actions/upload-artifact@master
with:
name: efiXloader64.dylib
path: build/efiXloader/efiXloader64.dylib
46 changes: 3 additions & 43 deletions .github/workflows/codeql-analysis.yml
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
name: "CodeQL"
on:
push:
branches: [ master, dev ]
branches: [ master ]
pull_request:
# The branches below must be a subset of the branches above
branches: [ master ]

jobs:
analyze-efiXplorer:
analyze-everything:
name: Analyze efiXplorer
runs-on: ubuntu-latest
permissions:
Expand Down Expand Up @@ -37,51 +37,11 @@ jobs:
cd ..
curl -J -L "$IDA_SDK" -o idasdk83.zip
unzip -P $PASSWORD idasdk83.zip
cd efiXplorer/efiXplorer
cd efiXplorer
mkdir build
cd build
cmake .. -DIdaSdk_ROOT_DIR="../../idasdk83" -DHexRaysSdk_ROOT_DIR="../../hexrays_sdk"
cmake --build . --config Release
- name: Perform CodeQL Analysis
uses: github/codeql-action/analyze@v2

analyze-efiXloader:
name: Analyze efiXloader
runs-on: ubuntu-latest
permissions:
actions: read
contents: read
security-events: write

strategy:
fail-fast: false
matrix:
language: [ 'cpp' ]

steps:
- name: Checkout repository
uses: actions/checkout@v2

- name: Initialize CodeQL
uses: github/codeql-action/init@v2
with:
languages: ${{ matrix.language }}

- name: Autobuild
env:
IDA_SDK: ${{ secrets.DOWNLOAD_LINK_IDA_SDK }}
PASSWORD: ${{ secrets.ZIP_PASSWORD }}
run: |
git submodule update --init --recursive
cd ..
curl -J -L "$IDA_SDK" -o idasdk83.zip
unzip -P $PASSWORD idasdk83.zip
cd efiXplorer/efiXloader
mkdir build
cd build
cmake .. -DIdaSdk_ROOT_DIR="../../idasdk83"
cmake --build . --config Release
- name: Perform CodeQL Analysis
uses: github/codeql-action/analyze@v2

0 comments on commit 1edc232

Please sign in to comment.