Blame SPECS/cpaste.spec

91920b
%if 0%{?rhel} >= 8
91920b
%undefine _debugsource_packages
91920b
%endif
91920b
4d702e
Name:           cpaste
4d702e
Version:        1.0.0
91920b
Release:        3%{?dist}
4d702e
Summary:        Command line tool to upload things to pastebin.centos.org
4d702e
4d702e
License:        GPL
4d702e
URL:            http://github.com/benapetr/stikkit
4d702e
Source0:        http://paste.scratchbook.ch/download/%{name}-%{version}.tar.gz
4d702e
Source1:        default_apikey
4d702e
Source2:        default_url
4d702e
Source3:        default_expiry
4d702e
Source4:        README.CentOS
4d702e
4d702e
4d702e
Patch1:         cpaste-support-private.patch
4d702e
Patch2:         cpaste-useragent.patch
4d702e
Patch3:         cpaste-lastargasfilename.patch
4d702e
4d702e
BuildRequires:  libcurl-devel cmake
4d702e
4d702e
BuildRoot:	%{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
4d702e
4d702e
%description
4d702e
Command line tool to upload things to the CentOS Project's pastebin service
4d702e
located at https://pastebin.centos.org.  Will accept input from a named file
4d702e
piped in via standard input.  Permits the user to specify title; authors name;
4d702e
expiry time; language/format and mark the paste as private.  May also be used
4d702e
for any other stikked-based pastebin service.
4d702e
4d702e
%prep
4d702e
%setup -q
4d702e
4d702e
%patch1 -p1
4d702e
%patch2 -p1
4d702e
%patch3 -p1
4d702e
4d702e
%build
4d702e
cmake .
4d702e
make %{?_smp_mflags}
4d702e
4d702e
%install
4d702e
make install DESTDIR=%{buildroot} INSTALL="install -p"
4d702e
mkdir -p %{buildroot}%{_bindir}
4d702e
mv %{buildroot}/usr/local/bin/cpaste %{buildroot}%{_bindir}/cpaste
4d702e
mkdir -p %{buildroot}%{_sysconfdir}/cpaste
4d702e
cp %{SOURCE1} %{buildroot}%{_sysconfdir}/cpaste/apikey
4d702e
cp %{SOURCE2} %{buildroot}%{_sysconfdir}/cpaste/url
4d702e
cp %{SOURCE3} %{buildroot}%{_sysconfdir}/cpaste/expiry
4d702e
4d702e
install -m 0644 %{SOURCE4} $RPM_BUILD_DIR/%{name}-%{version}/
4d702e
4d702e
%post
4d702e
4d702e
%preun
4d702e
4d702e
%files
4d702e
%doc README.md License.txt README.CentOS
4d702e
%{_bindir}/%{name}
4d702e
%dir %{_sysconfdir}/%{name}
4d702e
%config %{_sysconfdir}/%{name}/apikey
4d702e
%config %{_sysconfdir}/%{name}/url
4d702e
%config %{_sysconfdir}/%{name}/expiry
4d702e
4d702e
%changelog
91920b
* Thu Nov 7 2019 Fabian Arrotin <arrfab@centos.org> - 1.0.0-3
91920b
- patched .spec to build on/for .el8
91920b
4d702e
* Thu Sep 13 2018 Pablo Greco <pablo@fliagreco.com.ar> - 1.0.0-2
4d702e
- Backport patch from stikkit to support private pastes
4d702e
- Backport patch from stikkit to change useragent
4d702e
- Use last invalid arg as filename, no need to use -i to paste a file
4d702e
4d702e
* Thu Sep 13 2018 Psychotic Build System <builder@psychotic.ninja> - 1.0.0-1
4d702e
- Forked from the Psychotic Ninja 'stikkit-1.0.6-7' package and rebased to 1.0.0
4d702e
- Renamed stikkit->cpaste; stikkit.1->cpaste.1; README.Psychotic->README.CentOS
4d702e
- Updated README.CentOS
4d702e
- Updated stikkit.1
4d702e
- Path references changed from /stikkit/ to /cpaste/