%global debver 6.35.1.7021 %global debsha256 df1688591eb11bf4d9047b3cae44b66d7cd977a7650d79a44b997a2ed05cf5b0 # Upstream binaries and private Qt libraries are already built and stripped. %global debug_package %{nil} %global __strip /bin/true %global __brp_strip %{nil} %global __brp_strip_comment_note %{nil} %global __brp_strip_static_archive %{nil} %global _build_id_links none # Preserve the upstream bundle's $ORIGIN-based library search paths. %global __brp_check_rpaths %{nil} # Private Qt/ICU libraries must not satisfy dependencies of system packages. # Optional SQL/image plugins also refer to libraries not shipped by Fedora. # Keep the explicit runtime dependencies from the previous RPM packaging. %global __provides_exclude_from ^/opt/freedownloadmanager/.*$ %global __requires_exclude_from ^/opt/freedownloadmanager/.*$ Name: freedownloadmanager Version: %{debver} Release: 1%{?dist} Summary: Free Download Manager - download accelerator and organizer License: LicenseRef-Proprietary URL: https://www.freedownloadmanager.org/ ExclusiveArch: x86_64 # The original DEB is included in the SRPM, not downloaded during the build. Source0: %{name}_%{debver}_amd64.deb BuildRequires: binutils BuildRequires: coreutils BuildRequires: tar BuildRequires: xz BuildRequires: desktop-file-utils Requires: xdg-utils Requires: bubblewrap Requires: hicolor-icon-theme Requires: openssl-libs Requires: xcb-util-cursor Requires: xcb-util-wm Requires: xcb-util-keysyms Requires: libxkbcommon-x11 Recommends: ffmpeg-free %description FDM is a powerful modern download accelerator and organizer. Repackaged from the official .deb included in this source RPM. No network access is needed during preparation, build, installation or checks. %prep %setup -q -c -T printf '%s %s\n' '%{debsha256}' '%{SOURCE0}' | sha256sum --check --strict - ar x '%{SOURCE0}' data.tar.xz mkdir extracted tar -xJf data.tar.xz -C extracted %build # Nothing to compile: the original DEB contains the complete binary bundle. %install install -d '%{buildroot}/opt' cp -a extracted/opt/%{name} '%{buildroot}/opt/' chmod -R go-w '%{buildroot}/opt/%{name}' # Install only application data, excluding Debian/AppArmor integration. install -Dpm 0644 extracted/usr/share/applications/%{name}.desktop \ '%{buildroot}%{_datadir}/applications/%{name}.desktop' install -Dpm 0644 extracted/usr/share/appdata/%{name}.appdata.xml \ '%{buildroot}%{_datadir}/appdata/%{name}.appdata.xml' sed -i \ -e 's|^Icon=.*|Icon=%{name}|' \ -e 's|^Exec=/opt/%{name}/fdm|Exec=%{_bindir}/fdm|' \ '%{buildroot}%{_datadir}/applications/%{name}.desktop' if ! grep -q '^StartupWMClass=' '%{buildroot}%{_datadir}/applications/%{name}.desktop'; then sed -i '/^Exec=/a StartupWMClass=fdm' \ '%{buildroot}%{_datadir}/applications/%{name}.desktop' fi install -d '%{buildroot}%{_datadir}/icons/hicolor/256x256/apps' ln -s ../../../../../../opt/%{name}/icon.png \ '%{buildroot}%{_datadir}/icons/hicolor/256x256/apps/%{name}.png' install -d '%{buildroot}%{_bindir}' ln -s ../../opt/%{name}/fdm '%{buildroot}%{_bindir}/fdm' %check desktop-file-validate '%{buildroot}%{_datadir}/applications/%{name}.desktop' test -x '%{buildroot}/opt/%{name}/fdm' test -L '%{buildroot}%{_bindir}/fdm' test -f '%{buildroot}%{_bindir}/fdm' test -f '%{buildroot}%{_datadir}/icons/hicolor/256x256/apps/%{name}.png' test ! -e '%{buildroot}/etc/apt' %files %defattr(-,root,root,-) /opt/%{name} %{_bindir}/fdm %{_datadir}/applications/%{name}.desktop %{_datadir}/appdata/%{name}.appdata.xml %{_datadir}/icons/hicolor/256x256/apps/%{name}.png %changelog * Fri Oct 16 2026 Dmitry - 6.35.1.7021-1 - Update to 6.35.1.7021 from the supplied official amd64 DEB - Include the complete DEB as Source0 and verify its SHA-256 before extraction - Remove curl and all build-time network downloads - Validate the desktop entry and installed application links - Preserve upstream ELF files and normalize group-writable bundle permissions * Thu Aug 06 2026 Dmitry - 6.34.4.6974-1 - Bump to 6.34.4.6974 - Make StartupWMClass injection conditional (deb now ships it) - Add xcb-util-wm, xcb-util-keysyms, libxkbcommon-x11, openssl-libs (new deb Depends) * Thu Jul 16 2026 Dmitry - 6.34.2.6926-1 - Initial RPM repack of official .deb (fetched at build time)