minor change

This commit is contained in:
Roy Qu 2023-08-14 19:56:56 +08:00
parent c2c2e3c9b1
commit fbef3b4f29
1 changed files with 1 additions and 17 deletions

View File

@ -2318,7 +2318,7 @@ void Settings::CompilerSet::setSDCCProperties(const QString& binDir, const QStri
//Target //Target
int delimPos = 0; int delimPos = 0;
while (delimPos<output.length() && (output[delimPos]>=32)) while (delimPos<output.length() && (output[delimPos]>=((char)32)))
delimPos++; delimPos++;
QString triplet = output.mid(0,delimPos); QString triplet = output.mid(0,delimPos);
@ -2369,26 +2369,10 @@ QStringList Settings::CompilerSet::defines(bool isCpp) {
arguments.append(NULL_FILE); arguments.append(NULL_FILE);
// QStringList args;
// args.append("-nostdinc");
// args.append("-Wall");
// args.append("-std=c11");
// args.append("--obj-ext=.rel");
// args.append("-d\"M\"");
// args.append("-E");
// args.append("-isystem");
// args.append("D:\\sdcc\\bin\\..\\include\\mcs51");
// args.append("-xc");
// args.append("NUL");
// QFileInfo info(findProgramInBinDirs("sdcpp.exe"));
// qDebug()<<"**"<<getCompilerOutput(info.absolutePath(),info.fileName(),args);
// qDebug()<<mCCompiler<<arguments;
QFileInfo ccompiler(mCCompiler); QFileInfo ccompiler(mCCompiler);
QByteArray output = getCompilerOutput(ccompiler.absolutePath(),ccompiler.fileName(),arguments); QByteArray output = getCompilerOutput(ccompiler.absolutePath(),ccompiler.fileName(),arguments);
// 'cpp.exe -dM -E -x c++ -std=c++17 NUL' // 'cpp.exe -dM -E -x c++ -std=c++17 NUL'
// qDebug()<<"------------------"; // qDebug()<<"------------------";
// qDebug()<<output.split('\n');
QStringList result; QStringList result;
#ifdef ENABLE_SDCC #ifdef ENABLE_SDCC
if (mCompilerType==CompilerType::SDCC) { if (mCompilerType==CompilerType::SDCC) {