Zsh Mailing List Archive
Messages sorted by: Reverse Date, Date, Thread, Author

PATCH: more dynamic loading on AIX



hzoli@xxxxxxxxxx wrote:
> The patch below implements dynamic loading on AIX.

This is a good thing to have.  I tried it, and encountered the
following problems

1) module.c was trying to include <link.h>.  This doesn't exist here
under AIX 3.2, nor does it seem to be there on a 4.1 system at the
other end of Europe.  If it's sometimes necessary, it should probably
be tested for in configure.

2) AIXDYNAMIC was missing from config.h.in and so didn't appear in
config.h.  I am correct that config.h.in needs to be updated by hand,
not by autoconf?

3) I made comp1 and zle builtin, mainly as an act of cowardice after
my experience with IRIX, but even so loading compctl or deltochar
causes a core dump.  As far as I can see, it seems to be happening
when trying to call init_module(), which is special for the AIX
version.  Recompiling with compctl also builtin seems to work.
On the other hand, the remaining libraries (stat, file, ...) work fine
dynamically.  Any ideas?

Here's the simplest possible patch for the first two.

*** Src/module.c.aix	Fri May  8 11:53:19 1998
--- Src/module.c	Fri May  8 11:53:38 1998
***************
*** 204,210 ****
  #else
  # include <sys/types.h>
  # include <nlist.h>
- # include <link.h>
  #endif
  #ifndef HAVE_DLCLOSE
  # define dlclose(X) ((X), 0)
--- 204,209 ----
*** config.h.in.aix	Fri May  8 11:53:11 1998
--- config.h.in	Fri May  8 11:53:21 1998
***************
*** 256,261 ****
--- 256,264 ----
  /* Define to 1 if you want to use dynamically loaded modules */
  #undef DYNAMIC
  
+ /* Define to 1 if you want to use dynamically loaded modules on AIX */
+ #undef AIXDYNAMIC
+ 
  /* Define if you have the cap_init function.  */
  #undef HAVE_CAP_INIT
  
-- 
Peter Stephenson <pws@xxxxxxxxxxxxxxxxx>       Tel: +39 50 844536
WWW:  http://www.ifh.de/~pws/
Gruppo Teorico, Dipartimento di Fisica
Piazza Torricelli 2, 56100 Pisa, Italy



Messages sorted by: Reverse Date, Date, Thread, Author