%global project tamentis %global srcname mdp %global namex mdpass %global sum Minimalist password safe Name: %{srcname} Version: 0.7.4 Release: 3%{?dist} Summary: %sum # see REAMDE for and from BSD licensed files License: ISC and BSD URL: https://%{project}.com/projects/%{name} Source0: https://github.com/%{project}/%{srcname}/archive/v%{version}.tar.gz#/%{name}-%{version}.tar.gz BuildRequires: ncurses-devel # tests need some runtime driver BuildRequires: gnupg %description %{name} is a wrapper around GnuPG and a text editor, it includes a full- screen pager with timeout (avoids passwords from lingering on screen) and a password generator with profiles. %package -n %{project}-%{namex} Summary: %sum Requires: gnupg %description -n %{project}-%{namex} %{name} is a wrapper around GnuPG and a text editor, it includes a full- screen pager with timeout (avoids passwords from lingering on screen) and a password generator with profiles. %prep %setup -q # preserve timestamps sed -i -r "s|install |\0-p |" Makefile.src # install under buildroot sed -i -r "s|(install.*)(\\$\{PREFIX\})|\1\\$\\{DESTDIR\\}\2|" Makefile.src # W: spurious-executable-perm find tests -name \*.sh |xargs chmod 644 %build # do not use -debug flag, prevents cc from optimizations %configure %make_build %install %make_install # rename binary to prevent possible conflicts with too generic name pushd %{buildroot} mv ./%{_bindir}/%{srcname} ./%{_bindir}/%{namex} sed 's,%{name},%{namex},' ./%{_mandir}/man1/%{name}.1 >./%{_mandir}/man1/%{namex}.1 rm -fv ./%{_mandir}/man1/%{name}.1 %check pushd tests find -name \*.sh |xargs chmod +x # FIXME b0rken test rm functional/test_generate_profile_iso.sh # useless test fails in fedora-review/mock rm functional/test_pager_timeout.sh make %{?_smp_mflags} test-all rm -f regress/lock/fake_lock # exclude binaries from doc make clean find -name \*.sh |xargs chmod -x popd %files -n %{project}-%{namex} %license LICENSE %doc AUTHORS ChangeLog README TODO %doc config.example %doc tests/ %{_mandir}/man1/%{namex}.1* %{_bindir}/%{namex} %changelog * Sat Mar 26 2016 Raphael Groner - 0.7.4-3 - rename binary, use namespace:project in package name - remove debug flag * Fri Aug 14 2015 Raphael Groner - 0.7.4-2 - mention BSD license - preserve timestamps - install into DESTDIR - use correct name macro in description * Sat Jul 25 2015 Raphael Groner - 0.7.4-1 - initial