Skip to content

Commit 8369f8d

Browse files
authored
Merge pull request #60 from libxengine/develop
V3.19 Merge
2 parents 6bec8fd + 64d6401 commit 8369f8d

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

54 files changed

+1780
-566
lines changed
+78
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,78 @@
1+
name: rocky Arm64 build workflows
2+
3+
on:
4+
push:
5+
branches:
6+
- 'develop'
7+
paths:
8+
- 'XEngine_Source/**'
9+
- 'XEngine_Release/**'
10+
- '.github/**'
11+
12+
permissions:
13+
contents: read
14+
15+
jobs:
16+
build:
17+
runs-on: ubuntu-24.04
18+
env:
19+
IMAGE_NAME: rockylinux/rockylinux:9.5
20+
21+
strategy:
22+
fail-fast: false
23+
matrix:
24+
arch: [linux/arm64]
25+
26+
steps:
27+
# 检出您的主仓库代码
28+
- name: Checkout main repository code
29+
uses: actions/checkout@v4
30+
with:
31+
ref: 'develop'
32+
33+
- name: Set up QEMU
34+
uses: docker/setup-qemu-action@v3
35+
36+
- name: Build ${{ matrix.arch }}
37+
run: |
38+
docker run --platform ${{ matrix.arch }} --rm \
39+
-v ${{ github.workspace }}:/workspace \
40+
-w /workspace ${{ env.IMAGE_NAME }} /bin/sh -c '
41+
set -e
42+
dnf update -y
43+
dnf install --allowerasing git make g++ wget curl jq unzip -y
44+
45+
git config --global --add safe.directory /workspace
46+
git submodule init
47+
git submodule update
48+
49+
latest_tag=$(curl -s https://api.github.com/repos/libxengine/libxengine/releases/latest | jq -r .tag_name)
50+
wget https://github.com/libxengine/libxengine/releases/download/$latest_tag/XEngine_RockyLinux_9_Arm64.zip
51+
unzip ./XEngine_RockyLinux_9_Arm64.zip -d ./XEngine_RockyLinux_9_Arm64
52+
cd XEngine_RockyLinux_9_Arm64
53+
54+
chmod 777 ./XEngine_LINEnv.sh
55+
./XEngine_LINEnv.sh -i 0
56+
57+
cp -rf ./XEngine_Include /usr/local/include
58+
find ./XEngine_Linux -name "*.so" -exec cp {} /usr/lib64 \;
59+
ldconfig
60+
cd ..
61+
62+
cd XEngine_Source
63+
make ARCH=Arm64 RELEASE=1
64+
make FLAGS=InstallAll
65+
make FLAGS=CleanAll
66+
cd ..
67+
68+
cd XEngine_Release
69+
./XEngine_XStorageApp -t
70+
chown -R $(id -u):$(id -g) .
71+
chmod -R a+r . '
72+
73+
- name: Upload folder as artifact with RockyLinux
74+
uses: actions/upload-artifact@v4
75+
with:
76+
name: XEngine_XStorageApp-RockyLinux_9_Arm64
77+
path: XEngine_Release/
78+
retention-days: 1
+83
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,83 @@
1+
name: rocky x86_64 build workflows
2+
3+
on:
4+
push:
5+
branches:
6+
- 'develop'
7+
paths:
8+
- 'XEngine_Source/**'
9+
- 'XEngine_Release/**'
10+
- '.github/**'
11+
12+
permissions:
13+
contents: read
14+
15+
jobs:
16+
build:
17+
runs-on: ubuntu-latest
18+
container:
19+
image: rockylinux/rockylinux:9.5
20+
21+
steps:
22+
# 检出您的主仓库代码
23+
- name: Checkout main repository code
24+
uses: actions/checkout@v4
25+
with:
26+
ref: 'develop'
27+
28+
# 检出依赖的xengine仓库到指定的xengine目录
29+
- name: Checkout dependency repository (xengine)
30+
uses: actions/checkout@v4
31+
with:
32+
repository: libxengine/libxengine
33+
path: libxengine
34+
35+
- name: sub module checkout (opensource)
36+
uses: actions/checkout@v4
37+
with:
38+
repository: libxengine/XEngine_OPenSource
39+
path: XEngine_Source/XEngine_Depend
40+
41+
- name: install system package
42+
run: |
43+
dnf update -y
44+
dnf install gcc g++ make git jq unzip -y
45+
# 设置依赖库的环境变量
46+
- name: Set up Dependency rocky linux Environment
47+
run: |
48+
cd libxengine
49+
chmod 777 *
50+
./XEngine_LINEnv.sh -i 0
51+
- name: install xengine library
52+
run: |
53+
latest_tag=$(curl -s https://api.github.com/repos/libxengine/libxengine/releases/latest | jq -r .tag_name)
54+
wget https://github.com/libxengine/libxengine/releases/download/$latest_tag/XEngine_RockyLinux_9_x86-64.zip
55+
unzip ./XEngine_RockyLinux_9_x86-64.zip -d ./XEngine_RockyLinux_9_x86-64
56+
cd XEngine_RockyLinux_9_x86-64
57+
58+
cp -rf ./XEngine_Include /usr/local/include
59+
find ./XEngine_Linux -name "*.so" -exec cp {} /usr/lib64 \;
60+
ldconfig
61+
62+
- name: make
63+
run: |
64+
cd XEngine_Source
65+
make
66+
make FLAGS=InstallAll
67+
make FLAGS=CleanAll
68+
69+
make RELEASE=1
70+
make FLAGS=InstallAll
71+
make FLAGS=CleanAll
72+
73+
- name: test
74+
run: |
75+
cd XEngine_Release
76+
./XEngine_XStorageApp -t
77+
78+
- name: Upload folder as artifact with RockyLinux
79+
uses: actions/upload-artifact@v4
80+
with:
81+
name: XEngine_XStorageApp-RockyLinux_9_x86_64
82+
path: XEngine_Release/
83+
retention-days: 1
+74
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,74 @@
1+
name: ubuntu Arm64 build workflows
2+
3+
on:
4+
push:
5+
branches:
6+
- 'develop'
7+
paths:
8+
- 'XEngine_Source/**'
9+
- 'XEngine_Release/**'
10+
- '.github/**'
11+
12+
jobs:
13+
build:
14+
runs-on: ubuntu-24.04
15+
env:
16+
IMAGE_NAME: ubuntu:24.04
17+
18+
strategy:
19+
fail-fast: false
20+
matrix:
21+
arch: [linux/arm64]
22+
23+
steps:
24+
- name: Checkout main repository code
25+
uses: actions/checkout@v4
26+
with:
27+
ref: 'develop'
28+
29+
- name: Set up QEMU
30+
uses: docker/setup-qemu-action@v3
31+
32+
- name: Build ${{ matrix.arch }}
33+
run: |
34+
docker run --platform ${{ matrix.arch }} --rm \
35+
-v ${{ github.workspace }}:/workspace \
36+
-w /workspace ${{ env.IMAGE_NAME }} /bin/sh -c '
37+
set -e
38+
apt update -y
39+
apt install git make g++ wget curl jq unzip -y
40+
41+
git config --global --add safe.directory /workspace
42+
git submodule init
43+
git submodule update
44+
45+
latest_tag=$(curl -s https://api.github.com/repos/libxengine/libxengine/releases/latest | jq -r .tag_name)
46+
wget https://github.com/libxengine/libxengine/releases/download/$latest_tag/XEngine_UBuntu_24.04_Arm64.zip
47+
unzip ./XEngine_UBuntu_24.04_Arm64.zip -d ./XEngine_UBuntu_24.04_Arm64
48+
cd XEngine_UBuntu_24.04_Arm64
49+
50+
chmod 777 ./XEngine_LINEnv.sh
51+
./XEngine_LINEnv.sh -i 0
52+
53+
cp -rf ./XEngine_Include /usr/local/include
54+
find ./XEngine_Linux -name "*.so" -exec cp {} /usr/local/lib \;
55+
ldconfig
56+
cd ..
57+
58+
cd XEngine_Source
59+
make ARCH=Arm64 RELEASE=1
60+
make FLAGS=InstallAll
61+
make FLAGS=CleanAll
62+
cd ..
63+
64+
cd XEngine_Release
65+
./XEngine_XStorageApp -t
66+
chown -R $(id -u):$(id -g) .
67+
chmod -R a+r . '
68+
69+
- name: Upload folder as artifact with ubuntu Arm64
70+
uses: actions/upload-artifact@v4
71+
with:
72+
name: XEngine_XStorageApp-Ubuntu_24.04_Arm64
73+
path: XEngine_Release/
74+
retention-days: 1

.github/workflows/codeql.yml

+62
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,62 @@
1+
name: CodeQL Advanced
2+
3+
on:
4+
push:
5+
branches:
6+
- 'develop'
7+
paths:
8+
- 'XEngine_Source/**'
9+
- 'XEngine_Release/**'
10+
- '.github/**'
11+
12+
jobs:
13+
analyze:
14+
runs-on: ubuntu-24.04
15+
permissions:
16+
security-events: write
17+
packages: read
18+
actions: read
19+
contents: read
20+
21+
strategy:
22+
fail-fast: false
23+
matrix:
24+
include:
25+
- language: c-cpp
26+
steps:
27+
- name: Checkout repository
28+
uses: actions/checkout@v4
29+
with:
30+
ref: 'develop'
31+
32+
- name: Checkout dependency repository (xengine)
33+
uses: actions/checkout@v4
34+
with:
35+
repository: libxengine/libxengine
36+
path: libxengine
37+
38+
- name: sub module checkout (opensource)
39+
run: |
40+
git submodule init
41+
git submodule update
42+
43+
- name: Set up Dependency Environment
44+
run: |
45+
cd libxengine
46+
chmod +x ./XEngine_LINEnv.sh
47+
sudo ./XEngine_LINEnv.sh -i 3
48+
49+
- name: Initialize CodeQL
50+
uses: github/codeql-action/init@v3
51+
with:
52+
languages: ${{ matrix.language }}
53+
54+
- name: make
55+
run: |
56+
cd XEngine_Source
57+
make
58+
59+
- name: Perform CodeQL Analysis
60+
uses: github/codeql-action/analyze@v3
61+
with:
62+
category: "/language:${{ matrix.language }}"

.github/workflows/macbuild.yml

+5-3
Original file line numberDiff line numberDiff line change
@@ -87,11 +87,13 @@ jobs:
8787
if: matrix.os == 'macos-13'
8888
uses: actions/upload-artifact@v4
8989
with:
90-
name: XEngine_XStorageApp-x86_64-Mac
90+
name: XEngine_XStorageApp-Mac_x86_64
9191
path: XEngine_Release/
92+
retention-days: 1
9293
- name: Upload folder as artifact with mac arm
9394
if: matrix.os == 'macos-14'
9495
uses: actions/upload-artifact@v4
9596
with:
96-
name: XEngine_XStorageApp-Arm64-Mac
97-
path: XEngine_Release/
97+
name: XEngine_XStorageApp-Mac_Arm64
98+
path: XEngine_Release/
99+
retention-days: 1

0 commit comments

Comments
 (0)