Opened 8 years ago

Closed 8 years ago

#4407 closed defect (fixed)

Cleanup of workspace / case sensitivity

Reported by: Henning Kiel Owned by: Lennart Ochel
Priority: normal Milestone: 1.12.0
Component: Code Generation Version:
Keywords: Cc:

Description

This tickets regards Windows and OSX.
I had two similar files (from students' exams) to simulate in OMNotebook which only differed in case, like this:

model tank
  Real x(start=1,fixed=true);
equation
  der(x)=x;
end tank;

model Tank
  Real y(start=1,fixed=true);
equation
  der(y)=-y;
end Tank;
simulate(tank); // works fine
simulate(Tank); // fails on OSX (HFS+) and Windows

I additionally got some warnings on OSX and it failed to link:

Tank_02nls.c:2:10: warning: non-portable path to file '"tank_model.h"'; specified path differs in case from file name on disk [-Wnonportable-include-path]
#include "Tank_model.h"

On windows I do not get a warning, but directly the linker error.

It seems that only tank.o is not re-created when simulation starts second time. All files seem up to date, but with wrong case, because HFS+ is case-preserving.

When I remove tank.o manually and run simulate(Tank) again I get no rule to make target Tank.o, so this seems to be a problem of generating the files: they are simply updated instead of deleted and created.

Change History (4)

comment:1 by Henning Kiel, 8 years ago

I fixed that with PR1638. Now, we unlink() the files before creating on OSX and Windows.

comment:2 by Henning Kiel, 8 years ago

Is this PR going to be merged?

comment:3 by Adrian Pop, 8 years ago

The PR is running now. If it will have issues on Windows I'll fix them.

comment:4 by Adrian Pop, 8 years ago

Resolution: fixed
Status: newclosed

Fixed with: 709531/OMCompiler.

Note: See TracTickets for help on using tickets.