Package: dash
Version: 0.5.3-2
Severity: normal
Tags: patch
Also, build dietlibc based packages only when DEB_BUILD_OPTIONS is on
diet.
Includes cross-compiling patch.
--- dash-0.5.3/debian/control 2006-03-12 17:43:16.0 +0100
+++ dash-0.5.3-2.my/debian/control 2006-03-14 17:45:44.0 +0100
@@ -5,6 +5,24 @@
Build-Depends: po-debconf, dietlibc-dev [alpha amd64 arm hppa i386 ia64 mips
mipsel powerpc ppc64 s390 sparc]
Standards-Version: 3.6.2.0
+Package: dash-static
+Architecture: any
+Pre-Depends:
+Description: The Debian Almquist Shell
+ dash is a POSIX compliant shell that is much smaller than bash.
+ We take advantage of that by making it the shell on the installation
+ root floppy, where space is at a premium.
+ .
+ It can be usefully installed as /bin/sh (because it executes scripts
+ somewhat faster than bash), or as the default shell either of root
+ or of a second user with a userid of 0 (because it depends on fewer
+ libraries, and is therefore less likely to be affected by an upgrade
+ problem or a disk failure). It is also useful for checking that a
+ script uses only POSIX syntax.
+ .
+ bash is a better shell for most users, since it has some nice
+ features absent from dash, and is a required part of the system.
+
Package: dash
Architecture: any
Pre-Depends: ${shlibs:Depends}
@@ -23,6 +41,26 @@
bash is a better shell for most users, since it has some nice
features absent from dash, and is a required part of the system.
+Package: dash-static-udeb
+Architecture: any
+Depends:
+Section: debian-installer
+Priority: extra
+Description: The Debian Almquist Shell for boot floppies
+ dash is a POSIX compliant shell that is much smaller than bash.
+ We take advantage of that by making it the shell on the installation
+ root floppy, where space is at a premium.
+ .
+ It can be usefully installed as /bin/sh (because it executes scripts
+ somewhat faster than bash), or as the default shell either of root
+ or of a second user with a userid of 0 (because it depends on fewer
+ libraries, and is therefore less likely to be affected by an upgrade
+ problem or a disk failure). It is also useful for checking that a
+ script uses only POSIX syntax.
+ .
+ bash is a better shell for most users, since it has some nice
+ features absent from dash, and is a required part of the system.
+
Package: dash-udeb
Architecture: any
Depends: ${shlibs:Depends}
--- dash-0.5.3/debian/rules 2006-03-12 17:43:16.0 +0100
+++ dash-0.5.3-2.my/debian/rules2006-03-14 19:50:16.0 +0100
@@ -2,25 +2,46 @@
CC =cc
CFLAGS =-g -O2 -Wall
-CCUDEB =diet -v -Os gcc
-CFLAGSUDEB =-nostdinc -g -DREALLY_SMALL -Wall
+
+DCCUDEB =$(CC)
+SCCUDEB =$(CC) -static
+CFLAGSUDEB =-g -Os -DREALLY_SMALL -Wall
+
STRIP =strip
DIET_ARCHS =alpha amd64 arm hppa i386 ia64 mips mipsel powerpc ppc64 s390 sparc
+DIETDYN_ARCHS =alpha amd64 arm hppa i386 ia64 mips powerpc ppc64 s390 sparc
ARCH ?=$(shell dpkg-architecture -qDEB_HOST_ARCH)
+
+d=..
+ifneq (,$(findstring diet,$(DEB_BUILD_OPTIONS)))
+d=../DIET
+CFLAGS =-Wall
+SCC =diet -Os $(CC) -static
+SCCUDEB =diet -Os $(CC) -static
+ifeq (,$(findstring $(ARCH),$(DIETDYN_ARCHS)))
ifeq (,$(findstring $(ARCH),$(DIET_ARCHS)))
- CCUDEB =$(CC)
- CFLAGSUDEB =-g -Os -DREALLY_SMALL -Wall
+error
endif
-ifneq (,$(findstring diet,$(DEB_BUILD_OPTIONS)))
- CC =diet -v -Os gcc
- CFLAGS =-nostdinc -Wall
+ DCC =diet -Os $(CC)
+ DCCUDEB =diet -Os $(CC)
+else
+ DCC =diet-dyn -Os $(CC)
+ DCCUDEB =diet-dyn -Os $(CC)
endif
+endif
+
+ifeq (,$(findstring diet,$(DEB_BUILD_OPTIONS)))
+DCC=$(CC)
+SCC=$(CC) -static
+endif
+
ifneq (,$(findstring nostrip,$(DEB_BUILD_OPTIONS)))
STRIP =: strip
endif
DIR =$(shell pwd)/debian/dash
+SDIR =$(DIR)-static
DIRA =$(shell pwd)/debian/ash
patch: deb-checkdir patch-stamp
@@ -30,39 +51,63 @@
done
touch patch-stamp
-configure: deb-checkdir configure-stamp configure-udeb-stamp
+configure: deb-checkdir configure-stamp configure-udeb-stamp\
+ configure-static-stamp configure-static-udeb-stamp
+
configure-stamp: patch-stamp
mkdir -p build-tmp
- (cd build-tmp CC='$(CC)' CFLAGS='$(CFLAGS)' exec ../configure)
+ (cd build-tmp CC='$(DCC)' CFLAGS='$(CFLAGS)' exec ../configure
--host=$(DEB_HOST_GNU_TYPE))
touch configure-stamp
configure-udeb-stamp: patch-stamp
mkdir -p build-udeb-tmp
(cd build-udeb-tmp \
- CC='$(CCUDEB)' CFLAGS='$(CFLAGSUDEB)' exec ../configure)
+ CC='$(DCCUDEB)' CFLAGS='$(CFLAGSUDEB)' exec ../configure
--host=$(DEB_HOST_GNU_TYPE))
touch configure-udeb-stamp
-build: deb-checkdir build-stamp build-udeb-stamp
+configure-static-stamp:
+ mkdir -p build-static-tmp
+ (cd build-static-tmp CC='$(SCC)' CFLAGS='$(CFLAGS)' exec
../configure --host=$(DEB_HOST_GNU_TYPE))
+ touch configure-static-stamp
+configure-static-udeb-stamp:
+ mkdir -p build-static-udeb-tmp
+ (cd