busybox/busybox.spec

108 lines
3.3 KiB
RPMSpec

#
# spec file for package busybox (Version 1.12.3)
#
# Copyright (c) 2009 SUSE LINUX Products GmbH, Nuernberg, Germany.
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
# upon. The license for this file, and modifications and additions to the
# file, is the same license as for the pristine package itself (unless the
# license for the pristine package is not an Open Source License, in which
# case the license is the MIT License). An "Open Source License" is a
# license that conforms to the Open Source Definition (Version 1.9)
# published by the Open Source Initiative.
# Please submit bugfixes or comments via http://bugs.opensuse.org/
#
# norootforbuild
Name: busybox
Url: http://www.busybox.net/
Version: 1.12.3
Release: 3
Summary: The Swiss Army Knife of Embedded Linux
License: GPL v2 or later
Group: System/Base
AutoReqProv: on
Source: http://busybox.net/downloads/%{name}-%{version}.tar.bz2
Source2: busybox.SuSE.config
Source3: mkinitrd-setup.sh
Source4: mkinitrd-boot.sh
Patch100: busybox.install.patch
Patch101: busybox.libunarchive-array.patch
Patch102: busybox.dmesg-size.patch
Patch103: busybox-buildfix.patch
BuildRoot: %{_tmppath}/%{name}-%{version}-build
%description
BusyBox combines tiny versions of many common UNIX utilities into a
small single executable. It provides minimalist replacements for most
of the utilities usually found in fileutils, shellutils, findutils,
textutils, grep, gzip, tar, and more. BusyBox provides a fairly
complete POSIX environment for any small or embedded system. The
utilities in BusyBox generally have fewer options than their
full-featured GNU cousins. The options that are included provide the
expected functionality and behave very much like their GNU
counterparts.
Authors:
--------
Erik B. Andersen <andersee@debian.org>
%prep
%setup -q -n %{name}-%{version}
%patch100 -p1
%patch101 -p1
%patch102 -p1
%patch103
%build
cp -avL %{S:2} .config
find -name CVS | xargs rm -rf
find -name .svn | xargs rm -rf
export VERBOSE=-v
export BUILD_VERBOSE=2
make -e oldconfig
make -e %{?jobs:-j%jobs}
make -e doc busybox.links %{?jobs:-j%jobs}
%install
find -name ".cvsignore" -exec rm {} \;
install -d $RPM_BUILD_ROOT/usr/bin
install -d $RPM_BUILD_ROOT/usr/share/busybox
install busybox.links $RPM_BUILD_ROOT/usr/share/busybox
install applets/install.sh $RPM_BUILD_ROOT/usr/bin/busybox.install
install busybox $RPM_BUILD_ROOT/usr/bin
install -d $RPM_BUILD_ROOT%_mandir/man1
install -m 644 docs/BusyBox.1 $RPM_BUILD_ROOT%_mandir/man1
install -d $RPM_BUILD_ROOT/lib/mkinitrd/scripts
install -m 755 %{S:3} $RPM_BUILD_ROOT/lib/mkinitrd/scripts/setup-busybox.sh
install -m 755 %{S:4} $RPM_BUILD_ROOT/lib/mkinitrd/scripts/boot-busybox.sh
%post
[ -x /sbin/mkinitrd_setup ] && mkinitrd_setup
exit 0
%postun
[ -x /sbin/mkinitrd_setup ] && mkinitrd_setup
exit 0
%files
%defattr(-,root,root)
%doc docs/mdev.txt
%doc %{_mandir}/man1/BusyBox.1.gz
/usr/bin/busybox
/usr/bin/busybox.install
%dir /usr/share/busybox
%config /usr/share/busybox/busybox.links
%dir /lib/mkinitrd
%dir /lib/mkinitrd/scripts
/lib/mkinitrd/scripts/setup-busybox.sh
/lib/mkinitrd/scripts/boot-busybox.sh
%changelog