Пакет wmbday: Specfile

# Unpackaged files in buildroot should terminate build
%define _unpackaged_files_terminate_build 1

Name: wmbday
Version: 0.3.1
Release: alt7

Summary: This dockapp will remind you of birthdays
Summary(ru_RU.CP1251): \xdd\xf2\xee\xf2 \xe0\xef\xef\xeb\xe5\xf2 \xe1\xf3\xe4\xe5\xf2 \xed\xe0\xef\xee\xec\xe8\xed\xe0\xf2\xfc \xe2\xe0\xec \xee \xe4\xed\xff\xf5 \xf0\xee\xe6\xe4\xe5\xed\xe8\xff

License: GPL-2
Group: Graphical desktop/Other
Url: http://buzzinhornetz.ath.cx/code/wmbday/
Packager: Slava Semushin <php-coder@altlinux.ru>

Source0: http://buzzinhornetz.ath.cx/code/wmbday/files/%name-%version.tar.gz
Source1: %name.menu

Patch0: %name-0.3.1-alt-warnings-x86_64.patch
Patch1: %name-0.3.1-alt-autotools-support.patch
Patch2: %name-0.3.1-alt-man-kill_x11_path.patch
Patch3: %name-0.3.1-alt-doc-update_my_email.patch
Patch4: %name-0.3.1-fix-build-with-gcc10.patch

BuildRequires: libXext-devel libXpm-devel

Requires: xmessage

%description
wmbday is a Window Maker dockapp for Linux und FreeBSD that will
remind you of birthdays. It can show up to four names of persons whose
birthday is next. On a particular birthday it will notify you by
highlighting the concerning person. The data is loaded either from a
simple text file or from a vCard file.

%description -l ru_RU.CP1251
wmbday \xfd\xf2\xee \xe0\xef\xef\xeb\xe5\xf2 \xe4\xeb\xff Window Maker \xef\xee\xe4 Linux \xe8 FreeBSD, \xea\xee\xf2\xee\xf0\xfb\xe9 \xe1\xf3\xe4\xe5\xf2
\xed\xe0\xef\xee\xec\xe8\xed\xe0\xf2\xfc \xe2\xe0\xec \xee \xe4\xed\xff\xf5 \xf0\xee\xe6\xe4\xe5\xed\xe8\xff. \xce\xed \xee\xf2\xee\xe1\xf0\xe0\xe6\xe0\xe5\xf2 \xf7\xe5\xf2\xfb\xf0\xe5 \xe8\xec\xe5\xed\xe8 \xe4\xeb\xff \xeb\xfe\xe4\xe5\xe9,
\xf7\xfc\xe8 \xe4\xed\xe8 \xf0\xee\xe6\xe4\xe5\xed\xe8\xff \xe1\xf3\xe4\xf3\xf2 \xf1\xeb\xe5\xe4\xf3\xfe\xf9\xe8\xec\xe8. \xc2 \xe4\xe5\xed\xfc \xf0\xee\xe6\xe4\xe5\xed\xe8\xff \xf7\xe5\xeb\xee\xe2\xe5\xea\xe0 \xe8\xe7 \xf1\xef\xe8\xf1\xea\xe0
\xe0\xef\xef\xeb\xe5\xf2 \xef\xee\xe4\xf1\xe2\xe5\xf2\xe8\xf2 \xe8\xec\xff \xe8\xec\xe5\xed\xe8\xed\xed\xe8\xea\xe0. \xc4\xe0\xed\xed\xfb\xe5 \xec\xee\xe3\xf3\xf2 \xe7\xe0\xe3\xf0\xf3\xe6\xe0\xf2\xfc\xf1\xff \xe8\xe7 \xef\xf0\xee\xf1\xf2\xee\xe3\xee
\xf2\xe5\xea\xf1\xf2\xee\xe2\xee\xe3\xee \xf4\xe0\xe9\xeb\xe0 \xe8\xeb\xe8 \xe6\xe5 \xe8\xe7 vCard \xf4\xe0\xe9\xeb\xe0.

%prep
%setup

# fix modifier for size_t type
%patch0

# add autotools support
%patch1 -p1

# change path to rgb.txt in man page
%patch2

# update my email in ChangeLog
%patch3

%patch4 -p2

rm -f BSDmakefile configure Makefile
chmod -x *.[ch] wmbday.1 wmbday_text.xpm

mv build/wmbday-0.3.1.ebuild build/wmbday.ebuild
mv *.[ch] *.xpm src/
mv data.sample* data/
mv wmbday.1 doc/

autoheader &&
aclocal &&
automake --foreign --add-missing &&
autoconf

%build
export ac_cv_path_XM_PATH=/usr/bin/xmessage
%configure
%make_build CFLAGS="%optflags -Werror -U_FORTIFY_SOURCE" --silent --no-print-directory

%install
%make_install DESTDIR=%buildroot install --silent --no-print-directory
install -pD -m 644 %SOURCE1 %buildroot%_menudir/%name

%files
%doc ChangeLog data/data.sample.simple data/data.sample.vcard
%_bindir/%name
%_man1dir/%name.1.*
%_menudir/%name

%changelog
* Fri Mar 26 2021 Grigory Ustinov <grenka@altlinux.org> 0.3.1-alt7
- Fixed FTBFS.

* Wed Dec 19 2018 Grigory Ustinov <grenka@altlinux.org> 0.3.1-alt6
- Fixed FTBFS.

* Mon Apr 15 2013 Dmitry V. Levin (QA) <qa_ldv@altlinux.org> 0.3.1-alt5.qa1
- NMU: rebuilt for debuginfo.

* Sat Nov 29 2008 Slava Semushin <php-coder@altlinux.ru> 0.3.1-alt5
- Removed obsolete %%update_menus/%%clean_menus calls (noted by repocop)

* Fri Aug 10 2007 Slava Semushin <php-coder@altlinux.ru> 0.3.1-alt4
- Fixed path to rgb.txt in man-page
- Added autotools support
- Update my email address in ChangeLog file
- Removed xmessage from BuildRequires (use ac_cv_path_XM_PATH trick)
- Imported into git and built with gear
- Running make with --no-print-directory and --silent options to make
  terminal output clean

* Sun Nov 26 2006 Slava Semushin <php-coder@altlinux.ru> 0.3.1-alt3
- Fixed build by using -U_FORTIFY_SOURCE
- Spec cleanup:
  + Use builtin %%patch instead of external command
  + s/%%setup -q/%%setup/

* Sat Aug 12 2006 Slava Semushin <php-coder@altlinux.ru> 0.3.1-alt2
- Fixed build on x86_64: use %%zu instead of %%d for size_t type

* Wed Jul 26 2006 Slava Semushin <php-coder@altlinux.ru> 0.3.1-alt1
- Initial build for ALT Linux Sisyphus
- Using -Werror flag for compiler by default