# Open Orpheus RPM spec # Generated from packaging/resources/srpm.spec.ejs — do not edit by hand. %global debug_package %{nil} %define _binary_payload w2.xzdio Name: open-orpheus Version: 0.19.1 Release: 1%{?dist} Summary: An open-source Netease Cloud Music client License: MIT URL: https://github.com/YUCLing/open-orpheus Source0: %{name}-%{version}.tar.gz AutoReqProv: no Requires: (nss or mozilla-nss), gtk3 BuildRequires: gcc, gcc-c++, make, git, curl, freetype-devel %description An open-source implementation of Netease Cloud Music's Orpheus browser host. %prep %setup -q %build # Use a writable HOME for toolchain installs export HOME="$(mktemp -d)" # Install Rust toolchain for native modules export CARGO_HOME="$HOME/.cargo" export RUSTUP_HOME="$HOME/.rustup" curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh -s -- -y . "$HOME/.cargo/env" rustup target add wasm32-unknown-unknown cargo install "wasm-bindgen-cli@0.2.129" # Install cargo-zigbuild and zig (napi-rs shells out to them for cross builds). # The Rust binary links against the build host's glibc; Zig is kept in its # extraction layout next to its std lib and only symlinked onto PATH, because # zig resolves its lib directory relative to its own executable. BUILD_ARCH="$(uname -m)" curl --proto '=https' --tlsv1.2 -sSfL \ "https://github.com/rust-cross/cargo-zigbuild/releases/download/v0.23.4/cargo-zigbuild-${BUILD_ARCH}-unknown-linux-gnu.tar.xz" \ | tar xJ -C "$HOME" install -Dm755 "$HOME/cargo-zigbuild-${BUILD_ARCH}-unknown-linux-gnu/cargo-zigbuild" \ "$CARGO_HOME/bin/cargo-zigbuild" curl --proto '=https' --tlsv1.2 -sSfL \ "https://ziglang.org/download/0.16.0/zig-${BUILD_ARCH}-linux-0.16.0.tar.xz" \ | tar xJ -C "$HOME" ln -sf "$HOME/zig-${BUILD_ARCH}-linux-0.16.0/zig" "$CARGO_HOME/bin/zig" # Install nvm and Node.js export NVM_DIR="$HOME/.nvm" curl -o- https://raw.githubusercontent.com/nvm-sh/nvm/v0.40.4/install.sh | bash . "$HOME/.nvm/nvm.sh" nvm install 24 corepack enable pnpm corepack install # Install dependencies and build native modules pnpm install --frozen-lockfile # Copr adds a flag that is not supported by WASM rust-lld; strip it. Use sed # (POSIX) rather than ${var//.../} (a bashism) so %build also works when # rpmbuild runs it under dash (e.g. GitHub Actions' ubuntu runners). ORIGINAL_RUSTFLAGS="$RUSTFLAGS" export RUSTFLAGS="$(printf '%s' "$RUSTFLAGS" | sed 's|-Clink-arg=-specs=/usr/lib/rpm/redhat/redhat-package-notes||g')" # Strip CFLAGS/CXXFLAGS that zig cc / zig c++ cannot understand. # Remove -flto=auto, -ffat-lto-objects, -fno-omit-frame-pointer, # and -mno-omit-leaf-frame-pointer. strip_flags() { printf '%s' "$1" | sed \ -e 's|-flto=auto||g' \ -e 's|-ffat-lto-objects||g' \ -e 's|-fno-omit-frame-pointer||g' \ -e 's|-mno-omit-leaf-frame-pointer||g' \ -e 's|-mtune=[^ ]*||g' \ -e 's|-march=[^ ]*||g' } ORIGINAL_CFLAGS="$CFLAGS" ORIGINAL_CXXFLAGS="$CXXFLAGS" export CFLAGS="$(strip_flags "$CFLAGS")" export CXXFLAGS="$(strip_flags "$CXXFLAGS")" pnpm run build:modules export RUSTFLAGS="$ORIGINAL_RUSTFLAGS" export CFLAGS="$ORIGINAL_CFLAGS" export CXXFLAGS="$ORIGINAL_CXXFLAGS" # Package the Electron app (produces out/open-orpheus-linux-*) pnpm run package # Generate the install scaffolding (desktop file, icons, symlink) with our scaffolder node scripts/build-scaffold.ts %{_builddir}/%{name}-%{version}/rpm-scaffold --name %{name} %install mkdir -p %{buildroot} # Install the scaffolding generated in %build cp -r %{_builddir}/%{name}-%{version}/rpm-scaffold/usr %{buildroot}/ # Install the freshly-built Electron app mkdir -p %{buildroot}/usr/lib/%{name} cp -r %{_builddir}/%{name}-%{version}/out/%{name}-linux-*/. %{buildroot}/usr/lib/%{name}/ # Electron's SUID sandbox helper must be root-owned with mode 4755 (setuid) or # the app crashes at launch. chmod 4755 %{buildroot}/usr/lib/%{name}/chrome-sandbox # Install the license install -Dm0644 LICENSE %{buildroot}%{_licensedir}/%{name}/LICENSE %files /usr/bin/%{name} /usr/lib/%{name}/ /usr/share/applications/%{name}.desktop /usr/share/icons/hicolor/256x256/apps/%{name}.png /usr/share/icons/hicolor/512x512/apps/%{name}.png /usr/share/icons/hicolor/scalable/apps/%{name}.svg %license %{_licensedir}/%{name}/LICENSE %changelog * Fri Oct 2 2026 YUCLing - 0.19.1-1 - Corrected the commit hash of the resource pack. * Fri Oct 2 2026 YUCLing - 0.19.0-1 - Added support for the xeapi algorithm. - Added support for scheduled automatic shutdown. - Added support for the emotion mode player. - Fixed missing log output when stdout is redirected. - Refactored lifecycle management. - Updated dependencies and Electron. - Added update information to the About window. - Added scroll anchor offset in the management interface. - Updated the resource pack to 3.1.41. - Playback no longer pauses when switching output devices. - Reduced the description width on the package download screen. - Added icons for Windows and macOS. * Mon Sep 28 2026 YUCLing - 0.18.0-1 - Added support for opening local music files via file association. - Added desktop support for music reviews. - Fixed an issue where the log directory did not exist. - Fixed MPRIS volume setting return value being out of sync. - Fixed a crash when loading certain fonts. - Updated the Flatpak runtime. - Removed CJS support. - Refactored window management. * Mon Sep 14 2026 YUCLing - 0.17.1-1 - Fixed play/pause from system media integration being incorrectly handled as a state toggle. - Lowered the required glibc version. - Improved the drag experience. * Thu Sep 10 2026 YUCLing - 0.17.0-1 - Added AVS3-P3 decoding support. - Added scheduled shutdown support. - Added Pino logging. - Desktop lyrics offset can now be adjusted with the mouse wheel. - Added complete system media integration. - Added a notification when resource packs are updated. - Windows are now created on demand. - Fixed proxy settings not being fully applied. - Fixed auto-update settings not being saved. - Fixed missing song covers in system integration for local music. - Fixed touch screen support. - Improved the desktop lyrics interaction experience. - Refactored the Linux man-in-the-middle layer. - Migrated from CJS to ESM. - Refactored packaging. - Updated dependencies and Electron. * Thu Aug 27 2026 YUCLing - 0.16.2-1 - Initial RPM package.