Welcome, Guest
Username: Password: Remember me

TOPIC: Help, I can't compile in Ubuntu

Help, I can't compile in Ubuntu 11 years 8 months ago #7993

  • kurisusing
  • kurisusing's Avatar
Hi there,

I am a very new user and I am having problem compiling the program.

I have downloaded the package for Ubuntu, modified the .baschrc file but when I try to compile TELEMAC.py it just doesn't work telling me that there is not such a file and that compile isn't being recognized as a valid command.

I have checked both python and fortran are available...

Can anyone help me and/or give me a beginner step by step process to follow?

Thank you
The administrator has disabled public write access.

Help, I can't compile in Ubuntu 11 years 8 months ago #7994

  • abernard
  • abernard's Avatar
  • OFFLINE
  • Expert Boarder
  • Posts: 210
  • Thank you received: 45
Hi,

I've already pointed out this issue under ubuntu 12.10, see this post :
http://www.opentelemac.org/index.php/kunena/12-linux-version/5702-python-execution-problem#7207

Try to add your pytel directory address before compileTELEMAC.py

I haven't solved this issue, but it seems that your PATH isn't taken into account when you type $>python compileTELEMAC.py
The administrator has disabled public write access.
The following user(s) said Thank You: kurisusing

Help, I can't compile in Ubuntu 11 years 8 months ago #8002

  • kurisusing
  • kurisusing's Avatar
Thank you, this helped. Another bump on the road as appeared though:

christopher@ubuntu:~/opentelemac/pytel$ compileTELEMAC.py
Traceback (most recent call last):
File "/home/christopher/opentelemac/pytel/compileTELEMAC.py", line 59, in <module>
from parsers.parserFortran import scanSources
ImportError: No module named parsers.parserFortran

what do you think is the problem there?
The administrator has disabled public write access.

Help, I can't compile in Ubuntu 11 years 8 months ago #8004

  • Lufia
  • Lufia's Avatar
The error message says that the File/Module parserFortran.py was not found.
The python script parserFortran.py is in the directory pytel.

The python usually searches in the folder and subfolders for Modules. It looks like it is a further path error.

Maybe it works when you add the path of the parsers in the compileTELEMAC.py script (at the beginning before the parsers are imported)

sys.path.append(path.join( path.dirname(sys.argv[0]),'/myfolder/v6p2/pytel/parsers'))

/myfolder/... must be replaced by the path to your pytel/parsers
The administrator has disabled public write access.

Help, I can't compile in Ubuntu 11 years 8 months ago #8007

  • abernard
  • abernard's Avatar
  • OFFLINE
  • Expert Boarder
  • Posts: 210
  • Thank you received: 45
Hi,

Your problems (compilation and execution post 8006) are probably caused by incorrect settings.

Have you checked your settings by typing
$> echo$PATH (it must point to pytel directory)
and $> echo$SYSTELCFG (it must point to your systel.cfg file)

You also must edit the sytel.cfg file to be adapted to your configuration.
When you say
I have downloaded the package for Ubuntu
, do you mean that you have downloaded the source (from svn) or you have downloaded an already compiled version (from the website)?
The administrator has disabled public write access.

Help, I can't compile in Ubuntu 11 years 8 months ago #8019

  • kurisusing
  • kurisusing's Avatar
Dear abernard,

After some difficulties with the SVN, I decided to try first with the precompiled version.

I have therefore installed the folder and file structure in a folder named opentelemac in Ubuntu.

I did ammend the .bashr file with

with the export PATH.... and export SYSTELCFG... as presented on the 'installation page' of the website.

I have echo$PATH and echo$SYSTELCFG and the echo show me the systel.cfg and the pytel folder (although both lines ends with No such file or directory)

All of this being done, when I run

python runcode.py telemac2d -s (and here the cas file),

the system then send me an error:

Traceback (most recent call last):
File "runcode.py", line 105, in <module>
from utils.files import getFileContent, putFileContent, removeDirectories, isnewer
ImportError: No module named utils.files


... and then I get the prompt again.
The administrator has disabled public write access.

Help, I can't compile in Ubuntu 11 years 8 months ago #8024

  • abernard
  • abernard's Avatar
  • OFFLINE
  • Expert Boarder
  • Posts: 210
  • Thank you received: 45
Hi,

It's really recommended to compile from the source. You should add a post dealing with your SVN issue. Somebody may help you with this problem.

Maybe, you will find a solution to your problem with a pre-compiled version but you will probably need to optimize your installation by compiling from the source.
The administrator has disabled public write access.
The following user(s) said Thank You: kurisusing

Help, I can't compile in Ubuntu 11 years 8 months ago #8026

  • yugi
  • yugi's Avatar
  • OFFLINE
  • openTELEMAC Guru
  • Posts: 851
  • Thank you received: 244
Hi try to launch :
runcode.py telemac2d -s cas
instead of
python runcode.py telemac2d -s cas

That could be the source of your error.
There are 10 types of people in the world: those who understand binary, and those who don't.
The administrator has disabled public write access.

Help, I can't compile in Ubuntu 11 years 8 months ago #8028

  • kurisusing
  • kurisusing's Avatar
it did not work either, but thank you anyway
The administrator has disabled public write access.
Moderators: borisb

The open TELEMAC-MASCARET template for Joomla!2.5, the HTML 4 version.