diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 6d087ce..c01797a 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -2,6 +2,64 @@ name: Build on: [ push ] jobs: + linux: + strategy: + matrix: + configuration: [ Release, Debug ] + + name: Linux + runs-on: ubuntu-latest + + steps: + - uses: actions/checkout@v3 + name: Checkout repository + with: + submodules: recursive + + - name: Install Arch Linux + run: curl -L https://github.com/zaoqi/github-actions-archlinux/raw/master/install.sh | sh + + - name: Install required packages + run: sudo pacman --no-confirm -Syu \ + base-devel \ + clang \ + cmake \ + ninja \ + pugixml \ + ogre \ + qt6 + + - name: Generate Ninja build files + run: cmake -G Ninja -B build -DCI=ON -DCMAKE_BUILD_TYPE=${{ matrix.configuration == 'Release' && 'MinSizeRel' || matrix.configuration }} . + + - name: Run Ninja build + run: ninja -C build + + # ouch - unless and until we start using CMake's install command, these next few steps are a necessary evil + - name: Organize binaries + run: mkdir build/dist && find build -perm /a+x -exec mv {} build/dist \; + + - name: Add RNR resources + run: cp -R Content/RNR build/dist/content && cp LICENSE build/dist + + - name: Add OGRE plugins + run: cp -R build/plugins build/dist && cp Content/linux_plugins.cfg build/dist/plugins.cfg + + - name: Add OGRE shaders + run: cp -R build/shaders build/dist + + - name: Set output variables + id: vars + run: | + echo "configuration=${{ matrix.configuration }}" | awk '{print tolower($0)}' >> $GITHUB_OUTPUT + echo "hash=${GITHUB_SHA::7}" >> $GITHUB_OUTPUT + + - name: Upload artifact + uses: actions/upload-artifact@v3 + with: + name: rnr-${{ steps.vars.outputs.hash }}-linux_x64-${{ steps.vars.outputs.configuration }} + path: build/dist + windows: strategy: matrix: @@ -18,7 +76,7 @@ jobs: steps: - uses: actions/checkout@v3 - name: Clone repository + name: Checkout repository with: submodules: recursive @@ -58,7 +116,7 @@ jobs: run: mkdir build/dist/shaders && cp -R /${{ matrix.sys }}/share/OGRE/Media/Main/* build/dist/shaders && cp -R /${{ matrix.sys }}/share/OGRE/Media/RTShaderLib/* build/dist/shaders - name: Add additional runtime dependencies - run: ldd build/dist/*.exe | grep "=> /" | awk '{print $3}' | grep "clang64" | xargs -I '{}' cp -v '{}' build/dist + run: ldd build/dist/*.exe | grep "=> /" | awk '{print $3}' | grep "${{ matrix.sys }}" | xargs -I '{}' cp -v '{}' build/dist - name: Set output variables id: vars @@ -70,4 +128,4 @@ jobs: uses: actions/upload-artifact@v3 with: name: rnr-${{ steps.vars.outputs.hash }}-win_x64-${{ steps.vars.outputs.configuration }} - path: build/dist + path: build/dist \ No newline at end of file diff --git a/README.md b/README.md index ac204a1..6069f10 100644 --- a/README.md +++ b/README.md @@ -1,7 +1,7 @@ # RNR [![GitHub CI Status](https://img.shields.io/github/actions/workflow/status/lrre-foss/rnr/build.yml?branch=trunk&label=builds)](https://github.com/lrre-foss/rnr/actions) +[![Discord](https://img.shields.io/discord/1130992923329175552?style=social&logo=discord)](hhttps://discord.gg/2tj4TREby3) [![Star](https://img.shields.io/github/stars/lrre-foss/RNR?style=social)](https://github.com/lrre-foss/RNR/stargazers) -[Discord](https://discord.gg/89WagAUr) RNR (**R**NR's **N**ot **R**oblox) is a project that aims to recreate the look and feel of classic Roblox with new features while remaining fully compatible with clients from that era. It is built upon an engine that closely resembles Roblox's own at the time, referencing disassemblies of legacy client binaries.