CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > OpenFOAM Installation on Windows, Mac and other Unsupported Platforms

OF 2.1.0 under Windows XP or Windows 7

Register Blogs Members List Search Today's Posts Mark Forums Read

Reply
 
LinkBack Thread Tools Display Modes
Old   April 8, 2012, 16:19
Default OF 2.1.0 under Windows XP or Windows 7
  #1
New Member
 
Claudio
Join Date: May 2010
Location: Boston, MA
Posts: 28
Rep Power: 7
Claudio is on a distinguished road
Has anybody successfully compiled OpenFOAM 2.1.0 under either Windows XP or Windows 7?
Or does anybody know where I can find info/instructions to do so?

Thanks
Claudio is offline   Reply With Quote

Old   April 9, 2012, 05:17
Default
  #2
Super Moderator
 
Bruno Santos
Join Date: Mar 2009
Location: Lisbon, Portugal
Posts: 8,258
Blog Entries: 34
Rep Power: 84
wyldckat is just really nicewyldckat is just really nicewyldckat is just really nicewyldckat is just really nice
Greetings Claudio,

Currently there are a few efforts in making this possible, namely building OpenFOAM directly on Windows, but AFAIK, none of them are complete and/or released to the public.

The only fully public method that I'm aware of is by using Cygwin to handle the file system for then cross-compiling OpenFOAM on Cygwin for Windows. Here's where you can find all of the public info I'm familiar with (and which I wrote myself ): OpenFOAM on Windows OS

As for the other efforts:
If you have any more questions, feel free to ask!

Best regards,
Bruno
wyldckat is offline   Reply With Quote

Old   April 9, 2012, 13:42
Default
  #3
Senior Member
 
Daniele Vicario
Join Date: Mar 2009
Location: Novara, Italy
Posts: 142
Rep Power: 8
danvica is on a distinguished road
I'm not an experienced user, just a technical manager/engineer involved in taps/valves component... you should definitely try BlueCFD.

From my own point of view the porting is perfect and the support fast and precise.
__________________
Daniele Vicario

blueCFD2.1 - Windows 7
danvica is offline   Reply With Quote

Old   April 10, 2012, 08:37
Default
  #4
Ect
New Member
 
Join Date: Mar 2012
Posts: 3
Rep Power: 5
Ect is on a distinguished road
Hello,

I've cross-compiled the 2.1.0 version for win64 following symscape's instructions and somewhat merged it with Joseph Nishit's script files to make it behave as a "portable" openFoam. So far simple/pimple/pisoFoam are working ok for me on Win64 2008 and Vista, with mpich up to 12 cores on a shared memory computer.

If anyone is willing to test it more touroughly I would need some suggestions on how to share the 110 Mb archive (openFoam, mpich, paraview, gmsh & engrid).

Regards,
Ect
Ect is offline   Reply With Quote

Old   April 15, 2012, 15:41
Default
  #5
Senior Member
 
akidess's Avatar
 
Anton Kidess
Join Date: May 2009
Location: Delft, Netherlands
Posts: 919
Rep Power: 17
akidess will become famous soon enough
Ect, I'd give it a shot. You could upload the archive here: http://ge.tt/
__________________
*On twitter @akidTwit
*Spend as much time formulating your questions as you expect people to spend on their answer.
*Help define the OpenFOAM stackexchange Q&A site: http://area51.stackexchange.com/prop...oam-technology
akidess is offline   Reply With Quote

Old   April 20, 2012, 10:52
Default
  #6
New Member
 
Claudio
Join Date: May 2010
Location: Boston, MA
Posts: 28
Rep Power: 7
Claudio is on a distinguished road
Thanks for all the replies.

Daniele, I will look more into BlueCFD, however since I would like to have it on many different machine, it might not be feasible to have a commercial solution. It's not quite clear if the fee is just to access the executable and then you can install them many times or not.

Ect,
I would be interested too in you package. Would it be possible for you to use a free storage service, like Dropbox?

Thanks
Claudio is offline   Reply With Quote

Old   April 20, 2012, 11:03
Default
  #7
Super Moderator
 
Bruno Santos
Join Date: Mar 2009
Location: Lisbon, Portugal
Posts: 8,258
Blog Entries: 34
Rep Power: 84
wyldckat is just really nicewyldckat is just really nicewyldckat is just really nicewyldckat is just really nice
Greetings to all!

Claudio:
Quote:
Originally Posted by Claudio View Post
Daniele, I will look more into BlueCFD, however since I would like to have it on many different machine, it might not be feasible to have a commercial solution. It's not quite clear if the fee is just to access the executable and then you can install them many times or not.
I thought it was clear enough, since there is no such limitation specified in the "Statement of Service"; but a FAQ was also created for what isn't so clear; quoting from the FAQ, section "What is blueCFD's license?":
Quote:
So, to sum up: the blueCFD software, once purchased, can be used in any number of computers and even given to friends, family, neighbours and even that pen pal on the other side of the world. But those who haven't payed for the blueCFD service, will not be entitled to our support. But we will welcome any and all bug reports, so we can provide better builds and service of our product.
If you have any questions, feel free to ask!

Best regards,
Bruno
wyldckat is offline   Reply With Quote

Old   April 21, 2012, 17:38
Default
  #8
Ect
New Member
 
Join Date: Mar 2012
Posts: 3
Rep Power: 5
Ect is on a distinguished road
Hi all,

Here it is: http://ge.tt/2SfcweG/v/0?c

Use scotch as the decomposition method
Start smpd.bat, it runs smpd in debug mode on the port 41000 if I remember correctly, this way no mpich installation is required, it also runs without interferring with any existing mpi installation.
start dos_mode.bat
cd to your case directory
decomposepar
gompi simpleFoam

please give some feedback

regards,
Ect
Ect is offline   Reply With Quote

Old   April 22, 2012, 02:52
Default
  #9
Senior Member
 
Alberto Passalacqua
Join Date: Mar 2009
Location: Ames, Iowa, United States
Posts: 1,894
Rep Power: 26
alberto will become famous soon enoughalberto will become famous soon enough
Something to have OF working on Windows is available here too: http://www.symscape.com/openfoam-2-1...windows-64-mpi
__________________
Alberto Passalacqua

GeekoCFD - A free distribution based on openSUSE 64 bit with CFD tools, including OpenFOAM. Available as live DVD/USB, hard drive image and virtual image.
OpenQBMM - An open-source implementation of quadrature-based moment methods
alberto is offline   Reply With Quote

Old   April 23, 2012, 08:37
Default
  #10
New Member
 
Claudio
Join Date: May 2010
Location: Boston, MA
Posts: 28
Rep Power: 7
Claudio is on a distinguished road
Thanks Ect,

i have downloaded the package. I am working on something else now, so I have to put this on the back burner for now. Will update you once I get it working.

Bruno,

thanks for the clarification.

Alberto, ciao,

I did find symscape before. Again once I'll have time again will go back to this problem, but I appreciate everybody's input.
Claudio is offline   Reply With Quote

Old   May 2, 2012, 16:43
Default
  #11
New Member
 
Join Date: May 2012
Posts: 1
Rep Power: 0
MIGHTYBIRD is on a distinguished road
I haven't been able to get this working.

I'm getting the following in the command prompt:


Quote:
--> FOAM FATAL IO ERROR:
cannot find file

file: C:/Users/Brett/Desktop/OpenFOAM-2.1/system/controlDict at line 0.

From function regIOobject::readStream()
in file db/regIOobject/regIOobjectRead.C at line 73.

FOAM exiting

Does anyone have any ideas? I don't have that file or directory. It wasn't in the 7 zip file posted by ECT.

thanks!
MIGHTYBIRD is offline   Reply With Quote

Old   May 2, 2012, 16:52
Default
  #12
Super Moderator
 
Bruno Santos
Join Date: Mar 2009
Location: Lisbon, Portugal
Posts: 8,258
Blog Entries: 34
Rep Power: 84
wyldckat is just really nicewyldckat is just really nicewyldckat is just really nicewyldckat is just really nice
Hi MIGHTYBIRD and welcome to the forum!

Apparently you're trying to run a command in the wrong folder! Whenever a command in OpenFOAM gives that error message, it's because you're running the command in a folder that isn't an OpenFOAM case.

In other words: read the OpenFOAM User Guide

Best regards,
Bruno
wyldckat is offline   Reply With Quote

Old   June 1, 2012, 05:15
Default
  #13
New Member
 
Le Phi Long
Join Date: Feb 2011
Posts: 18
Rep Power: 6
Mr.Cloud is on a distinguished road
Quote:
Originally Posted by Ect View Post
Hello,

I've cross-compiled the 2.1.0 version for win64 following symscape's instructions and somewhat merged it with Joseph Nishit's script files to make it behave as a "portable" openFoam. So far simple/pimple/pisoFoam are working ok for me on Win64 2008 and Vista, with mpich up to 12 cores on a shared memory computer.

If anyone is willing to test it more touroughly I would need some suggestions on how to share the 110 Mb archive (openFoam, mpich, paraview, gmsh & engrid).

Regards,
Ect
Hi Etc... I'm trying to combile an vesion of OF (1.7.x) for my windows, but it apear a lot of error that I cant figure out... Please help me...! Here is my email: tieuliphilong@gmail.com
Best regards.
Mr.Cloud is offline   Reply With Quote

Old   August 29, 2012, 05:46
Default
  #14
New Member
 
Le Phi Long
Join Date: Feb 2011
Posts: 18
Rep Power: 6
Mr.Cloud is on a distinguished road
Hi Ect, can you help me to build an version 2.1.0 for window? I need build and OF source to make my thermal foam (simpleThermal,...). I followed this tutorial but got alot of error
Quote:
make: Nothing to be done for `all'.
no ThirdParty sources found - skipping
+ set -e
+ wmakePrintBuild -check
no git description found
+ /bin/rm -f OpenFOAM/Make/*/global.?
+ wmakeLnInclude OpenFOAM
wmakeLnInclude: linking include files to OpenFOAM/lnInclude
+ wmakeLnInclude OSspecific/MSwindows
wmakeLnInclude: linking include files to OSspecific/MSwindows/lnInclude
+ OSspecific/MSwindows/Allwmake
wmakeLnInclude: linking include files to ./lnInclude
Making dependency list for source file MSwindows.C
Making dependency list for source file printStack.C
Making dependency list for source file regExp.C
Making dependency list for source file signals/sigFpe.C
Making dependency list for source file signals/sigSegv.C
Making dependency list for source file signals/sigInt.C
Making dependency list for source file signals/sigQuit.C
Making dependency list for source file signals/sigStopAtWriteNow.C
Making dependency list for source file signals/sigWriteNow.C
Making dependency list for source file timer.C
Making dependency list for source file fileMonitor.C
Making dependency list for source file fileStat.C
Making dependency list for source file cpuTime/cpuTime.C
Making dependency list for source file clockTime/clockTime.C
SOURCE=MSwindows.C ; x86_64-w64-mingw32-g++ -m64 -Dlinux64 -DWM_DP -DMSWIN -DLITTLE_ENDIAN -Wall -Wextra -Wno-unused-parameter -Wnon-virtual-dtor -O3 -DNDEBUG -DNoRepository -ftemplate-depth-40 -IlnInclude -I. -I/home/longlp/OpenFOAM/OpenFOAM-2.1.x/src/OpenFOAM/lnInclude -I/home/longlp/OpenFOAM/OpenFOAM-2.1.x/src/OSspecific/MSwindows/lnInclude -c $SOURCE -o Make/linux64GccDPOpt/MSwindows.o
SOURCE=printStack.C ; x86_64-w64-mingw32-g++ -m64 -Dlinux64 -DWM_DP -DMSWIN -DLITTLE_ENDIAN -Wall -Wextra -Wno-unused-parameter -Wnon-virtual-dtor -O3 -DNDEBUG -DNoRepository -ftemplate-depth-40 -IlnInclude -I. -I/home/longlp/OpenFOAM/OpenFOAM-2.1.x/src/OpenFOAM/lnInclude -I/home/longlp/OpenFOAM/OpenFOAM-2.1.x/src/OSspecific/MSwindows/lnInclude -c $SOURCE -o Make/linux64GccDPOpt/printStack.o
SOURCE=regExp.C ; x86_64-w64-mingw32-g++ -m64 -Dlinux64 -DWM_DP -DMSWIN -DLITTLE_ENDIAN -Wall -Wextra -Wno-unused-parameter -Wnon-virtual-dtor -O3 -DNDEBUG -DNoRepository -ftemplate-depth-40 -IlnInclude -I. -I/home/longlp/OpenFOAM/OpenFOAM-2.1.x/src/OpenFOAM/lnInclude -I/home/longlp/OpenFOAM/OpenFOAM-2.1.x/src/OSspecific/MSwindows/lnInclude -c $SOURCE -o Make/linux64GccDPOpt/regExp.o
SOURCE=signals/sigFpe.C ; x86_64-w64-mingw32-g++ -m64 -Dlinux64 -DWM_DP -DMSWIN -DLITTLE_ENDIAN -Wall -Wextra -Wno-unused-parameter -Wnon-virtual-dtor -O3 -DNDEBUG -DNoRepository -ftemplate-depth-40 -IlnInclude -I. -I/home/longlp/OpenFOAM/OpenFOAM-2.1.x/src/OpenFOAM/lnInclude -I/home/longlp/OpenFOAM/OpenFOAM-2.1.x/src/OSspecific/MSwindows/lnInclude -c $SOURCE -o Make/linux64GccDPOpt/sigFpe.o
signals/sigFpe.C: In function ‘void clearFpe()’:
signals/sigFpe.C:45:15: error: ‘_clearfp’ was not declared in this scope
signals/sigFpe.C:46:35: error: ‘_controlfp’ was not declared in this scope
signals/sigFpe.C: In member function ‘void Foam::sigFpe::set(bool)’:
signals/sigFpe.C:136:33: error: ‘_controlfp’ was not declared in this scope
signals/sigFpe.C:138:22: error: ‘_EM_ZERODIVIDE’ was not declared in this scope
signals/sigFpe.C:138:39: error: ‘_EM_INVALID’ was not declared in this scope
signals/sigFpe.C:138:53: error: ‘_EM_OVERFLOW’ was not declared in this scope
signals/sigFpe.C:139:27: error: ‘_MCW_EM’ was not declared in this scope
make: *** [Make/linux64GccDPOpt/sigFpe.o] Error 1
This is the begin...
I user the mingw-w64, with this version, i was success in build a OF1.7.x version.
Mr.Cloud is offline   Reply With Quote

Old   August 31, 2012, 02:03
Default
  #15
Ect
New Member
 
Join Date: Mar 2012
Posts: 3
Rep Power: 5
Ect is on a distinguished road
I've stumbled upon the same issue, if i trust my notes you have to rename

Mingw-w64/lib/gcc/x86_64-w64-mingw32/4.5.4/include/float.h

to something like _float.h to prevent its usage

then you have to add

-I path-to/Mingw-w64/x86_64-w64-mingw32/x86_64-w64-mingw32/include

into wmake/rules/linux64mingw-w64/c++
Ect is offline   Reply With Quote

Old   September 3, 2012, 23:00
Default
  #16
New Member
 
Le Phi Long
Join Date: Feb 2011
Posts: 18
Rep Power: 6
Mr.Cloud is on a distinguished road
Thanks Ect.
First, I Mingw-w64 release to "mingw-w64-bin_x86_64-linux_20120823" and these error no existed any more. I create a copy of float.h then name it _float.h. When I add
Quote:
-I path-to/Mingw-w64/x86_64-w64-mingw32/x86_64-w64-mingw32/include
to file c++ it appear a lot of error, then i removed it.
But when i think it's ok, it return to me some strange error like that:
Quote:
clock.o:clock.C: (.text+0x99): undefined reference to `construction vtable for std:stream-in-std::basic_ostringstream<char, std::char_traits<char>, std::allocator<char> >'
clock.o:clock.C: (.text+0xa0): undefined reference to `construction vtable for std:stream-in-std::basic_ostringstream<char, std::char_traits<char>, std::allocator<char> >'
clock.o:clock.C: (.text+0x4e1): undefined reference to `construction vtable for std:stream-in-std::basic_ostringstream<char, std::char_traits<char>, std::allocator<char> >'
clock.o:clock.C: (.text+0x736): undefined reference to `construction vtable for std:stream-in-std::basic_ostringstream<char, std::char_traits<char>, std::allocator<char> >'
clock.o:clock.C: (.text+0x73d): undefined reference to `construction vtable for std:stream-in-std::basic_ostringstream<char, std::char_traits<char>, std::allocator<char> >'
clock.o:clock.C: (.text+0x7b5): more undefined references to `construction vtable for std:stream-in-std::basic_ostringstream<char, std::char_traits<char>, std::allocator<char> >' follow
/home/longlp/mingw-w64/bin/../lib/gcc/x86_64-w64-mingw32/4.8.0/../../../../x86_64-w64-mingw32/bin/ld: clock.o: bad reloc address 0x0 in section `.data'
collect2: error: ld returned 1 exit status
And there are a lot of error appear after that.
Here is my full buildlog: https://docs.google.com/open?id=0BxL...GRMMUJwWnJrQlE
please dowload and open on notepad++, these errors appear from line 3161
Mr.Cloud is offline   Reply With Quote

Old   September 4, 2012, 14:40
Default
  #17
Super Moderator
 
Bruno Santos
Join Date: Mar 2009
Location: Lisbon, Portugal
Posts: 8,258
Blog Entries: 34
Rep Power: 84
wyldckat is just really nicewyldckat is just really nicewyldckat is just really nicewyldckat is just really nice
Greetings to all!

@Mr.Cloud: Apparently you're using Gcc 4.8.0, which is the latest Gcc version under development, which is what the mingw-w64 team usually does: they always test with the (near-)bleeding edge versions of Gcc to make sure nothing gets broken with the constant evolution of Gcc!

Try using Gcc 4.5 from here: http://sourceforge.net/projects/ming..._4.5_20111101/

Good luck!
Bruno
wyldckat is offline   Reply With Quote

Old   September 5, 2012, 00:24
Default
  #18
New Member
 
Le Phi Long
Join Date: Feb 2011
Posts: 18
Rep Power: 6
Mr.Cloud is on a distinguished road
Hi Bruno. With that gcc, i got 2 error
First is
Quote:
error while loading shared libraries: libmpfr.so.1
Then I create a link, and it fixed,
Second is the typical error
Quote:
signals/sigFpe.C:45:15: error: '_clearfp' was not declared in this scope
I try to fix it but, i found no file float.h in
Quote:
<mingw-w64>/lib/gcc/x86_64-w64-mingw32/<gcc-version>/include/float.h
then i copy the float.h in
Quote:
<mingw-w64>/x86_64-w64-mingw32/include/float.h
then add #include_next <float.h> to the end of
Quote:
<mingw-w64>/x86_64-w64-mingw32/include/float.h
but I still got that error, the same with error when i use mingw-x64 (gcc 4.5.4) version at the first (with that version i was success when build OF 1.7)
Mr.Cloud is offline   Reply With Quote

Old   September 5, 2012, 00:48
Default
  #19
New Member
 
Le Phi Long
Join Date: Feb 2011
Posts: 18
Rep Power: 6
Mr.Cloud is on a distinguished road
Quote:
Originally Posted by Ect View Post
I've stumbled upon the same issue, if i trust my notes you have to rename

Mingw-w64/lib/gcc/x86_64-w64-mingw32/4.5.4/include/float.h

to something like _float.h to prevent its usage

then you have to add

-I path-to/Mingw-w64/x86_64-w64-mingw32/x86_64-w64-mingw32/include


into wmake/rules/linux64mingw-w64/c++
I dont know the step that i have paint it, here is my c++:
Quote:
.SUFFIXES: .C .cxx .cc .cpp

c++WARN = -Wall -Wextra -Wno-unused-parameter -Wnon-virtual-dtor

CC = x86_64-w64-mingw32-g++ -m64

include $(RULES)/c++$(WM_COMPILE_OPTION)

ptFLAGS = -DNoRepository -ftemplate-depth-40

c++FLAGS = $(GFLAGS) $(c++WARN) $(c++OPT) $(c++DBUG) $(ptFLAGS) $(LIB_HEADER_DIRS)

Ctoo = $(WM_SCHEDULER) $(CC) $(c++FLAGS) -c $$SOURCE -o $@
cxxtoo = $(Ctoo)
cctoo = $(Ctoo)
cpptoo = $(Ctoo)

LINK_LIBS = $(c++DBUG)

# Tried using -Wl,-no-undefined,--enable-runtime-pseudo-reloc
# but didnt forgive undefined symbols during linking
LINKLIBSO = $(CC) $(c++FLAGS) -Wl,--output-def,$(LIB).def,--out-implib,$(LIB).a,--enable-auto-import,--enable-auto-image-base,--strip-all -shared
LINKEXE = $(CC) $(c++FLAGS) -Wl,--enable-auto-import,--enable-auto-image-base,--force-exe-suffix,--strip-all
and here is my path to mingw-x64
Quote:
/home/longlp/mingw-w64/x86_64-w64-mingw32/include
Can you show me how to add it, because when i add
Quote:
-I ~/mingw-w64/x86_64-w64-mingw32/include
to the end, it return error when i build.
Mr.Cloud is offline   Reply With Quote

Old   September 10, 2012, 10:14
Default
  #20
New Member
 
Mark Pitman
Join Date: Mar 2009
Location: Perth, Western Australia, Australia
Posts: 7
Rep Power: 8
pitmanm is on a distinguished road
Hi Claudio,
I have a complete set of OpenFOAM-2.1.1 cross-compiled binaries for 64-bit Windows (based on Symscape's patches) available for free here: www.ods-engineering.com . They have been compiled to work with MSMPI for full multi-processing.

Just follow the instructions for Third Party (Windows) installation at the bottom of the page downloads page here. Please let me know through the website if you find any issues or bugs.

I compiled the binaries to work primarily with my Blender-based GUI for OpenFOAM (ODS Studio) but they should work for any other purpose too.
pitmanm is offline   Reply With Quote

Reply

Thread Tools
Display Modes

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 On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
queries of star-CD on windows machines Arnab CD-adapco 3 April 6, 2011 10:13
CFX11 + Fortran compiler ? Mohan CFX 20 March 30, 2011 18:56
Dual Boot Windows and Linux and Go Open Source andyj Main CFD Forum 2 October 21, 2010 16:49
Cross-compiling OpenFOAM 1.7.0 on Linux for Windows 32 and 64bits with Mingw-w64 wyldckat OpenFOAM Announcements from Other Sources 3 September 8, 2010 06:25
Cross-compiling OpenFOAM 1.6 on Linux for Windows 32 and 64bits with Mingw-w64 wyldckat OpenFOAM Announcements from Other Sources 7 January 19, 2010 16:39


All times are GMT -4. The time now is 10:03.