|
[Sponsors] |
[swak4Foam] swak4foam installation on OpenFOAM 7 |
![]() |
|
LinkBack | Thread Tools | Search this Thread | Display Modes |
![]() |
![]() |
#21 |
Senior Member
julien
Join Date: Dec 2018
Posts: 107
Rep Power: 7 ![]() |
Hello,
I don't succeed to install swak4foam with openfoam 8 on ubuntu 20.04. Openfoam is working fine. hg clone http://hg.code.sf.net/p/openfoam-extend/swak4Foam swak4Foam cd swak4Foam hg update develop ./AllwmakeAll I have follow the steps in this thread. The first ./AllmakeAll command was running and it seems that swak4Foam is installed but I try funkySetFields command -> command not found message error. So I try to run again the Allwmake command as I see on different discussion, and I have the Current OpenFOAM version is 8. This is a clean install ./Allwmake: ligne 32: foamVersionThisIsCompiledFor: Permission non accordée /home/julien/OpenFOAM/julien-8/swak4Foam/privateRequirements/bin existing. Prepending to PATH-variable (private version of Bison) Reading variables from 'swakConfiguration' Looking for Python 2 Looking for Python 3 Using our own Lua at /home/julien/OpenFOAM/julien-8/swak4Foam/privateRequirements Checking swak4Foam-version and generating file Swak version is 20xx.yy.0 not trusting file /home/julien/OpenFOAM/julien-8/swak4Foam/.hg/hgrc from untrusted user root, group root not trusting file /home/julien/OpenFOAM/julien-8/swak4Foam/.hg/hgrc from untrusted user root, group root hg info: b8e73355892c (develop) tip No 'bear' installed Bison: /home/julien/OpenFOAM/julien-8/swak4Foam/privateRequirements/bin/bison Flex: /usr/bin/flex Bison at /home/julien/OpenFOAM/julien-8/swak4Foam/privateRequirements/bin/bison is version 3.4 (Major 3 Minor 4) Flex is version 2.6.4 (Minor version: 4) ./Allwmake: ligne 69: swak4FoamParsers/foamVersion4swak.H.tmp: Permission non accordée No swak4FoamParsers/foamVersion4swak.H. Generated mv: impossible d'évaluer 'swak4FoamParsers/foamVersion4swak.H.tmp': Aucun fichier ou dossier de ce type ./Allwmake: ligne 88: swak4FoamParsers/foamVersion4swak.H: Aucun fichier ou dossier de ce type ./Allwmake: ligne 89: swak4FoamParsers/foamVersion4swak.H: Aucun fichier ou dossier de ce type Please include the output above when reporting a problem in the compilation. It helps diagnosing the problem mkdir: impossible de créer le répertoire «simpleFunctionObjects/lnInclude»: Permission non accordée wmakeLnInclude error: failed to create include directory simpleFunctionObjects/lnInclude wmake libso swak4FoamParsers mkdir: impossible de créer le répertoire «Make/linux64GccDPInt32Opt»: Permission non accordée /bin/sh: 1: cannot create Make/linux64GccDPInt32Opt/options: Directory nonexistent make: *** Aucune règle pour fabriquer la cible « Make/linux64GccDPInt32Opt/options ». Arrêt. /bin/sh: 1: cannot create Make/linux64GccDPInt32Opt/options: Directory nonexistent make: *** Aucune règle pour fabriquer la cible « Make/linux64GccDPInt32Opt/options », nécessaire pour « all ». Arrêt. wmake error: file 'Make/linux64GccDPInt32Opt/sourceFiles' could not be created in /home/julien/OpenFOAM/julien-8/swak4Foam/Libraries/swak4FoamParsers Parser library did not compile OK. No sense continuing as everything else depends on it Requirements for Library not satisfied. I see no sense in going on Check the README before you go on to ask. And search: Most likely your problem occurred to 5 other people before and has been solved on the MessageBoarderror message When I do the same command as an administrator, I have the message: Environment variable WM_PROJECT_VERSION unset This means that no OpenFOAM version is actived Please activate the OF for which you want to compile swak4Foam I have add in my .bashrc file: source /opt/openfoam8/etc/bashrc export WM_PROJECT_VERSION=of8 export PATH="/home/julien/OpenFOAM/julien-8/swak4Foam/privateRequirements/bin:$PATH" The PATH is recognize when I call it in the terminal. Other problem, since I try to install swak4Foam, paraFoam doesn't work any more! After the paraFoam command line: FATAL ERROR: The official reader module for OpenFOAM data does not exist on your system. This means that the version of ParaView you are using was not compiled with OpenFOAM, or distributed with a packaged version of OpenFOAM. For information on packaged versions of OpenFOAM/ParaView and compilation of OpenFOAM/ParaView, see https://openfoam.org/download Alternatively, you might be able to view your OpenFOAM data with the reader module provided with ParaView by running: paraFoam -builtin If I type paraFoam -builtin then Created temporary 'Cyl_geo_reelle_snappy_rho_const_acierdiam120lg110 _v2ms-frozenflow_avradT81degC-veineairof8.foam' /opt/openfoam8/bin/paraFoam: 66: paraview: not found Thank you for your help Julien PS: my swak4Foam installation directory: julien@julien-X99-DUAL-Z8:~/OpenFOAM/julien-8/swak4Foam$ my openfoam installation directory: julien@julien-X99-DUAL-Z8:/opt/openfoam8$ |
|
![]() |
![]() |
![]() |
![]() |
#22 | |
Assistant Moderator
Bernhard Gschaider
Join Date: Mar 2009
Posts: 4,225
Rep Power: 51 ![]() ![]() |
Quote:
"Permission non accordée" means "Permission denied", right? (it would be great if people set the language to English before generating the error message. "export LANGUAGE=en_US" would do that. It says "Thanks for taking the time to answer my question for free. Let me make this easier for you". I would say the same thing if the error messages were in German) Anyway. Seems like you don't have the permissions to write anything in the swak-directory. The line "not trusting file /home/julien/OpenFOAM/julien-8/swak4Foam/.hg/hgrc from untrusted user root, group root" tells me that you used the root user to clone the sources (and now the directory "belongs" to root) and now you try to compile as a regular user (who is not allowed to mess with roots things). Something like "sudo chown -R julieng:julieng ." should make you the owner and then you can compile
__________________
Note: I don't use "Friend"-feature on this forum out of principle. Ah. And by the way: I'm not on Facebook either. So don't be offended if I don't accept your invitation/friend request |
||
![]() |
![]() |
![]() |
![]() |
#23 |
Senior Member
julien
Join Date: Dec 2018
Posts: 107
Rep Power: 7 ![]() |
Thank you for your answer and excuse me for the non translated log, I didn't know the possibility of "export LANGUAGE=en_US"
funkySetFields command is working now! I have test a real case but I have errors. It seems that something is not well installed. "Unknown function type swakExpression" Attached files are my controldict and also the terminal error message. The case is working fine when I disable swak4Foam postproccessing functions in the controlDict. This controlDict file is the one that I used when I was working with bluecfdcore on windows 10. Julien |
|
![]() |
![]() |
![]() |
![]() |
#24 | |
Assistant Moderator
Bernhard Gschaider
Join Date: Mar 2009
Posts: 4,225
Rep Power: 51 ![]() ![]() |
Quote:
That function object is in the one library you've got commented out in the libs-entry in the controlDict
__________________
Note: I don't use "Friend"-feature on this forum out of principle. Ah. And by the way: I'm not on Facebook either. So don't be offended if I don't accept your invitation/friend request |
||
![]() |
![]() |
![]() |
![]() |
#25 |
Senior Member
julien
Join Date: Dec 2018
Posts: 107
Rep Power: 7 ![]() |
Hello,
I have share the wrong controlDict file with the line disabled... I have try to comment out the "libsimpleSwakFunctionObjects.so" line when I see that there is a problem with it. But the issue "Unknown function type swakExpression" happened with the "libsimpleSwakFunctionObjects.so" activated. With "libsimpleSwakFunctionObjects.so" line commented out it still don't works. libs ( "libOpenFOAM.so" "libgroovyBC.so" // "libsimpleSwakFunctionObjects.so" "libswakFunctionObjects.so" "libswakTopoSources.so" ); I have attached the terminal output generated when I run the command ./AllwmakeAll in swak4Foam directory Thank you again Best regards Julien |
|
![]() |
![]() |
![]() |
![]() |
#26 |
Senior Member
julien
Join Date: Dec 2018
Posts: 107
Rep Power: 7 ![]() |
Hello,
I see that I still have root permissions problem on my swak4Foam directory, not a padlock but I see in the log that something is wrong because of root permissions. So I solved definitly this with the command line sudo chown julien:julien -R ./swak4Foam I have also install "bear" because I see in the log file that it is missing. I run again the ./Allwmake command Please see my log file. It complains in the beginning: HTML Code:
ld not correctly identify the OpenFOAM version becauseenvironment variable WM_PROJECT_VERSION is 'of8'which is not of the expected form XX.YY.ZZ (or only XX)Because of this compilation of swak4Foam might failNo change to swak4FoamParsers/foamVersion4swak.H HTML Code:
make: *** [/opt/openfoam8/wmake/makefiles/general:169 : /home/julien/OpenFOAM/julien-8/platforms/linux64GccDPInt32Opt/lib/libsimpleFunctionObjects.so] Erreur 1 Julien |
|
![]() |
![]() |
![]() |
![]() |
#27 |
Senior Member
julien
Join Date: Dec 2018
Posts: 107
Rep Power: 7 ![]() |
Hello,
I have all clean, all delete and start again from the beginning. I have done this, following what is described for installation with Openfoam 8. hg clone http://hg.code.sf.net/p/openfoam-extend/swak4Foam swak4Foam cd swak4Foam hg update develop ./AllwmakeAll ./Allwmake > log.make 2>&1 My log file is attached I have in my baschrc file HTML Code:
source /opt/openfoam8/etc/bashrcexport WM_PROJECT_VERSION=of8export PATH="/home/julien/OpenFOAM/julien-8/swak4Foam/privateRequirements/bin:$PATH"alias of8='source /opt/openfoam8/etc/bashrc' "libsimpleSwakFunctionObjects.so" Best regards Julien |
|
![]() |
![]() |
![]() |
![]() |
#28 |
Senior Member
julien
Join Date: Dec 2018
Posts: 107
Rep Power: 7 ![]() |
Hello
I found the problem. The right syntax for the version is 8 not of8!!!!! |
|
![]() |
![]() |
![]() |
![]() |
#29 | |
New Member
Ignacio Z
Join Date: Mar 2022
Posts: 6
Rep Power: 4 ![]() |
Quote:
Code:
Reading variables from 'swakConfiguration' Looking for Python 2 Found Python 2.7 Configuring Python 2.7 Using python2.7 at /usr/bin/python2.7-config for python2 Looking for Python 3 Using our own Lua at /opt/openfoam7/swak4Foam/privateRequirements Checking swak4Foam-version and generating file Swak version is 2021.05.0 hg info: af74ec7e1714 Using /usr/bin/bear to build compilation database Bison: /opt/openfoam7/swak4Foam/privateRequirements/bin/bison Flex: /usr/bin/flex Bison at /opt/openfoam7/swak4Foam/privateRequirements/bin/bison is version 3.4 (Major 3 Minor 4) Flex is version 2.6.4 (Minor version: 4) OpenFOAM-version: Major 7 Minor 0 Patch -1 (-1 == x / 98) Fork: org No change to swak4FoamParsers/foamVersion4swak.H Please include the output above when reporting a problem in the compilation. It helps diagnosing the problem wmake libso swak4FoamParsers /opt/openfoam7/platforms/linux64GccDPInt32Opt/swak4Foam/Libraries/swak4FoamParsers/options:56: /opt/openfoam7/platforms/linux64GccDPInt32Opt/swak4Foam/Libraries/swak4FoamParsers/../../../rules/versionOptions: No such file or directory /opt/openfoam7/platforms/linux64GccDPInt32Opt/swak4Foam/Libraries/swak4FoamParsers/options:66: /opt/openfoam7/platforms/linux64GccDPInt32Opt/swak4Foam/Libraries/swak4FoamParsers/../mybison: No such file or directory /opt/openfoam7/platforms/linux64GccDPInt32Opt/swak4Foam/Libraries/swak4FoamParsers/options:67: /opt/openfoam7/platforms/linux64GccDPInt32Opt/swak4Foam/Libraries/swak4FoamParsers/../myflex: No such file or directory make: *** No rule to make target '/opt/openfoam7/platforms/linux64GccDPInt32Opt/swak4Foam/Libraries/swak4FoamParsers/../myflex'. Stop. /opt/openfoam7/platforms/linux64GccDPInt32Opt/swak4Foam/Libraries/swak4FoamParsers/options:56: /opt/openfoam7/platforms/linux64GccDPInt32Opt/swak4Foam/Libraries/swak4FoamParsers/../../../rules/versionOptions: No such file or directory /opt/openfoam7/platforms/linux64GccDPInt32Opt/swak4Foam/Libraries/swak4FoamParsers/options:66: /opt/openfoam7/platforms/linux64GccDPInt32Opt/swak4Foam/Libraries/swak4FoamParsers/../mybison: No such file or directory /opt/openfoam7/platforms/linux64GccDPInt32Opt/swak4Foam/Libraries/swak4FoamParsers/options:67: /opt/openfoam7/platforms/linux64GccDPInt32Opt/swak4Foam/Libraries/swak4FoamParsers/../myflex: No such file or directory make: *** No rule to make target '/opt/openfoam7/platforms/linux64GccDPInt32Opt/swak4Foam/Libraries/swak4FoamParsers/../myflex'. Stop. wmake error: file '/opt/openfoam7/platforms/linux64GccDPInt32Opt/swak4Foam/Libraries/swak4FoamParsers/sourceFiles' could not be created in /opt/openfoam7/swak4Foam/Libraries/swak4FoamParsers Parser library did not compile OK. No sense continuing as everything else depends on it Requirements for Library not satisfied. I see no sense in going on Thank you in advance. |
||
![]() |
![]() |
![]() |
![]() |
#30 | |
Assistant Moderator
Bernhard Gschaider
Join Date: Mar 2009
Posts: 4,225
Rep Power: 51 ![]() ![]() |
Quote:
OK. That is a weird one. Seems that the problem is that you put the sources into $WM_PROJECT_DIR (the installation directory of OF. In your case /opt/openfoam7). In that case wmake works differently (compiles to the platform-directory etc) and some of the stuff swak4foam does during compiling don't work. Put the swak-directory somewhere else (outside of $WM_PROJECT_DIR) and compilation should work
__________________
Note: I don't use "Friend"-feature on this forum out of principle. Ah. And by the way: I'm not on Facebook either. So don't be offended if I don't accept your invitation/friend request |
||
![]() |
![]() |
![]() |
![]() |
#31 |
New Member
Ignacio Z
Join Date: Mar 2022
Posts: 6
Rep Power: 4 ![]() |
Thanks for the quick reply!
I'll have to check if it is possible since I am trying to install it in a shared server. In that case what would the best option be? If it is not possible is there any other workaround? Regards, Nacho |
|
![]() |
![]() |
![]() |
![]() |
#32 | |
Assistant Moderator
Bernhard Gschaider
Join Date: Mar 2009
Posts: 4,225
Rep Power: 51 ![]() ![]() |
Quote:
For most users that is the best option as they should not have write access to $FOAM_APPBIN/$FOAM_LIBBIN There is a script maintainanceScripts/copySwakFilesToSite.sh that copies all the binary files to $FOAM_SITE_LIBBIN/$FOAM_SITE_APPBIN which is were binaries that should be accessible to everyone but are not part of the OF-distro should go This should be sufficient for people who don't do C++-programming based on swak (almost nobody does) So: - compile as a regular user - Check if it works for that user - run the script as a user with write access to the SITE-directories - check if it works for everybody (it is possible that the SITE-dirs are only added to the path by OF if they exist. So it is possible that you've got to start a new terminal to "see" the binaries as a regular user)
__________________
Note: I don't use "Friend"-feature on this forum out of principle. Ah. And by the way: I'm not on Facebook either. So don't be offended if I don't accept your invitation/friend request |
||
![]() |
![]() |
![]() |
![]() |
#33 |
New Member
Ignacio Z
Join Date: Mar 2022
Posts: 6
Rep Power: 4 ![]() |
It's finally working. I had to install it in what would be the equivalent of my /run directory. It is working for me, wouldn't know if it is working for other users. Thank you for all the help Bernhard.
|
|
![]() |
![]() |
![]() |
![]() |
#34 |
New Member
Liangyuan Wei
Join Date: Jun 2022
Location: Netherlands
Posts: 2
Rep Power: 0 ![]() |
sudo chown -R julieng:julieng .
This command works in my case. I successfully built swak4Foam on Ubuntu 22.04, OpenFOAM 9, under /home/foam/swak4foam Thank you all. Detailed instructions on how to install swak4Foam followed:https://openfoamwiki.net/index.php/I...tion/swak4Foam |
|
![]() |
![]() |
![]() |
![]() |
#35 |
New Member
Erik T
Join Date: Jun 2022
Posts: 8
Rep Power: 4 ![]() |
Hi,
I've been trying for some time, but cannot get swak4Foam to work with my installation of OF7. Steps taken: Code:
Steps taken: 1) make applications folder in my OF directory (/home/rmg/OpenFOAM/rmg-7/run/applications) and cd into it. 2) run hg clone http://hg.code.sf.net/p/openfoam-extend/swak4Foam swak4Foam 3) cd swak4Foam 4) hg update feature/port/of7 5) launch OF openfoam7-linux 6) ./AllwmakeAll > makelog Some of the log: Code:
md5sum found at /usr/bin Could not find an 'unzip' program. Tried: unzip. Make sure one of them is installed and available in your PATH. configure failed. If there were problems during compilation install the readline-devel package (name may be different on platforms) Lua successfully compiled Add /home/openfoam/privateRequirements/bin to PATH-variable. The ./Allwmake-script will use this directory automatically Using automatic swakConfiguration because none is there Current OpenFOAM version is 7. This is a clean install /home/openfoam/privateRequirements/bin existing. Prepending to PATH-variable (private version of Bison) Reading variables from 'swakConfiguration' Using our own Lua at /home/openfoam/privateRequirements Checking swak4Foam-version and generating file Swak version is 0.4.3 Could not get version of the sources Bison: /home/openfoam/privateRequirements/bin/bison Flex: /usr/bin/flex Bison at /home/openfoam/privateRequirements/bin/bison is version 3.4 (Major 3 Minor 4) Flex is version 2.6.4 (Minor version: 4) No swak4FoamParsers/foamVersion4swak.H. Generated Please include the output above when reporting a problem in the compilation. It helps diagnosing the problem The obvious concern to me is the failure to unzip. It continues to make for some time but I am not able to run groovyBC, which is what I really want. Any ideas how I might fix this? Thank you. Attached is the whole log of the make operation. |
|
![]() |
![]() |
![]() |
![]() |
#36 |
New Member
Erik T
Join Date: Jun 2022
Posts: 8
Rep Power: 4 ![]() |
Struggled with this for 2 days, then get it working 2 hrs after posting. FWIW, I *think* that using
>./maintainanceScripts/compileRequirements.sh then >./Allwmake instead of >./AllwmakeAll made the difference |
|
![]() |
![]() |
![]() |
![]() |
#37 |
New Member
Marcus Voigt
Join Date: Sep 2022
Posts: 5
Rep Power: 4 ![]() |
Hello everybody I am struggeling right now as to install swak4foam for OF10
in WSL 2. The Linux version is: Ubuntu 22.04.3 LTS I did the following steps: Code:
mkdir -p $FOAM_RUN cd "$HOME/OpenFOAM/$USER-$WM_PROJECT_VERSION" hg clone http://hg.code.sf.net/p/openfoam-extend/swak4Foam swak4Foam cd swak4Foam/ ./maintainanceScripts/compileRequirements.sh <-- here it downloads bison 3.4 Code:
export PATH=$PATH:/home/rodekamp/OpenFOAM/rodekamp-10/swak4Foam/privateRequirements/bin Code:
./Allwmake Code:
Current OpenFOAM version is 10. Previously compiled for OpenFOAM (10) /home/rodekamp/OpenFOAM/rodekamp-10/swak4Foam/privateRequirements/bin existing. Prepending to PATH-variable (private version of Bison) Reading variables from 'swakConfiguration' Looking for Python 2 Looking for Python 3 Using our own Lua at /home/rodekamp/OpenFOAM/rodekamp-10/swak4Foam/privateRequirements Checking swak4Foam-version and generating file Swak version is 2021.05.0 hg info: af74ec7e1714 Using /usr/bin/bear to build compilation database Bison: /home/rodekamp/OpenFOAM/rodekamp-10/swak4Foam/privateRequirements/bin/bison Flex: /usr/bin/flex Bison at /home/rodekamp/OpenFOAM/rodekamp-10/swak4Foam/privateRequirements/bin/bison is version 3.4 (Major 3 Minor 4) Flex is version 2.6.4 (Minor version: 4) OpenFOAM-version: Major 10 Minor 0 Patch -1 (-1 == x / 98) Fork: org No change to swak4FoamParsers/foamVersion4swak.H Please include the output above when reporting a problem in the compilation. It helps diagnosing the problem Unrecognized parameter: "--cdb=/home/rodekamp/OpenFOAM/rodekamp-10/swak4Foam/compile_commands.json" Usage: bear [--output <arg>] [--verbose] -- ... Parser library did not compile OK. No sense continuing as everything else depends on it Requirements for Library not satisfied. I see no sense in going on In the upcoming day I will try to install it on my Ubuntu-Laptop and see if I have more luck. Thank you guys in advance |
|
![]() |
![]() |
![]() |
Tags |
swak4foam error |
|
|
![]() |
||||
Thread | Thread Starter | Forum | Replies | Last Post |
[swak4Foam] Swak4FOAM installation for OpenFOAM v1806 | exx110 | OpenFOAM Community Contributions | 1 | July 5, 2021 20:07 |
[swak4Foam] swak4foam >>>> INSTALLATION PROBLEM | steven123 | OpenFOAM Community Contributions | 35 | January 11, 2021 16:53 |
OpenFOAM Training Jan-Jul 2017, Virtual, London, Houston, Berlin | CFDFoundation | OpenFOAM Announcements from Other Sources | 0 | January 4, 2017 06:15 |
[Discussion] Restructuring the Installation page at openfoamwiki.net | wyldckat | OpenFOAM Installation | 16 | November 2, 2013 11:43 |
New OpenFOAM Forum Structure | jola | OpenFOAM | 2 | October 19, 2011 06:55 |