]> git.pld-linux.org Git - projects/template-specs.git/blame - lib.spec
pecl: use exec in script to propagate make failure
[projects/template-specs.git] / lib.spec
CommitLineData
3cb1cd3d 1#
66df3cad
ER
2# Conditional build:
3%bcond_without apidocs # do not build and package API docs
aed9d573 4%bcond_without static_libs # don't build static libraries
66df3cad 5#
f9986cd5 6Summary: -
ce39d734 7Summary(pl.UTF-8): -
3f8f5e5b
ER
8Name: ---
9Version: 0.1
10Release: 0.1
f9986cd5
JB
11License: - (enter GPL/LGPL/BSD/BSD-like/other license name here)
12Group: Libraries
13Source0: %{name}-%{version}.tar.gz
14# Source0-md5: -
3f8f5e5b
ER
15#Patch0: %{name}-what.patch
16#URL: -
17#BuildRequires: -
c53387e8
ER
18#BuildRequires: autoconf
19#BuildRequires: automake
20#BuildRequires: intltool
21#BuildRequires: libtool
3f8f5e5b
ER
22#Requires(postun): -
23#Requires(pre,post): -
24#Requires(preun): -
25#Requires: -
26#Provides: -
27#Obsoletes: -
28#Conflicts: -
f9986cd5
JB
29BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
30
a1a32384
ER
31# do not keep them in newly created specs
32# these are only here to help fixing quickly broken specs
33%define filterout_ld -Wl,--no-copy-dt-needed-entries
34%define filterout_ld -Wl,--as-needed
31c122e0
ER
35# do not commit spec containing this (use for local testing only):
36%define filterout_c -Werror=format-security
c392e5f5 37%define filterout_cpp -D_FORTIFY_SOURCE=.
877721ed 38%define filterout_cxx -Werror=format-security
a1a32384 39
20667fb2 40# Ignore file in __spec_install_post_check_so
5346ce74 41BuildRequires: rpmbuild(macros) >= 1.583
e24df1c5 42%define skip_post_check_so libunresolved.so.*
20667fb2 43
e025831d
ER
44# do not commit spec containing this (use for local testing only):
45%define no_install_post_check_tmpfiles 1
46
f9986cd5
JB
47%description
48
3f8f5e5b 49#%description -l pl.UTF-8
f9986cd5 50
41119926 51%package common
ca8abdb7
TP
52Summary: Common files for %{name} library
53Summary(pl.UTF-8): Wspólne pliki biblioteki %{name}
41119926
TP
54Group: Libraries
55Requires: %{name} = %{version}-%{release}
56
57%description common
ca8abdb7 58Common files for %{name} library.
41119926
TP
59
60%description common -l pl.UTF-8
ca8abdb7 61Wspólne pliki biblioteki %{name}.
41119926 62
f9986cd5 63%package devel
ca8abdb7
TP
64Summary: Header files for %{name} library
65Summary(pl.UTF-8): Pliki nagłówkowe biblioteki %{name}
f9986cd5 66Group: Development/Libraries
d7dd7729 67Requires: %{name} = %{version}-%{release}
f9986cd5
JB
68
69%description devel
ca8abdb7 70Header files for %{name} library.
f9986cd5 71
9be49f18 72%description devel -l pl.UTF-8
ca8abdb7 73Pliki nagłówkowe biblioteki %{name}.
f9986cd5
JB
74
75%package static
ca8abdb7
TP
76Summary: Static %{name} library
77Summary(pl.UTF-8): Statyczna biblioteka %{name}
f9986cd5 78Group: Development/Libraries
d7dd7729 79Requires: %{name}-devel = %{version}-%{release}
f9986cd5
JB
80
81%description static
ca8abdb7 82Static %{name} library.
f9986cd5 83
9be49f18 84%description static -l pl.UTF-8
ca8abdb7 85Statyczna biblioteka %{name}.
f9986cd5 86
66df3cad 87%package apidocs
ca8abdb7
TP
88Summary: %{name} API documentation
89Summary(pl.UTF-8): Dokumentacja API biblioteki %{name}
66df3cad
ER
90Group: Documentation
91
92%description apidocs
e077345b 93API documentation for %{name} library.
66df3cad 94
3cb1cd3d 95%description apidocs -l pl.UTF-8
ca8abdb7 96Dokumentacja API biblioteki %{name}.
3cb1cd3d 97
f9986cd5
JB
98%prep
99%setup -q
1c854c4b 100#%patch0 -p1
f9986cd5
JB
101
102%build
c42a30cf
JB
103# if ac/am/lt/* rebuilding is necessary, do it in this order and add
104# appropriate BuildRequires
105#%{__libtoolize}
106#%{__aclocal}
107#%{__autoconf}
108#%{__autoheader}
109#%{__automake}
f6de6810
ER
110%configure \
111 %{!?with_static_libs:--disable-static}
f9986cd5
JB
112%{__make}
113
114%install
115rm -rf $RPM_BUILD_ROOT
116# create directories if necessary
117#install -d $RPM_BUILD_ROOT
118
119%{__make} install \
120 DESTDIR=$RPM_BUILD_ROOT
121
14750145
JB
122# if library provides pkgconfig file containing proper {Requires,Libs}.private
123# then remove .la pollution
4b532792
JR
124#%{__rm} $RPM_BUILD_ROOT%{_libdir}/*.la
125
f9986cd5
JB
126%clean
127rm -rf $RPM_BUILD_ROOT
128
129%post -p /sbin/ldconfig
130%postun -p /sbin/ldconfig
131
132%files
133%defattr(644,root,root,755)
41119926
TP
134%doc AUTHORS CREDITS README THANKS
135%attr(755,root,root) %{_libdir}/%{name}.so.*.*.*
136%attr(755,root,root) %ghost %{_libdir}/%{name}.so.N
137
138%files common
139%defattr(644,root,root,755)
140%attr(755,root,root) %{_bindir}/%{name}*
f9986cd5
JB
141%{_datadir}/%{name}
142
143%files devel
144%defattr(644,root,root,755)
41119926
TP
145%doc devel-doc/* ChangeLog NEWS TODO
146%attr(755,root,root) %{_libdir}/%{name}.so
14750145
JB
147# if no pkgconfig support, or it misses .private deps, then include .la file
148#%{_libdir}/libFOO.la
41119926
TP
149%{_includedir}/%{name}
150%{_aclocaldir}/%{name}.m4
151%{_pkgconfigdir}/%{name}.pc
f9986cd5 152
f6de6810 153%if %{with static_libs}
f9986cd5
JB
154%files static
155%defattr(644,root,root,755)
41119926 156%{_libdir}/%{name}.a
f6de6810 157%endif
66df3cad 158
a5f7d790 159%if %{with apidocs}
66df3cad
ER
160%files apidocs
161%defattr(644,root,root,755)
162%doc apidocs/*
a5f7d790 163%endif
This page took 0.111353 seconds and 4 git commands to generate.