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] swak4Foam on OpenFoam-v2006? (https://www.cfd-online.com/Forums/openfoam-community-contributions/228638-swak4foam-openfoam-v2006.html)

petros July 8, 2020 13:48

swak4Foam on OpenFoam-v2006?
 
Hi all,

Is there any chance to compile swak4Foam for the new OpenFOAM-v2006 release?

I gave it a try but with no success:

Code:

hg clone http://hg.code.sf.net/p/openfoam-extend/swak4Foam
cd swak4Foam
./AllwmakeAll > log.make 2>&1

The log.make file reads:

Code:

Current OpenFOAM version is v2006.
Previously compiled for OpenFOAM (v2006)

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

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 /home/petros/OpenFOAM/petros-v2006/swak4Foam/privateRequirements
Checking swak4Foam-version and generating file
Swak version is 2020.06.0
hg info: 76087ce82a32 tip
No 'bear' installed
Bison: /home/petros/OpenFOAM/petros-v2006/swak4Foam/privateRequirements/bin/bison
Flex: /usr/bin/flex
Bison at /home/petros/OpenFOAM/petros-v2006/swak4Foam/privateRequirements/bin/bison is version 3.4 (Major 3 Minor 4)
Flex is version 2.6.4 (Minor version: 4)
OpenFOAM-version: Major 2006 Minor 0 Patch 0 (-1 == x / 0) Fork: com
No change to swak4FoamParsers/foamVersion4swak.H

Best,
Petros

petros July 20, 2020 14:27

Still trying to compile swak4Foam in v2006
 
Still trying to compile swak4Foam in v2006 after Bernhard announced that it is now fully functional.

I get the following fatal error:

Code:

In file included from facInterpolationFunctionPlugin.C:33:0:
../../swakFiniteArea/lnInclude/FaFieldValueExpressionDriver.H:49:47: fatal error: FaFieldValueExpressionParser.tab.hh: No such file or directory
 #include "FaFieldValueExpressionParser.tab.hh"

You may have a look at the log.make file here

fuzzydunlop November 12, 2020 10:54

Hi Petros,

Did you ever manage to find the cause of this error? Getting the same message here trying to install swak4Foam on OpenFoam-v2006.

Thanks

petros November 12, 2020 11:33

Hi,

I can confirm that swak4Foam compiles smoothly with v2006 after Bernhard Gschaider's newer updates. Try:

Code:

hg clone http://hg.code.sf.net/p/openfoam-extend/swak4Foam swak4Foam
cd swak4Foam
./AllwmakeAll


gschaider November 13, 2020 13:57

Quote:

Originally Posted by petros (Post 787574)
Hi,

I can confirm that swak4Foam compiles smoothly with v2006 after Bernhard Gschaider's newer updates. Try:

Code:

hg clone http://hg.code.sf.net/p/openfoam-extend/swak4Foam swak4Foam
cd swak4Foam
./AllwmakeAll



I'm not 100% sure if the latest release (that would be the one pulled by your command) compiles completely with your command as it was released before v2006 (I did some adaptions according to the git that would become 2006 which compile most of it)


To be sure do
Code:

hg update develop
if the released version does not compile

G_G_ January 15, 2021 06:10

Hi Bernhard,

I am trying to compile as well, but so far unsuccessfully:

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/OpenFOAM-v2006/swak4Foam/privateRequirements
Checking swak4Foam-version and generating file
Swak version is 20xx.yy.0
hg info: b8e73355892c (develop) tip
No 'bear' installed
Bison: /opt/OpenFOAM-v2006/swak4Foam/privateRequirements/bin/bison
Flex: /usr/bin/flex
Bison at /opt/OpenFOAM-v2006/swak4Foam/privateRequirements/bin/bison is version 3.4 (Major 3 Minor 4)
Flex is version 2.6.4 (Minor version: 4)
OpenFOAM-version: Major 2006 Minor 0 Patch 0 (-1 == x / 0) Fork: com
No swak4FoamParsers/foamVersion4swak.H. Generated

Please include the output above when reporting a problem in the compilation. It helps diagnosing the problem


ln: simpleFunctionObjects/lnInclude
wmake libso swak4FoamParsers
/opt/OpenFOAM-v2006/build/linux64GccDPInt32Opt/swak4Foam/Libraries/swak4FoamParsers/options:61: /opt/OpenFOAM-v2006/build/linux64GccDPInt32Opt/swak4Foam/Libraries/swak4FoamParsers/../../../rules/versionOptions: No such file or directory
/opt/OpenFOAM-v2006/build/linux64GccDPInt32Opt/swak4Foam/Libraries/swak4FoamParsers/options:71: /opt/OpenFOAM-v2006/build/linux64GccDPInt32Opt/swak4Foam/Libraries/swak4FoamParsers/../mybison: No such file or directory
/opt/OpenFOAM-v2006/build/linux64GccDPInt32Opt/swak4Foam/Libraries/swak4FoamParsers/options:72: /opt/OpenFOAM-v2006/build/linux64GccDPInt32Opt/swak4Foam/Libraries/swak4FoamParsers/../myflex: No such file or directory
make: *** No rule to make target '/opt/OpenFOAM-v2006/build/linux64GccDPInt32Opt/swak4Foam/Libraries/swak4FoamParsers/../myflex'. Stop.
/opt/OpenFOAM-v2006/build/linux64GccDPInt32Opt/swak4Foam/Libraries/swak4FoamParsers/options:61: /opt/OpenFOAM-v2006/build/linux64GccDPInt32Opt/swak4Foam/Libraries/swak4FoamParsers/../../../rules/versionOptions: No such file or directory
/opt/OpenFOAM-v2006/build/linux64GccDPInt32Opt/swak4Foam/Libraries/swak4FoamParsers/options:71: /opt/OpenFOAM-v2006/build/linux64GccDPInt32Opt/swak4Foam/Libraries/swak4FoamParsers/../mybison: No such file or directory
/opt/OpenFOAM-v2006/build/linux64GccDPInt32Opt/swak4Foam/Libraries/swak4FoamParsers/options:72: /opt/OpenFOAM-v2006/build/linux64GccDPInt32Opt/swak4Foam/Libraries/swak4FoamParsers/../myflex: No such file or directory
make: *** No rule to make target '/opt/OpenFOAM-v2006/build/linux64GccDPInt32Opt/swak4Foam/Libraries/swak4FoamParsers/../myflex'. Stop.
wmake error: file '/opt/OpenFOAM-v2006/build/linux64GccDPInt32Opt/swak4Foam/Libraries/swak4FoamParsers/sourceFiles' could not be created in /opt/OpenFOAM-v2006/swak4Foam/Libraries/swak4FoamParsers
Parser library did not compile OK. No sense continuing as everything else depends on it

Any suggestion about what may have caused the issue?

Best wishes,

Giovanni

Ron.CC April 7, 2021 23:28

Hi Bernhard,

I am trying to compile swak4foam on OFv2012 and have done the hg update, but meet an error:

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
Found Python 3.6
Configuring Python 3.6
Using python3.6 at /usr/bin/python3.6-config for python3
Using our own Lua at /home/user2/OF2012/OpenFOAM/user2-v2012/swak4Foam/privateRequirements
Checking swak4Foam-version and generating file
Swak version is 20xx.yy.0
hg info: b8e73355892c+ (develop) tip
which: no bear in (/home/user2/OF2012/OpenFOAM/user2-v2012/swak4Foam/privateRequirements/bin:/OF2012/OpenFOAM/user2-v2012/platforms/linux64GccDPInt32Opt/bin:/home/user2/OF2012/OpenFOAM/OpenFOAM-v2012/site/2012/platforms/linux64GccDPInt32Opt/bin:/home/user2/OF2012/OpenFOAM/OpenFOAM-v2012/platforms/linux64GccDPInt32Opt/bin:/home/user2/OF2012/OpenFOAM/OpenFOAM-v2012/bin:/home/user2/OF2012/OpenFOAM/OpenFOAM-v2012/wmake:/home/user2/dakota-6.9.0-release-public-rhel7.x86_64-UI/bin:/home/user2/dakota-6.9.0-release-public-rhel7.x86_64-UI/share/dakota/test:/home/user2/dakota-6.9.0-release-public-rhel7.x86_64-UI/gui:/usr/local/MATLAB/R2015b/bin:/usr/ansys_inc/v171/fluent/bin:/usr/ansys_inc/v171/icemcfd/linux64_amd/bin:/usr/local/bin:/usr/bin:/usr/local/sbin:/usr/sbin:/home/user2/.local/bin:/home/user2/bin)
No 'bear' installed
Bison: /home/user2/OF2012/OpenFOAM/user2-v2012/swak4Foam/privateRequirements/bin/bison
Flex: /usr/bin/flex
Bison at /home/user2/OF2012/OpenFOAM/user2-v2012/swak4Foam/privateRequirements/bin/bison is version 3.4 (Major 3 Minor 4)
Flex is version 2.5.37 (Minor version: 37)
OpenFOAM-version: Major 2012 Minor 0 Patch 0 (-1 == x / 0) Fork: com
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
mkdir: cannot create directory '/OF2012/OpenFOAM/user2-v2012/platforms': Permission denied
make: *** [/OF2012/OpenFOAM/user2-v2012/platforms/linux64GccDPInt32Opt/lib/libswak4FoamParsers.so] Error 1
Parser library did not compile OK. No sense continuing as everything else depends on it.

I have tried:
1.Manually create the directory '/OF2012/OpenFOAM/user2-v2012/platforms'.
2.Apply "chmod -R 777 user2-v2012/".
Both can't solve the problem and the error message is the same.

Could you please give me a hint? Thank you in advance.

Ron

Ron.CC April 8, 2021 08:07

Problem solved!
 
Quote:

Originally Posted by Ron.CC (Post 800908)
Hi Bernhard,

I am trying to compile swak4foam on OFv2012 and have done the hg update, but meet an error:

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
Found Python 3.6
Configuring Python 3.6
Using python3.6 at /usr/bin/python3.6-config for python3
Using our own Lua at /home/user2/OF2012/OpenFOAM/user2-v2012/swak4Foam/privateRequirements
Checking swak4Foam-version and generating file
Swak version is 20xx.yy.0
hg info: b8e73355892c+ (develop) tip
which: no bear in (/home/user2/OF2012/OpenFOAM/user2-v2012/swak4Foam/privateRequirements/bin:/OF2012/OpenFOAM/user2-v2012/platforms/linux64GccDPInt32Opt/bin:/home/user2/OF2012/OpenFOAM/OpenFOAM-v2012/site/2012/platforms/linux64GccDPInt32Opt/bin:/home/user2/OF2012/OpenFOAM/OpenFOAM-v2012/platforms/linux64GccDPInt32Opt/bin:/home/user2/OF2012/OpenFOAM/OpenFOAM-v2012/bin:/home/user2/OF2012/OpenFOAM/OpenFOAM-v2012/wmake:/home/user2/dakota-6.9.0-release-public-rhel7.x86_64-UI/bin:/home/user2/dakota-6.9.0-release-public-rhel7.x86_64-UI/share/dakota/test:/home/user2/dakota-6.9.0-release-public-rhel7.x86_64-UI/gui:/usr/local/MATLAB/R2015b/bin:/usr/ansys_inc/v171/fluent/bin:/usr/ansys_inc/v171/icemcfd/linux64_amd/bin:/usr/local/bin:/usr/bin:/usr/local/sbin:/usr/sbin:/home/user2/.local/bin:/home/user2/bin)
No 'bear' installed
Bison: /home/user2/OF2012/OpenFOAM/user2-v2012/swak4Foam/privateRequirements/bin/bison
Flex: /usr/bin/flex
Bison at /home/user2/OF2012/OpenFOAM/user2-v2012/swak4Foam/privateRequirements/bin/bison is version 3.4 (Major 3 Minor 4)
Flex is version 2.5.37 (Minor version: 37)
OpenFOAM-version: Major 2012 Minor 0 Patch 0 (-1 == x / 0) Fork: com
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
mkdir: cannot create directory '/OF2012/OpenFOAM/user2-v2012/platforms': Permission denied
make: *** [/OF2012/OpenFOAM/user2-v2012/platforms/linux64GccDPInt32Opt/lib/libswak4FoamParsers.so] Error 1
Parser library did not compile OK. No sense continuing as everything else depends on it.

I have tried:
1.Manually create the directory '/OF2012/OpenFOAM/user2-v2012/platforms'.
2.Apply "chmod -R 777 user2-v2012/".
Both can't solve the problem and the error message is the same.

Could you please give me a hint? Thank you in advance.

Ron

If you meet the same problem you should apply echo $FOAM_USER_LIBBIN and check the returned directory. For my case it led to a wrong root directory. That's why wmake complains about the mkdir permission.
The solution for my case is to change the WM_PROJECT_USER_DIR in bashrc to right user directory.Then $FOAM_USER_LIBBIN will be corrected automatically.
I hope it will help someone.

Ron

choist31 July 26, 2021 10:00

swak4Foam download issue
 
1 Attachment(s)
Dear Mr. Ron.CC

Thanks for your sharing your experience. I am new OF user and try to download the swak4foam on OFv2012 but I have a error message as follows.
I used below command in my Ubuntu terminal:

hg clone http://hg.code.sf.net/p/openfoam-extend/swak4Foam swak4Foam

Please see the attached snapshot of error message.

I have no clear idea what cased the problem.
It would be great if you can give me any comments on this issue.

gschaider July 26, 2021 12:32

Quote:

Originally Posted by choist31 (Post 808978)
Dear Mr. Ron.CC

Thanks for your sharing your experience. I am new OF user and try to download the swak4foam on OFv2012 but I have a error message as follows.
I used below command in my Ubuntu terminal:

hg clone http://hg.code.sf.net/p/openfoam-extend/swak4Foam swak4Foam

Please see the attached snapshot of error message.

I have no clear idea what cased the problem.
It would be great if you can give me any comments on this issue.

That is a problem with your system (not with swak4Foam). Seems that a standard-library that is installed with OpenFOAM (the compiler in thirdParty to be specific) "shadows" the library of the same name that is installed in your system. Probably the library in your system is NEWER than the library from OpenFOAM an Mercurial complains because it wants the new library


Try downloading from a shell where OpenFOAM is not activated


For reasons like this I recommend NOT activating OpenFOAM in your bashrc automatically because it is possible with such a library mixup to lock yourself out completely


Last: PLEASE don't post screenshots of your error messages. Copy the text from the terminal and put it into a CODE-environment (the #-icon above). This makes it easier to answer your questions because people can copy-past from it and it helps other people with similar problems because the problem is found when searching for the error message

choist31 July 30, 2021 15:41

swak4Foam download issue
 
Dear Mr. gschaider

I do appreciate your kind and detail suggestions. I am in the middle of understanding your comments.
I am new to use Unix environment. Even though I have a experience of simply modifying the source code, but I still feel uncomfortable to work in Unix environment.

In addition, I am using the Ubuntu to run OpenFOAM. I have no idea how to get the error message on the Ubuntu terminal. That's way I made a snap shot.

Anyhow, I learn a lot thanks to your valuable help and suggestions..
Thank you again.

Sung

gschaider August 1, 2021 06:46

Quote:

Originally Posted by choist31 (Post 809390)
Dear Mr. gschaider

I do appreciate your kind and detail suggestions. I am in the middle of understanding your comments.
I am new to use Unix environment. Even though I have a experience of simply modifying the source code, but I still feel uncomfortable to work in Unix environment.

In addition, I am using the Ubuntu to run OpenFOAM. I have no idea how to get the error message on the Ubuntu terminal. That's way I made a snap shot.

Anyhow, I learn a lot thanks to your valuable help and suggestions..
Thank you again.

Sung


First: to get the error message from the terminal just copy-paste it like you would with any regular text


What happens is that when OF is "activated" it manipulates an environment variable LD_LIBRARY_PATH that tells Linux where to look for so-files (the equivalent to DLLs in Windows and Windows has a similar mechanism with the PATH-variable). Now your OpenFOAM-version (you never mention where you get these binaries from) bring their own version of libstdFoo.so in /opt/foo (instead of foo I could give you the correct names if I could copy paste them from your post but I can't copy them from your screenshot). There is a so-file of the same name in your system (probably in /usr/lib or /lib). But as the /opt/foo-directory comes in the LD_LIBRARY_PATH before that your system uses that one. Now the problem seems to be that the version on your system is Newer than the version in /opt/foo and a lot of programs (like your python in that case) rely on the newer version and fail because they stop searching after they found the old version


A lot of OF-installation-recipies recommend adding something like "source /opt/foo/.../etc/bashrc" to the ~/.bashrc so that you automatically have OF on your terminals. This is bad practice because it leads to problems like yours and in extreme cases can prevent you from logging in. I strongly recommend removing such a line from your ~/.bashrc (or similar file) and activate OF only when you need it

choist31 August 2, 2021 10:25

swak4Foam download issue
 
Dear Mr. gschaider

I don't know how to appreciate your kind and very helpful tips. You are the first expert to reply my question on not only prompt but also giving me a detail information. Your kindness and valuable comments are very very useful and guideline for the new OF users like me.
Typically, the prompt reply is very very helpful for me to get to the correction direction.
I have also many experience in OF to spend somewhat time to get the answer with wrong direction in this OF forum site due to delay of reply or no reply. To some point, I also learned it from my effort with non-successful result but the my working fund resources and boss does not allows me to do that (academical approach).

Anyhow, your comments will be big guide line for the other reviewers on this issue.

ErenC August 7, 2021 09:18

I needed additional computational source, so I downloaded OF2012 with ubuntu on windows. Couldn't compile swak4foam for hours, then I switched to OF2006 and now it compiles nicely. So, if you have problem with OF2012, switch back to OF2006.

gschaider August 8, 2021 14:41

Quote:

Originally Posted by ErenC (Post 809835)
I needed additional computational source, so I downloaded OF2012 with ubuntu on windows. Couldn't compile swak4foam for hours, then I switched to OF2006 and now it compiles nicely. So, if you have problem with OF2012, switch back to OF2006.


Could you be a bit more specific about your problems? The latest release of swak4foam compiles with 2012 for me. If I don't hear about problems that some people might have in specific configurations it is very unlikely that these problems will get fixed

ErenC August 10, 2021 05:35

Quote:

Originally Posted by gschaider (Post 809897)
Could you be a bit more specific about your problems? The latest release of swak4foam compiles with 2012 for me. If I don't hear about problems that some people might have in specific configurations it is very unlikely that these problems will get fixed


I can't reproduce error right now, when run finishes (it will probably take three-four more days) I'll do it and share it.

But what I remember was bison didn't compile, I downloaded it myself. There was no error with dependencies (I downloaded everything myself starting from "essentials") but I got errors like:
"/a/path/I/cant/recall/mybison not found"
"cannot create directory"
etc.

gschaider August 10, 2021 05:50

Quote:

Originally Posted by ErenC (Post 810007)
I can't reproduce error right now, when run finishes (it will probably take three-four more days) I'll do it and share it.

But what I remember was bison didn't compile, I downloaded it myself. There was no error with dependencies (I downloaded everything myself starting from "essentials") but I got errors like:
"/a/path/I/cant/recall/mybison not found"
"cannot create directory"
etc.


"Can not create directory" usually is an OS-problem. Usually

- a full disk
- user has no permissions to create that directory

ErenC August 10, 2021 07:23

Quote:

Originally Posted by gschaider (Post 810009)
"Can not create directory" usually is an OS-problem. Usually

- a full disk
- user has no permissions to create that directory


Well problem was neither of those. Because it compiled with 2006 without that problems. I will share the exact errors when I can touch the PC again(cpu is overwhelming right now).

ErenC October 14, 2021 05:47

Sorry about extremely late reply, this was on a remote computer(not mine) and I was extremely busy with writing new paper, job interviews and PhD proposal... Anyway, after using
Code:

hg update develop
./AllwmakeAll

I got these errors. Exactly same procedure worked for v2006. Operating system was Win10, with bash on windows. I will probably never use OpenFOAM with windows(it was sloooooooooooooooooooooooooow), but I wanted to share the error anyway.

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
Checking swak4Foam-version and generating file
Swak version is 202x.yy.0
hg info: 06fdbe848844 (develop) tip
Using /usr/bin/bear to build compilation database
Bison: /home/erenc/OpenFOAM/OpenFOAM-v2012/swak4Foam/privateRequirements/bin/bison
Flex: /usr/bin/flex
Bison at /home/erenc/OpenFOAM/OpenFOAM-v2012/swak4Foam/privateRequirements/bin/bison is version 3.4 (Major 3 Minor 4)
Flex is version 2.6.4 (Minor version: 4)
OpenFOAM-version: Major 2012 Minor 0 Patch 0 (-1 == x / 0) Fork: com
No swak4FoamParsers/foamVersion4swak.H. Generated

Please include the output above when reporting a problem in the compilation. It helps diagnosing the problem


ln: simpleFunctionObjects/lnInclude
wmake libso swak4FoamParsers
/home/erenc/OpenFOAM/OpenFOAM-v2012/build/linux64Gcc63DPInt32Opt/swak4Foam/Libraries/swak4FoamParsers/options:61: /home/erenc/OpenFOAM/OpenFOAM-v2012/build/linux64Gcc63DPInt32Opt/swak4Foam/Libraries/swak4FoamParsers/../../../rules/versionOptions: No such file or directory
/home/erenc/OpenFOAM/OpenFOAM-v2012/build/linux64Gcc63DPInt32Opt/swak4Foam/Libraries/swak4FoamParsers/options:71: /home/erenc/OpenFOAM/OpenFOAM-v2012/build/linux64Gcc63DPInt32Opt/swak4Foam/Libraries/swak4FoamParsers/../mybison: No such file or directory
/home/erenc/OpenFOAM/OpenFOAM-v2012/build/linux64Gcc63DPInt32Opt/swak4Foam/Libraries/swak4FoamParsers/options:72: /home/erenc/OpenFOAM/OpenFOAM-v2012/build/linux64Gcc63DPInt32Opt/swak4Foam/Libraries/swak4FoamParsers/../myflex: No such file or directory
make: *** No rule to make target '/home/erenc/OpenFOAM/OpenFOAM-v2012/build/linux64Gcc63DPInt32Opt/swak4Foam/Libraries/swak4FoamParsers/../myflex'. Stop.
/home/erenc/OpenFOAM/OpenFOAM-v2012/build/linux64Gcc63DPInt32Opt/swak4Foam/Libraries/swak4FoamParsers/options:61: /home/erenc/OpenFOAM/OpenFOAM-v2012/build/linux64Gcc63DPInt32Opt/swak4Foam/Libraries/swak4FoamParsers/../../../rules/versionOptions: No such file or directory
/home/erenc/OpenFOAM/OpenFOAM-v2012/build/linux64Gcc63DPInt32Opt/swak4Foam/Libraries/swak4FoamParsers/options:71: /home/erenc/OpenFOAM/OpenFOAM-v2012/build/linux64Gcc63DPInt32Opt/swak4Foam/Libraries/swak4FoamParsers/../mybison: No such file or directory
/home/erenc/OpenFOAM/OpenFOAM-v2012/build/linux64Gcc63DPInt32Opt/swak4Foam/Libraries/swak4FoamParsers/options:72: /home/erenc/OpenFOAM/OpenFOAM-v2012/build/linux64Gcc63DPInt32Opt/swak4Foam/Libraries/swak4FoamParsers/../myflex: No such file or directory
make: *** No rule to make target '/home/erenc/OpenFOAM/OpenFOAM-v2012/build/linux64Gcc63DPInt32Opt/swak4Foam/Libraries/swak4FoamParsers/../myflex'. Stop.
wmake error: file '/home/erenc/OpenFOAM/OpenFOAM-v2012/build/linux64Gcc63DPInt32Opt/swak4Foam/Libraries/swak4FoamParsers/sourceFiles' could not be created in /home/erenc/OpenFOAM/OpenFOAM-v2012/swak4Foam/Libraries/swak4FoamParsers
Parser library did not compile OK. No sense continuing as everything else depends on it
@gschaider

gschaider October 14, 2021 15:05

Quote:

Originally Posted by ErenC (Post 814268)
Sorry about extremely late reply, this was on a remote computer(not mine) and I was extremely busy with writing new paper, job interviews and PhD proposal... Anyway, after using
Code:

hg update develop
./AllwmakeAll

I got these errors. Exactly same procedure worked for v2006. Operating system was Win10, with bash on windows. I will probably never use OpenFOAM with windows(it was sloooooooooooooooooooooooooow), but I wanted to share the error anyway.

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
Checking swak4Foam-version and generating file
Swak version is 202x.yy.0
hg info: 06fdbe848844 (develop) tip
Using /usr/bin/bear to build compilation database
Bison: /home/erenc/OpenFOAM/OpenFOAM-v2012/swak4Foam/privateRequirements/bin/bison
Flex: /usr/bin/flex
Bison at /home/erenc/OpenFOAM/OpenFOAM-v2012/swak4Foam/privateRequirements/bin/bison is version 3.4 (Major 3 Minor 4)
Flex is version 2.6.4 (Minor version: 4)
OpenFOAM-version: Major 2012 Minor 0 Patch 0 (-1 == x / 0) Fork: com
No swak4FoamParsers/foamVersion4swak.H. Generated

Please include the output above when reporting a problem in the compilation. It helps diagnosing the problem


ln: simpleFunctionObjects/lnInclude
wmake libso swak4FoamParsers
/home/erenc/OpenFOAM/OpenFOAM-v2012/build/linux64Gcc63DPInt32Opt/swak4Foam/Libraries/swak4FoamParsers/options:61: /home/erenc/OpenFOAM/OpenFOAM-v2012/build/linux64Gcc63DPInt32Opt/swak4Foam/Libraries/swak4FoamParsers/../../../rules/versionOptions: No such file or directory
/home/erenc/OpenFOAM/OpenFOAM-v2012/build/linux64Gcc63DPInt32Opt/swak4Foam/Libraries/swak4FoamParsers/options:71: /home/erenc/OpenFOAM/OpenFOAM-v2012/build/linux64Gcc63DPInt32Opt/swak4Foam/Libraries/swak4FoamParsers/../mybison: No such file or directory
/home/erenc/OpenFOAM/OpenFOAM-v2012/build/linux64Gcc63DPInt32Opt/swak4Foam/Libraries/swak4FoamParsers/options:72: /home/erenc/OpenFOAM/OpenFOAM-v2012/build/linux64Gcc63DPInt32Opt/swak4Foam/Libraries/swak4FoamParsers/../myflex: No such file or directory
make: *** No rule to make target '/home/erenc/OpenFOAM/OpenFOAM-v2012/build/linux64Gcc63DPInt32Opt/swak4Foam/Libraries/swak4FoamParsers/../myflex'. Stop.
/home/erenc/OpenFOAM/OpenFOAM-v2012/build/linux64Gcc63DPInt32Opt/swak4Foam/Libraries/swak4FoamParsers/options:61: /home/erenc/OpenFOAM/OpenFOAM-v2012/build/linux64Gcc63DPInt32Opt/swak4Foam/Libraries/swak4FoamParsers/../../../rules/versionOptions: No such file or directory
/home/erenc/OpenFOAM/OpenFOAM-v2012/build/linux64Gcc63DPInt32Opt/swak4Foam/Libraries/swak4FoamParsers/options:71: /home/erenc/OpenFOAM/OpenFOAM-v2012/build/linux64Gcc63DPInt32Opt/swak4Foam/Libraries/swak4FoamParsers/../mybison: No such file or directory
/home/erenc/OpenFOAM/OpenFOAM-v2012/build/linux64Gcc63DPInt32Opt/swak4Foam/Libraries/swak4FoamParsers/options:72: /home/erenc/OpenFOAM/OpenFOAM-v2012/build/linux64Gcc63DPInt32Opt/swak4Foam/Libraries/swak4FoamParsers/../myflex: No such file or directory
make: *** No rule to make target '/home/erenc/OpenFOAM/OpenFOAM-v2012/build/linux64Gcc63DPInt32Opt/swak4Foam/Libraries/swak4FoamParsers/../myflex'. Stop.
wmake error: file '/home/erenc/OpenFOAM/OpenFOAM-v2012/build/linux64Gcc63DPInt32Opt/swak4Foam/Libraries/swak4FoamParsers/sourceFiles' could not be created in /home/erenc/OpenFOAM/OpenFOAM-v2012/swak4Foam/Libraries/swak4FoamParsers
Parser library did not compile OK. No sense continuing as everything else depends on it
@gschaider


OK. The problem is that the build-scripts assume that the OBJECT_DIR-variable set up by the wmake-script points to a directory inside the Make-directories in the sources. Then the relative references like "../myflex" work (because they are in the Make-directories). In your case it points to a directory in the /home/erenc/OpenFOAM/OpenFOAM-v2012/build-directory and therefore the relative path doesn't work anymore.
I forgot when wmake makes the decision to compile to outside the sources. Either because some environment variables are missing. Or because things are compiled as root.
You don't compile as root (with sudo) by any chance?


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