CFD Online Discussion Forums

CFD Online Discussion Forums (https://www.cfd-online.com/Forums/)
-   OpenFOAM Community Contributions (https://www.cfd-online.com/Forums/openfoam-community-contributions/)
-   -   [swak4Foam] Problem in Installing swak4Foam (https://www.cfd-online.com/Forums/openfoam-community-contributions/157974-problem-installing-swak4foam.html)

AmirBaqa1987 August 12, 2015 08:29

Problem in Installing swak4Foam
 
Dear friends,

I've tried to install swak4Foam on OpenFOAM 2.3, but I faced the following message:

Code:

Previously compiled for OpenFOAM 2.3.0
Reading variables from 'swakConfiguration'
swakConfiguration: line 1: python-config: command not found
swakConfiguration: line 2: python-config: command not found
swakConfiguration: line 13: [: : integer expression expected
Checking swak4Foam-version and generating file
Swak version is 0.3.2
Bison is version 2.5
Flex is version 2.5.35 (Minor version: 35)
OpenFOAM-version: Major 2 Minor 3 Patch 0 (-1 == x / 0)
No change to swak4FoamParsers/foamVersion4swak.H
'/home/amir/OpenFOAM/amir-2.3.0/platforms/linux64GccDPOpt/lib/libswak4FoamParsers.so' is up to date.
'/home/amir/OpenFOAM/amir-2.3.0/platforms/linux64GccDPOpt/lib/libswakLagrangianParser.so' is up to date.
'/home/amir/OpenFOAM/amir-2.3.0/platforms/linux64GccDPOpt/lib/libgroovyBC.so' is up to date.
'/home/amir/OpenFOAM/amir-2.3.0/platforms/linux64GccDPOpt/lib/libswakFunctionObjects.so' is up to date.
'/home/amir/OpenFOAM/amir-2.3.0/platforms/linux64GccDPOpt/lib/libsimpleFunctionObjects.so' is up to date.
'/home/amir/OpenFOAM/amir-2.3.0/platforms/linux64GccDPOpt/lib/libsimpleLagrangianFunctionObjects.so' is up to date.
'/home/amir/OpenFOAM/amir-2.3.0/platforms/linux64GccDPOpt/lib/libsimpleSearchableSurfaces.so' is up to date.
'/home/amir/OpenFOAM/amir-2.3.0/platforms/linux64GccDPOpt/lib/libsimpleSwakFunctionObjects.so' is up to date.
'/home/amir/OpenFOAM/amir-2.3.0/platforms/linux64GccDPOpt/lib/libswakTopoSources.so' is up to date.
'/home/amir/OpenFOAM/amir-2.3.0/platforms/linux64GccDPOpt/lib/libswakSourceFields.so' is up to date.
Compiling swakFvOptions
'/home/amir/OpenFOAM/amir-2.3.0/platforms/linux64GccDPOpt/lib/libswakFvOptions.so' is up to date.
'/home/amir/OpenFOAM/amir-2.3.0/platforms/linux64GccDPOpt/lib/libgroovyStandardBCs.so' is up to date.

SWAK_PYTHON_INCLUDE not defined .... no Python-Integration. Most people are fine without it

'/home/amir/OpenFOAM/amir-2.3.0/platforms/linux64GccDPOpt/lib/libswakChemistryModelFunctionPlugin.so' is up to date.
'/home/amir/OpenFOAM/amir-2.3.0/platforms/linux64GccDPOpt/lib/libswakFvcSchemesFunctionPlugin.so' is up to date.
'/home/amir/OpenFOAM/amir-2.3.0/platforms/linux64GccDPOpt/lib/libswakLagrangianCloudSourcesFunctionPlugin.so' is up to date.
'/home/amir/OpenFOAM/amir-2.3.0/platforms/linux64GccDPOpt/lib/libswakLocalCalculationsFunctionPlugin.so' is up to date.
'/home/amir/OpenFOAM/amir-2.3.0/platforms/linux64GccDPOpt/lib/libswakMeshQualityFunctionPlugin.so' is up to date.
'/home/amir/OpenFOAM/amir-2.3.0/platforms/linux64GccDPOpt/lib/libswakMeshWaveFunctionPlugin.so' is up to date.
'/home/amir/OpenFOAM/amir-2.3.0/platforms/linux64GccDPOpt/lib/libswakRadiationModelFunctionPlugin.so' is up to date.
'/home/amir/OpenFOAM/amir-2.3.0/platforms/linux64GccDPOpt/lib/libswakRandomFunctionPlugin.so' is up to date.
'/home/amir/OpenFOAM/amir-2.3.0/platforms/linux64GccDPOpt/lib/libswakSurfacesAndSetsFunctionPlugin.so' is up to date.
'/home/amir/OpenFOAM/amir-2.3.0/platforms/linux64GccDPOpt/lib/libswakThermoTurbFunctionPlugin.so' is up to date.
'/home/amir/OpenFOAM/amir-2.3.0/platforms/linux64GccDPOpt/lib/libswakTransportTurbFunctionPlugin.so' is up to date.
'/home/amir/OpenFOAM/amir-2.3.0/platforms/linux64GccDPOpt/lib/libswakVelocityFunctionPlugin.so' is up to date.
'/home/amir/OpenFOAM/amir-2.3.0/platforms/linux64GccDPOpt/lib/libswakCoalCloudAdaptor.so' is up to date.

If you have your own function-plugins you can specify them using the SWAK_USER_PLUGINS environment variable and they would be compiled now. If you don't know what this means: don't bother. You propably don't need it

make[1]: Entering directory `/home/amir/Desktop/swak4Foam-compiled/swak4Foam_2.x/Utilities/calcNonUniformOffsetsForMapped'
make[1]: `/home/amir/OpenFOAM/amir-2.3.0/platforms/linux64GccDPOpt/bin/calcNonUniformOffsetsForMapped' is up to date.
make[1]: Leaving directory `/home/amir/Desktop/swak4Foam-compiled/swak4Foam_2.x/Utilities/calcNonUniformOffsetsForMapped'
make[1]: Entering directory `/home/amir/Desktop/swak4Foam-compiled/swak4Foam_2.x/Utilities/fieldReport'
make[1]: `/home/amir/OpenFOAM/amir-2.3.0/platforms/linux64GccDPOpt/bin/fieldReport' is up to date.
make[1]: Leaving directory `/home/amir/Desktop/swak4Foam-compiled/swak4Foam_2.x/Utilities/fieldReport'
make[1]: Entering directory `/home/amir/Desktop/swak4Foam-compiled/swak4Foam_2.x/Utilities/funkyDoCalc'
make[1]: `/home/amir/OpenFOAM/amir-2.3.0/platforms/linux64GccDPOpt/bin/funkyDoCalc' is up to date.
make[1]: Leaving directory `/home/amir/Desktop/swak4Foam-compiled/swak4Foam_2.x/Utilities/funkyDoCalc'

SWAK_PYTHON_INCLUDE not defined .... no Python-Integration. Utility funkyPythonPostproc not compiled

make[1]: Entering directory `/home/amir/Desktop/swak4Foam-compiled/swak4Foam_2.x/Utilities/funkySetBoundaryField'
make[1]: `/home/amir/OpenFOAM/amir-2.3.0/platforms/linux64GccDPOpt/bin/funkySetBoundaryField' is up to date.
make[1]: Leaving directory `/home/amir/Desktop/swak4Foam-compiled/swak4Foam_2.x/Utilities/funkySetBoundaryField'
make[1]: Entering directory `/home/amir/Desktop/swak4Foam-compiled/swak4Foam_2.x/Utilities/funkySetFields'
make[1]: `/home/amir/OpenFOAM/amir-2.3.0/platforms/linux64GccDPOpt/bin/funkySetFields' is up to date.
make[1]: Leaving directory `/home/amir/Desktop/swak4Foam-compiled/swak4Foam_2.x/Utilities/funkySetFields'
make[1]: Entering directory `/home/amir/Desktop/swak4Foam-compiled/swak4Foam_2.x/Utilities/funkySetLagrangianField'
make[1]: `/home/amir/OpenFOAM/amir-2.3.0/platforms/linux64GccDPOpt/bin/funkySetLagrangianField' is up to date.
make[1]: Leaving directory `/home/amir/Desktop/swak4Foam-compiled/swak4Foam_2.x/Utilities/funkySetLagrangianField'
make[1]: Entering directory `/home/amir/Desktop/swak4Foam-compiled/swak4Foam_2.x/Utilities/funkyWarpMesh'
make[1]: `/home/amir/OpenFOAM/amir-2.3.0/platforms/linux64GccDPOpt/bin/funkyWarpMesh' is up to date.
make[1]: Leaving directory `/home/amir/Desktop/swak4Foam-compiled/swak4Foam_2.x/Utilities/funkyWarpMesh'
make[1]: Entering directory `/home/amir/Desktop/swak4Foam-compiled/swak4Foam_2.x/Utilities/replayTransientBC'
make[1]: `/home/amir/OpenFOAM/amir-2.3.0/platforms/linux64GccDPOpt/bin/replayTransientBC' is up to date.
make[1]: Leaving directory `/home/amir/Desktop/swak4Foam-compiled/swak4Foam_2.x/Utilities/replayTransientBC'


If you want to use swakCoded-function object or compile software based on swak set the environment variable SWAK4FOAM_SRC to /home/amir/Desktop/swak4Foam-compiled/swak4Foam_2.x/Libraries (most people will be fine without setting that variable)

how can i overcome this problem?

Best Regards,
Arjang

michu August 12, 2015 12:52

Hello,

I was having a similar problem in my Openfoam. (Thread: http://www.cfd-online.com/Forums/ope...ate-swirl.html) but I think I managed to figure out how to fix one or two of the problems. If you look in the file swakConfiguration you will notice the first and second lines:

Quote:

export SWAK_PYTHON_INCLUDE="$(python-config --cflags)"
export SWAK_PYTHON_LINK="$(python-config --ldflags)"
try to copy and paste into a terminal just:

Quote:

export SWAK_PYTHON_INCLUDE="$(python-config --cflags)"
I got a notice saying that python-config is not installed and to install it.

It fixed the error messages about Line 1 and Line 2 in the swakConfiguration.

Also if you want to do the thing at the end just enter:

Quote:

export SWAK4FOAM_SRC=/home/amir/Desktop/swak4Foam-compiled/swak4Foam_2.x/Libraries
Cheers,
~Michu

AmirBaqa1987 August 13, 2015 06:53

Quote:

Originally Posted by michu (Post 559315)
Hello,

I was having a similar problem in my Openfoam. (Thread: http://www.cfd-online.com/Forums/ope...ate-swirl.html) but I think I managed to figure out how to fix one or two of the problems. If you look in the file swakConfiguration you will notice the first and second lines:



try to copy and paste into a terminal just:



I got a notice saying that python-config is not installed and to install it.

It fixed the error messages about Line 1 and Line 2 in the swakConfiguration.

Also if you want to do the thing at the end just enter:



Cheers,
~Michu

Dear Michu,

The problem is solved:).

Thanks a lot.

michu August 13, 2015 09:11

Hello Arjang,

Glad that helped. I was just curious how you fixed the error in line 13 or the error with swak4Foam. Do you mind sharing how you fixed the problem?

Thank you,
~Michu

sabago November 19, 2015 13:07

Hello all!

Anyone have an idea how to get rid of the line 13 error?

I was initially having this problem: http://www.cfd-online.com/Forums/ope...n-problem.html

And after taking a break and reinstalling, I can't seem to get past this error:
Code:

Previously compiled for OpenFOAM

/home/sandra/OpenFOAM/sandra-2.3.0/swak4Foam/privateRequirements/bin existing. Prepending to PATH-variable (private version of Bison)

Reading variables from 'swakConfiguration'
swakConfiguration: line 13: [: : integer expression expected
Checking swak4Foam-version and generating file
abort: no repository found in '/home/sandra/OpenFOAM/sandra-2.3.0/swak4Foam' (.hg not found)!
Swak version is 0.3.2
./Allwmake: line 61: wmake: command not found

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 occured to 5 other people before and has been solved on the MessageBoard

I also tried the suggestions in this thread: http://www.cfd-online.com/Forums/ope...ate-swirl.html

Best regards,
Sandra

michu November 19, 2015 15:43

Hello Sandra,

So technically when installing swak4foam the swakconfiguration file can be deleted. I think your problem is something else. I got this error when I didn't do another step (if memory serves). I think based on the code you provided your bison version may be out of date? Actually- what version of openfoam are you using? (and just to confirm your using swak 0.3.2 right?)

~Michu

sabago November 19, 2015 15:54

Quote:

Originally Posted by michu (Post 574096)
Hello Sandra,

So technically when installing swak4foam the swakconfiguration file can be deleted.

Hi Michu,

Yes, Bruno did suggest that in one of the links that I cite but instead it gave an error along the lines that "swakConfiguration couldn't be found"

Quote:

I think your problem is something else. I got this error when I didn't do another step (if memory serves). I think based on the code you provided your bison version may be out of date? Actually- what version of openfoam are you using? (and just to confirm your using swak 0.3.2 right?)

~Michu
I installed it by going through all the links here: https://openfoamwiki.net/index.php/I...tion/swak4Foam
which also involved a manual install of bison and m4.
Also, I had installed it successfully a couple of weeks ago but had to reinstall due to unavoidable circumstances so I'm quite familiar with the process now, I think.

And I'm using OpenFOAM-2.3.0 and swak 0.3.2.

Although I saw the last post in a thread where you seem to still be stuck with the line 13 error; did you solve it?

Sandra

michu November 19, 2015 16:14

Hello Sandra,

I talked to a python programming friend a while back when I was still trying to get that to work. He told me that line is actually incomplete and needs like either another number or reference to somewhere else or reference to another config file or a ; at the end. (I don't remember exactly what.) Sorry I can't be more helpful with line 13.

As a side note I am still working with swak4foam and at least for me it is working without the swakconfiguration file. And for me when I did install and was getting errors with the swakconfiguration I dont remember the

"./Allwmake: line 61: wmake: command not found"

I am currently running a simulation on my computer but when it is done Ill check out one other thing and see if that helps.

Cheers,
~ Michu

sabago November 19, 2015 17:27

Thanks for your input Michu!

Does anyone know how I can avoid the "swakConfiguration not found" related error when I delete the swakConfiguration files?

Do I have to delete all four (.automatic, .centos6, .debian and .examples)? If you've taken this route of ignoring Python in swak4foam, care to share at which step you deleted this files to avoid the error that insists I need the swakConfiguration file?

Best,
Sandra

sabago November 20, 2015 12:18

It turns out that I wasn't installing in the right folder.

The fix is here: http://www.cfd-online.com/Forums/ope...tml#post574225.

Best regards,
Sandra


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