CFD Online Discussion Forums

CFD Online Discussion Forums (http://www.cfd-online.com/Forums/)
-   OpenFOAM Installation (http://www.cfd-online.com/Forums/openfoam-installation/)
-   -   Trouble with installing OpenFOAM on Ubuntu (http://www.cfd-online.com/Forums/openfoam-installation/16416-trouble-installing-openfoam-ubuntu.html)

Milos February 28, 2009 06:35

Trouble with installing OpenFOAM on Ubuntu
 
I'm a brand new user of Linux Ubuntu 8.10 (32-bit) and I'm experiencing some issues with the installation of OpenFOAM 1.5.

ParaView binaries will work only with the Qt version with which it was made, namely 4.3.x (for the 32-bit version). Now, there is a link on the official site for the repositories, but the only thing that happens when I put the URL into my Synaptic APT is "malformed line 85...", which in addition completely crashed my Synaptic. I solved that, but I still can't find a proper repository for Qt 4.3.x.

Can anyone provide me with a full, appropriate APT address that has got Qt 4.3.x?

Thanx a lot!

Ahmed March 1, 2009 05:15

Re: Trouble with installing OpenFOAM on any Distro
 
try this one http://www.linuxfromscratch.org/blfs...ble/x/qt4.html Do you know, where exactly this version of Qt should be installed so it does not interfere with the already installed distro Qt, I mean, should it be installed within the third party folder or the OpenFOAM folder? thanks and good luck

pei-ying hsieh March 1, 2009 07:32

Re: Trouble with installing OpenFOAM on any Distro
 
Hi,

Search the OpenFOAM forum. You can find detailed steps and links on how to install OpenFOAM-1.5/paraview there (Ubuntu and OpenSUSE).

phsieh2005

Ahmed March 1, 2009 15:48

Re: Trouble with installing OpenFOAM on any Distro
 
pei-ying hsieh wrote "Search the OpenFOAM forum", no comment on that, the openFoam forum has a lot of information and a new comer to OpenFOAM/Linux will definitely get confused. Have a positive reply, put a link(s) to what you consider the proper and easy procedure to solve this situation or write a few lines telling us how?


Ahmed March 1, 2009 16:41

Re: Trouble with installing OpenFOAM on any Distro
 
for instance, look that thread http://openfoam.cfd-online.com/cgi-b...2166#POST32166 How many have succeeded and how many have failed?

Ahmed March 1, 2009 17:26

Re: Trouble with installing OpenFOAM on any Distro
 
instructions for installing are here http://doc.trolltech.com/4.4/install-x11.html


Harish March 1, 2009 20:23

Re: Trouble with installing OpenFOAM on any Distro
 
I run OpenFoam 1.5 on Ubuntu 8.10. There are two things that you need to look into.

1. Is your version of gcc higher/equal to the standard build used for openfoam 1.5 2. Check the compiler openfoam employs in the ../etc/bashrc file

Qt is required for you to compile paraview and its a bit of effort to make it work. The paraview part is totally unrelated to the solvers. Also if paraview does not work you can always use foamToVTK utility and view the vtk files in paraview directly.

Hope this helps.

Milos March 2, 2009 03:25

Re: Trouble with installing OpenFOAM on any Distro
 
Thanks a lot to everyone! I'll look up all the options and let you know how I did.

Ahmed March 4, 2009 11:42

Re: Trouble with installing OpenFOAM on any Distro
 
Open Foam 1.5 comes with an old version of paraview that requires an old version of Qt. Here is How I solved the first part of the problem, i.e., installing qt4.3.5 within the OpenFOAM's ThirdParty folder.

1- In your home directory create a Tmp folder

2- Download into this folder the following file ftp://ftp.trolltech.com/qt/source/qt...c-4.3.5.tar.gz

3- Once the download is finished, change to that Tmp directory and issue the following two commands

i- gunzip qt-x11-opensource-src-4.3.5.tar.gz

ii- tar xvf qt-x11-opensource-src-4.3.5.tar

now you have the folder qt-x11-opensource-src-4.3.5, so change to that folder and issue the following command

./configure -prefix /home/XXXXX/OpenFOAM/ThirdParty/QT-4.3.5

where XXXXX stands for your name, then accept the license by typing yes

After few minutes you will get the following:-

Qt is now configured for building. Just type "gmake" Once everything is built you must run "gmake install" Qt will be installed into /home/XXXXX/OpenFOAM/ThirdParty/Qt-4.3.5.

at the end of this process (45 minutes or more) you will have qt-4.3.5 installed into the ThirdParty folder.

Now the question is How to make OpenFOAM use this qt and not the already installed qt?

If you have solved this question and willing to share your knowledge with us, Please write back and tell us what you did.

If you plan to write "search for" or "google for", Please abstain from writing Thank you for your understanding

Harish, thanks for the tip, I did not know that foamtoVTK can be used, thanks again

Ahmed March 6, 2009 21:46

Re: Trouble with installing OpenFOAM on any Distro
 
The linker uses the following search paths to locate required shared libraries:

1. Any directories specified by -rpath-link options.

2. Any directories specified by -rpath options. The difference between -rpath

and -rpath-link is that directories specified by -rpath options are

included in the executable and used at runtime, whereas the -rpath-link

option is only effective at link time. Searching -rpath in this way is only

supported by native linkers and cross linkers which have been configured

with the --with-sysroot option.

3. On an ELF system, for native linkers, if the -rpath and -rpath-link options

were not used, search the contents of the environment variable

"LD_RUN_PATH".

4. On SunOS, if the -rpath option was not used, search any directories speci-

fied using -L options.

5. For a native linker, the search the contents of the environment variable

"LD_LIBRARY_PATH".

6. For a native ELF linker, the directories in "DT_RUNPATH" or "DT_RPATH" of a

shared library are searched for shared libraries needed by it. The

"DT_RPATH" entries are ignored if "DT_RUNPATH" entries exist.

7. The default directories, normally /lib and /usr/lib.

8. For a native linker on an ELF system, if the file /etc/ld.so.conf exists,

the list of directories found in that file.

So, set LD_LIBRARY_PATH to the "subfolder to the OpenFOAM folder".

Milos Stanic March 11, 2009 09:15

Re: Trouble with installing OpenFOAM on any Distro
 
Hi everyone!

I managed to do it relatively easy...it never actually crossed my mind that there could be a binary version of ParaView.

Ok, so here what I did:

1. Downloaded OpenFOAM 1.5 and installed it on my Linux Ubuntu 8.10 in the manner described in detail on the official OpenFOAM website.

2. Everything's fine until the point where I needed to compile ParaView, so I DIDN'T! Here's the link to the binary version which will download ParaView 3.2.2 as a .deb file, so you just need to double-click it and it will install the ParaView 3.2.2 on your computer:

http://yu.archive.ubuntu.com/ubuntu/...2.2-1_i386.deb

Hope this helps!

Cheers!

Ahmed March 11, 2009 17:57

Re: Trouble with installing OpenFOAM on any Distro
 
more important than putting the link, is your willingness to share your experience with others Good Luck

Jandre May 16, 2009 17:21

I have ubuntu 9.04 and i did like Ahmed

1- In your home directory create a Tmp folder

2- Download into this folder the following file ftp://ftp.trolltech.com/qt/source/qt...c-4.3.5.tar.gz

3- Once the download is finished, change to that Tmp directory and issue the following two commands

i- gunzip qt-x11-opensource-src-4.3.5.tar.gz

ii- tar xvf qt-x11-opensource-src-4.3.5.tar

now you have the folder qt-x11-opensource-src-4.3.5, so change to that folder and issue the following command

./configure -prefix /home/XXXXX/OpenFOAM/ThirdParty/QT-4.3.5

where XXXXX stands for your name, then accept the license by typing yes

After few minutes you will get the following:-

Qt is now configured for building. Just type "make" Once everything is built you must run "make install" Qt will be installed into /home/XXXXX/OpenFOAM/ThirdParty/Qt-4.3.5.




Them i add the following lines to the ~/OpenFOAM/OpenFOAM-1.5/etc/bashrc at the very end

# set QT related variables
QT=~/OpenFOAM/ThirdParty/Qt-4.3.5
export PATH=$QT/bin:$PATH
export LD_LIBRARY_PATH=$QT/lib:$LD_LIBRARY_PATH

like in http://www.cfd-online.com/cgi-bin/Op...8466#POST28466

after that i just had to do all the compiling like in the README file of openFOAM (7.1 and 7.2)

thanks for you help

oort June 15, 2009 17:46

Quote:

Originally Posted by Jandre (Post 216380)

Qt is now configured for building. Just type "make" Once everything is built you must run "make install" Qt will be installed into /home/XXXXX/OpenFOAM/ThirdParty/Qt-4.3.5.

it give me these errors:

Quote:

[sudo] password for carlos:
cd src/tools/moc/ && make -f Makefile
make[1]: Entering directory `/home/carlos/Tmp/qt-x11-opensource-src-4.3.5/src/tools/moc'
g++ -c -pipe -g -O2 -Wall -W -DQT_BOOTSTRAPPED -DQT_MOC -DQT_NO_CODECS -DQT_LITE_UNICODE -DQT_NO_LIBRARY -DQT_NO_STL -DQT_NO_COMPRESS -DQT_NO_DATASTREAM -DQT_NO_TEXTSTREAM -DQT_NO_TEXTCODEC -DQT_NO_UNICODETABLES -DQT_NO_THREAD -DQT_NO_REGEXP -DQT_NO_QOBJECT -DQT_NO_SYSTEMLOCALE -DQT_NO_GEOM_VARIANT -D_LARGEFILE64_SOURCE -D_LARGEFILE_SOURCE -I../../../mkspecs/linux-g++ -I. -I../../corelib/arch/generic -I../../../include -I. -I../../../include/QtCore -I. -I.uic/release-shared -o release-shared/moc.o moc.cpp
make[1]: g++: Command not found
make[1]: *** [release-shared/moc.o] Error 127
make[1]: Leaving directory `/home/carlos/Tmp/qt-x11-opensource-src-4.3.5/src/tools/moc'
make: *** [sub-moc-make_default-ordered] Error 2

Ahmed June 15, 2009 22:37

use synaptic to install g++
read the error mnessage g++ command not found

aliakbar82 November 16, 2009 02:39

Jandre I have ubuntu 9.04 but use OpenFOAM1.6. I want to know Is this instruction you said usefull for OpenFOAM1.6 as well as OpenFOAM1.5 and if yes after that paraview works properly?
Thanks.

aliakbar82 November 16, 2009 02:44

Jandre I have ubuntu 9.04 but use OpenFOAM1.6. I want to know Is this instruction you said usefull for OpenFOAM1.6 as well as OpenFOAM1.5 and if yes after that paraview works properly?
Thanks.


All times are GMT -4. The time now is 02:23.