mirror of
https://github.com/reactos/CMake.git
synced 2024-11-24 12:09:48 +00:00
bindexplib: Add support for parsing and integrating .def
files
This commit is contained in:
parent
845c482448
commit
24361a455a
@ -258,12 +258,19 @@ int cmcmd::ExecuteCMakeCommand(std::vector<std::string>& args)
|
||||
<< "\n";
|
||||
return 1;
|
||||
}
|
||||
std::string objfile;
|
||||
std::string file;
|
||||
bindexplib deffile;
|
||||
while (cmSystemTools::GetLineFromStream(fin, objfile)) {
|
||||
if (!deffile.AddObjectFile(objfile.c_str())) {
|
||||
while (cmSystemTools::GetLineFromStream(fin, file)) {
|
||||
std::string const& ext = cmSystemTools::GetFilenameLastExtension(file);
|
||||
if (cmSystemTools::LowerCase(ext) == ".def") {
|
||||
if (!deffile.AddDefinitionFile(file.c_str())) {
|
||||
return 1;
|
||||
}
|
||||
} else {
|
||||
if (!deffile.AddObjectFile(file.c_str())) {
|
||||
return 1;
|
||||
}
|
||||
}
|
||||
}
|
||||
deffile.WriteFile(fout);
|
||||
fclose(fout);
|
||||
|
Loading…
Reference in New Issue
Block a user