[PATCH] Allow ldflags to be used in SAMBA_MODULE()

Andrew Bartlett abartlet at samba.org
Mon Jul 29 15:15:21 MDT 2013


On Wed, 2013-07-24 at 16:12 +0100, Jon Knight wrote:
> Please find attached a small patch to buildtools/wafsamba/wafsamba.py 
> which a couple of us have found useful.  We're developing a local VFS 
> module that requires a number of external libraries to be included (for 
> example libcurl - yes, our VFS module is doing Evil Web Stuff!).  This 
> patch permits you to have a wscript_build in the source3/modules directory 
> with an entry such as:
> 
> bld.SAMBA3_MODULE('vfs_lboro_local',
>                    subsystem='vfs',
>                    source=VFS_LBORO_LOCAL_SRC,
>                    deps='samba-util ldap ',
>                    init_function='',
>                    internal_module=False,
>                    enabled=True,
>                    cflags='-lcurl -lssl -I/opt/ssl/include/ -L/opt/ssl/lib/ 
> -lcrypto -lyajl',
>                    ldflags='-lcurl -lssl -I/opt/ssl/include/ 
> -L/opt/ssl/lib/ -lcrypto -lyajl',
>                    )
> 
> It doesn't seem to make any difference to the existing Samba modules but 
> provides a bit of flexibility for VFS module authors such as ourselves.

So, the 'waf' way of doing this is to locate the library using the
configure stuff, and the depend on that library.  

Andrew Bartlett

-- 
Andrew Bartlett
http://samba.org/~abartlet/
Authentication Developer, Samba Team           http://samba.org
Samba Developer, Catalyst IT                   http://catalyst.net.nz




More information about the samba-technical mailing list