Commit 04838041 authored by Axel Beckert's avatar Axel Beckert

Split .zwc and its sources into separate packages

parent 6362089b
......@@ -46,7 +46,7 @@ Depends: ${misc:Depends}
Replaces: zsh (<= 5.0.2-1)
Breaks: zsh (<= 5.0.2-1)
Recommends: zsh
Suggests: zsh-doc
Suggests: zsh-doc, zsh-common-source
Description: architecture independent files for Zsh
Zsh is a UNIX command interpreter (shell) usable as an
interactive login shell and as a shell script command
......@@ -56,8 +56,26 @@ Description: architecture independent files for Zsh
shell functions (with autoloading), a history mechanism, and a
host of other features.
.
This package contains the common zsh files shared by all
architectures.
This package contains the precompiled shell functions (.zwc) and
other zsh files shared by all architectures.
Package: zsh-common-source
Architecture: all
Depends: ${misc:Depends},
zsh-common (= ${source:Version})
Replaces: zsh-common (<= 5.0.2-3)
Breaks: zsh-common (<= 5.0.2-3)
Enhances: zsh-common
Description: architecture independent source files for Zsh
Zsh is a UNIX command interpreter (shell) usable as an
interactive login shell and as a shell script command
processor. Of the standard shells, zsh most closely resembles
ksh but includes many enhancements. Zsh has command-line editing,
built-in spelling correction, programmable command completion,
shell functions (with autoloading), a history mechanism, and a
host of other features.
.
This package contains the uncompiled shell functions and examples.
Package: zsh-doc
Architecture: all
......
......@@ -119,7 +119,7 @@ binary-arch-dynamic: build-arch
dh_testdir
dh_testroot
dh_installdirs -pzsh -pzsh-common -pzsh-dbg
dh_installdirs -pzsh -pzsh-common -pzsh-common-source -pzsh-dbg
cd obj && $(MAKE) install.man DESTDIR=$(CURDIR)/debian/zsh-common
nroff -mandoc -Tascii Doc/zshbuiltins.1 | colcrt - | \
......@@ -127,16 +127,18 @@ binary-arch-dynamic: build-arch
perl $(CURDIR)/Util/helpfiles )
# functions
dh_installexamples -pzsh-common -X.distfiles
cd debian/zsh-common/usr/share/doc/zsh-common/examples/; mv Example Functions
dh_installexamples -pzsh-common-source -X.distfiles
cd debian/zsh-common-source/usr/share/doc/zsh-common-source/examples/; mv Example Functions
sed -i -e '1!b;s:^#!.*[ /]zsh:#!/bin/zsh:;s#/usr/local/bin#/usr/bin#' \
debian/zsh-common/usr/share/doc/zsh-common/examples/Misc/*
debian/zsh-common-source/usr/share/doc/zsh-common-source/examples/Misc/*
mv -v debian/zsh-common-source/usr/share/doc/zsh-common-source \
debian/zsh-common-source/usr/share/doc/zsh-common
cd obj && $(MAKE) install.bin DESTDIR=$(CURDIR)/debian/zsh INSTALL_PROGRAM='$(INSTALL_PROGRAM)'
cd obj && $(MAKE) install.modules DESTDIR=$(CURDIR)/debian/zsh INSTALL_PROGRAM='$(INSTALL_PROGRAM)'
cd obj && $(MAKE) install.fns DESTDIR=$(CURDIR)/debian/zsh-common
cd obj && $(MAKE) install.fns DESTDIR=$(CURDIR)/debian/zsh-common-source
rm -r debian/zsh-common/usr/local
rm -r debian/zsh-common-source/usr/local
# move this to a non-root section; also drop it for cross-compiles
awk '/^#define FPATH_DIR/ { head=$$3; gsub(/"/,"",head); }; \
......@@ -145,7 +147,7 @@ binary-arch-dynamic: build-arch
obj/Src/zshpaths.h >obj/Src/zshpaths.temp
debian/zsh/bin/zsh -fc \
'setopt extendedglob; \
for i in debian/zsh-common/'`cat obj/Src/zshpaths.temp`'; do \
for i in debian/zsh-common-source/'`cat obj/Src/zshpaths.temp`'; do \
zcompile -U -M $$i.zwc $$i/*~*.zwc(^/); \
chmod 644 $$i.zwc; \
done'
......@@ -153,35 +155,44 @@ binary-arch-dynamic: build-arch
mv debian/zsh/bin/zsh debian/zsh/bin/zsh5
rm debian/zsh/bin/zsh-5.[0-9]*
dh_strip -pzsh --dbg-package=zsh-dbg
dh_link -pzsh -pzsh-common -pzsh-dbg
dh_install -pzsh -pzsh-common -pzsh-dbg
dh_strip -pzsh --dbg-package=zsh-dbg
dh_link -pzsh -pzsh-common -pzsh-common-source -pzsh-dbg
dh_install -pzsh -pzsh-common -pzsh-common-source -pzsh-dbg
sed -i -e 's,^local HELPDIR=.*,local HELPDIR=$${HELPDIR:-/usr/share/zsh/help},; s,:-more,:-/usr/bin/pager,;' \
debian/zsh-common/usr/share/zsh/functions/Misc/run-help
debian/zsh-common-source/usr/share/zsh/functions/Misc/run-help
sed -i -e '1!b;s:^#!.*[ /]zsh:#!/bin/zsh:;s#/usr/local/bin#/usr/bin#;' \
`find debian/zsh-common/usr/share/zsh/functions -type f`
chmod 755 debian/zsh-common/usr/share/zsh/functions/Misc/checkmail \
debian/zsh-common/usr/share/zsh/functions/Misc/harden \
debian/zsh-common/usr/share/zsh/functions/Misc/run-help \
debian/zsh-common/usr/share/zsh/functions/Misc/zkbd \
debian/zsh-common/usr/share/zsh/functions/Misc/zcalc
`find debian/zsh-common-source/usr/share/zsh/functions -type f`
# chmod 755 debian/zsh-common-source/usr/share/zsh/functions/Misc/checkmail \
# debian/zsh-common-source/usr/share/zsh/functions/Misc/harden \
# debian/zsh-common-source/usr/share/zsh/functions/Misc/run-help \
# debian/zsh-common-source/usr/share/zsh/functions/Misc/zkbd \
# debian/zsh-common-source/usr/share/zsh/functions/Misc/zcalc
for zwc in debian/zsh-common-source/usr/share/zsh/functions/*/*.zwc \
debian/zsh-common-source/usr/share/zsh/functions/*.zwc \
`find debian/zsh-common-source/usr/share/zsh/functions -type f | \
xargs fgrep bin/zsh | fgrep '#!' | cut -d: -f1`; do \
target=`dirname $$zwc | sed -e s/zsh-common-source/zsh-common/`; \
mkdir -pv $$target; \
mv -v $$zwc $$target/; \
done
dh_shlibdeps -pzsh -pzsh-dbg -- \
-dDepends debian/zsh/bin/* \
-dRecommends debian/zsh/usr/lib/zsh/*/zsh/*.so
dh_installmenu -pzsh-common
dh_installdocs -pzsh -pzsh-common -pzsh-dbg --link-doc=zsh-common
dh_installchangelogs -pzsh-common -pzsh-dbg ChangeLog
dh_lintian -pzsh -pzsh-common -pzsh-dbg
dh_compress -pzsh -pzsh-common -pzsh-dbg
dh_fixperms -pzsh -pzsh-common -pzsh-dbg
dh_installdeb -pzsh -pzsh-common -pzsh-dbg
dh_md5sums -pzsh -pzsh-common -pzsh-dbg
dh_gencontrol -pzsh -pzsh-common -pzsh-dbg
dh_builddeb -pzsh -pzsh-common
dh_builddeb -pzsh-dbg
dh_installmenu -pzsh-common -pzsh-common-source
dh_installdocs -pzsh -pzsh-common -pzsh-common-source -pzsh-dbg --link-doc=zsh-common
dh_installchangelogs -pzsh-common -pzsh-common-source -pzsh-dbg ChangeLog
dh_lintian -pzsh -pzsh-common -pzsh-common-source -pzsh-dbg
dh_compress -pzsh -pzsh-common -pzsh-common-source -pzsh-dbg
dh_fixperms -pzsh -pzsh-common -pzsh-common-source -pzsh-dbg
dh_installdeb -pzsh -pzsh-common -pzsh-common-source -pzsh-dbg
dh_md5sums -pzsh -pzsh-common -pzsh-common-source -pzsh-dbg
dh_gencontrol -pzsh -pzsh-common -pzsh-common-source -pzsh-dbg
dh_builddeb -pzsh -pzsh-common -pzsh-common-source
dh_builddeb -pzsh-dbg
binary-arch-static: build-static
dh_testdir
......
usr/share/zsh/functions/Completion
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment