Opened 7 years ago

Closed 5 years ago

#4504 closed defect (fixed)

Respect the standards of Windows application installation

Reported by: anonymous Owned by: Adeel Asghar
Priority: blocker Milestone: 1.14.0
Component: Installation program Version: v1.13.0-dev-nightly
Keywords: Cc:

Description (last modified by Francesco Casella)

(English translation)

Thank you for respecting the standards of installation of Windows and to allow the installation under c:\Program Files or c:\Program Files (x86). This is to allow a standard deployment on enterprise systems where these directories have appropriate security settings.

The non-conformancy w.r.t. good practices and standars is a blocker for a correct deployment of the program.

============================
merci de respecter les standards d'installation de Windows et d'autorise l'installation dans c:\program Fiels ou c:\program Files (x86). Et ce pour permettre un déploiement standard sur des postes d'entreprises ou ces répertoires comporte les sécurités adéquates.
Le non respect de ces recommandations et bonnes pratiques est == bloquant == pour un déploiement correct.

Attachments (1)

test.mos (1.7 KB ) - added by Francesco Casella 6 years ago.

Download all attachments as: .zip

Change History (21)

comment:1 by Jan Kokert, 7 years ago

Google translate:

Please respect the Windows installation standards and allow installation in c: \ program Fiels or c: \ program Files (x86). And this to allow a standard deployment on corporate stations or these directories includes the appropriate security.
Failure to adhere to these recommendations and good practices is == blocking == for proper deployment.

comment:2 by Adrian Pop, 7 years ago

Version: v1.11.0v1.13.0-dev-nightly

Adeel, can you make it a warning not an error to install in a path with spaces so we can properly test if is working?

comment:3 by Francesco Casella, 7 years ago

Tried it right now with the latest nightly and OMEdit, installed in C:\Program Files\. This is what I get

C:/Program Files/OpenModelica1.13.0-dev-64bit//share/omc/scripts/Compile.bat Modelica.Blocks.Examples.Filter gcc mingw64 parallel 4 0
PATH = "C:\Program Files\OpenModelica1.13.0-dev-64bit\tools\msys\mingw64\bin;C:\Program Files\OpenModelica1.13.0-dev-64bit\tools\msys\mingw64\bin\..\..\usr\bin;"
"C:/Program" non è riconosciuto come comando interno o esterno,
 un programma eseguibile o un file batch.
Compilation process failed. Exited with code 9009.

The OS message is in Italian but it basically seems that "C:/Program" is not a valid command. Not sure when this is invoked, but it seems it is quite early in the compilation process.

comment:4 by Francesco Casella, 7 years ago

Milestone: Future1.13.0

Another issue (orginally reported in #3769 and #3554) is that some users cannot run simulations because they lack admin rights and OMEdit wants to run executable files in %Localappdata%, %Localappdata%\Temp, and sub directories.

We should make sure that the default working directory chosen by OMEdit doesn't have this problem.

Last edited 7 years ago by Francesco Casella (previous) (diff)

comment:5 by Francesco Casella, 7 years ago

See also #1752 and the Compile.c file therein

Last edited 7 years ago by Francesco Casella (previous) (diff)

comment:6 by Francesco Casella, 6 years ago

Milestone: 1.13.02.0.0

This issue is important but not critical, and we have much more critical fixes to take care of. I'll retarget this to 2.0.0

comment:7 by Francesco Casella, 6 years ago

Description: modified (diff)
Summary: Respecter les standards d'installation de WindowsRespect the standards of Windows application installation

See also the comments in #5192: the installation on a Windows 7 PC with a Cyrillic username causes OMEdit to crash. We should check with Cyrillic usernames, as well as usernames with Swedish, German, and Italian accented letter, which are probably quite common among European users.

comment:8 by Francesco Casella, 6 years ago

Milestone: 2.0.01.14.0

Thanks to recent work by @adeas31, we should be able to install OpenModelica in the proper directories in 1.14.0 already.

comment:9 by Adeel Asghar, 6 years ago

A 64bit nightly build is already available for testing now. https://build.openmodelica.org/omc/builds/windows/nightly-builds/64bit/

comment:10 by Adrian Pop, 6 years ago

This is not working properly yet, I will remove the builds for now as they do not work as they should. See:
https://openmodelica.org/forum/default-topic/2721-error-process-failed-to-start-no-such-file-or-directory#p9205

comment:11 by Francesco Casella, 6 years ago

@adrpo, @adeas31, I'm not sure what was the latest Windows nightly build that still used the c:\OpenModelica path - I'd recommend that you copy that here https://build.openmodelica.org/omc/builds/windows/nightly-builds/64bit/ and remove all past nightly builds (if any) which are known to be broken.

The same applies to 32-bit installations.

comment:12 by Francesco Casella, 6 years ago

As I reported during today's webmeeting, the new Windows installation of OMEdit works fine for me. However, OMNotebook fails with this error message:

record SimulationResult
    resultFile = "",
    messages = "Simulation execution failed for model: TestSuperheater
\"\"C:/Users/FRANCE~1/AppData/Local/Temp/OpenModelica/TestSuperheater.exe\"\" non � riconosciuto come comando interno o esterno,
 un programma eseguibile o un file batch.
"
end SimulationResult;
false

when I try to simulate a model. I guess the damn 6-character short Windows name are to blame, FRANCE~1 should be Francesco Casella.

This is too bad, because I'm using OMNotebook for teaching, so I need to install an older version to use it.

comment:13 by Adeel Asghar, 6 years ago

FRANCE~1 is expected.
Can you run getErrorString() afterwards to see if there are anymore error messages.
What will happen if you run this via a mos-script.

in reply to:  13 comment:14 by Francesco Casella, 6 years ago

Replying to adeas31:

FRANCE~1 is expected.

Good to hear. I'm having a bout of nostalgia for early '80s home computing, MS-DOS and Windows 3.1. Or maybe not. It's incredible we still have to deal with this crap after so many years :)

Can you run getErrorString() afterwards to see if there are anymore error messages.

getErrorString() returns ""

What will happen if you run this via a mos-script.

I put the model in a .mos script (attached) and ran it from the command line provided by OMEdit with omc test.mos > log.txt. The result is more or less the same

true
true
record SimulationResult
    resultFile = "",
    simulationOptions = "startTime = 0.0, stopTime = 1.0, numberOfIntervals = 500, tolerance = 1e-006, method = 'dassl', fileNamePrefix = 'TestSuperheater', options = '', outputFormat = 'mat', variableFilter = '.*', cflags = '', simflags = ''",
    messages = "Simulation execution failed for model: TestSuperheater
\"\"D:/Temp/OMEdit/TestSuperheater.exe\"\" non � riconosciuto come comando interno o esterno,
 un programma eseguibile o un file batch.
",
    timeFrontend = 0.019118,
    timeBackend = 0.0572006,
    timeSimCode = 0.0103997,
    timeTemplates = 0.1271479,
    timeCompile = 0.1424594
end SimulationResult;
""

by Francesco Casella, 6 years ago

Attachment: test.mos added

comment:15 by Adeel Asghar, 6 years ago

I think your model is failing for some other known reason. Do you have the file TestSuperheater.exe in D:/Temp/OMEdit/?

Guessing from the above two results it should also fail in OMEdit.

in reply to:  15 comment:16 by Francesco Casella, 6 years ago

Replying to adeas31:

I think your model is failing for some other known reason. Do you have the file TestSuperheater.exe in D:/Temp/OMEdit/?

In fact, I haven't. I have all the .c and .h source code files, but no .o files and no .exe. It looks like the compilation didn't take place for some reason.

Guessing from the above two results it should also fail in OMEdit.

The same models run fine in OMEdit.

It also runs fine in OMNotebook if I use older versions installed in c:\openmodelica.

comment:17 by Adeel Asghar, 6 years ago

That is very weird since all of them use the same compile script.

I will install the nightly build and test it myself tomorrow.

comment:18 by Francesco Casella, 6 years ago

I tried a variant of test.mos which calls translateModel instead of simulate. It runs fine, getErrorString() returns "", but at the end of the day all source files are found in the working directory, but the C-compiler hasn't really run, nor has the linker, and their outputs are not in there.

BTW, running the GNU linker takes several seconds on Windows, so I would have noticed it running, while the script is actually executed in much less than a second. Too fast to be true :)

comment:19 by Adeel Asghar, 6 years ago

c2275ed/OpenModelica should work fine.

in reply to:  19 comment:20 by Francesco Casella, 5 years ago

Resolution: fixed
Status: newclosed

Replying to adeas31:

c2275ed/OpenModelica should work fine.

OMNotebook now also works fine with the latest nightly build. I think we can close this ticket for good, if anybody still experiences problems, please reopen it.

Note: See TracTickets for help on using tickets.