summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJelmer Vernooij <jelmer@samba.org>2011-08-21 02:09:14 +0200
committerJelmer Vernooij <jelmer@samba.org>2011-08-21 03:22:05 +0200
commit12e1fdf0899c8f9176f4a7e789faa2758c4eaa70 (patch)
tree237311dafdb5746ef6d14fbfa428ff3336d13458
parent2b4028359135058700456eb3720ece105611425f (diff)
downloadsamba-12e1fdf0899c8f9176f4a7e789faa2758c4eaa70.tar.gz
samba-12e1fdf0899c8f9176f4a7e789faa2758c4eaa70.tar.bz2
samba-12e1fdf0899c8f9176f4a7e789faa2758c4eaa70.zip
wafsamba: Require public libraries to have a pc file specified, or explicitly specified that they don't need one.
-rw-r--r--buildtools/wafsamba/wafsamba.py15
-rwxr-xr-xlib/util/wscript_build3
-rw-r--r--librpc/wscript_build7
-rwxr-xr-xsource3/wscript_build4
4 files changed, 21 insertions, 8 deletions
diff --git a/buildtools/wafsamba/wafsamba.py b/buildtools/wafsamba/wafsamba.py
index 3858770a6f..85ff732f14 100644
--- a/buildtools/wafsamba/wafsamba.py
+++ b/buildtools/wafsamba/wafsamba.py
@@ -191,13 +191,19 @@ def SAMBA_LIBRARY(bld, libname, source,
link_name = bld.map_shlib_extension(link_name, python=(target_type=='PYTHON'))
# we don't want any public libraries without version numbers
- if not private_library and vnum is None and soname is None and target_type != 'PYTHON' and not realname:
- raise Utils.WafError("public library '%s' must have a vnum" % libname)
+ if (not private_library and target_type != 'PYTHON' and not realname):
+ if vnum is None and soname is None:
+ raise Utils.WafError("public library '%s' must have a vnum" %
+ libname)
+ if pc_files is None:
+ raise Utils.WafError("public library '%s' must have pkg-config file" %
+ libname)
if target_type == 'PYTHON' or realname or not private_library:
bundled_name = libname.replace('_', '-')
else:
- bundled_name = PRIVATE_NAME(bld, libname, bundled_extension, private_library)
+ bundled_name = PRIVATE_NAME(bld, libname, bundled_extension,
+ private_library)
ldflags = TO_LIST(ldflags)
@@ -273,7 +279,8 @@ def SAMBA_LIBRARY(bld, libname, source,
if pc_files is not None:
bld.PKG_CONFIG_FILES(pc_files, vnum=vnum)
- if manpages is not None and 'XSLTPROC_MANPAGES' in bld.env and bld.env['XSLTPROC_MANPAGES']:
+ if (manpages is not None and 'XSLTPROC_MANPAGES' in bld.env and
+ bld.env['XSLTPROC_MANPAGES']):
bld.MANPAGES(manpages)
diff --git a/lib/util/wscript_build b/lib/util/wscript_build
index 82af65c010..553748a22e 100755
--- a/lib/util/wscript_build
+++ b/lib/util/wscript_build
@@ -54,7 +54,8 @@ bld.SAMBA_LIBRARY('tevent-util',
public_deps='tevent',
public_headers='tevent_ntstatus.h tevent_unix.h tevent_werror.h',
header_path=[ ('*', 'util') ],
- vnum='0.0.1'
+ pc_files=[],
+ vnum='0.0.1'
)
diff --git a/librpc/wscript_build b/librpc/wscript_build
index 444cb94671..cf6c448646 100644
--- a/librpc/wscript_build
+++ b/librpc/wscript_build
@@ -588,6 +588,7 @@ bld.SAMBA_LIBRARY('ndr',
)
bld.SAMBA_LIBRARY('dcerpc-binding',
- source='rpc/dcerpc_error.c rpc/binding.c rpc/dcerpc_util.c rpc/binding_handle.c',
- deps='ndr tevent NDR_DCERPC LIBTSOCKET tevent-util',
- vnum='0.0.1')
+ source='rpc/dcerpc_error.c rpc/binding.c rpc/dcerpc_util.c rpc/binding_handle.c',
+ deps='ndr tevent NDR_DCERPC LIBTSOCKET tevent-util',
+ pc_files=[],
+ vnum='0.0.1')
diff --git a/source3/wscript_build b/source3/wscript_build
index 3cc84710f2..8d4a02f33a 100755
--- a/source3/wscript_build
+++ b/source3/wscript_build
@@ -670,6 +670,7 @@ bld.SAMBA3_LIBRARY('netapi',
RPC_NDR_SRVSVC RPC_NDR_WKSSVC RPC_NDR_INITSHUTDOWN
INIT_NETLOGON INIT_SAMR popt_samba3''',
public_headers='../source3/lib/netapi/netapi.h',
+ pc_files=[],
vnum='0',
vars=locals())
@@ -679,6 +680,7 @@ bld.SAMBA3_LIBRARY('libsmb/smbclient',
LIBMSRPC_GEN msrpc3 libcli_lsa3 RPC_NDR_SRVSVC popt_samba3''',
public_headers='include/libsmbclient.h',
vnum='0',
+ pc_files=[],
vars=locals())
bld.SAMBA3_LIBRARY('smbsharemodes',
@@ -686,6 +688,7 @@ bld.SAMBA3_LIBRARY('smbsharemodes',
public_deps='''talloc tdb_compat''',
deps='''ccan''',
public_headers='include/smb_share_modes.h',
+ pc_files=[],
vnum='0',
vars=locals())
@@ -886,6 +889,7 @@ bld.SAMBA3_LIBRARY('smbconf',
deps='''LIBSMBCONF smbregistry REG_SMBCONF talloc param
util_reg samba-util errors3 charset SAMBA_VERSION''',
public_headers='../lib/smbconf/smbconf.h',
+ pc_files=[],
vnum='0')
bld.SAMBA3_LIBRARY('smbd_conn',