zsh-workers
 help / color / mirror / code / Atom feed
* module names
@ 1997-03-24 18:51 Zefram
  0 siblings, 0 replies; 2+ messages in thread
From: Zefram @ 1997-03-24 18:51 UTC (permalink / raw)
  To: zsh-workers

-----BEGIN PGP SIGNED MESSAGE-----

In one of the early versions of the module code, all the boot/cleanup
functions had fixed names, so that a single module could be linked
under several names and loaded as any of them.  However, some systems
apparently couldn't cope with the symbol name clash.  This patch adds
the capability back, but with an autoconf test to see if the differing
names must be used.

Unlike the earlier versions, in this patch the code defining boot/cleanup
functions must know the canonical name of the module.  In practice
this has not been a problem.  The layout of the function headers looks
a little odd, but it avoids problems with makepro.sed, and keeps the
function name starting in column 1.

 -zefram

begin 644 nameclash_patch.gz
M'XL("$NW-#,"`VYA;65C;&%S:%]P871C:`#56GEWFT@2_SOS*=H:;PP*LCB$
M+J^SZ]A*XA?%SHOL?3F7AZ!EL4'``G+B'-]]J[J;0Q*2CXPSLSXDCNKJ.GY5
M7=50K]?)2_L3G7@^W?6"!UJOUVFJ6E/O$=7HZZV^;C[0=GN_-1J-"CJCJ1M$
M;?6U=E_O_%9?_,%SHK5T16MU";M`B!,&$^]B-TGM=)[TQ>D\IF04.\U+&B=>
M&.Q.@?#!;G.!EC0:,76FU/D$-W_;*D:6F(!<Q';\T+']W5D+F3@NV9:2V'&]
M6"8/'Q)[GH9(CCQR8:9]`G/,HL:4:9E)#,>-7RLQ''Y-IG<4O=+XIJIH9CLS
M_H/#TY.GQ\^LI\?#P6B?B+/G@X.CP>O1?L:2+.FQ."%(G,\)QZ!7<;*B6,[R
M>J],J>W2&.^"S4+RF&S_$R=F#A%:"(?\%;2XUE-KU$&G%`PK@JT-P:893.T5
M.AYL1M_4^J9>[>\N6*IK<G\ST[$+.9:;=7($$1Q0DH9$(]Z$V`&9!R!IXH0`
MZ:F=X)TQ)5%,(PHW7#QW_>1J)LG$CB_F,QJDI-X$9K_CP`DY&H[>OK1.!H.C
MD75^@CXX/'T]0&4?5<PWF_NI%_F4S$)W[M.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[?/9XMIS$C`,0/6K3[,-3:G&;S?2L($$D&1S?@IY
M-QQ8+P:#5Z/SIT^/W\CE#>I%OC+3E\M[L[4BGT7^4\6N?"'&5'JW+G4V>X%/
M6E9@29#JHIU+<M>XN<;$=Y!I.1!@L(4OXY4QS;>_81EIX7M)ZDH@5(W)XD"O
M?D.IT^D"L,SKEY&O:S82FB`V3<D\(M3UTC`F-$CC*Q*%,#8I'A"D,:RJP"-*
M$7'9&7=%)L,-5XROZS8)?E*42KRJ;:6K&;=%[#ICH2[>7K95EC&_*PC7&J*8
*YG]AX4&V@3@`````
`
end

-----BEGIN PGP SIGNATURE-----
Version: 2.6.3ia
Charset: ascii

iQCVAwUBMzS6u3D/+HJTpU/hAQEU0gQAlk64oqZZaRonYHwO7VGvZqe2zDEv6dtK
tLxLCngottRqu6BmLgnqLZ98CHC9nbWX0W4Mc3e+AHGxOMSV5Q2fODuZNbsfkA1M
F0tJf1LQYzs/uz1uJEkuCbdvSxd2Bzuv3sw+1JONtNq/3OOwthS+7yiuQqc21nMU
km7R7cSrW38=
=Jv46
-----END PGP SIGNATURE-----


^ permalink raw reply	[flat|nested] 2+ messages in thread

* module names
@ 1997-05-11 17:51 Zefram
  0 siblings, 0 replies; 2+ messages in thread
From: Zefram @ 1997-05-11 17:51 UTC (permalink / raw)
  To: zsh-workers

-----BEGIN PGP SIGNED MESSAGE-----

This is an updated version of the code part of patch 3028, making all
the boot/cleanup functions have fixed names, on systems that can handle
the symbol name clash.  In addition to what was in 3028, this patch
modifies ansi2knr such that it can grok the new function headers --
this mirrors the modification of makepro.sed.

 -zefram

 *** Src/ansi2knr.c	1995/06/30 22:07:14	1.1.1.1
 --- Src/ansi2knr.c	1997/05/11 14:05:17
 ***************
 *** 234,240 ****
   	   }
   	while ( isidchar(*p) ) p++;
   	endfn = p;
 ! 	p = skipspace(p, 1);
   	if ( *p++ != '(' )
   		return 0;		/* not a function */
   	p = skipspace(p, 1);
 --- 234,242 ----
   	   }
   	while ( isidchar(*p) ) p++;
   	endfn = p;
 ! 	do
 ! 		p = skipspace(p, 1);
 ! 	while(*p == ')' && (endfn = ++p, 1));
   	if ( *p++ != '(' )
   		return 0;		/* not a function */
   	p = skipspace(p, 1);
 *** Src/makepro.sed	1997/05/11 12:06:20	1.3
 --- Src/makepro.sed	1997/05/11 14:10:57
 ***************
 *** 2,8 ****
   /^\/\*\*\/$/{
   n
   N
 ! s/\n\([_a-zA-Z][_0-9a-zA-Z]* *\)(/ \1 _((/
   s/$/);/
   p
   }
 --- 2,8 ----
   /^\/\*\*\/$/{
   n
   N
 ! s/\n\([_a-zA-Z][_0-9a-zA-Z]*[ )]*\)(/ \1 _((/
   s/$/);/
   p
   }
 *** Src/module.c	1997/05/11 12:06:20	1.29
 --- Src/module.c	1997/05/11 13:52:33
 ***************
 *** 180,185 ****
 --- 180,197 ----
   # define dlclose(X) ((X), 0)
   #endif
   
 + #ifdef DLSYM_NEEDS_UNDERSCORE
 + # define STR_BOOT      "_boot_"
 + # define STR_BOOT_S    "_boot_%s"
 + # define STR_CLEANUP   "_cleanup_"
 + # define STR_CLEANUP_S "_cleanup_%s"
 + #else /* !DLSYM_NEEDS_UNDERSCORE */
 + # define STR_BOOT      "boot_"
 + # define STR_BOOT_S    "boot_%s"
 + # define STR_CLEANUP   "cleanup_"
 + # define STR_CLEANUP_S "cleanup_%s"
 + #endif /* !DLSYM_NEEDS_UNDERSCORE */
 + 
   typedef int (*Module_func) _((Module));
   
   /**/
 ***************
 *** 253,259 ****
 --- 265,273 ----
   init_module(Module m)
   {
       char *s, *t;
 + #ifndef DYNAMIC_NAME_CLASH_OK
       char buf[PATH_MAX + 1];
 + #endif
       Module_func fn;
   
       s = strrchr(m->nam, '/');
 ***************
 *** 263,276 ****
   	s = m->nam;
       if ((t = strrchr(s, '.')))
   	*t = '\0';
       if (strlen(s) + 6 > PATH_MAX)
   	return 1;
 ! #ifdef DLSYM_NEEDS_UNDERSCORE
 !     sprintf(buf, "_boot_%s", s);
 ! #else
 !     sprintf(buf, "boot_%s", s);
 ! #endif
       fn = (Module_func) dlsym(m->handle, buf);
       if(fn)
   	return fn(m);
       zwarnnam(m->nam, "no boot function", NULL, 0);
 --- 277,290 ----
   	s = m->nam;
       if ((t = strrchr(s, '.')))
   	*t = '\0';
 + #ifdef DYNAMIC_NAME_CLASH_OK
 +     fn = (Module_func) dlsym(m->handle, STR_BOOT);
 + #else /* !DYNAMIC_NAME_CLASH_OK */
       if (strlen(s) + 6 > PATH_MAX)
   	return 1;
 !     sprintf(buf, STR_BOOT_S, s);
       fn = (Module_func) dlsym(m->handle, buf);
 + #endif /* !DYNAMIC_NAME_CLASH_OK */
       if(fn)
   	return fn(m);
       zwarnnam(m->nam, "no boot function", NULL, 0);
 ***************
 *** 331,337 ****
 --- 345,353 ----
   cleanup_module(Module m)
   {
       char *s, *t;
 + #ifndef DYNAMIC_NAME_CLASH_OK
       char buf[PATH_MAX + 1];
 + #endif
       Module_func fn;
   
       s = strrchr(m->nam, '/');
 ***************
 *** 341,354 ****
   	s = m->nam;
       if ((t = strrchr(s, '.')))
   	*t = '\0';
       if (strlen(s) + 9 > PATH_MAX)
   	return 1;
 ! #ifdef DLSYM_NEEDS_UNDERSCORE
 !     sprintf(buf, "_cleanup_%s", s);
 ! #else
 !     sprintf(buf, "cleanup_%s", s);
 ! #endif
       fn = (Module_func) dlsym(m->handle, buf);
       if(fn)
   	return fn(m);
       zwarnnam(m->nam, "no cleanup function", NULL, 0);
 --- 357,370 ----
   	s = m->nam;
       if ((t = strrchr(s, '.')))
   	*t = '\0';
 + #ifdef DYNAMIC_NAME_CLASH_OK
 +     fn = (Module_func) dlsym(m->handle, STR_CLEANUP);
 + #else /* !DYNAMIC_NAME_CLASH_OK */
       if (strlen(s) + 9 > PATH_MAX)
   	return 1;
 !     sprintf(buf, STR_CLEANUP_S, s);
       fn = (Module_func) dlsym(m->handle, buf);
 + #endif /* !DYNAMIC_NAME_CLASH_OK */
       if(fn)
   	return fn(m);
       zwarnnam(m->nam, "no cleanup function", NULL, 0);
 *** Src/zsh.h	1997/05/11 12:06:28	1.58
 --- Src/zsh.h	1997/05/11 13:52:33
 ***************
 *** 50,55 ****
 --- 50,63 ----
   # define compctlread(N,A,O,R) compctlreadptr(N,A,O,R)
   #endif /* !IN_COMP */
   
 + #if defined(MODULE) && defined(DYNAMIC_NAME_CLASH_OK)
 + # define BOOT(X)    boot_
 + # define CLEANUP(X) cleanup_
 + #else
 + # define BOOT(X)    X
 + # define CLEANUP(X) X
 + #endif
 + 
   /* A few typical macros */
   #define minimum(a,b)  ((a) < (b) ? (a) : (b))
   
 *** Src/Builtins/rlimits.c	1997/05/11 00:12:17	1.1.1.1
 --- Src/Builtins/rlimits.c	1997/05/11 14:06:28
 ***************
 *** 586,593 ****
   };
   
   /**/
 ! int
 ! boot_rlimits(Module m)
   {
       return !addbuiltins(m->nam, bintab, sizeof(bintab)/sizeof(*bintab));
   }
 --- 586,593 ----
   };
   
   /**/
 ! int BOOT(
 ! boot_rlimits)(Module m)
   {
       return !addbuiltins(m->nam, bintab, sizeof(bintab)/sizeof(*bintab));
   }
 ***************
 *** 595,602 ****
   #ifdef MODULE
   
   /**/
 ! int
 ! cleanup_rlimits(Module m)
   {
       deletebuiltins(m->nam, bintab, sizeof(bintab)/sizeof(*bintab));
       return 0;
 --- 595,602 ----
   #ifdef MODULE
   
   /**/
 ! int CLEANUP(
 ! cleanup_rlimits)(Module m)
   {
       deletebuiltins(m->nam, bintab, sizeof(bintab)/sizeof(*bintab));
       return 0;
 *** Src/Builtins/sched.c	1997/05/11 00:12:17	1.1.1.1
 --- Src/Builtins/sched.c	1997/05/11 14:06:49
 ***************
 *** 186,193 ****
   };
   
   /**/
 ! int
 ! boot_sched(Module m)
   {
       if(!addbuiltins(m->nam, bintab, sizeof(bintab)/sizeof(*bintab)))
   	return 1;
 --- 186,193 ----
   };
   
   /**/
 ! int BOOT(
 ! boot_sched)(Module m)
   {
       if(!addbuiltins(m->nam, bintab, sizeof(bintab)/sizeof(*bintab)))
   	return 1;
 ***************
 *** 198,205 ****
   #ifdef MODULE
   
   /**/
 ! int
 ! cleanup_sched(Module m)
   {
       struct schedcmd *sch, *schn;
   
 --- 198,205 ----
   #ifdef MODULE
   
   /**/
 ! int CLEANUP(
 ! cleanup_sched)(Module m)
   {
       struct schedcmd *sch, *schn;
   
 *** Src/Modules/cap.c	1997/05/11 12:06:41	1.2
 --- Src/Modules/cap.c	1997/05/11 14:04:16
 ***************
 *** 133,140 ****
   };
   
   /**/
 ! int
 ! boot_cap(Module m)
   {
       return !addbuiltins(m->nam, bintab, sizeof(bintab)/sizeof(*bintab));
   }
 --- 133,140 ----
   };
   
   /**/
 ! int BOOT(
 ! boot_cap)(Module m)
   {
       return !addbuiltins(m->nam, bintab, sizeof(bintab)/sizeof(*bintab));
   }
 ***************
 *** 142,149 ****
   #ifdef MODULE
   
   /**/
 ! int
 ! cleanup_cap(Module m)
   {
       deletebuiltins(m->nam, bintab, sizeof(bintab)/sizeof(*bintab));
       return 0;
 --- 142,149 ----
   #ifdef MODULE
   
   /**/
 ! int CLEANUP(
 ! cleanup_cap)(Module m)
   {
       deletebuiltins(m->nam, bintab, sizeof(bintab)/sizeof(*bintab));
       return 0;
 *** Src/Modules/clone.c	1997/05/11 12:06:41	1.3
 --- Src/Modules/clone.c	1997/05/11 14:07:07
 ***************
 *** 99,106 ****
   };
   
   /**/
 ! int
 ! boot_clone(Module m)
   {
       return !addbuiltins(m->nam, bintab, sizeof(bintab)/sizeof(*bintab));
   }
 --- 99,106 ----
   };
   
   /**/
 ! int BOOT(
 ! boot_clone)(Module m)
   {
       return !addbuiltins(m->nam, bintab, sizeof(bintab)/sizeof(*bintab));
   }
 ***************
 *** 108,115 ****
   #ifdef MODULE
   
   /**/
 ! int
 ! cleanup_clone(Module m)
   {
       deletebuiltins(m->nam, bintab, sizeof(bintab)/sizeof(*bintab));
       return 0;
 --- 108,115 ----
   #ifdef MODULE
   
   /**/
 ! int CLEANUP(
 ! cleanup_clone)(Module m)
   {
       deletebuiltins(m->nam, bintab, sizeof(bintab)/sizeof(*bintab));
       return 0;
 *** Src/Modules/example.c	1997/05/11 12:06:41	1.8
 --- Src/Modules/example.c	1997/05/11 14:07:19
 ***************
 *** 29,38 ****
    *
    */
   
 - #ifndef MODULE
 - #define mod_boot mod_boot_example
 - #endif
 - 
   #include "zsh.h"
   #include "example.pro"
   
 --- 29,34 ----
 ***************
 *** 64,71 ****
   };
   
   /**/
 ! int
 ! boot_example(Module m)
   {
       return !addbuiltins(m->nam, bintab, sizeof(bintab)/sizeof(*bintab));
   }
 --- 60,67 ----
   };
   
   /**/
 ! int BOOT(
 ! boot_example)(Module m)
   {
       return !addbuiltins(m->nam, bintab, sizeof(bintab)/sizeof(*bintab));
   }
 ***************
 *** 73,80 ****
   #ifdef MODULE
   
   /**/
 ! int
 ! cleanup_example(Module m)
   {
       deletebuiltins(m->nam, bintab, sizeof(bintab)/sizeof(*bintab));
       return 0;
 --- 69,76 ----
   #ifdef MODULE
   
   /**/
 ! int CLEANUP(
 ! cleanup_example)(Module m)
   {
       deletebuiltins(m->nam, bintab, sizeof(bintab)/sizeof(*bintab));
       return 0;
 *** Src/Modules/files.c	1997/05/11 12:06:41	1.15
 --- Src/Modules/files.c	1997/05/11 14:07:32
 ***************
 *** 514,521 ****
   };
   
   /**/
 ! int
 ! boot_files(Module m)
   {
       return !addbuiltins(m->nam, bintab, sizeof(bintab)/sizeof(*bintab));
   }
 --- 514,521 ----
   };
   
   /**/
 ! int BOOT(
 ! boot_files)(Module m)
   {
       return !addbuiltins(m->nam, bintab, sizeof(bintab)/sizeof(*bintab));
   }
 ***************
 *** 523,530 ****
   #ifdef MODULE
   
   /**/
 ! int
 ! cleanup_files(Module m)
   {
       deletebuiltins(m->nam, bintab, sizeof(bintab)/sizeof(*bintab));
       return 0;
 --- 523,530 ----
   #ifdef MODULE
   
   /**/
 ! int CLEANUP(
 ! cleanup_files)(Module m)
   {
       deletebuiltins(m->nam, bintab, sizeof(bintab)/sizeof(*bintab));
       return 0;
 *** Src/Modules/stat.c	1997/05/11 12:06:42	1.4
 --- Src/Modules/stat.c	1997/05/11 14:07:44
 ***************
 *** 516,523 ****
   }
   
   /**/
 ! int
 ! boot_stat(Module m)
   {
       return addbuiltin("stat", 0, bin_stat, 0, -1, 0, NULL, NULL);
   }
 --- 516,523 ----
   }
   
   /**/
 ! int BOOT(
 ! boot_stat)(Module m)
   {
       return addbuiltin("stat", 0, bin_stat, 0, -1, 0, NULL, NULL);
   }
 ***************
 *** 525,532 ****
   #ifdef MODULE
   
   /**/
 ! int
 ! cleanup_stat(Module m)
   {
       return deletebuiltin("stat");
   }
 --- 525,532 ----
   #ifdef MODULE
   
   /**/
 ! int CLEANUP(
 ! cleanup_stat)(Module m)
   {
       return deletebuiltin("stat");
   }
 *** Src/Zle/comp1.c	1997/05/11 12:06:45	1.5
 --- Src/Zle/comp1.c	1997/05/11 14:07:58
 ***************
 *** 241,248 ****
   }
   
   /**/
 ! int
 ! boot_comp1(Module m)
   {
       compctlreadptr = compctlread;
       clwords = (char **) zcalloc((clwsize = 16) * sizeof(char *));
 --- 241,248 ----
   }
   
   /**/
 ! int BOOT(
 ! boot_comp1)(Module m)
   {
       compctlreadptr = compctlread;
       clwords = (char **) zcalloc((clwsize = 16) * sizeof(char *));
 ***************
 *** 258,265 ****
   #ifdef MODULE
   
   /**/
 ! int
 ! cleanup_comp1(Module m)
   {
       deletehashtable(compctltab);
       zfree(clwords, clwsize * sizeof(char *));
 --- 258,265 ----
   #ifdef MODULE
   
   /**/
 ! int CLEANUP(
 ! cleanup_comp1)(Module m)
   {
       deletehashtable(compctltab);
       zfree(clwords, clwsize * sizeof(char *));
 *** Src/Zle/compctl.c	1997/05/11 12:06:45	1.11
 --- Src/Zle/compctl.c	1997/05/11 14:08:11
 ***************
 *** 1027,1034 ****
   };
   
   /**/
 ! int
 ! boot_compctl(Module m)
   {
       if(!addbuiltins(m->nam, bintab, sizeof(bintab)/sizeof(*bintab)))
   	return 1;
 --- 1027,1034 ----
   };
   
   /**/
 ! int BOOT(
 ! boot_compctl)(Module m)
   {
       if(!addbuiltins(m->nam, bintab, sizeof(bintab)/sizeof(*bintab)))
   	return 1;
 ***************
 *** 1039,1046 ****
   #ifdef MODULE
   
   /**/
 ! int
 ! cleanup_compctl(Module m)
   {
       compctltab->printnode = NULL;
       deletebuiltins(m->nam, bintab, sizeof(bintab)/sizeof(*bintab));
 --- 1039,1046 ----
   #ifdef MODULE
   
   /**/
 ! int CLEANUP(
 ! cleanup_compctl)(Module m)
   {
       compctltab->printnode = NULL;
       deletebuiltins(m->nam, bintab, sizeof(bintab)/sizeof(*bintab));
 *** Src/Zle/deltochar.c	1997/05/11 12:06:45	1.8
 --- Src/Zle/deltochar.c	1997/05/11 14:08:24
 ***************
 *** 72,79 ****
   }
   
   /**/
 ! int
 ! boot_deltochar(Module m)
   {
       w_deletetochar = addzlefunction("delete-to-char", deltochar, ZLE_KEEPSUFFIX);
       if (w_deletetochar)
 --- 72,79 ----
   }
   
   /**/
 ! int BOOT(
 ! boot_deltochar)(Module m)
   {
       w_deletetochar = addzlefunction("delete-to-char", deltochar, ZLE_KEEPSUFFIX);
       if (w_deletetochar)
 ***************
 *** 86,93 ****
   #ifdef MODULE
   
   /**/
 ! int
 ! cleanup_deltochar(Module m)
   {
       deletezlefunction(w_deletetochar);
       return 0;
 --- 86,93 ----
   #ifdef MODULE
   
   /**/
 ! int CLEANUP(
 ! cleanup_deltochar)(Module m)
   {
       deletezlefunction(w_deletetochar);
       return 0;
 *** Src/Zle/zle_main.c	1997/05/11 12:06:46	1.37
 --- Src/Zle/zle_main.c	1997/05/11 14:08:41
 ***************
 *** 778,785 ****
   };
   
   /**/
 ! int
 ! boot_zle(Module m)
   {
       /* Set up editor entry points */
       trashzleptr = trashzle;
 --- 778,785 ----
   };
   
   /**/
 ! int BOOT(
 ! boot_zle)(Module m)
   {
       /* Set up editor entry points */
       trashzleptr = trashzle;
 ***************
 *** 806,813 ****
   #ifdef MODULE
   
   /**/
 ! int
 ! cleanup_zle(Module m)
   {
       int i;
   
 --- 806,813 ----
   #ifdef MODULE
   
   /**/
 ! int CLEANUP(
 ! cleanup_zle)(Module m)
   {
       int i;
   

-----BEGIN PGP SIGNATURE-----
Version: 2.6.3ia
Charset: ascii

iQCVAwUBM3XW1XD/+HJTpU/hAQG60wP+NK36DWXFJj549Mh4UbHjEN2SUgEHmzAo
eL4pmDsje2oOh3Df+PNAphypFAdOZRXPea0hbp8oeaX84IHUBfXjqM7MGESSZpVb
VRcW/mBsBirqP6ms5WfcCCULwdgPJT0ZHU9fEW3g5pPCGp+aYEzEEsaAl7luMGW0
XrIXAgm/H2Q=
=M9jl
-----END PGP SIGNATURE-----


^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~1997-05-11 18:04 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
1997-03-24 18:51 module names Zefram
1997-05-11 17:51 Zefram

Code repositories for project(s) associated with this public inbox

	https://git.vuxu.org/mirror/zsh/

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).