]> git.pld-linux.org Git - packages/busybox.git/blob - busybox.spec
- release 15: added -static subpackage
[packages/busybox.git] / busybox.spec
1 Summary:        Set of common unix utils for embeded systems
2 Summary(pl):    Zestaw narzêdzi uniksowych dla systemów wbudowanych
3 Name:           busybox
4 Version:        0.60.1
5 Release:        15
6 License:        GPL
7 Group:          Applications
8 Group(de):      Applikationen
9 Group(es):      Aplicaciones
10 Group(pl):      Aplikacje
11 Group(pt):      Aplicações
12 Group(pt_BR):   Aplicações
13 Source0:        ftp://ftp.lineo.com/pub/busybox/%{name}-%{version}.tar.gz
14 Source1:        %{name}-config.h
15 Patch0:         %{name}-logconsole.patch
16 Patch1:         %{name}-tee.patch
17 Patch3:         %{name}-printf-gettext.patch
18 Patch4:         %{name}-loadfont.patch
19 Patch5:         %{name}-cread.patch
20 Patch6:         %{name}-malloc.patch
21 Patch7:         %{name}-pivot_root.patch
22 URL:            http://busybox.lineo.com/
23 %{?BOOT:BuildRequires:  uClibc-devel-BOOT >= 20010521-3}
24 %{!?_without_static:BuildRequires:      glibc-static}
25 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
26
27 %description
28 BusyBox combines tiny versions of many common UNIX utilities into a
29 single small executable. It provides minimalist replacements for most
30 of the utilities you usually find in fileutils, shellutils, findutils,
31 textutils, grep, gzip, tar, etc. BusyBox provides a fairly complete
32 POSIX environment for any small or embedded system. The utilities in
33 BusyBox generally have fewer options than their full-featured GNU
34 cousins; however, the options that are included provide the expected
35 functionality and behave very much like their GNU counterparts.
36
37 BusyBox has been written with size-optimization and limited resources
38 in mind. It is also extremely modular so you can easily include or
39 exclude commands (or features) at compile time. This makes it easy to
40 customize your embedded systems. To create a working system, just add
41 a kernel, a shell (such as ash), and an editor (such as elvis-tiny or
42 ae).
43
44 %description -l pl
45 BusyBox sk³ada ma³e wersje wielu narzêdzi uniksowych w jeden ma³y plik
46 wykonywalny. Zapewnia minimalne zastêpniki wiêkszo¶ci narzêdzi
47 zawartych w pakietach fileutils, shellutils, findutils, grep, gzip,
48 tar itp. BusyBox daje w miarê kompletne ¶rodowisko POSIX dla ma³ych
49 lub wbudowanych systemów. Narzêdzia maj± mniej opcji ni¿ ich pe³ne
50 odpowiedniki GNU, ale maj± podstawow± funkcjonalno¶æ. Do dzia³aj±cego
51 systemu potrzeba jeszcze tylko kernela, shella (np. ash) oraz edytora
52 (np. elvis-tiny albo ae).
53
54 %package static
55 Summary:        Static busybox
56 Summary(pl):    Statycznie linkowany busybox
57 Group:          Applications
58 Group(de):      Applikationen
59 Group(es):      Aplicaciones
60 Group(pl):      Aplikacje
61 Group(pt):      Aplicações
62 Group(pt_BR):   Aplicações
63
64 %description static
65 Static busybox.
66
67 %description static -l pl
68 Statycznie linkowany busybox.
69
70 %package BOOT
71 Summary:        busybox for PLD bootdisk
72 Summary(pl):    busybox dla bootkietki PLD
73 Group:          Applications
74 Group(de):      Applikationen
75 Group(es):      Aplicaciones
76 Group(pl):      Aplikacje
77 Group(pt):      Aplicações
78 Group(pt_BR):   Aplicações
79
80 %description BOOT
81 busybox for PLD bootdisk.
82
83 %description BOOT -l pl
84 busybox dla bootkietki PLD.
85
86 %prep
87 %setup -q
88 %patch0 -p1
89 %patch1 -p1
90 %patch3 -p1
91 %patch4 -p1
92 %patch5 -p1
93 %patch6 -p1
94 %patch7 -p1
95
96 %build
97 cp -f %{SOURCE1} Config.h
98 # BOOT
99 %if %{?BOOT:1}%{!?BOOT:0}
100 %{__make} \
101         CFLAGS_EXTRA="-I%{_libdir}/bootdisk%{_includedir}" \
102         LDFLAGS="-nostdlib" \
103         LIBRARIES="%{_libdir}/bootdisk%{_libdir}/crt0.o %{_libdir}/bootdisk%{_libdir}/libc.a -lgcc"
104 mv -f busybox busybox-BOOT
105 %{__make} clean
106 %endif
107
108 %if %{?_without_static:0}%{!?_without_static:1}
109 %{__make} \
110         CFLAGS_EXTRA="%{rpmcflags}" \
111         LDFLAGS="%{rpmldflags} -static"
112 mv -f busybox busybox.static
113 %{__make} clean
114 %endif
115
116 # TODO make main package dynamically linked
117 %{__make} \
118         CFLAGS_EXTRA="%{rpmcflags}" \
119         LDFLAGS="%{rpmldflags}"
120         
121 %install
122 rm -rf $RPM_BUILD_ROOT
123 install -d $RPM_BUILD_ROOT{%{_bindir},%{_mandir}/man1,%{_libdir}/busybox}
124
125 %if %{?BOOT:1}%{!?BOOT:0}
126 install -d $RPM_BUILD_ROOT%{_libdir}/bootdisk/{bin,%{_libdir}}
127
128 install busybox-BOOT $RPM_BUILD_ROOT%{_libdir}/bootdisk/bin/busybox
129
130 for i in `cat busybox.links`; do
131         ln -sfn busybox "$RPM_BUILD_ROOT%{_libdir}/bootdisk/bin/`basename $i`"
132 done
133 install busybox.links $RPM_BUILD_ROOT%{_libdir}/bootdisk%{_libdir}/busybox
134 %endif
135
136 %{!?_without_static:install busybox.static $RPM_BUILD_ROOT%{_bindir}}
137
138 install busybox $RPM_BUILD_ROOT%{_bindir}
139 install busybox.links $RPM_BUILD_ROOT%{_libdir}/busybox
140 install docs/BusyBox.1 $RPM_BUILD_ROOT%{_mandir}/man1
141 echo ".so BusyBox.1" > $RPM_BUILD_ROOT%{_mandir}/man1/busybox.1
142
143 gzip -9nf AUTHORS TODO Changelog README
144
145 %clean
146 rm -rf $RPM_BUILD_ROOT
147
148 %files
149 %defattr(644,root,root,755)
150 %doc *.gz
151 %attr(755,root,root) %{_bindir}/busybox
152 %{_libdir}/busybox
153 %{_mandir}/man1/*
154
155 %if %{?_without_static:0}%{!?_without_static:1}
156 %files static
157 %defattr(644,root,root,755)
158 %attr(755,root,root) %{_bindir}/busybox.static
159 %endif
160
161 %if %{?BOOT:1}%{!?BOOT:0}
162 %files BOOT
163 %defattr(644,root,root,755)
164 %attr(755,root,root) %{_libdir}/bootdisk/bin/*
165 %{_libdir}/bootdisk%{_libdir}/*
166 %endif
This page took 0.044453 seconds and 4 git commands to generate.