2007-01-16 00:06:26 +01:00
|
|
|
#
|
2011-03-18 19:51:17 +01:00
|
|
|
# spec file for package busybox
|
2007-01-16 00:06:26 +01:00
|
|
|
#
|
2023-01-04 19:07:01 +01:00
|
|
|
# Copyright (c) 2023 SUSE LLC
|
2007-01-16 00:06:26 +01:00
|
|
|
#
|
2008-08-23 00:08:11 +02:00
|
|
|
# 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.
|
|
|
|
|
2019-04-02 13:46:57 +02:00
|
|
|
# Please submit bugfixes or comments via https://bugs.opensuse.org/
|
2007-01-16 00:06:26 +01:00
|
|
|
#
|
|
|
|
|
2011-03-21 10:33:42 +01:00
|
|
|
|
2022-07-11 14:57:07 +02:00
|
|
|
%ifarch x86_64 aarch64 i586
|
|
|
|
%bcond_without ww3
|
|
|
|
%else
|
|
|
|
%bcond_with ww3
|
|
|
|
%endif
|
|
|
|
%bcond_without static
|
|
|
|
|
2007-01-16 00:06:26 +01:00
|
|
|
Name: busybox
|
2023-06-06 15:46:17 +02:00
|
|
|
Version: 1.36.1
|
Accepting request 113102 from home:oertel:branches:openSUSE:Factory
- busybox-1.19.4-typedef_umode_t.patch:
fix compile as umode_t is only defined with KERNEL and is
used in header linux/linux/ext2_fs.h
- update to 1.19.4
- fix getty, mdev, modinfo and wget
- update to 1.19.3
- fix chpasswd, crond, inetd, syslogd, tail, tftp
- update to 1.19.2
- fix ash/hush, cttyhack, find, grep, less, patch, sed, top,
uncompress
- update to 1.19.0:
- countless fixes in all utility programs, please see
http://www.busybox.net/ for details
- remove obsolete patches previously marked as upstreamed
- busybox-1.19.4-typedef_umode_t.patch:
fix compile as umode_t is only defined with KERNEL and is
used in header linux/linux/ext2_fs.h
- update to 1.19.4
- fix getty, mdev, modinfo and wget
- update to 1.19.3
- fix chpasswd, crond, inetd, syslogd, tail, tftp
- update to 1.19.2
- fix ash/hush, cttyhack, find, grep, less, patch, sed, top,
uncompress
- update to 1.19.0:
- countless fixes in all utility programs, please see
http://www.busybox.net/ for details
OBS-URL: https://build.opensuse.org/request/show/113102
OBS-URL: https://build.opensuse.org/package/show/Base:System/busybox?expand=0&rev=18
2012-04-11 20:33:48 +02:00
|
|
|
Release: 0
|
2019-09-20 09:58:17 +02:00
|
|
|
Summary: Minimalist variant of UNIX utilities linked in a single executable
|
2019-04-02 13:46:57 +02:00
|
|
|
License: GPL-2.0-or-later
|
2007-01-16 00:06:26 +01:00
|
|
|
Group: System/Base
|
2021-05-10 15:45:30 +02:00
|
|
|
URL: https://www.busybox.net/
|
|
|
|
Source: https://busybox.net/downloads/%{name}-%{version}.tar.bz2
|
2019-04-02 13:46:57 +02:00
|
|
|
Source2: busybox.config
|
2021-10-15 10:33:08 +02:00
|
|
|
# Make sure busybox-static.config stays in sync with busybox.config -
|
|
|
|
# exception: SELinux commands - these do not build statically.
|
2021-10-26 16:04:43 +02:00
|
|
|
Source3: busybox.config.static
|
2020-04-10 10:09:23 +02:00
|
|
|
Source4: man.conf
|
2021-05-10 15:45:30 +02:00
|
|
|
Source5: https://busybox.net/downloads/%{name}-%{version}.tar.bz2.sig
|
|
|
|
Source6: https://busybox.net/~vda/vda_pubkey.gpg#/%{name}.keyring
|
2021-10-26 16:04:43 +02:00
|
|
|
Source7: busybox.config.static.warewulf3
|
2020-12-07 11:52:11 +01:00
|
|
|
Patch0: cpio-long-opt.patch
|
2021-01-05 10:00:02 +01:00
|
|
|
Patch1: sendmail-ignore-F-option.patch
|
2021-10-26 16:40:09 +02:00
|
|
|
Patch2: testsuite-gnu-echo.patch
|
2011-03-18 19:51:17 +01:00
|
|
|
# other patches
|
2020-02-10 12:27:06 +01:00
|
|
|
Patch100: busybox.install.patch
|
2019-08-02 20:50:05 +02:00
|
|
|
Provides: useradd_or_adduser_dep
|
2019-04-02 13:46:57 +02:00
|
|
|
BuildRequires: glibc-devel-static
|
2022-11-15 10:31:32 +01:00
|
|
|
#in SLE12 hostname is part of the net-tools package
|
|
|
|
%if %{?suse_version} && %{?suse_version} <= 1315
|
|
|
|
BuildRequires: net-tools
|
|
|
|
%else
|
2022-03-24 11:23:13 +01:00
|
|
|
BuildRequires: hostname
|
2022-11-15 10:31:32 +01:00
|
|
|
%endif
|
2020-08-12 15:44:45 +02:00
|
|
|
BuildRequires: pkgconfig(libselinux)
|
2020-07-08 09:52:43 +02:00
|
|
|
# for test suite
|
|
|
|
BuildRequires: zip
|
2007-01-16 00:06:26 +01:00
|
|
|
|
|
|
|
%description
|
|
|
|
BusyBox combines tiny versions of many common UNIX utilities into a
|
2019-09-20 09:58:17 +02:00
|
|
|
single executable. It provides minimalist replacements for utilities
|
|
|
|
usually found in fileutils, shellutils, findutils, textutils, grep,
|
|
|
|
gzip, tar, and more. BusyBox provides a fairly complete POSIX
|
|
|
|
environment for small or embedded systems. The utilities in BusyBox
|
|
|
|
generally have fewer options than their GNU cousins. The options that
|
|
|
|
are included provide the expected functionality and behave much like
|
|
|
|
their GNU counterparts.
|
2007-01-16 00:06:26 +01:00
|
|
|
|
2019-04-02 13:46:57 +02:00
|
|
|
%package static
|
2019-09-20 09:58:17 +02:00
|
|
|
Summary: Static linked version of Busybox, a compact UNIX utility collection
|
2019-04-02 13:46:57 +02:00
|
|
|
Group: System/Base
|
|
|
|
|
|
|
|
%description static
|
2019-09-20 09:58:17 +02:00
|
|
|
BusyBox combines tiny versions of many common UNIX utilities into a
|
|
|
|
single executable.
|
2019-04-02 13:46:57 +02:00
|
|
|
|
2021-10-15 10:33:08 +02:00
|
|
|
%package warewulf3
|
|
|
|
Summary: Static version of Busybox - for building Warewulf3
|
|
|
|
Group: System/Base
|
|
|
|
|
|
|
|
%description warewulf3
|
|
|
|
This version of busybox is only for building Warewulf3
|
|
|
|
https://github.com/warewulf/warewulf3
|
|
|
|
|
2020-07-08 09:52:43 +02:00
|
|
|
%package testsuite
|
|
|
|
Summary: Testsuite of busybox
|
|
|
|
Group: Development/Testing
|
|
|
|
Requires: %{name} = %{version}
|
|
|
|
Requires: zip
|
|
|
|
|
|
|
|
%description testsuite
|
2021-10-26 16:04:43 +02:00
|
|
|
Using this package you can test the busybox build on different kernels and glibc.
|
2020-07-08 09:52:43 +02:00
|
|
|
It needs to run with permission to the current directory, so either copy it away
|
|
|
|
as is or run as root:
|
|
|
|
|
2021-10-26 16:04:43 +02:00
|
|
|
cd /usr/share/busybox/testsuite
|
2020-07-08 09:52:43 +02:00
|
|
|
PATH=/usr/share/busybox:$PATH SKIP_KNOWN_BUGS=1 ./runtest
|
|
|
|
|
2007-01-16 00:06:26 +01:00
|
|
|
%prep
|
2022-11-15 10:31:32 +01:00
|
|
|
#SLE12 needs an empty line after autosetup for it to expand properly (bsc#1205420)
|
2022-07-11 14:57:07 +02:00
|
|
|
%autosetup -p1
|
2022-11-15 10:31:32 +01:00
|
|
|
|
2019-09-20 09:58:17 +02:00
|
|
|
find "(" -name CVS -o -name .cvsignore -o -name .svn -o -name .gitignore ")" \
|
|
|
|
-exec rm -Rf {} +
|
2011-03-18 19:51:17 +01:00
|
|
|
|
|
|
|
%build
|
2016-03-07 13:34:52 +01:00
|
|
|
export KCONFIG_NOTIMESTAMP=KCONFIG_NOTIMESTAMP
|
2022-07-11 14:57:07 +02:00
|
|
|
export KBUILD_VERBOSE=1
|
|
|
|
export CFLAGS="%{optflags} -fPIC -fno-strict-aliasing -I/usr/include/tirpc"
|
2015-04-25 11:02:17 +02:00
|
|
|
export CC="gcc"
|
2011-10-04 10:31:06 +02:00
|
|
|
export HOSTCC=gcc
|
2022-07-11 14:57:07 +02:00
|
|
|
%if %{with static}
|
2021-10-26 16:04:43 +02:00
|
|
|
cat %{SOURCE3} %{SOURCE2} > .config
|
2019-04-02 13:46:57 +02:00
|
|
|
make %{?_smp_mflags} -e oldconfig
|
|
|
|
make -e %{?_smp_mflags}
|
|
|
|
mv busybox busybox-static
|
2022-07-11 14:57:07 +02:00
|
|
|
%endif
|
2021-10-15 10:33:08 +02:00
|
|
|
|
2022-07-11 14:57:07 +02:00
|
|
|
%if 0%{with ww3}
|
2021-10-15 10:33:08 +02:00
|
|
|
make -e %{?_smp_mflags} clean
|
2021-10-26 16:04:43 +02:00
|
|
|
cat %{SOURCE7} %{SOURCE3} %{SOURCE2} > .config
|
2021-10-15 10:33:08 +02:00
|
|
|
make %{?_smp_mflags} -e oldconfig
|
|
|
|
make -e %{?_smp_mflags}
|
|
|
|
mv busybox busybox-warewulf3
|
|
|
|
make -e busybox.links %{?_smp_mflags}
|
|
|
|
mv busybox.links busybox-warewulf3.links
|
|
|
|
%endif
|
|
|
|
|
2019-04-02 13:46:57 +02:00
|
|
|
make -e %{?_smp_mflags} clean
|
|
|
|
cp -a %{SOURCE2} .config
|
2015-04-25 11:02:17 +02:00
|
|
|
make %{?_smp_mflags} -e oldconfig
|
2021-02-02 16:43:27 +01:00
|
|
|
#make -e %{?_smp_mflags}
|
|
|
|
make -e
|
2010-11-01 09:22:07 +01:00
|
|
|
make -e doc busybox.links %{?_smp_mflags}
|
2021-10-15 10:33:08 +02:00
|
|
|
|
2023-01-04 19:07:01 +01:00
|
|
|
%if 0%{?suse_version} >= 1550
|
2022-07-11 14:57:07 +02:00
|
|
|
for i in busybox.links %{?with_ww3:busybox-warewulf3.links}; do
|
2021-10-15 10:33:08 +02:00
|
|
|
sed -i -e 's,^/\(s\?bin\)/,/usr/\1/,' $i
|
|
|
|
done
|
2020-12-03 14:59:15 +01:00
|
|
|
%endif
|
2007-01-16 00:06:26 +01:00
|
|
|
|
|
|
|
%install
|
2015-04-25 11:02:17 +02:00
|
|
|
install -d %{buildroot}/%{_bindir}
|
|
|
|
install -d %{buildroot}/%{_datadir}/busybox
|
2019-04-02 13:46:57 +02:00
|
|
|
install -m 0644 busybox.links %{buildroot}%{_datadir}/busybox
|
2015-04-25 11:02:17 +02:00
|
|
|
install applets/install.sh %{buildroot}%{_bindir}/busybox.install
|
2019-10-23 22:36:10 +02:00
|
|
|
install -m 0755 busybox %{buildroot}%{_bindir}
|
2022-07-11 14:57:07 +02:00
|
|
|
%if %{with static}
|
2019-10-23 22:36:10 +02:00
|
|
|
install -m 0755 busybox-static %{buildroot}%{_bindir}
|
2022-07-11 14:57:07 +02:00
|
|
|
%endif
|
2019-10-23 22:36:10 +02:00
|
|
|
install -d %{buildroot}%{_sysconfdir}
|
2020-04-10 10:09:23 +02:00
|
|
|
install -m 0644 %{SOURCE4} %{buildroot}%{_sysconfdir}/
|
2015-04-25 11:02:17 +02:00
|
|
|
install -d %{buildroot}%{_mandir}/man1
|
2022-07-11 14:57:07 +02:00
|
|
|
install -m 644 docs/busybox.1 %{buildroot}%{_mandir}/man1
|
|
|
|
%if %{with ww3}
|
2021-10-15 10:33:08 +02:00
|
|
|
install -m 0644 busybox-warewulf3.links %{buildroot}%{_datadir}/busybox
|
|
|
|
install -m 0755 busybox-warewulf3 %{buildroot}%{_bindir}
|
|
|
|
%endif
|
2020-07-08 09:52:43 +02:00
|
|
|
cp %{SOURCE2} %{buildroot}%{_datadir}/busybox/.config
|
|
|
|
ln -s %_bindir/busybox %{buildroot}%{_datadir}/busybox/busybox
|
|
|
|
cp -a testsuite %{buildroot}%{_datadir}/busybox/testsuite
|
|
|
|
|
|
|
|
%check
|
|
|
|
export KCONFIG_NOTIMESTAMP=KCONFIG_NOTIMESTAMP
|
2022-07-11 14:57:07 +02:00
|
|
|
export KBUILD_VERBOSE=1
|
|
|
|
export CFLAGS="%{optflags} -fPIC -fno-strict-aliasing -I/usr/include/tirpc"
|
2020-07-08 09:52:43 +02:00
|
|
|
export CC="gcc"
|
|
|
|
export HOSTCC=gcc
|
2021-10-26 16:04:43 +02:00
|
|
|
export SKIP_KNOWN_BUGS=1
|
|
|
|
export SKIP_INTERNET_TESTS=1
|
2020-07-08 09:52:43 +02:00
|
|
|
make -e %{?_smp_mflags} test
|
2008-09-05 22:11:30 +02:00
|
|
|
|
2007-01-16 00:06:26 +01:00
|
|
|
%files
|
2019-04-02 13:46:57 +02:00
|
|
|
%license LICENSE
|
2007-07-16 07:36:25 +02:00
|
|
|
%doc docs/mdev.txt
|
2020-04-10 10:09:23 +02:00
|
|
|
%config %{_sysconfdir}/man.conf
|
2022-07-11 14:57:07 +02:00
|
|
|
%doc %{_mandir}/man1/busybox.1.gz
|
2012-12-11 13:41:58 +01:00
|
|
|
%{_bindir}/busybox
|
|
|
|
%{_bindir}/busybox.install
|
|
|
|
%dir %{_datadir}/busybox
|
2019-04-02 13:46:57 +02:00
|
|
|
%{_datadir}/busybox/busybox.links
|
|
|
|
|
2020-07-08 09:52:43 +02:00
|
|
|
%files testsuite
|
|
|
|
%{_datadir}/busybox/busybox
|
|
|
|
%{_datadir}/busybox/.config
|
|
|
|
%{_datadir}/busybox/testsuite
|
|
|
|
|
2022-07-11 14:57:07 +02:00
|
|
|
%if %{with static}
|
2019-04-02 13:46:57 +02:00
|
|
|
%files static
|
|
|
|
%license LICENSE
|
|
|
|
%{_bindir}/busybox-static
|
2022-07-11 14:57:07 +02:00
|
|
|
%endif
|
2008-01-17 22:10:25 +01:00
|
|
|
|
2022-07-11 14:57:07 +02:00
|
|
|
%if %{with ww3}
|
2021-10-15 10:33:08 +02:00
|
|
|
%files warewulf3
|
|
|
|
%license LICENSE
|
|
|
|
%{_bindir}/busybox-warewulf3
|
|
|
|
%dir %{_datadir}/busybox
|
|
|
|
%{_datadir}/busybox/busybox-warewulf3.links
|
|
|
|
%endif
|
|
|
|
|
2007-04-29 00:40:39 +02:00
|
|
|
%changelog
|