1 Summary: C code generator that generates command line options parsers
2 Summary(pl.UTF-8): Generator kodu C generujący analizatory opcji linii poleceń
7 Group: Development/Tools
8 Source0: http://ftp.gnu.org/gnu/gengetopt/%{name}-%{version}.tar.gz
9 # Source0-md5: 29749a48dda69277ab969c510597a14e
10 Patch0: %{name}-info.patch
11 Patch1: %{name}-am.patch
12 URL: http://www.gnu.org/software/gengetopt/
13 BuildRequires: autoconf >= 2.58
14 BuildRequires: automake
15 BuildRequires: help2man
16 BuildRequires: libstdc++-devel
17 BuildRequires: libtool >= 2:1.5
18 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
21 Gengetopt generates a C function that uses getopt_long function to
22 parse the command line options, to validate them and fills a struct.
24 %description -l pl.UTF-8
25 Gengetopt jest to narzędzie generujące kod w języku C, wykorzystujący
26 funkcję getopt_long do analizy opcji linii poleceń, sprawdzania ich
27 poprawności i umieszczania ich w strukturze.
30 Summary: gengetopt examples
31 Summary(pl.UTF-8): Przykłady do gengetopt
33 Requires: %{name} = %{version}-%{release}
38 %description examples -l pl.UTF-8
39 Przykłady do gengetopt.
48 %{__aclocal} -I m4 -I gl/m4
56 rm -rf $RPM_BUILD_ROOT
57 install -d $RPM_BUILD_ROOT%{_examplesdir}/%{name}-%{version}
60 DESTDIR=$RPM_BUILD_ROOT
62 cp -p doc/*.{c,cc,ggo,h} $RPM_BUILD_ROOT%{_examplesdir}/%{name}-%{version}
63 cp -p doc/README.example $RPM_BUILD_ROOT%{_examplesdir}/%{name}-%{version}
66 %{__rm} -r $RPM_BUILD_ROOT%{_docdir}/gengetopt
69 rm -rf $RPM_BUILD_ROOT
71 %post -p /sbin/postshell
72 -/usr/sbin/fix-info-dir -c %{_infodir}
74 %postun -p /sbin/postshell
75 -/usr/sbin/fix-info-dir -c %{_infodir}
78 %defattr(644,root,root,755)
79 %doc AUTHORS ChangeLog LICENSE NEWS README THANKS TODO doc/{gengetopt,index}.html
80 %attr(755,root,root) %{_bindir}/gengetopt
81 %{_mandir}/man1/gengetopt.1*
82 %{_infodir}/gengetopt.info*
86 %defattr(644,root,root,755)
87 %{_examplesdir}/%{name}-%{version}