source: spec/trunk/SPECS/popt.spec@ 1330

Last change on this file since 1330 was 600, checked in by Yuri Dario, 10 years ago

spec: popt, strip path and extension from programname, added debug info package.

  • Property svn:eol-style set to native
File size: 3.1 KB
Line 
1#define svn_url F:/rd/ports/popt/trunk
2%define svn_url http://svn.netlabs.org/repos/ports/popt/trunk
3%define svn_rev 1209
4
5%define name popt
6%define version 1.15
7
8Summary: C library for parsing command line parameters
9Name: %{name}
10Version: %{version}
11Release: 5%{?dist}
12Epoch: 1
13License: MIT
14Group: System/Libraries
15Url: http://rpm5.org/files/popt/
16BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-buildroot
17Source: %{name}-%{version}%{?svn_rev:-r%{svn_rev}}.zip
18
19Requires: popt-libs = %{epoch}:%{version}-%{release}
20Requires: popt-data = %{epoch}:%{version}-%{release}
21
22%description
23Popt is a C library for parsing command line parameters. Popt was
24heavily influenced by the getopt() and getopt_long() functions, but
25it improves on them by allowing more powerful argument expansion.
26Popt can parse arbitrary argv[] style arrays and automatically set
27variables based on command line arguments. Popt allows command line
28arguments to be aliased via configuration files and includes utility
29functions for parsing arbitrary strings into argv[] arrays using
30shell-like rules.
31
32%package libs
33Summary: Main %{name} library
34Group: System/Libraries
35Requires: popt-data = %{epoch}:%{version}
36
37%description libs
38This package contains the library needed to run programs dynamically
39linked with the %{name} library.
40
41%package devel
42Summary: Development headers and libraries for %{name}
43Group: Development/C
44Requires: popt-libs >= %{epoch}:%{version}
45
46%description devel
47This package contains the header files and libraries needed for
48developing programs using the %{name} library.
49
50%package data
51Summary: Data files for %{name}
52Group: System/Libraries
53
54%description data
55This package contains popt data files like locales.
56
57%package debug
58Summary: HLL debug data for exception handling support.
59
60%description debug
61HLL debug data for exception handling support.
62
63%prep
64%if %{?svn_rev:%(sh -c 'if test -f "%{_sourcedir}/%{name}-%{version}-r%{svn_rev}.zip" ; then echo 1 ; else echo 0 ; fi')}%{!?svn_rev):0}
65%setup -q
66%else
67%setup -n "%{name}-%{version}" -Tc
68svn export %{?svn_rev:-r %{svn_rev}} %{svn_url} . --force
69rm -f "%{_sourcedir}/%{name}-%{version}%{?svn_rev:-r%{svn_rev}}.zip"
70(cd .. && zip -SrX9 "%{_sourcedir}/%{name}-%{version}%{?svn_rev:-r%{svn_rev}}.zip" "%{name}-%{version}")
71%endif
72
73%build
74export CONFIG_SITE="/@unixroot/usr/share/config.legacy";
75export LDFLAGS="-Zbin-files -Zhigh-mem -Zomf -Zargs-wild -Zargs-resp";
76%configure --disable-rpath \
77 --disable-shared --enable-static
78
79make %{?_smp_mflags}
80
81%install
82rm -rf %{buildroot}
83make DESTDIR=${RPM_BUILD_ROOT} install
84cp popt.dll $RPM_BUILD_ROOT/%{_libdir}
85%find_lang %name
86
87%clean
88rm -rf %{buildroot}
89
90%files
91%defattr(-,root,root)
92%doc README
93
94%files libs
95%defattr(-,root,root)
96%doc README
97%{_libdir}/*.dll
98
99%files devel
100%defattr(-,root,root)
101%{_includedir}/%{name}.h
102%{_libdir}/%{name}*a
103%{_libdir}/lib%{name}*a
104%{_mandir}/man3/popt.*
105%files data -f %{name}.lang
106
107%files debug
108%defattr(-,root,root)
109%{_libdir}/*.dbg
110
111%changelog
112* Tue Dec 08 2015 yd <yd@os2power.com> 1.15-5
113- r1209, strip path and extension from programname.
114- added debug package with symbolic info for exceptq.
Note: See TracBrowser for help on using the repository browser.