Skip to content

Build Depends and Submit #7

Build Depends and Submit

Build Depends and Submit #7

name: Build Depends and Submit
on:
schedule:
- cron: '00 00/12 * * *'
workflow_dispatch: {}
jobs:
Builder:
runs-on: macos-latest
steps:
- name: Checkout Code
uses: actions/checkout@v4
- name: Checkout Code From Local Repository
uses: actions/checkout@v4
with:
ref: 'ci_cd_auto_build_depends'
path: 'ci_cd_auto_build_depends'
- name: Checkout Code From Remote Repository
uses: actions/checkout@v4
with:
repository: 'bouldev/neo-omega-kernel'
path: 'neomega_kernel'
- name: Set Up Go
uses: actions/setup-go@v2
- name: Configure Raknet
run: |
mkdir configure_raknet_depends
cd configure_raknet_depends
go mod init configure_raknet_depends
go get github.com/sandertv/[email protected]
sudo sed -i "" "s/urrentProtocol byte = 11/urrentProtocol byte = 8/g" /Users/runner/go/pkg/mod/github.com/sandertv/[email protected]/conn.go
- name: Configure Makefile
run: mv ci_cd_auto_build_depends/Makefile neomega_kernel/neomega/c_api
- name: Install Dependencies
run: |
brew install mingw-w64
brew install messense/macos-cross-toolchains/x86_64-unknown-linux-gnu
brew install messense/macos-cross-toolchains/aarch64-unknown-linux-gnu
brew install android-ndk
brew install make
- name: Build Connect Library
run: |
cd neomega_kernel/neomega/c_api
make all
rm -rf libs/*.h
- name: Build Access Point
run: |
cd neomega_kernel/neomega/entries/access_point_entry/cli
GODEBUG=madvdontneed=1 CGO_ENABLED=0 GOOS=linux GOARCH=amd64 go build -o build/neomega_linux_access_point_amd64
GODEBUG=madvdontneed=1 CGO_ENABLED=0 GOOS=windows GOARCH=amd64 go build -o build/neomega_windows_access_point_amd64.exe
GODEBUG=madvdontneed=1 CGO_ENABLED=0 GOOS=linux GOARCH=arm64 go build -o build/neomega_linux_access_point_arm64
GODEBUG=madvdontneed=1 CGO_ENABLED=0 GOOS=windows GOARCH=arm64 go build -o build/neomega_windows_access_point_arm64.exe
GODEBUG=madvdontneed=1 CGO_ENABLED=0 GOOS=android GOARCH=arm64 go build -o build/neomega_android_arm64
- name: Move Binary Files and Clean Up
run: |
mv neomega_kernel/neomega/c_api/libs/* ./
mv neomega_kernel/neomega/entries/access_point_entry/cli/build/* ./
rm -rf configure_raknet_depends
rm -rf ci_cd_auto_build_depends
rm -rf neomega_kernel
- name: Submit Changes
uses: EndBug/add-and-commit@v9
with:
default_author: github_actions
message: '[AUTO] build depends and submit'
push: '-f' # 要求暴力推送