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 IAA10467 for ; Thu, 7 Nov 1996 08:41:23 +1100 (EST) Received: (from list@localhost) by euclid.skiles.gatech.edu (8.7.3/8.7.3) id QAA24610; Wed, 6 Nov 1996 16:37:39 -0500 (EST) Resent-Date: Wed, 6 Nov 1996 16:37:39 -0500 (EST) From: Zoltan Hidvegi Message-Id: <199611062138.WAA21625@bolyai.cs.elte.hu> Subject: zsh-3.1 development: dynamic modules To: zsh-workers@math.gatech.edu (Zsh workers list) Date: Wed, 6 Nov 1996 22:38:05 +0100 (MET) Organization: Dept. of Comp. Sci., Eotvos University, Budapest, Hungary Phone: (36 1)2669833 ext: 2667, home phone: (36 1) 2752368 X-Mailer: ELM [version 2.4ME+ PL27 (25)] MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Resent-Message-ID: <"9Sg3w.0.R06.ZKGWo"@euclid> Resent-From: zsh-workers@math.gatech.edu X-Mailing-List: archive/latest/2327 X-Loop: zsh-workers@math.gatech.edu Precedence: list Resent-Sender: zsh-workers-request@math.gatech.edu I have stared working on binary module support in zsh. The preliminary version is almost usable. I tested it on ELF Linux SunOS and Solaris and it seems to work. Of course the most difficult part is to make it portable. I looked at the perl sources for that but I not yet added everything which is there. You can find my current version as a patch to zsh-3.0.1 in ftp://ftp.cs.elte.hu/pub/zsh/testing/zsh-3.1.0-test1.diff.gz The file date/size: 15793 Nov 6 22:19 zsh-3.1.0-test1.diff.gz md5sum: 2b83517e832b9318bc02016ff508ab23 zsh-3.1.0-test1.diff.gz This is very experimental. You have to give the --enable-dynamic option to configure to compile in binary module support. This adds a new builtin, modload. Whithout arguments it lists the currently loaded modules. Otherwise it loads the given module. The $module_path array is user to seatch for the modules. modload -u modue unloads the given module. An example module is provided in mod_example.c. Compile it with make mod_example.so Mosules may work on all systems with an ANSI C compiler and dlopen/dlsym interface. Other systems need some hacking. This is an experimental code and I release it only to get it moving. I've done this several weeks ago but I had not much time to continue the work and I'd like to hear others opinions about it. At the moment there is no support to link a module statically to zsh. Also K&R C compilers cannot be used to compile the modules. When the module code works it can provide completely new and exciting extensions to zsh: database extensions, X windows etc. Any new program may be built around zsh using zsh as a user interface and command language. Zoltan