CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > Software User Forums > OpenFOAM

OpenFoam wmake

Register Blogs Community New Posts Updated Threads Search

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   June 22, 2012, 11:44
Default OpenFoam wmake
  #1
New Member
 
Junpeng
Join Date: Jun 2012
Posts: 3
Rep Power: 14
rolandde is on a distinguished road
Hi guys,
Does anyone know how to use g++, instead of wmake, to compile the solver, like icoFoam? Cause I need to write my own make and the makefile.
Thanks.
rolandde is offline   Reply With Quote

Old   June 23, 2012, 16:08
Default
  #2
Retired Super Moderator
 
Bruno Santos
Join Date: Mar 2009
Location: Lisbon, Portugal
Posts: 10,981
Blog Entries: 45
Rep Power: 128
wyldckat is a name known to allwyldckat is a name known to allwyldckat is a name known to allwyldckat is a name known to allwyldckat is a name known to allwyldckat is a name known to all
Greetings Junpeng and welcome to the forum!

You don't want to use OpenFOAM's wmake? OK... do you just want the command for building icoFoam or every single OpenFOAM library dependency that icoFoam has on it? You can see the dependency list by running this command:
Code:
ldd `which icoFoam`
If it's just icoFoam:
  1. Go to the folder "applications/solvers/incompressible/icoFoam" and run:
    Code:
    wclean
    wmake
  2. See the commands that are shown on the terminal? Simply copy them and you should be able to use them directly in the command line... although you'll have to take care of the specific details, such as creating the helper folders wmake uses to build stuff.
If you need the whole thing... then try FreeFOAM: http://freefoam.sourceforge.net/ - it uses CMake and I think CMake will generate "Makefiles" for each library and application.


Nonetheless, if you need 2.1.x, you might have to stick to wmake if you want to make your life easier. If you can detail a bit more about what you want to specifically do, we might be able to provide more possibilities to solve the issue.

Best regards,
Bruno
__________________
wyldckat is offline   Reply With Quote

Old   June 25, 2012, 12:11
Default
  #3
New Member
 
Junpeng
Join Date: Jun 2012
Posts: 3
Rep Power: 14
rolandde is on a distinguished road
Quote:
Originally Posted by wyldckat View Post
Greetings Junpeng and welcome to the forum!

You don't want to use OpenFOAM's wmake? OK... do you just want the command for building icoFoam or every single OpenFOAM library dependency that icoFoam has on it? You can see the dependency list by running this command:
Code:
ldd `which icoFoam`
If it's just icoFoam:
  1. Go to the folder "applications/solvers/incompressible/icoFoam" and run:
    Code:
    wclean
    wmake
  2. See the commands that are shown on the terminal? Simply copy them and you should be able to use them directly in the command line... although you'll have to take care of the specific details, such as creating the helper folders wmake uses to build stuff.
If you need the whole thing... then try FreeFOAM: http://freefoam.sourceforge.net/ - it uses CMake and I think CMake will generate "Makefiles" for each library and application.


Nonetheless, if you need 2.1.x, you might have to stick to wmake if you want to make your life easier. If you can detail a bit more about what you want to specifically do, we might be able to provide more possibilities to solve the issue.

Best regards,
Bruno
Thanks I got the commands. Can you explain these parameters to me?

g++ -m64 -Dlinux64 -DWM_DP -Wall -Wextra -Wno-unused-parameter -Wold-style-cast -Wnon-virtual-dtor -O3 -DNoRepository -ftemplate-depth-100 -I/opt/openfoam211/src/finiteVolume/lnInclude -IlnInclude -I. -I/opt/openfoam211/src/OpenFOAM/lnInclude -I/opt/openfoam211/src/OSspecific/POSIX/lnInclude -fPIC -c $SOURCE -o Make/linux64GccDPOpt/cicoFoam.o

like -m64, -Wall, -Wextra ...
or where I can find some materials for these parameters?
rolandde is offline   Reply With Quote

Old   June 25, 2012, 14:31
Default
  #4
Senior Member
 
akidess's Avatar
 
Anton Kidess
Join Date: May 2009
Location: Germany
Posts: 1,377
Rep Power: 30
akidess will become famous soon enough
In the gcc documentation of course: http://gcc.gnu.org/onlinedocs/gcc-4....c_Invoking-GCC

Have fun!
__________________
*On twitter @akidTwit
*Spend as much time formulating your questions as you expect people to spend on their answer.
akidess is offline   Reply With Quote

Reply


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
[OpenFOAM.com] wmake error: file 'Make/linux64Gcc44DPOpt/objectFiles' could not be created l_r_mcglashan OpenFOAM Installation 17 June 14, 2016 12:56
OpenFOAM 1.6 ext - Compilation errors - Fedora 17(32bit) toolpost OpenFOAM Installation 15 September 21, 2012 10:38
New OpenFOAM Forum Structure jola OpenFOAM 2 October 19, 2011 07:55
wmake in openfoam mac 1.7.x atareen64 OpenFOAM Installation 10 July 12, 2011 12:02
OpenFOAM 1.5.x package - CentOS 5.3 x86_64 linnemann OpenFOAM Installation 7 July 30, 2009 04:14


All times are GMT -4. The time now is 08:50.