+# Env: 123
+# Branch: HEAD
# conditional build:
# if BOOT is defined, build BOOT package too
Summary: Small bourne shell from Berkeley
Summary(tr): Ufak bir bourne kabuĂ°u
Name: ash
Version: 0.4.0
-Release: 2
+Release: 3
License: BSD
Group: Applications/Shells
Group(de): Applikationen/Shells
Patch17: %{name}-debian.patch
Patch18: %{name}-ppid.patch
Patch19: %{name}-freebsd.patch
+Patch20: %{name}-sighup.patch
Prereq: fileutils
Prereq: grep
BuildRequires: glibc-static
BuildRequires: flex
BuildRequires: byacc
-%{?BOOT:BuildRequires: uClibc-devel-BOOT}
+%if %{?BOOT:1}%{!?BOOT:0}
+BuildRequires: uClibc-devel-BOOT >= 20000521
+%endif
BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
Conflicts: mkinitrd <= 1.7
%patch7 -p1
%patch8 -p1
%patch9 -p1
-%patch10 -p1
+#%patch10 -p1
%patch11 -p1
%patch12 -p1
%patch13 -p1
%patch17 -p1
%patch18 -p1
%patch19 -p1
+%patch20 -p1
%build
# BOOT
%if %{?BOOT:1}%{!?BOOT:0}
+# some of this utilities does not compile with uClibc
+# and it is not necessary
+%{__make} mksignames mkbuiltins mknodes mksignames mksyntax mktokens
%{__make} \
OPT_FLAGS="-I/usr/lib/bootdisk%{_includedir} -Os" \
LDFLAGS="-nostdlib %{rpmldflags}" \
%{__make} clean
%endif
+# this patch imposes memory buffers - uClibc lacks them
+patch -p1 <%{PATCH10}
+
# other
%{__make} OPT_FLAGS="%{rpmcflags}" LDFLAGS="-static %{rpmldflags}"
mv -f sh ash.static