Name: clash-verge Version: 2.5.10 Release: 1%{?dist} Summary: Clash Verge Rev - a Clash GUI client based on Tauri License: GPL-3.0-only URL: https://github.com/clash-verge-rev/clash-verge-rev Source0: Clash.Verge-%{version}-1.x86_64.rpm ExclusiveArch: x86_64 %global debug_package %{nil} # 上游 rpm 声明的运行时依赖,照抄 Requires: libayatana-appindicator-gtk3 Requires: gtk3 Requires: webkit2gtk4.1 Requires: openssl %description Clash Verge Rev is a Clash GUI client built with Tauri, supporting the Mihomo (Clash Meta) core. This package repacks the official x86_64 rpm published upstream, so the installed file layout is identical to the upstream package. %prep rm -rf %{_builddir}/payload mkdir -p %{_builddir}/payload cd %{_builddir}/payload rpm2cpio %{SOURCE0} | cpio -idm --quiet %build %install cp -a %{_builddir}/payload/. %{buildroot}/ # mock 里以 root 构建;本地非 root 试打时忽略失败 find %{buildroot} -exec chown --no-dereference 0:0 {} + 2>/dev/null || : %post #!/bin/bash set -e chmod +x /usr/bin/clash-verge-service-install chmod +x /usr/bin/clash-verge-service-uninstall chmod +x /usr/bin/clash-verge-service # The enforcement file exists in both Enforcing and Permissive mode. if [ ! -e /sys/fs/selinux/enforce ]; then exit 0 fi if [ ! -x /usr/sbin/semanage ] || [ ! -x /usr/sbin/restorecon ]; then echo "Warning: persistent SELinux rules were not installed; install policycoreutils and policycoreutils-python-utils, then reinstall this package." >&2 exit 0 fi for service in clash-verge-service clash-verge-service-dev; do for directory in bin cores; do target="/var/lib/$service/$directory" if [ -L "/var/lib/$service" ] || [ -L "$target" ]; then echo "Refusing to relabel a symlinked service directory: $target" >&2 exit 1 fi spec="$target(/.*)?" if ! add_error="$(/usr/sbin/semanage fcontext -a -t bin_t "$spec" 2>&1)"; then if ! /usr/sbin/semanage fcontext -m -t bin_t "$spec"; then printf '%s\n' "$add_error" >&2 exit 1 fi fi if [ -d "$target" ]; then /usr/sbin/restorecon -R "$target" fi done done %preun #!/bin/bash /usr/bin/clash-verge-service-uninstall . /etc/os-release if [ "$ID" = "deepin" ]; then if [ -f "/usr/share/applications/clash-verge.desktop" ]; then echo "Removing deepin desktop file" rm -vf "/usr/share/applications/clash-verge.desktop" fi fi %files %{_bindir}/clash-verge %{_bindir}/clash-verge-service %{_bindir}/clash-verge-service-install %{_bindir}/clash-verge-service-uninstall %{_bindir}/verge-mihomo %{_bindir}/verge-mihomo-alpha "/usr/lib/Clash Verge/resources/ASN.mmdb" "/usr/lib/Clash Verge/resources/Country.mmdb" "/usr/lib/Clash Verge/resources/geoip.dat" "/usr/lib/Clash Verge/resources/geosite.dat" "/usr/share/applications/Clash Verge.desktop" %{_datadir}/icons/hicolor/128x128/apps/clash-verge.png %{_datadir}/icons/hicolor/256x256@2/apps/clash-verge.png %{_datadir}/icons/hicolor/32x32/apps/clash-verge.png %changelog * Wed Nov 04 2026 dmqf - 2.5.10-1 - repack of upstream binary rpm (x86_64 only)