parent
dd5b8db3a6
commit
e548044a82
|
@ -9,53 +9,41 @@ concurrency:
|
||||||
jobs:
|
jobs:
|
||||||
freebsd:
|
freebsd:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
name: FreeBSD
|
name: '${{ matrix.platform.name }} ${{ matrix.platform.os-version }}'
|
||||||
timeout-minutes: 30
|
timeout-minutes: 30
|
||||||
|
strategy:
|
||||||
|
fail-fast: false
|
||||||
|
matrix:
|
||||||
|
platform:
|
||||||
|
- { name: FreeBSD, os: freebsd, os-version: 13.2, os-arch: x86-64, artifact: SDL-freebsd-x64,
|
||||||
|
sdl-cmake-configure-arguments: '-DSDL_CHECK_REQUIRED_INCLUDES="/usr/local/include" -DSDL_CHECK_REQUIRED_LINK_OPTIONS="-L/usr/local/lib"',
|
||||||
|
setup-cmd: 'sudo pkg update',
|
||||||
|
install-cmd: 'sudo pkg install -y cmake ninja pkgconf libXcursor libXext libXinerama libXi libXfixes libXrandr libXScrnSaver libXxf86vm wayland wayland-protocols libxkbcommon mesa-libs libglvnd evdev-proto libinotify alsa-lib jackit pipewire pulseaudio sndio dbus zh-fcitx ibus libudev-devd',
|
||||||
|
}
|
||||||
|
- { name: NetBSD, os: netbsd, os-version: 9.3, os-arch: x86-64, artifact: SDL-netbsd-x64,
|
||||||
|
sdl-cmake-configure-arguments: '',
|
||||||
|
setup-cmd: 'export PATH="/usr/pkg/sbin:/usr/pkg/bin:/sbin:$PATH";export PKG_CONFIG_PATH="/usr/pkg/lib/pkgconfig";export PKG_PATH="https://cdn.netBSD.org/pub/pkgsrc/packages/NetBSD/$(uname -p)/$(uname -r|cut -f "1 2" -d.)/All/";echo "PKG_PATH=$PKG_PATH";echo "uname -a -> \"$(uname -a)\"";sudo -E sysctl -w security.pax.aslr.enabled=0;sudo -E sysctl -w security.pax.aslr.global=0;sudo -E pkgin clean;sudo -E pkgin update',
|
||||||
|
install-cmd: 'sudo -E pkgin -y install cmake dbus pkgconf ninja-build pulseaudio libxkbcommon wayland wayland-protocols libinotify libusb1',
|
||||||
|
}
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v3
|
- uses: actions/checkout@v3
|
||||||
- name: Build
|
- name: Build
|
||||||
uses: cross-platform-actions/action@v0.19.1
|
uses: cross-platform-actions/action@v0.21.1
|
||||||
with:
|
with:
|
||||||
operating_system: freebsd
|
operating_system: ${{ matrix.platform.os }}
|
||||||
version: '13.2'
|
architecture: ${{ matrix.platform.os-arch }}
|
||||||
|
version: ${{ matrix.platform.os-version }}
|
||||||
run: |
|
run: |
|
||||||
sudo pkg update
|
${{ matrix.platform.setup-cmd }}
|
||||||
sudo pkg install -y \
|
${{ matrix.platform.install-cmd }}
|
||||||
cmake \
|
|
||||||
ninja \
|
|
||||||
pkgconf \
|
|
||||||
libXcursor \
|
|
||||||
libXext \
|
|
||||||
libXinerama \
|
|
||||||
libXi \
|
|
||||||
libXfixes \
|
|
||||||
libXrandr \
|
|
||||||
libXScrnSaver \
|
|
||||||
libXxf86vm \
|
|
||||||
wayland \
|
|
||||||
wayland-protocols \
|
|
||||||
libxkbcommon \
|
|
||||||
mesa-libs \
|
|
||||||
libglvnd \
|
|
||||||
evdev-proto \
|
|
||||||
libinotify \
|
|
||||||
alsa-lib \
|
|
||||||
jackit \
|
|
||||||
pipewire \
|
|
||||||
pulseaudio \
|
|
||||||
sndio \
|
|
||||||
dbus \
|
|
||||||
zh-fcitx \
|
|
||||||
ibus \
|
|
||||||
libudev-devd
|
|
||||||
cmake -S . -B build -GNinja \
|
cmake -S . -B build -GNinja \
|
||||||
-Wdeprecated -Wdev -Werror \
|
-Wdeprecated -Wdev -Werror \
|
||||||
-DCMAKE_BUILD_TYPE=Release \
|
-DCMAKE_BUILD_TYPE=Release \
|
||||||
-DSDL_CHECK_REQUIRED_INCLUDES="/usr/local/include" \
|
-DSDL_WERROR=ON \
|
||||||
-DSDL_CHECK_REQUIRED_LINK_OPTIONS="-L/usr/local/lib"
|
${{ matrix.platform.sdl-cmake-configure-arguments }}
|
||||||
cmake --build build/ --config Release --verbose -- -j`sysctl -n hw.ncpu`
|
cmake --build build/ --config Release --verbose
|
||||||
cmake --build build/ --config Release --target package
|
cmake --build build/ --config Release --target package
|
||||||
|
|
||||||
cmake --build build/ --config Release --target clean
|
cmake --build build/ --config Release --target clean
|
||||||
rm -rf build/dist/_CPack_Packages
|
rm -rf build/dist/_CPack_Packages
|
||||||
rm -rf build/CMakeFiles
|
rm -rf build/CMakeFiles
|
||||||
|
@ -64,5 +52,5 @@ jobs:
|
||||||
- uses: actions/upload-artifact@v3
|
- uses: actions/upload-artifact@v3
|
||||||
with:
|
with:
|
||||||
if-no-files-found: error
|
if-no-files-found: error
|
||||||
name: SDL-freebsd
|
name: ${{ matrix.platform.artifact }}
|
||||||
path: build/dist/SDL3*
|
path: build/dist/SDL3*
|
||||||
|
|
|
@ -1590,7 +1590,7 @@ elseif(UNIX AND NOT APPLE AND NOT RISCOS AND NOT HAIKU)
|
||||||
set(SDL_USE_IME 1)
|
set(SDL_USE_IME 1)
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
if(FREEBSD AND NOT HAVE_INOTIFY)
|
if((FREEBSD OR NETBSD) AND NOT HAVE_INOTIFY)
|
||||||
set(LibInotify_PKG_CONFIG_SPEC libinotify)
|
set(LibInotify_PKG_CONFIG_SPEC libinotify)
|
||||||
pkg_check_modules(PC_LIBINOTIFY IMPORTED_TARGET ${LibInotify_PKG_CONFIG_SPEC})
|
pkg_check_modules(PC_LIBINOTIFY IMPORTED_TARGET ${LibInotify_PKG_CONFIG_SPEC})
|
||||||
if(PC_LIBINOTIFY_FOUND)
|
if(PC_LIBINOTIFY_FOUND)
|
||||||
|
|
Loading…
Reference in New Issue