mirror of
https://github.com/supleed2/svd2cpp.git
synced 2024-12-22 05:35:50 +00:00
Remove OutputFile include
This commit is contained in:
parent
a88a46a9a9
commit
04dce84fff
|
@ -9,9 +9,8 @@ include_directories(tinyxml2)
|
|||
|
||||
add_library(ClassBuilder Src/ClassBuilder.cpp)
|
||||
add_library(Builders Src/Builders.cpp)
|
||||
add_library(OutputFile Src/OutputFile.cpp)
|
||||
add_library(XmlParser Src/XmlParser.cpp)
|
||||
add_library(tinyxml2 tinyxml2/tinyxml2.cpp)
|
||||
|
||||
add_executable(svd2cpp Src/main.cpp)
|
||||
target_link_libraries(svd2cpp ClassBuilder Builders OutputFile XmlParser tinyxml2)
|
||||
target_link_libraries(svd2cpp ClassBuilder Builders XmlParser tinyxml2)
|
||||
|
|
|
@ -1,8 +1,8 @@
|
|||
#include <fstream>
|
||||
#include <iostream>
|
||||
#include <cxxopts.hpp>
|
||||
#include <XmlParser.hpp>
|
||||
#include <ClassBuilder.hpp>
|
||||
#include <OutputFile.hpp>
|
||||
|
||||
int main(int argc, char** argv){
|
||||
// Create and configure options for the program
|
||||
|
@ -47,6 +47,8 @@ int main(int argc, char** argv){
|
|||
classBuilder.setupBuilders();
|
||||
classBuilder.build();
|
||||
|
||||
OutputFile oFile(outputFile);
|
||||
std::cout << (oFile.save(classBuilder.getStream()) ? "Successfuly created " : "Failed to create ") << outputFile << std::endl;
|
||||
std::ofstream oFile;
|
||||
oFile.open(outputFile);
|
||||
oFile << classBuilder.getStream().str();
|
||||
oFile.close();
|
||||
}
|
Loading…
Reference in a new issue