1 #include <msp/builder/builder.h>
2 #include <msp/builder/sourcepackage.h>
3 #include <msp/core/algorithm.h>
4 #include "vssolutionfile.h"
9 VsSolutionFile::VsSolutionFile(Builder &b, const SourcePackage &p):
10 FileTarget(b, p, p.get_source_directory()/(p.get_name()+".sln"))
12 tool = &builder.get_toolchain().get_tool("VSSG");
15 void VsSolutionFile::find_dependencies()
17 find_dependencies(*package);
20 void VsSolutionFile::find_dependencies(const SourcePackage &spkg)
22 if(FileTarget *project = builder.get_vfs().get_target(spkg.get_source_directory()/(spkg.get_name()+".vcxproj")))
23 if(!any_equals(depends, static_cast<Target *>(project)))
25 add_dependency(*project);
27 for(const Package *r: spkg.get_required_packages())
28 if(const SourcePackage *s = dynamic_cast<const SourcePackage *>(r))
29 find_dependencies(*s);