Skip to content
This repository was archived by the owner on May 18, 2019. It is now read-only.

Commit e3fba96

Browse files
sjoelundOpenModelica-Hudson
authored andcommitted
Do not enforce -flto when building FMUs
The link-time optimization flags might not be available for all targets. Belonging to [master]: - #2524
1 parent 7f3aeef commit e3fba96

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

Compiler/Script/CevalScriptBackend.mo

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1879,10 +1879,10 @@ algorithm
18791879
equation
18801880
Values.ENUM_LITERAL(index=access) = Interactive.checkAccessAnnotationAndEncryption(className, SymbolTable.getAbsyn());
18811881
if (access >= 9) then // i.e., The class is not encrypted.
1882-
(newp,filename) = Interactive.getContainedClassAndFile(className, SymbolTable.getAbsyn());
1883-
str = Dump.unparseStr(newp);
1884-
System.writeFile(filename, str);
1885-
b = true;
1882+
(newp,filename) = Interactive.getContainedClassAndFile(className, SymbolTable.getAbsyn());
1883+
str = Dump.unparseStr(newp);
1884+
System.writeFile(filename, str);
1885+
b = true;
18861886
else
18871887
Error.addMessage(Error.SAVE_ENCRYPTED_CLASS_ERROR, {});
18881888
b = false;
@@ -3392,7 +3392,7 @@ algorithm
33923392
then ();
33933393
else
33943394
algorithm
3395-
cmd := "cd \"" + fmutmp + "/sources\" && ./configure --host="+quote+platform+quote+" CFLAGS="+quote+"-Os -flto"+quote+" LDFLAGS=-flto";
3395+
cmd := "cd \"" + fmutmp + "/sources\" && ./configure --host="+quote+platform+quote+" CFLAGS="+quote+"-Os"+quote+" LDFLAGS=";
33963396
if 0 <> System.systemCall(cmd, outFile=logfile) then
33973397
Error.addMessage(Error.SIMULATOR_BUILD_ERROR, {System.readFile(logfile)});
33983398
System.removeFile(dir + logfile);

0 commit comments

Comments
 (0)