Skip to content

Commit

Permalink
Update staging and CI
Browse files Browse the repository at this point in the history
  • Loading branch information
dhadka committed Dec 30, 2023
1 parent dd323ce commit 29a69f4
Show file tree
Hide file tree
Showing 5 changed files with 47 additions and 28 deletions.
21 changes: 0 additions & 21 deletions .github/workflows/build-windows.yml

This file was deleted.

3 changes: 1 addition & 2 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,7 @@ jobs:
with:
java-version: ${{ matrix.java }}
distribution: zulu
- name: Build native programs (Linux only)
if: runner.os == 'Linux'
- name: Build native programs
run: make -C native
- name: Build and test with Maven
run: mvn package
Expand Down
22 changes: 22 additions & 0 deletions .github/workflows/stage.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,21 @@ on:
type: boolean

jobs:
build:
runs-on: windows-latest
steps:
- uses: actions/checkout@v3
- name: Build Windows native files
run: make -C native
- name: Create native bundle
run: zip -r native-windows.zip native
- uses: actions/upload-artifact@v4
if: always()
with:
name: native-windows
path: native-windows.zip
stage:
needs: build
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
Expand Down Expand Up @@ -76,10 +90,18 @@ jobs:
with:
name: Maven bundle
path: maven/*-bundle.jar
- name: Download Windows native bundle
uses: actions/download-artifact@v4
if: always()
with:
name: native-windows
- name: Show content
run: ls -R .
- name: Stage GitHub release
if: ${{ inputs.publish_github }}
run: |
gh release create "v${{ inputs.version }}" --draft --title "Version ${{ inputs.version }}" \
native-windows.zip \
target/${BUILD_ARTIFACT}.jar \
$([ -f "${BUILD_ARTIFACT}-jar-with-dependencies.jar" ] && echo "target/${BUILD_ARTIFACT}-jar-with-dependencies.jar" || echo "")
env:
Expand Down
23 changes: 21 additions & 2 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,5 +1,24 @@
.settings/
target/
jMetal.log
dependency-reduced-pom.xml
native/WDS/bin/reportFile.rpt

*.so
*.exe
*.dll

native/HBV/bin/hbv
native/LRGV/bin/lrgv
native/LakeProblem/bin/lake
native/WDS/bin/BAK
native/WDS/bin/BIN
native/WDS/bin/BLA
native/WDS/bin/EXN
native/WDS/bin/FOS
native/WDS/bin/GOY
native/WDS/bin/HAN
native/WDS/bin/MOD
native/WDS/bin/NYT
native/WDS/bin/PES
native/WDS/bin/TLN
native/WDS/bin/TRN
native/WDS/bin/reportFile.rpt
6 changes: 3 additions & 3 deletions native/Radar/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -3,11 +3,11 @@ SHARED_DIR = ../shared
C_FLAGS = -Wall -O3 -fPIC

ifeq ($(OS),Windows_NT)
EXT = dll
LIB_NAME = moeaframework.dll
else
EXT = so
LIB_NAME = libmoeaframework.so
endif

all:
$(CC) $(C_FLAGS) -shared -o bin/moeaframework.$(EXT) -c $(SHARED_DIR)/moeaframework.c
$(CC) $(C_FLAGS) -shared -o bin/$(LIB_NAME) -c $(SHARED_DIR)/moeaframework.c

0 comments on commit 29a69f4

Please sign in to comment.