55 const std::string& code,
56 const std::string& cflags) {
58 std::stringstream codeStream(code);
70 std::stringstream& code,
71 const std::string& cflags) {
78 if (tempDir.empty()) {
81 std::string tempAdfFile =
83 std::string sourceCFile =
85 std::string resultFile =
97 std::ofstream cStream(sourceCFile);
102 cStream << code.rdbuf();
106 "-a " + tempAdfFile +
" " +
107 "-o " + resultFile +
" " +
110 std::vector<std::string> output;
115 resultProgram = Program::loadFromTPEF(resultFile, target);
123 return resultProgram;
135 const std::stringstream& code,
136 const std::string compileOptions) {
143 if (tempDir.empty()) {
146 std::string tempAdfFile =
148 std::string sourceLLFile =
150 std::string resultFile =
162 std::ofstream llStream(sourceLLFile);
163 if (llStream.fail()) {
167 llStream << code.rdbuf();
171 +
"-a " + tempAdfFile +
" "
172 +
"-o " + resultFile +
" " +
" "
173 + compileOptions +
" "
178 resultProgram = Program::loadFromTPEF(resultFile, target);
186 return resultProgram;