Since DataTransform is not buildable, it won't get a rebuild flag even if
its dependencies change. Thus the dependencies must also be added to
DataCollection.
{
return comp.get_package().get_temp_directory()/comp.get_name()/(FS::basepart(FS::basename(src))+".mdc");
}
+
+void DataCollection::find_dependencies()
+{
+ source.prepare();
+ const Target::Dependencies &tdeps = source.get_transitive_dependencies();
+ for(Target::Dependencies::const_iterator i=tdeps.begin(); i!=tdeps.end(); ++i)
+ add_dependency(**i);
+}
public:
virtual const char *get_type() const { return "DataCollection"; }
DataTransform &get_source() const { return source; }
+
+private:
+ virtual void find_dependencies();
};
#endif
{
FS::Path file_path = FS::dirname(path)/ *i;
if(Target *tgt = builder.get_vfs().get_target(file_path))
- add_dependency(*tgt);
+ add_transitive_dependency(*tgt);
else
- add_dependency(*new File(builder, *package, file_path));
+ add_transitive_dependency(*new File(builder, *package, file_path));
}
}