From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: zsh-workers-request@euclid.skiles.gatech.edu Received: from euclid.skiles.gatech.edu (list@euclid.skiles.gatech.edu [130.207.146.50]) by coral.primenet.com.au (8.7.5/8.7.3) with ESMTP id MAA06901 for ; Mon, 11 Nov 1996 12:11:31 +1100 (EST) Received: (from list@localhost) by euclid.skiles.gatech.edu (8.7.3/8.7.3) id UAA02244; Sun, 10 Nov 1996 20:05:53 -0500 (EST) Resent-Date: Sun, 10 Nov 1996 20:05:53 -0500 (EST) From: Zoltan Hidvegi Message-Id: <199611102200.XAA01454@hzoli.ppp.cs.elte.hu> Subject: Re: modules configuration patch To: zefram@dcs.warwick.ac.uk (Zefram) Date: Sun, 10 Nov 1996 23:00:00 +0100 (MET) Cc: zsh-workers@math.gatech.edu In-Reply-To: <8164.199611081323@stone.dcs.warwick.ac.uk> from Zefram at "Nov 8, 96 01:23:42 pm" X-Mailer: ELM [version 2.4ME+ PL17 (25)] MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Resent-Message-ID: <"aIpoa.0.-Y.nldXo"@euclid> Resent-From: zsh-workers@math.gatech.edu X-Mailing-List: archive/latest/2365 X-Loop: zsh-workers@math.gatech.edu Precedence: list Resent-Sender: zsh-workers-request@math.gatech.edu Zefram wrote: [...] > like $(@D@LEXT) have varying effect. It's hacky, but portably doing > anything complex in a Makefile is a bit of a black art anyway. I was a bit afraid of that myself. With a better make we can hack up some automatic rules for K&R compilers and we may delete those _file.c rules. This hack is a bit more difficult for modules. > * Src/mod_example.c > Include "zsh.h", in order to get all the type definitions, prototypes > and so on that should be available. Modules should do this some > way or other, in order to allow proper interface checking. Of course you are right. Here I just wanted to demonstrare that a module can be compiled independently from zsh. > Some other points that occurred to me: > > The initialise/cleanup interface, with varying names that depend on > the filename of the module, is really ugly. Is there a good reason to > have varying names? Fixed names would be easier to implement. And the If we want to statically link modules to zsh we must use unique names. I also think that the _init/_fini functions are not always available. > The interface to modload could use some more thought. Is the argument > a filename, or a module name? At the moment only a pathname starting > with /, ./ or ../ is treated as a filename. It would be more consistent > to treat any pathname containing a / as an actual pathname, and only do > the path search and .so appending when only a bare name is specified. I know that the interface is not good at the mement but this is the easiest part. I wrote this interface a few months ago just to test the capabilities of my ELF system. The most difficult part is to make everything portable and allow static linking of modules. The user interface part is really half finished I showed it to the public just to give you some food for thought. > And finally a more general question. Are any non-trivial modules going > to be included in the zsh distribution? I hope so. Perl comes with several modules and I think it would make zsh popular if it came with a few powefull module. Zoltan