mirror of
https://github.com/EQEmu/Server.git
synced 2026-05-08 02:32:21 +00:00
Guard ccache and avoid lib name collisions
Co-authored-by: Valorith <76063792+Valorith@users.noreply.github.com>
This commit is contained in:
parent
d27e901421
commit
9e220a05c5
7
.github/workflows/build.yaml
vendored
7
.github/workflows/build.yaml
vendored
@ -24,6 +24,13 @@ jobs:
|
||||
with:
|
||||
key: ${{ runner.os }}-ccache-${{ hashFiles('CMakeLists.txt', '.github/workflows/build.yaml') }}
|
||||
|
||||
- name: Ensure ccache installed
|
||||
run: |
|
||||
if ! command -v ccache >/dev/null 2>&1; then
|
||||
apt-get update -qq
|
||||
DEBIAN_FRONTEND=noninteractive apt-get install -y -qq ccache
|
||||
fi
|
||||
|
||||
- name: Mark workspace safe
|
||||
run: git config --global --add safe.directory "$GITHUB_WORKSPACE"
|
||||
|
||||
|
||||
13
.github/workflows/release.yaml
vendored
13
.github/workflows/release.yaml
vendored
@ -71,6 +71,15 @@ jobs:
|
||||
zip_add() {
|
||||
zip -uj eqemu-server-linux-x64.zip "$1"
|
||||
}
|
||||
zip_add_unique() {
|
||||
local target_name
|
||||
target_name="$(basename "$1")"
|
||||
if unzip -Z1 eqemu-server-linux-x64.zip | grep -qx "$target_name"; then
|
||||
echo "Skipping duplicate library: $target_name"
|
||||
return 0
|
||||
fi
|
||||
zip_add "$1"
|
||||
}
|
||||
|
||||
# Add all executable files (excluding tests)
|
||||
for f in *; do
|
||||
@ -84,7 +93,7 @@ jobs:
|
||||
if [ "$bin_lib_count" -gt 0 ]; then
|
||||
find . -maxdepth 1 -type f \( -name "*.so" -o -name "*.so.[0-9]*" \) -print0 | \
|
||||
while IFS= read -r -d '' lib; do
|
||||
zip_add "$lib"
|
||||
zip_add_unique "$lib"
|
||||
done
|
||||
fi
|
||||
|
||||
@ -93,7 +102,7 @@ jobs:
|
||||
if [ "$lib_count" -gt 0 ]; then
|
||||
find ../libs -type f \( -name "*.so" -o -name "*.so.[0-9]*" \) -print0 | \
|
||||
while IFS= read -r -d '' lib; do
|
||||
zip_add "$lib"
|
||||
zip_add_unique "$lib"
|
||||
done
|
||||
else
|
||||
echo "No shared libraries found in build/libs"
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user