Skip to content

Commit

Permalink
Move waf into third_party/.
Browse files Browse the repository at this point in the history
Signed-Off-By: Jelmer Vernooij <[email protected]>
Reviewed-by: Jeremy Allison <[email protected]>
  • Loading branch information
jelmer authored and jrasamba committed Mar 26, 2015
1 parent 32cbbed commit 90ec37c
Show file tree
Hide file tree
Showing 84 changed files with 16 additions and 89 deletions.
2 changes: 1 addition & 1 deletion buildtools/bin/waf
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@ def test(dir):
except OSError: pass

def find_lib():
return os.path.abspath(os.path.dirname(os.path.dirname(__file__)))
return os.path.abspath(os.path.join(os.path.dirname(__file__), '../../third_party/waf'))

wafdir = find_lib()
w = join(wafdir, 'wafadmin')
Expand Down
2 changes: 1 addition & 1 deletion ctdb/wscript
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ samba_dist.DIST_DIRS('''ctdb:. lib/replace:lib/replace lib/talloc:lib/talloc
third_party/popt:third_party/popt
lib/util:lib/util lib/tdb_wrap:lib/tdb_wrap
lib/ccan:lib/ccan libcli/util:libcli/util
buildtools:buildtools''')
buildtools:buildtools third_party/waf:third_party/waf''')


def set_options(opt):
Expand Down
2 changes: 1 addition & 1 deletion lib/ldb/wscript
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ import wafsamba, samba_dist, Options, Utils
samba_dist.DIST_DIRS('''lib/ldb:. lib/replace:lib/replace lib/talloc:lib/talloc
lib/tdb:lib/tdb lib/tdb:lib/tdb lib/tevent:lib/tevent
third_party/popt:third_party/popt
buildtools:buildtools''')
buildtools:buildtools third_party/waf:third_party/waf''')


def set_options(opt):
Expand Down
2 changes: 1 addition & 1 deletion lib/replace/wscript
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ sys.path.insert(0, srcdir + '/buildtools/wafsamba')
import wafsamba, samba_dist
import Options

samba_dist.DIST_DIRS('lib/replace buildtools:buildtools')
samba_dist.DIST_DIRS('lib/replace buildtools:buildtools third_party/waf:third_party/waf')

def set_options(opt):
opt.BUILTIN_DEFAULT('NONE')
Expand Down
3 changes: 2 additions & 1 deletion lib/talloc/wscript
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,8 @@ sys.path.insert(0, srcdir+"/buildtools/wafsamba")
import wafsamba, samba_dist, Options

# setup what directories to put in a tarball
samba_dist.DIST_DIRS('lib/talloc:. lib/replace:lib/replace buildtools:buildtools')
samba_dist.DIST_DIRS("""lib/talloc:. lib/replace:lib/replace
buildtools:buildtools third_party/waf:third_party/waf""")


def set_options(opt):
Expand Down
2 changes: 1 addition & 1 deletion lib/tdb/wscript
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ sys.path.insert(0, srcdir + '/buildtools/wafsamba')

import wafsamba, samba_dist, Options, Logs

samba_dist.DIST_DIRS('lib/tdb:. lib/replace:lib/replace buildtools:buildtools')
samba_dist.DIST_DIRS('lib/tdb:. lib/replace:lib/replace buildtools:buildtools third_party/waf:third_party/waf')

tdb1_unit_tests = [
'run-3G-file',
Expand Down
2 changes: 1 addition & 1 deletion lib/tevent/wscript
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ sys.path.insert(0, srcdir + '/buildtools/wafsamba')

import wafsamba, samba_dist, Options, Logs

samba_dist.DIST_DIRS('lib/tevent:. lib/replace:lib/replace lib/talloc:lib/talloc buildtools:buildtools')
samba_dist.DIST_DIRS('lib/tevent:. lib/replace:lib/replace lib/talloc:lib/talloc buildtools:buildtools third_party/waf:third_party/waf')

def set_options(opt):
opt.BUILTIN_DEFAULT('replace')
Expand Down
2 changes: 1 addition & 1 deletion selftest/tests.py
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@
planpythontestsuite(
"none", "wafsamba.tests.test_suite",
extra_path=[os.path.join(samba4srcdir, "..", "buildtools"),
os.path.join(samba4srcdir, "..", "buildtools", "wafadmin")])
os.path.join(samba4srcdir, "..", "third_party", "waf", "wafadmin")])
plantestsuite(
"samba4.blackbox.dbcheck.alpha13", "none",
["PYTHON=%s" % python, os.path.join(bbdir, "dbcheck-oldrelease.sh"),
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -295,5 +295,3 @@ def process_colors(producer):
#node = producer.bld.path.make_node('pdebug.svg')
f = open('pdebug.svg', 'w')
f.write("".join(out))


Original file line number Diff line number Diff line change
Expand Up @@ -180,4 +180,3 @@ def can_retrieve_cache(self):
setattr(t, 'post_run', post_run)
setattr(t, 'old_can_retrieve_cache', t.can_retrieve_cache)
setattr(t, 'can_retrieve_cache', can_retrieve_cache)

Original file line number Diff line number Diff line change
Expand Up @@ -340,4 +340,3 @@ def check_boost(self, *k, **kw):
self.check_message_2(kw['okmsg'])

return ret

Original file line number Diff line number Diff line change
Expand Up @@ -51,4 +51,3 @@ def signature(self):

Task.Task.signature_bak = Task.Task.signature # unused, kept just in case
Task.Task.signature = signature # overridden

Original file line number Diff line number Diff line change
Expand Up @@ -24,4 +24,3 @@ def fluid(self, node):
def detect(conf):
fluid = conf.find_program('fluid', var='FLUID', mandatory=True)
conf.check_cfg(path='fltk-config', package='', args='--cxxflags --ldflags', uselib_store='FLTK', mandatory=True)

Original file line number Diff line number Diff line change
Expand Up @@ -125,4 +125,3 @@ def sig_implicit_deps(self):
cls.post_run = post_run
cls.scan = scan
cls.sig_implicit_deps = sig_implicit_deps

Original file line number Diff line number Diff line change
Expand Up @@ -108,4 +108,3 @@ def apply_golink(self):
self.path.find_or_declare(self.target))
self.go_link_task.set_run_after(self.go_compile_task)
self.go_link_task.dep_nodes.extend(self.go_compile_task.outputs)

Original file line number Diff line number Diff line change
Expand Up @@ -94,4 +94,3 @@ def sweep(self):
Build.BuildContext.raw_compile = Build.BuildContext.compile
Build.BuildContext.compile = compile
Build.BuildContext.sweep = sweep

Original file line number Diff line number Diff line change
Expand Up @@ -32,4 +32,3 @@ def compile(self):
check_task_classes(self)
return comp(self)
Build.BuildContext.compile = compile

Original file line number Diff line number Diff line change
Expand Up @@ -273,4 +273,3 @@ def __init__(self):
def build(bld):
# dangerous, there is no other command hopefully
Utils.exec_command = exec_command

Original file line number Diff line number Diff line change
Expand Up @@ -187,4 +187,3 @@ def check_swig_version(conf, minver=None):

def detect(conf):
swig = conf.find_program('swig', var='SWIG', mandatory=True)

Original file line number Diff line number Diff line change
Expand Up @@ -110,4 +110,3 @@ def process_valadoc(self):

def detect(conf):
conf.find_program('valadoc', var='VALADOC', mandatory=False)

Original file line number Diff line number Diff line change
Expand Up @@ -1030,4 +1030,3 @@ def use_the_magic(self):
install_as = group_method(install_as)
install_files = group_method(install_files)
symlink_as = group_method(symlink_as)

Original file line number Diff line number Diff line change
Expand Up @@ -440,5 +440,3 @@ def conftest(f):
"decorator: attach new configuration tests (registered as strings)"
ConfigurationContext.tests[f.__name__] = f
return conf(f)


Original file line number Diff line number Diff line change
Expand Up @@ -73,4 +73,3 @@
# negative '<-' uninstall
INSTALL = 1337
UNINSTALL = -1337

Original file line number Diff line number Diff line change
Expand Up @@ -207,4 +207,3 @@ def __delattr__(self, name):
object.__delattr__(self, name)
else:
del self[name]

Original file line number Diff line number Diff line change
Expand Up @@ -131,4 +131,3 @@ def init_log():

# may be initialized more than once
init_log()

Original file line number Diff line number Diff line change
Expand Up @@ -692,4 +692,3 @@ def update_build_dir(self, env=None):

class Nodu(Node):
pass

Original file line number Diff line number Diff line change
Expand Up @@ -285,4 +285,3 @@ def tool_options(self, *k, **kw):

def parse_args(self, args=None):
parse_args_impl(self.parser, args)

Original file line number Diff line number Diff line change
Expand Up @@ -233,4 +233,3 @@ def start(self):

#print loop
assert (self.count == 0 or self.stop)

Original file line number Diff line number Diff line change
Expand Up @@ -583,4 +583,3 @@ def distcheck(appname='', version='', subdir=''):
# FIXME remove in Waf 1.6 (kept for compatibility)
def add_subdir(dir, bld):
bld.recurse(dir, 'build')

Original file line number Diff line number Diff line change
Expand Up @@ -1197,4 +1197,3 @@ def extract_deps(tasks):
delattr(x, 'cache_sig')
except AttributeError:
pass

Original file line number Diff line number Diff line change
Expand Up @@ -291,8 +291,8 @@ def find_sources_in_dirs(self, dirnames, excludes=[], exts=[]):
else: self.source += lst

def clone(self, env):
"""when creating a clone in a task generator method,
make sure to set posted=False on the clone
"""when creating a clone in a task generator method,
make sure to set posted=False on the clone
else the other task generator will not create its tasks"""
newobj = task_gen(bld=self.bld)
for x in self.__dict__:
Expand Down Expand Up @@ -609,4 +609,3 @@ def sequence_order(self):
self.bld.prev = self

feature('seq')(sequence_order)

Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
#!/usr/bin/env python
# encoding: utf-8
# Thomas Nagy, 2006 (ita)

Original file line number Diff line number Diff line change
Expand Up @@ -32,5 +32,3 @@ def find_ar(conf):
v = conf.env
conf.check_tool('ar')
if not v['AR']: conf.fatal('ar is required for static libraries - not found')


Original file line number Diff line number Diff line change
Expand Up @@ -35,4 +35,3 @@ def big_bison(self, node):
def detect(conf):
bison = conf.find_program('bison', var='BISON', mandatory=True)
conf.env['BISONFLAGS'] = '-d'

Original file line number Diff line number Diff line change
Expand Up @@ -97,4 +97,3 @@ def c_hook(self, node):
cls = Task.simple_task_type('cc_link', link_str, color='YELLOW', ext_in='.o', ext_out='.bin', shell=False)
cls.maxjobs = 1
cls.install = Utils.nada

Original file line number Diff line number Diff line change
Expand Up @@ -637,4 +637,3 @@ def exec_vnum_link(self):
def add_as_needed(conf):
if conf.env.DEST_BINFMT == 'elf' and 'gcc' in (conf.env.CXX_NAME, conf.env.CC_NAME):
conf.env.append_unique('LINKFLAGS', '--as-needed')

Original file line number Diff line number Diff line change
Expand Up @@ -64,4 +64,3 @@ def set_options(opt):

for c_compiler in test_for_compiler.split():
opt.tool_options('%s' % c_compiler, option_group=cc_compiler_opts)

Original file line number Diff line number Diff line change
Expand Up @@ -59,4 +59,3 @@ def set_options(opt):

for cxx_compiler in test_for_compiler.split():
opt.tool_options('%s' % cxx_compiler, option_group=cxx_compiler_opts)

Original file line number Diff line number Diff line change
Expand Up @@ -30,4 +30,3 @@ def set_options(opt):

for d_compiler in ['gdc', 'dmd']:
opt.tool_options('%s' % d_compiler, option_group=d_compiler_opts)

Original file line number Diff line number Diff line change
Expand Up @@ -746,4 +746,3 @@ def cc_load_tools(conf):
@conftest
def cxx_load_tools(conf):
conf.check_tool('cxx')

Original file line number Diff line number Diff line change
Expand Up @@ -65,4 +65,3 @@ def detect(conf):

def set_options(opt):
opt.add_option('--with-csc-binary', type='string', dest='cscbinary')

Original file line number Diff line number Diff line change
Expand Up @@ -101,4 +101,3 @@ def cxx_hook(self, node):
cls = Task.simple_task_type('cxx_link', link_str, color='YELLOW', ext_in='.o', ext_out='.bin', shell=False)
cls.maxjobs = 1
cls.install = Utils.nada

Original file line number Diff line number Diff line change
Expand Up @@ -532,4 +532,3 @@ def check_dlibrary(conf):
print imp + " ",
print
"""

Original file line number Diff line number Diff line change
Expand Up @@ -31,4 +31,3 @@ def process_dbus(self):

def detect(conf):
dbus_binding_tool = conf.find_program('dbus-binding-tool', var='DBUS_BINDING_TOOL')

Original file line number Diff line number Diff line change
Expand Up @@ -61,4 +61,3 @@ def detect(conf):

if conf.env.D_COMPILER.find('ldc') > -1:
conf.common_flags_ldc()

Original file line number Diff line number Diff line change
Expand Up @@ -22,4 +22,3 @@ def decide_ext(self, node):
def detect(conf):
conf.find_program('flex', var='FLEX', mandatory=True)
conf.env['FLEXFLAGS'] = ''

Original file line number Diff line number Diff line change
Expand Up @@ -35,4 +35,3 @@ def detect(conf):
conf.find_program(['gas', 'as'], var='AS')
if not conf.env.AS: conf.env.AS = conf.env.CC
#conf.env.ASFLAGS = ['-c'] <- may be necesary for .S files

Original file line number Diff line number Diff line change
Expand Up @@ -136,4 +136,3 @@ def detect(conf):
conf.cc_load_tools()
conf.cc_add_flags()
conf.link_add_flags()

Original file line number Diff line number Diff line change
Expand Up @@ -49,4 +49,3 @@ def detect(conf):
conf.check_tool('d')
conf.common_flags_gdc()
conf.d_platform_flags()

Original file line number Diff line number Diff line change
Expand Up @@ -161,4 +161,3 @@ def process_enums(self):
def detect(conf):
glib_genmarshal = conf.find_program('glib-genmarshal', var='GLIB_GENMARSHAL')
mk_enums_tool = conf.find_program('glib-mkenums', var='GLIB_MKENUMS')

Original file line number Diff line number Diff line change
Expand Up @@ -220,4 +220,3 @@ def getstr(varname):

def set_options(opt):
opt.add_option('--want-rpath', type='int', default=1, dest='want_rpath', help='set rpath to 1 or 0 [Default 1]')

Original file line number Diff line number Diff line change
Expand Up @@ -108,4 +108,3 @@ def set_options(opt):
str_default = default
str_help = '%s [Default: %s]' % (help, str_default)
dirs_options.add_option(option_name, help=str_help, default='', dest=name.upper())

Original file line number Diff line number Diff line change
Expand Up @@ -15,4 +15,3 @@ def detect(conf):
gob2 = conf.find_program('gob2', var='GOB2', mandatory=True)
conf.env['GOB2'] = gob2
conf.env['GOB2FLAGS'] = ''

Original file line number Diff line number Diff line change
Expand Up @@ -100,7 +100,7 @@ def gxx_modifier_darwin(conf):

v['SHLIB_MARKER'] = ''
v['STATICLIB_MARKER'] = ''
v['SONAME_ST'] = ''
v['SONAME_ST'] = ''

@conftest
def gxx_modifier_aix(conf):
Expand Down Expand Up @@ -134,4 +134,3 @@ def detect(conf):
conf.cxx_load_tools()
conf.cxx_add_flags()
conf.link_add_flags()

File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -136,4 +136,3 @@ def getstr(varname):
def set_options(opt):
opt.add_option('--want-rpath', type='int', default=1, dest='want_rpath', help='set rpath to 1 or 0 [Default 1]')
opt.add_option('--datadir', type='string', default='', dest='datadir', help='read-only application data')

Original file line number Diff line number Diff line change
Expand Up @@ -252,4 +252,3 @@ def check_jni_headers(conf):
break
else:
conf.fatal('could not find lib jvm in %r (see config.log)' % libDirs)

Original file line number Diff line number Diff line change
Expand Up @@ -71,4 +71,3 @@ def detect(conf):
conf.env['MSGFMT'] = conf.find_program('msgfmt')

Task.simple_task_type('msgfmt', '${MSGFMT} ${SRC} -o ${TGT}', color='BLUE', shell=False)

Original file line number Diff line number Diff line change
Expand Up @@ -327,4 +327,3 @@ def p(x):

if __name__ == '__main__':
useCmdLine()

Original file line number Diff line number Diff line change
Expand Up @@ -22,4 +22,3 @@ def init_lua(self):

def detect(conf):
conf.find_program('luac', var='LUAC', mandatory = True)

Original file line number Diff line number Diff line change
Expand Up @@ -427,4 +427,3 @@ def runnable_status(self):

Task.task_type_from_func('copy', vars=[], func=action_process_file_func)
TaskGen.task_gen.classes['command-output'] = cmd_output_taskgen

Original file line number Diff line number Diff line change
Expand Up @@ -729,15 +729,15 @@ def exec_mf(self):
self.do_manifest = False

outfile = self.outputs[0].bldpath(env)

manifest = None
for out_node in self.outputs:
if out_node.name.endswith('.manifest'):
manifest = out_node.bldpath(env)
break
if manifest is None:
# Should never get here. If we do, it means the manifest file was
# never added to the outputs list, thus we don't have a manifest file
# Should never get here. If we do, it means the manifest file was
# never added to the outputs list, thus we don't have a manifest file
# to embed, so we just return.
return 0

Expand Down Expand Up @@ -794,4 +794,3 @@ def exec_command_msvc(self, *k, **kw):
cls = Task.TaskBase.classes.get(k, None)
if cls:
cls.exec_command = exec_command_msvc

Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ def nasm_file(self, node):
try: obj_ext = self.obj_ext
except AttributeError: obj_ext = '_%d.o' % self.idx

task = self.create_task('nasm', node, node.change_ext(obj_ext))
task = self.create_task('nasm', node, node.change_ext(obj_ext))
self.compiled_tasks.append(task)

self.meths.append('apply_nasm_vars')
Expand All @@ -46,4 +46,3 @@ def nasm_file(self, node):

def detect(conf):
nasm = conf.find_program(['nasm', 'yasm'], var='NASM', mandatory=True)

Original file line number Diff line number Diff line change
Expand Up @@ -295,4 +295,3 @@ def detect(conf):
v['LIBPATH_OCAML'] = Utils.cmd_output(conf.env['OCAMLC']+' -where').strip()+os.sep
v['CPPPATH_OCAML'] = Utils.cmd_output(conf.env['OCAMLC']+' -where').strip()+os.sep
v['LIB_OCAML'] = 'camlrun'

Loading

0 comments on commit 90ec37c

Please sign in to comment.