summaryrefslogtreecommitdiff
path: root/buildtools
diff options
context:
space:
mode:
authorAndrew Tridgell <tridge@samba.org>2010-03-21 11:04:57 +1100
committerAndrew Tridgell <tridge@samba.org>2010-04-06 20:26:59 +1000
commite8775226ad2e40b96d8d5aae6c31c5845c562f20 (patch)
tree2d8740c627f74592e7208041432f8f2a3c8f4046 /buildtools
parent69c065c719c208c5ef0fd8cb5df55621dc77a3e1 (diff)
downloadsamba-e8775226ad2e40b96d8d5aae6c31c5845c562f20.tar.gz
samba-e8775226ad2e40b96d8d5aae6c31c5845c562f20.tar.bz2
samba-e8775226ad2e40b96d8d5aae6c31c5845c562f20.zip
build: added --disable-shared option
Diffstat (limited to 'buildtools')
-rw-r--r--buildtools/wafsamba/wafsamba.py16
1 files changed, 11 insertions, 5 deletions
diff --git a/buildtools/wafsamba/wafsamba.py b/buildtools/wafsamba/wafsamba.py
index 7324f8ff48..bfe20ce5eb 100644
--- a/buildtools/wafsamba/wafsamba.py
+++ b/buildtools/wafsamba/wafsamba.py
@@ -79,10 +79,10 @@ def SAMBA_LIBRARY(bld, libname, source,
SET_TARGET_TYPE(bld, libname, 'EMPTY')
return
- if not SET_TARGET_TYPE(bld, libname, 'LIBRARY'):
- return
-
- obj_target = libname + '.objlist'
+ if bld.env.DISABLE_SHARED:
+ obj_target = libname
+ else:
+ obj_target = libname + '.objlist'
# first create a target for building the object files for this library
# by separating in this way, we avoid recompiling the C files
@@ -99,6 +99,12 @@ def SAMBA_LIBRARY(bld, libname, source,
depends_on = depends_on,
local_include = local_include)
+ if bld.env.DISABLE_SHARED:
+ return
+
+ if not SET_TARGET_TYPE(bld, libname, 'LIBRARY'):
+ return
+
# the library itself will depend on that object target
deps += ' ' + public_deps
deps = TO_LIST(deps)
@@ -283,7 +289,7 @@ def SAMBA_MODULE(bld, modname, source,
# all disabled
bld.ADD_INIT_FUNCTION(subsystem, modname, init_function)
- if internal_module:
+ if internal_module or bld.env.DISABLE_SHARED:
# treat internal modules as subsystems for now
SAMBA_SUBSYSTEM(bld, modname, source,
deps=deps,