[PATCHSET] cwrap for 'make test'

Alexander Bokovoy ab at samba.org
Tue Mar 4 06:15:25 MST 2014


Hi Andrew,

On Tue, Mar 4, 2014 at 10:08 AM, Andrew Bartlett <abartlet at samba.org> wrote:

> On Thu, 2014-02-20 at 18:20 +0100, Andreas Schneider wrote:
> > Hello Team,
> >
> > I'm finally done with migrating our source tree to use the preloadable
> > wrappers. I check if a system version of the wrappers is installed and
> > available with the needed version. If none is installed it will use the
> > bundled version.
> >
> >
> > What are the advantages of the preloadable version?
> > * You can run 'make test' with a optimized build.
> > * It works with each system library and binary.
> > * We can use external projects in future (MIT KDC)
> >
> > You can find the patchset here:
> > https://git.samba.org/?p=asn/samba.git;a=shortlog;h=refs/heads/cwrap
> >
> >
> > I'm looking forward to discuss the patches with you!
>
> One issue I raised last time that is un-addressed is the change to the
> ldb module code, which worked around issues with samba_dlz.so being
> linked against internal Heimdal, and BIND9 itself being linked against
> the system MIT.
>
> I understand (but do not agree with) your position that having both in
> the same binary is a problem, but this is essentially what every single
> Samba installation using BIND9 does, and does sucessfully, and we can't
> break it.
>
We discussed it with Andreas this morning and came up with few possible
options to allow loading modules with both RTLD_DEEPBIND and without it:

- environmental variable, LDB_MODULES_DISABLE_DEEPBIND
- extend internal API for loading modules to take ldb struct and use flags
there to pass a flag to disable deepbind.
  Since modules are global, first ldb struct will override others, though
this would be a subtle change. Flags already can be set per ldb struct.
- Extend global initialization by providing ldb_global_init_ext(int flags)
and set preferred values somewhere where LDB modules loader would take it.

Out of three the latter would be less invasive and would only require
minimal change to dlz plugin.
Andreas has implemented the first one as it is the simplest code-wise for
ldb_modules.c

-- 
/ Alexander Bokovoy


More information about the samba-technical mailing list