Skip to content

Commit

Permalink
Fix for #3472. Set environment variables for compilation process same…
Browse files Browse the repository at this point in the history
… as in compile.bat
  • Loading branch information
adeas31 committed Dec 2, 2015
1 parent 1894748 commit e09f9bc
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions OMEdit/OMEditGUI/Util/StringHandler.cpp
Expand Up @@ -1409,6 +1409,12 @@ bool StringHandler::naturalSort(const QString &s1, const QString &s2) {
QProcessEnvironment StringHandler::compilationProcessEnvironment(QString *pCompilationProcessPath)
{
QProcessEnvironment environment = QProcessEnvironment::systemEnvironment();
// remove some environment variables if they exist.
environment.remove("GCC_EXEC_PREFIX");
environment.remove("CPLUS_INCLUDE_PATH");
environment.remove("C_INCLUDE_PATH");
environment.remove("LIBRARY_PATH");
environment.remove("ADDITIONAL_ARGS");
const char *OMDEV = getenv("OMDEV");
if (QString(OMDEV).isEmpty()) {
QString OMHOME = QString(Helper::OpenModelicaHome).replace("/", "\\");
Expand Down

0 comments on commit e09f9bc

Please sign in to comment.