diff --git a/playground/relocate/c/a.c b/playground/relocate/c/a.c index 5bdc2c54..be5b1790 100644 --- a/playground/relocate/c/a.c +++ b/playground/relocate/c/a.c @@ -1 +1,4 @@ +#include "a.h" + int k = 332; + diff --git a/playground/relocate/c/a/a.h b/playground/relocate/c/a/a.h new file mode 100644 index 00000000..dc5422f1 --- /dev/null +++ b/playground/relocate/c/a/a.h @@ -0,0 +1 @@ +int u = 0; diff --git a/playground/relocate/c/wscript b/playground/relocate/c/wscript index 63370c72..b1cc5b21 100644 --- a/playground/relocate/c/wscript +++ b/playground/relocate/c/wscript @@ -7,5 +7,5 @@ def configure(conf): conf.load('relocation compiler_c') def build(bld): - bld.shlib(source='a.c', target='one') + bld.shlib(source='a.c', target='one', includes='a') bld.program(source='main.c', target='two', use='one') diff --git a/waflib/extras/relocation.py b/waflib/extras/relocation.py index ab8dd361..aa758b44 100644 --- a/waflib/extras/relocation.py +++ b/waflib/extras/relocation.py @@ -80,6 +80,6 @@ def apply_incpaths(self): lst = self.to_incnodes(self.to_list(getattr(self, 'includes', [])) + self.env['INCLUDES']) self.includes_nodes = lst bld = self.bld - self.env['INCPATHS'] = [x.is_child_of(bld.srcnode) and x.path_from(bld.srcnode) or x.abspath() for x in lst] + self.env['INCPATHS'] = [x.is_child_of(bld.srcnode) and x.path_from(bld.bldnode) or x.abspath() for x in lst]