1 |
slords |
1.2 |
# $Id: dietlibc.spec,v 1.1 2007/06/12 15:03:52 slords Exp $ |
2 |
slords |
1.1 |
|
3 |
|
|
## This package understands the following switches: |
4 |
|
|
|
5 |
|
|
## Fedora Extras specific customization below... |
6 |
|
|
## |
7 |
|
|
|
8 |
|
|
%ifarch %ix86 x86_64 arm |
9 |
|
|
%global do_dyn 1 |
10 |
|
|
%else |
11 |
|
|
%global do_dyn 0 |
12 |
|
|
%endif |
13 |
|
|
|
14 |
|
|
%if %do_dyn |
15 |
|
|
%global with_dyn 1 |
16 |
|
|
%endif |
17 |
|
|
|
18 |
|
|
%ifarch %ix86 |
19 |
|
|
%global target_cpu i386 |
20 |
|
|
%else |
21 |
|
|
%global target_cpu %_target_cpu |
22 |
|
|
%endif |
23 |
|
|
|
24 |
|
|
|
25 |
|
|
%{!?release_func:%global release_func() %1%{?dist}.1} |
26 |
|
|
|
27 |
|
|
Summary: Small libc implementation |
28 |
|
|
Name: dietlibc |
29 |
|
|
Version: 0.30 |
30 |
|
|
Release: %release_func 4 |
31 |
|
|
License: GPL |
32 |
|
|
Group: Development/Libraries |
33 |
|
|
URL: http://www.fefe.de/dietlibc/ |
34 |
|
|
Source0: http://www.kernel.org/pub/linux/libs/dietlibc/%name-%version.tar.bz2 |
35 |
|
|
Source1: http://www.fefe.de/dietlibc/%name-%version.tar.bz2.sig |
36 |
|
|
Patch1: dietlibc-0.28-setpriority.patch |
37 |
|
|
Patch10: dietlibc-0.29-scall.patch |
38 |
|
|
Patch20: dietlibc-0.29-nostackprotector.patch |
39 |
|
|
Patch30: dietlibc-0.30-longdouble.patch |
40 |
|
|
Patch40: dietlibc-0.30-gnuokay.patch |
41 |
|
|
Patch50: dietlibc-0.30-x86_64-lseek64.patch |
42 |
|
|
Patch60: dietlibc-0.30-x86_64-stat64.patch |
43 |
|
|
BuildRoot: %_tmppath/%name-%version-%release-buildroot |
44 |
|
|
%{?with_dyn:Requires: dietlibc-lib = %version-%release} |
45 |
|
|
|
46 |
|
|
|
47 |
|
|
|
48 |
|
|
%package lib |
49 |
|
|
Summary: Dynamic libraries for dietlibc |
50 |
|
|
Group: System Environment/Libraries |
51 |
|
|
|
52 |
|
|
%description |
53 |
|
|
The diet libc is a libc that is optimized for small size. It can be |
54 |
|
|
used to create small statically linked binaries for Linux on alpha, |
55 |
|
|
arm, hppa, ia64, i386, mips, s390, sparc, sparc64, ppc and x86_64. |
56 |
|
|
|
57 |
|
|
|
58 |
|
|
%description lib |
59 |
|
|
The diet libc is a libc that is optimized for small size. It can be |
60 |
|
|
used to create small statically linked binaries for Linux on alpha, |
61 |
|
|
arm, hppa, ia64, i386, mips, s390, sparc, sparc64, ppc and x86_64. |
62 |
|
|
|
63 |
|
|
This package contains the dynamic libraries for dietlibc. |
64 |
|
|
|
65 |
|
|
|
66 |
|
|
%prep |
67 |
|
|
%setup -q |
68 |
|
|
%patch1 -p1 -b .nice |
69 |
|
|
%patch10 -p1 -b .scall |
70 |
|
|
%patch20 -p1 -b .nostackprotector |
71 |
|
|
%patch30 -p1 -b .longdouble |
72 |
|
|
%patch40 -p1 -b .gnuokay |
73 |
|
|
%patch50 -p1 -b .lseek64 |
74 |
|
|
%patch60 -p1 -b .stat64 |
75 |
|
|
|
76 |
|
|
sed -i -e 's!strip !: !g' Makefile |
77 |
|
|
sed -i -e 's!^#define WANT_SSP$!// \0!g; |
78 |
|
|
s!.*\(#define WANT_STACKGAP\).*!\1!g' dietfeatures.h |
79 |
|
|
|
80 |
|
|
%if "%{?rhel}" == "5" |
81 |
|
|
%global fixcflags -fomit-frame-pointer -fno-exceptions -fno-asynchronous-unwind-tables -fno-stack-protector -Os |
82 |
|
|
%else |
83 |
|
|
%global fixcflags -fomit-frame-pointer -fno-exceptions -fno-asynchronous-unwind-tables -Os |
84 |
|
|
%endif |
85 |
|
|
%global basemakeflags prefix=%_libdir/dietlibc BINDIR=%_bindir MAN1DIR=%_mandir/man1 COMMENT=: CFLAGS="$RPM_OPT_FLAGS %fixcflags" PDIET=%_libdir/dietlibc |
86 |
|
|
%global makeflags %basemakeflags |
87 |
|
|
|
88 |
|
|
|
89 |
|
|
%build |
90 |
|
|
make %makeflags all %{?_smp_mflags} |
91 |
|
|
|
92 |
|
|
# 'dyn' target is not SMP safe |
93 |
|
|
%{?with_dyn:make %makeflags dyn} |
94 |
|
|
|
95 |
|
|
|
96 |
|
|
%install |
97 |
|
|
rm -rf $RPM_BUILD_ROOT |
98 |
|
|
|
99 |
|
|
install -d -m755 $RPM_BUILD_ROOT/etc |
100 |
|
|
make %makeflags DESTDIR=$RPM_BUILD_ROOT install |
101 |
|
|
|
102 |
|
|
ln -s lib-%_arch ${RPM_BUILD_ROOT}%_libdir/dietlibc/lib-%_arch-%_vendor |
103 |
|
|
|
104 |
|
|
|
105 |
|
|
|
106 |
|
|
%clean |
107 |
|
|
rm -rf $RPM_BUILD_ROOT |
108 |
|
|
|
109 |
|
|
%files |
110 |
|
|
%defattr(-,root,root,-) |
111 |
|
|
%{?with_dyn:%exclude %_libdir/dietlibc/*/*.so} |
112 |
|
|
%doc AUTHOR BUGS CAVEAT CHANGES COPYING FAQ PORTING README* |
113 |
|
|
%doc SECURITY THANKS TODO |
114 |
|
|
%doc %_mandir/*/* |
115 |
|
|
%_bindir/* |
116 |
|
|
%_libdir/dietlibc |
117 |
|
|
|
118 |
|
|
%if %do_dyn |
119 |
|
|
%files lib |
120 |
|
|
%defattr(-,root,root,-) |
121 |
|
|
%config(noreplace) %_sysconfdir/* |
122 |
|
|
%dir %_libdir/dietlibc |
123 |
|
|
%dir %_libdir/dietlibc/lib-* |
124 |
|
|
%_libdir/dietlibc/lib-%target_cpu/*.so |
125 |
|
|
%endif |
126 |
|
|
|
127 |
|
|
|
128 |
|
|
%changelog |
129 |
|
|
* Mon May 14 2007 Shad L. Lords <slords@mail.com> 0.30-4.1 |
130 |
|
|
- Add 64 bit stat and lseek functions |
131 |
|
|
- Enable gnu safe functions |
132 |
|
|
|
133 |
|
|
* Wed Jan 17 2007 David Woodhouse <dwmw2@infradead.org> 0.30-4 |
134 |
|
|
- Bump release to be higher than unexplained 0.30-3.fc6 |
135 |
|
|
|
136 |
|
|
* Wed Jan 17 2007 David Woodhouse <dwmw2@infradead.org> 0.30-3 |
137 |
|
|
- Apply workaround for GCC PR26374 to build on PPC again (#182118) |
138 |
|
|
|
139 |
|
|
* Fri Sep 15 2006 Enrico Scholz <enrico.scholz@informatik.tu-chemnitz.de> - 0.30-2 |
140 |
|
|
- rebuilt |
141 |
|
|
|
142 |
|
|
* Sun Jul 9 2006 Enrico Scholz <enrico.scholz@informatik.tu-chemnitz.de> - 0.30-1 |
143 |
|
|
- updated to 0.30 |
144 |
|
|
- removed cross-arch support |
145 |
|
|
- disable (non-working) SSP support; enable old stackgap code instead of |
146 |
|
|
|
147 |
|
|
* Sat Feb 18 2006 Enrico Scholz <enrico.scholz@informatik.tu-chemnitz.de> - 0.29-6 |
148 |
|
|
- added '-Os' to the CFLAGS |
149 |
|
|
- exclude PPC arch due to strange compilation errors |
150 |
|
|
|
151 |
|
|
* Sun Oct 30 2005 Enrico Scholz <enrico.scholz@informatik.tu-chemnitz.de> - 0.29-4 |
152 |
|
|
- added '-fno-stack-protector' to the CFLAGS |
153 |
|
|
|
154 |
|
|
* Sun Oct 30 2005 Enrico Scholz <enrico.scholz@informatik.tu-chemnitz.de> - 0.29-3 |
155 |
|
|
- removed '-fstack-protector' from CLI because it uses __stack_chk_fail |
156 |
|
|
which is not provided by dietlibc |
157 |
|
|
|
158 |
|
|
* Thu May 26 2005 Enrico Scholz <enrico.scholz@informatik.tu-chemnitz.de> - 0.29-2 |
159 |
|
|
- rebuilt |
160 |
|
|
|
161 |
|
|
* Tue May 24 2005 Enrico Scholz <enrico.scholz@informatik.tu-chemnitz.de> - 0.29-1 |
162 |
|
|
- updated to 0.29 |
163 |
|
|
- unset some compiler options which cause errors with gcc4 |
164 |
|
|
- rediffed -scall patch |
165 |
|
|
- removed most patches as already in upstream |
166 |
|
|
|
167 |
|
|
* Thu May 19 2005 Enrico Scholz <enrico.scholz@informatik.tu-chemnitz.de> - 0.28-6 |
168 |
|
|
- use %%dist instead of %%disttag |
169 |
|
|
- package some more %%doc files (reported by Chris Ricker) |
170 |
|
|
- add %%release to the BuildRoot (reported by Chris Ricker) |
171 |
|
|
- fixed URLs of the sources (reported by Chris Ricker) |
172 |
|
|
|
173 |
|
|
* Sun May 1 2005 Enrico Scholz <enrico.scholz@informatik.tu-chemnitz.de> - 0.28-5 |
174 |
|
|
- added Herbert Poetzl's syscall(2) implementation for x86_64 and |
175 |
|
|
sparc* architectures (see |
176 |
|
|
http://vserver.13thfloor.at/Experimental/delta-diet.diff); rediffed |
177 |
|
|
the .call patch |
178 |
|
|
- catch the case when syscall(2) is used on archs where it is not |
179 |
|
|
implemented yet |
180 |
|
|
- define MADV_* constants on HPPA and IA64 archs |
181 |
|
|
- fix *truncate64() handling on 64bit archs |
182 |
|
|
|
183 |
|
|
* Fri Mar 4 2005 Enrico Scholz <enrico.scholz@informatik.tu-chemnitz.de> - 0.28-4 |
184 |
|
|
- rebuild |
185 |
|
|
- fixed compilation with gcc4 |
186 |
|
|
- made nice(2) SUSv3 compliantly on x86_64 and other platforms (patch |
187 |
|
|
provided by Colin Hill) |
188 |
|
|
- build the dynamic libs for x86, x86_64 and arm only |
189 |
|
|
- fixed PPC issues in ISO mode (do not use the 'powerpc' macro but the |
190 |
|
|
'__powerpc__' one) |
191 |
|
|
- added some O_* -flags for the HPPA arch |
192 |
|
|
- use more modern flags for '-Os' |
193 |
|
|
|
194 |
|
|
* Tue Feb 1 2005 Enrico Scholz <enrico.scholz@informatik.tu-chemnitz.de> - 1:0.28-1 |
195 |
|
|
- updated to 0.28 |
196 |
|
|
- unset LD_RUN_PATH which would result in empty rpaths else |
197 |
|
|
- removed the waitpid patch; it is solved upstream |
198 |
|
|
|
199 |
|
|
* Tue Aug 17 2004 Enrico Scholz <enrico.scholz@informatik.tu-chemnitz.de> - 1:0.27-1 |
200 |
|
|
- updated to 0.27 |
201 |
|
|
|
202 |
|
|
* Fri Jun 11 2004 Enrico Scholz <enrico.scholz@informatik.tu-chemnitz.de> - 1:0.26-1 |
203 |
|
|
- updated to 0.26 |
204 |
|
|
|
205 |
|
|
* Fri Apr 9 2004 Enrico Scholz <enrico.scholz@informatik.tu-chemnitz.de> - 1:0.25-1 |
206 |
|
|
- updated to 0.25 |
207 |
|
|
|
208 |
|
|
* Sat Jan 17 2004 Enrico Scholz <enrico.scholz@informatik.tu-chemnitz.de> - 1:%VERSION.90.%DATE}-5 |
209 |
|
|
- renewed -snprintf patch |
210 |
|
|
|
211 |
|
|
* Tue Jan 6 2004 Enrico Scholz <enrico.scholz@informatik.tu-chemnitz.de> - 1:%VERSION.90.%DATE}-4 |
212 |
|
|
- applied -snprintf patch (from fedora dietlibc-0.24-2 package) |
213 |
|
|
|
214 |
|
|
* Tue Dec 30 2003 Enrico Scholz <enrico.scholz@informatik.tu-chemnitz.de> - 1:%VERSION.90.%DATE}-2 |
215 |
|
|
- added C99 patch |
216 |
|
|
|
217 |
|
|
* Thu Dec 4 2003 Enrico Scholz <enrico.scholz@informatik.tu-chemnitz.de> - 1:0.24-1 |
218 |
|
|
- updated to 0.24 |
219 |
|
|
|
220 |
|
|
* Tue Sep 16 2003 Enrico Scholz <enrico.scholz@informatik.tu-chemnitz.de> - 1:0.23-1 |
221 |
|
|
- updated to 0.23 |
222 |
|
|
|
223 |
|
|
* Fri Nov 8 2002 Enrico Scholz <enrico.scholz@informatik.tu-chemnitz.de> 1:0.21-1 |
224 |
|
|
- updated to 0.21 |
225 |
|
|
- removed unpackaged files in %%install-stage |
226 |
|
|
|
227 |
|
|
* Thu Jul 11 2002 Enrico Scholz <enrico.scholz@informatik.tu-chemnitz.de> 1:0.18-1 |
228 |
|
|
- updated to 0.18 |
229 |
|
|
|
230 |
|
|
* Thu Jul 4 2002 Enrico Scholz <enrico.scholz@informatik.tu-chemnitz.de> |
231 |
|
|
- Initial build. |