#559124 unnecessary files

Package:
zsh
Source:
zsh
Description:
shell with lots of features
Submitter:
sergio
Date:
2014-11-15 02:51:15 UTC
Severity:
minor
#559124#5
Date:
2009-12-02 01:35:36 UTC
From:
To:
It's look like most non *.zwc files in /usr/share/zsh are unnecessary.
#559124#10
Date:
2009-12-02 01:57:24 UTC
From:
To:
While it would be annoying to me personally to not have them there,
this would save roughly 8 megs.

#559124#15
Date:
2009-12-02 04:23:53 UTC
From:
To:
Clint Adams wrote:

It's not so little for have them there. This files not needed for
ordinary users. Yes, sometimes it's very handy to see something there.
But usually this needed on developing. And if this is permanently it's
reasonable to keep them at home.

May be it will be better to move this file to zsh-doc, or to other
package zsh-doc-functions (which will carry them under doc).

#559124#20
Date:
2009-12-13 01:21:44 UTC
From:
To:
This breaks both the prompt and completion systems.  Do you have a working
patch?

#559124#25
Date:
2010-01-05 21:22:10 UTC
From:
To:
No. But I've realized two things.

First is that completion system depends on non-compiled files.
compinit looks for first line to see what to do with it.

And second is that zwc files in /usr/share/zsh/functions is not used.
mtime for Misc/zcalc is the same as for Misc.zwc, and zsh looks for great time:
 Src/parse.c, try_dump_file:
 std.st_mtime > stn.st_mtime
strace confirms this.

Moreover may be it will be better to compile all functions in functions.zwc ?

#559124#30
Date:
2010-01-05 22:20:48 UTC
From:
To:
  File: `/usr/share/zsh/functions/Misc.zwc'
  Size: 127776          Blocks: 264        IO Block: 4096   regular file
Device: fe01h/65025d    Inode: 164117      Links: 1
Access: (0644/-rw-r--r--)  Uid: (    0/    root)   Gid: (    0/    root)
Access: 2010-01-05 12:14:59.000000000 -0500
Modify: 2009-12-12 20:24:48.000000000 -0500
Change: 2009-12-12 20:27:31.000000000 -0500


% stat /usr/share/zsh/functions/Misc/zcalc
  File: `/usr/share/zsh/functions/Misc/zcalc'
  Size: 7131            Blocks: 16         IO Block: 4096   regular file
Device: fe01h/65025d    Inode: 262235      Links: 1
Access: (0755/-rwxr-xr-x)  Uid: (    0/    root)   Gid: (    0/    root)
Access: 2009-12-16 22:04:44.000000000 -0500
Modify: 2009-12-12 20:24:47.000000000 -0500
Change: 2009-12-12 20:27:30.000000000 -0500

Which architecture are you on?

Any particular reason?

#559124#35
Date:
2010-01-05 23:34:01 UTC
From:
To:
amd64
% stat -c %y /usr/share/zsh/functions/Misc.zwc
2009-12-28 06:57:20.000000000 +0300
% stat -c %y /usr/share/zsh/functions/Misc/zcalc
2009-12-28 06:57:20.000000000 +0300
Speed, I hope. Search will be faster if it will for only one file.
fpath allows to specify .zwc file, I think this is the same case for it.
And I don't see any particular reason for divide system functions in multiple .zwc files.

#559124#40
Date:
2013-11-08 01:06:23 UTC
From:
To:
Hi,

sergio wrote:

Not in the current situation. Only shipping the zwc files and not the
source breaks zsh badly.

Clint Adams wrote:

Yep.

sergio wrote:

That's especially true on small machines like ALIX, EeePC or many ARM
devices which run of SD cards or CF cards.

I'd named it zsh-common-extras or zsh-common-source.

Clint Adams wrote:

Ack.

I didn't manage to find one. But I also didn't dig too deep when I
noticed that the obvious variant breaks a lot of things.

It seems a laborious task to figure out which files are necessary and
which are not. If anyone has the leisure to find that set of files,
I'll happily accept a proper patch or list of files.

I already put hours into it without finding that set of files. In case
you want to continue that work or fix this issue in general, see
http://anonscm.debian.org/gitweb/?p=collab-maint/zsh.git;a=shortlog;h=refs/heads/abe/split-common
and especially
http://anonscm.debian.org/gitweb/?p=collab-maint/zsh.git;a=commitdiff;h=04838041ad6e6f6fd865ba05cf22850f93249e5b
for what I did so far.

Downgrading severity to minor and tagging the bug with "help" as it's
not really important, probably more work than gain, but still a small
shortcoming.

		Regards, Axel