discord/discord.spec
ObserverOfTime 3f417e97a2 Add PTB support and fallback for missing wget
* Add support for Discord PTB and update the documentation accordingly
* Add curl as a fallback when wget is not installed
* Fix installation directory being /opt/discord-stable regardless of version
* Remove suffix from the Stable version (now simply discord/Discord)
* Exit with exit code 1 on error
* Miscellaneous minor edits and fixes
2018-03-01 22:17:50 +02:00

44 lines
933 B
RPMSpec
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

# Defined by the caller (ie the script):
# pkg_name
# pkg_version
# pkg_req
# downloaded_dir
# desktop_file
%define install_dir /opt/%{pkg_name}
%define apps_dir /usr/share/applications
%define _build_id_links none
Name: %{pkg_name}
Version: %{pkg_version}
Release: 2%{?dist}
Summary: Free Voice and Text Chat for Gamers.
Group: Applications/Internet
License: Proprietary
URL: https://discordapp.com/
BuildArch: x86_64
Requires: %{pkg_req}
%description
All-in-one voice and text chat for gamers thats free, secure, and works on both your desktop and phone.
Its time to ditch Skype and TeamSpeak.
%prep
%build
%install
mkdir -p "%{buildroot}%{install_dir}"
mkdir -p "%{buildroot}%{apps_dir}"
mv "%{downloaded_dir}"/* "%{buildroot}%{install_dir}"
cp "%{desktop_file}" "%{buildroot}%{apps_dir}"
chmod +x "%{buildroot}%{install_dir}"/*.so
%files
%{install_dir}
%{apps_dir}/*
%post
cd "%{install_dir}"
sh postinst.sh