CFD Online Discussion Forums

CFD Online Discussion Forums (https://www.cfd-online.com/Forums/)
-   OpenFOAM Installation (https://www.cfd-online.com/Forums/openfoam-installation/)
-   -   [foam-extend.org] foam-extend-4.0 Debian Testing bison problem fseterr.c (https://www.cfd-online.com/Forums/openfoam-installation/217697-foam-extend-4-0-debian-testing-bison-problem-fseterr-c.html)

brett1 May 21, 2019 17:29

foam-extend-4.0 Debian Testing bison problem fseterr.c
 
3 Attachment(s)
Hello, I recently attained this computer from our work group at school. It 'had' some version of foam-extend on it but no longer. It does have OPENMPI, PARAVIEW and other 'programming' things on it. It is DEBIAN TESTING and current. Also, the prerequisites;


Code:

sbh@sbh:~/foam/foam-extend-4.0$ sudo apt-cache policy git build-essential binutils-dev cmake flex zlib1g-dev qt4-dev-tools libqt4-dev libncurses5-dev libxt-dev rpm mercurial graphviz python python-dev libiberty-dev | grep -e "Installed" -B 1
git:
  Installed: 1:2.20.1-2
--
build-essential:
  Installed: 12.6
--
binutils-dev:
  Installed: 2.31.1-16
--
cmake:
  Installed: 3.13.4-1
--
flex:
  Installed: 2.6.4-6.2
--
zlib1g-dev:
  Installed: 1:1.2.11.dfsg-1
--
qt4-dev-tools:
  Installed: 4:4.8.7+dfsg-18
--
libqt4-dev:
  Installed: 4:4.8.7+dfsg-18
--
libncurses5-dev:
  Installed: 6.1+20181013-2
--
libxt-dev:
  Installed: 1:1.1.5-1+b3
--
rpm:
  Installed: 4.14.2.1+dfsg1-1
--
mercurial:
  Installed: 4.8.2-1
--
graphviz:
  Installed: 2.40.1-6
--
python:
  Installed: 2.7.16-1
--
python-dev:
  Installed: 2.7.16-1
--
libiberty-dev:
  Installed: 20190122-1

and for GCC;


Code:

sbh@sbh:~/foam/foam-extend-4.0$ gcc --version
gcc (Debian 8.3.0-6) 8.3.0

Reading around for help I noticed that there is this test, /bin/foamInstallationTest, whose results are before and after the first install,


Code:

sbh@sbh:~/foam/foam-extend-4.0$ ./bin/foamInstallationTest
Executing ./bin/foamInstallationTest:


Checking basic setup...
-------------------------------------------------------------------------------
Shell:              bash
Host:              sbh
OS:                Linux version 4.19.0-5-amd64
-------------------------------------------------------------------------------


Checking main foam-extend env variables...
-------------------------------------------------------------------------------
Environment_variable Set_to_file_or_directory                Valid      Crit
-------------------------------------------------------------------------------
$WM_PROJECT_INST_DIR /home/sbh/foam                          yes      yes
$WM_PROJECT_USER_DIR /home/sbh/foam/sbh-4.0                  no        no
$WM_THIRD_PARTY_DIR  .../sbh/foam/foam-extend-4.0/ThirdParty  yes      yes
-------------------------------------------------------------------------------


Checking the foam-extend env variables set on the PATH...
-------------------------------------------------------------------------------
Environment_variable Set_to_file_or_directory                Valid Path Crit
-------------------------------------------------------------------------------
$WM_PROJECT_DIR      /home/sbh/foam/foam-extend-4.0          yes  yes  yes

$FOAM_APPBIN        ...4.0/applications/bin/linux64GccDPOpt  yes  yes  yes
$FOAM_SITE_APPBIN    ...bh/foam/site/4.0/bin/linux64GccDPOpt  no        no
$FOAM_USER_APPBIN    ...4.0/applications/bin/linux64GccDPOpt  no        no
$WM_DIR              /home/sbh/foam/foam-extend-4.0/wmake    yes  yes  yes
-------------------------------------------------------------------------------


Checking the foam-extend env variables set on the LD_LIBRARY_PATH...
-------------------------------------------------------------------------------
Environment_variable Set_to_file_or_directory                Valid Path Crit
-------------------------------------------------------------------------------
$FOAM_LIBBIN        .../foam-extend-4.0/lib/linux64GccDPOpt  yes  yes  yes
$FOAM_SITE_LIBBIN    ...bh/foam/site/4.0/lib/linux64GccDPOpt  no        no
$FOAM_USER_LIBBIN    ...sbh/foam/sbh-4.0/lib/linux64GccDPOpt  no        no
$MPI_ARCH_PATH      /usr                                    yes  yes  yes
-------------------------------------------------------------------------------


Third party software
-------------------------------------------------------------------------------
Software Version  Location
-------------------------------------------------------------------------------
WARNING: gcc version does not match gcc supplied with this release of foam-extend
        Supplied version: 4.3.3
        User version    : 8.3.0
        Minimum required: 4.3.1

gcc      8.3.0   
WARNING:  Conflicting installations:
          foam-extend settings        : /bin/gcc
          current path            : /usr/bin/gcc
          CRITICAL ERROR

gzip    1.9      /usr/bin/gzip                                           
tar      1.30      /usr/bin/tar                                           
icoFoam         
WARNING:  Conflicting installations:
          foam-extend settings        : /home/sbh/foam/foam-extend-4.0/applications/bin/linux64GccDPOpt/icoFoam
          current path            :
          CRITICAL ERROR

-------------------------------------------------------------------------------


Summary
-------------------------------------------------------------------------------
Base configuration ok.

The foam installation contains 2 critical error(s).

Review the output for warning messages and consult
the installation guide for trouble shooting.

done.

Not sure what MPI_ARCH_PATH refers to - the libraries, the binaries... But DPKG says that

openmpi-bin has binaries in /usr/bin/ and

openmpi-common has txt files in /usr/share/ and

libopenmpi-dev (all 3.1.3-11) has libraries in /usr/lib/x86_64-linux-gnu/openmpi/...


Speaking of libraries, I did read that openmpi has some weird issue with $LD_LIBRARY_PATH (can't find the website at the moment), so here is that PATH;

Code:


/home/sbh/foam/sbh-4.0/lib/linux64GccDPOpt:/home/sbh/foam/site/4.0/lib/linux64GccDPOpt:/home/sbh/foam/foam-extend-4.0/lib/linux64GccDPOpt:/home/sbh/SW/Cantera/installed/lib:/usr/lib:/usr/lib/x86_64-linux-gnu

For the 2 CRITICAL ERROR from the test.... I have no idea about the second one, except that the 'foam-extend settings' was there just after a fresh git pull, so not sure why that path was listed... hard-coded? The first CRITICAL ERROR is interesting because

/bin is a symbolic link to /usr/bin, verified by ls -ld /bin.

Then, from here,

https://openfoamwiki.net/index.php/I...end-4.0/Ubuntu

I've tried all the prerequisite requirements except for gcc-5 (it's not in my repositories though I suppose I could find them somewhere if it is heavily suggested - partly why I am posting this question. Pinning various repositories is not something I'm too interested in... FrankenDebian). From here,

https://openfoamwiki.net/index.php/I...oam-extend-4.0,

I have tried the installation (I don't specifically have Ubuntu or OpenSUSE so I think I mostly try to go with Ubuntu). I've also tried the instructions (for my initial attempt of foam-extend-4.1) from this site,
https://pingpong.chalmers.se/public/...ml?language=en
but it didn't work for me.



In a fresh git pull, my etc/bashrc was left alone and my etc/prefs.sh utilized,

Code:


export QT_BIN_DIR=/usr/bin/
export WM_THIRD_PARTY_USE_BISON_27=1
#export MPI_ARCH_PATH=/usr/bin/
export WM_MPLIB=SYSTEMOPENMPI
export OPENMPI_DIR=/usr
export OPENMPI_BIN_DIR=\$OPENMPI_DIR/bin

and the errors I received found their way into ThirdParty/BUILD and pertained to bison and fseterr.c not being ported to my platform. I used APT-FILE SEARCH fseterr.c and found GNULIB, but I had it installed and current.


I found the installationTest later but earlier I did try going into the ThirdParty/rpmBuild/SOURCES/ and trying to untar different bisons I got from

https://ftp.gnu.org/gnu/bison/

and then changing their name to match 2.7.1. They all (even the 2.6.5 and others) complained of this fseterr.c problem.


Well I'll stop now as I think I need help to go further.


Thank you for reading this far!


Bret


PS. I'll gladly start over and follow someone's kind instructions!

I also did this for the logs (running Allwmake.firstInstall twice [big one first and split into parts, smaller file second as log2.gz]), as noted in



https://pingpong.chalmers.se/public/...ml?language=en


and the first error I found is;


Code:




make[3]: Entering directory '/home/sbh/foam/foam-extend-4.0/ThirdParty/rpmBuild/BUILD/bison-2.7/lib'
  CC      main.o
  CC      yyerror.o
  CC      argmatch.o
  CC      binary-io.o
  CC      bitrotate.o
  CC      c-ctype.o
  CC      c-strncasecmp.o
  CC      c-strcasecmp.o
  CC      cloexec.o
  CC      close-stream.o
  CC      closeout.o
  CC      dirname.o
  CC      basename.o
  CC      dirname-lgpl.o
  CC      basename-lgpl.o
  CC      stripslash.o
  CC      exitfail.o
  CC      fatal-signal.o
  CC      fd-hook.o
  CC      fd-safer-flag.o
  CC      dup-safer-flag.o
  CC      fopen-safer.o
  CC      hash.o
  CC      localcharset.o
  CC      lock.o
  CC      math.o
  CC      mbchar.o
  CC      mbschr.o
  CC      mbsrchr.o
  CC      mbswidth.o
  CC      mbuiter.o
  CC      pipe2.o
  CC      pipe2-safer.o
  CC      printf-frexp.o
  CC      printf-frexpl.o
  CC      progname.o
  CC      quotearg.o
  CC      sig-handler.o
  CC      spawn-pipe.o
  CC      stdio.o
  CC      strnlen1.o
  CC      threadlib.o
  CC      unistd.o
  CC      dup-safer.o
  CC      fd-safer.o
  CC      pipe-safer.o
  CC      width.o
  CC      wait-process.o
  CC      wctype-h.o
  CC      xmalloc.o
  CC      xalloc-die.o
  CC      xsize.o
  CC      xstrndup.o
  CC      get-errno.o
  CC      abitset.o
  CC      bitset.o
  CC      bitset_stats.o
  CC      bitsetv.o
  CC      ebitset.o
  CC      vbitset.o
  CC      lbitset.o
  CC      bitsetv-print.o
  CC      timevar.o
  CC      asnprintf.o
  CC      fcntl.o
  CC      fprintf.o
  CC      fseterr.o
  CC      isnand.o
  CC      isnanf.o
  CC      isnanl.o
  CC      printf.o
fseterr.c: In function 'fseterr':
fseterr.c:77:3: error: #error "Please port gnulib fseterr.c to your platform! Look at the definitions of ferror and clearerr on your system, then report this to bug-gnulib."
  #error "Please port gnulib fseterr.c to your platform! Look at the definitions of ferror and clearerr on your system, then report this to bug-gnulib."
  ^~~~~
make[3]: *** [Makefile:1895: fseterr.o] Error 1
make[3]: *** Waiting for unfinished jobs....
make[3]: Leaving directory '/home/sbh/foam/foam-extend-4.0/ThirdParty/rpmBuild/BUILD/bison-2.7/lib'
make[2]: *** [Makefile:1651: all] Error 2
make[2]: Leaving directory '/home/sbh/foam/foam-extend-4.0/ThirdParty/rpmBuild/BUILD/bison-2.7/lib'
make[1]: *** [Makefile:1532: all-recursive] Error 1
make[1]: Leaving directory '/home/sbh/foam/foam-extend-4.0/ThirdParty/rpmBuild/BUILD/bison-2.7'
make: *** [Makefile:1462: all] Error 2
error: Bad exit status from /home/sbh/foam/foam-extend-4.0/ThirdParty/rpmBuild/tmp/rpm-tmp.H2roMJ (%build)


RPM build errors:
    Bad exit status from /home/sbh/foam/foam-extend-4.0/ThirdParty/rpmBuild/tmp/rpm-tmp.H2roMJ (%build)
Installing package: bison-2.7
  Uninstalling bison-2.7 using RPM: bison-2.7-linux64GccDPOpt.x86_64
  Installing bison-2.7 using RPM file: /home/sbh/foam/foam-extend-4.0/ThirdParty/rpmBuild/RPMS/x86_64/bison-2.7-linux64GccDPOpt.x86_64.rpm
error: open of /home/sbh/foam/foam-extend-4.0/ThirdParty/rpmBuild/RPMS/x86_64/bison-2.7-linux64GccDPOpt.x86_64.rpm failed: No such file or directory
Done installing package


brett1 May 26, 2019 15:57

update: attempt after fresh git pull (link to logs [can view online] - too big ?)
 
Another edit (3rd) - I deleted all and started over, with trying a prefs.sh file from a similar case on cfd-online. The log file, from

Code:



./Allwmake.firstInstall > log.make 2>&1

shrunk from 168,20,565 to 587,573, which is still too big to upload... Is my compiler more verbose? flag maybe? If I use zpaq it will fit but I didn't see the uploader on the site accept that type of file, ie 158,526.





================================================== =



Hello, I have a Debian Testing machine,



Code:

   
Linux sbh 4.19.0-5-amd64 #1 SMP Debian 4.19.37-3 (2019-05-15) x86_64 GNU/Linux

and I pulled a Git version of the foam-extend-4.0 to try and compile (mostly following Ubuntu installation guides), e.g.,

https://openfoamwiki.net/index.php/I...oam-extend-4.0

and some ideas from questions posted on cfd online;

https://www.cfd-online.com/Forums/op...-not-root.html

https://www.cfd-online.com/Forums/op...u-18-04-a.html

Additionally, I modified the prefs.sh file (attached), and the AllMake.pre and the Allwmake.firstInstall files by simply adding on the same logging instructions I had seen wyldckat use - something like ./Allwmake > $WM_THIRD_PARTY_DIR/logfile 2>&1. It was for my own purposes because I thought it might make it easier to find the problem, especially since I have tried 'stepping through' the make files manually.

I started deleting the folder foam-extend-4.0 each time because even after using Allclean, I would find errors in different places, e.g. wmake libso finiteVolume "area" had a 'bad bool casting' complaint, or I would have some problems with gcc49.

I also saw confusing (to me at least) things like this in the output logs (attached),

Code:

 
../../gcc/defaults.h:126:24: warning: invalid suffix on literal; C++11  requires a space between literal and string macro [-Wliteral-suffix]
      fprintf ((FILE), ","HOST_WIDE_INT_PRINT_UNSIGNED",%u\n",  \
                        ^
cfns.gperf:26:14: warning: inline function 'const char* libc_name_p(const char*, unsigned int)' used but never defined
make[3]: *** [Makefile:1058: cp/except.o] Error 1
make[3]: *** Waiting for unfinished jobs....
rm gcc.pod
make[3]: Leaving directory '/home/sbh/foam/foam-extend-4.0/ThirdParty/rpmBuild/BUILD/gcc-4.9.2/objBuildDir/gcc'
make[2]: *** [Makefile:4234: all-stage1-gcc] Error 2
make[2]: Leaving directory '/home/sbh/foam/foam-extend-4.0/ThirdParty/rpmBuild/BUILD/gcc-4.9.2/objBuildDir'
make[1]: *** [Makefile:22967: stage1-bubble] Error 2
make[1]: Leaving directory '/home/sbh/foam/foam-extend-4.0/ThirdParty/rpmBuild/BUILD/gcc-4.9.2/objBuildDir'
make: *** [Makefile:901: all] Error 2
error: Bad exit status from /home/sbh/foam/foam-extend-4.0/ThirdParty/rpmBuild/tmp/rpm-tmp.gjhR8W (%build)


RPM build errors:
    Bad exit status from /home/sbh/foam/foam-extend-4.0/ThirdParty/rpmBuild/tmp/rpm-tmp.gjhR8W (%build)
Installing package: gcc-4.9.2
  Uninstalling gcc-4.9.2 using RPM: gcc-4.9.2-linux64Gcc49DPOpt.x86_64
  Installing gcc-4.9.2 using RPM file:  /home/sbh/foam/foam-extend-4.0/ThirdParty/rpmBuild/RPMS/x86_64/gcc-4.9.2-linux64Gcc49DPOpt.x86_64.rpm
error: open of  /home/sbh/foam/foam-extend-4.0/ThirdParty/rpmBuild/RPMS/x86_64/gcc-4.9.2-linux64Gcc49DPOpt.x86_64.rpm  failed: No such file or directory
Done installing package

Building cmake 3.2.2
Package name      : cmake-3.2.2
Package URL      : http://www.cmake.org/files/v3.2/cmake-3.2.2.tar.gz

where after finishing gcc-4.9, and before starting cmake-3.2.2, the message would say "RPM build errors:.."; but then at the end say "Done installing package" - so was it successful?

I had some problems attaching files due to size (just the src/Allwmake file gzipped is at 357kB - I really hope my amendments to the 2 make files didn't cause these to be too big, i.e. over 195.3kB - so here is a box.com link to view/download the files: https://app.box.com/s/dn5yh2074e4hgly9harjpmfz92ztnicr - I would fix this issue if I knew how. ), and also it seems to help (for me) to break it down some, so I added a couple additions to the two files

Allwmake.firstInstall;

Code:

 
# wmake is required for subsequent targets
( cd wmake/src && make > $WM_PROJECT_DIR/log.wmake.src 2>&1 )

# build ThirdParty sources
( cd $WM_THIRD_PARTY_DIR && ./AllMake.pre > $WM_PROJECT_DIR/log.AllMake.pre 2>&1 )

# We make sure the ThirdParty packages environment variables are up-to-date
# before compiling the rest of OpenFOAM
. $WM_PROJECT_DIR/etc/settings.sh

# build OpenFOAM libraries and applications
src/Allwmake > $WM_PROJECT_DIR/log.src.Allwmake 2>&1
applications/Allwmake > $WM_PROJECT_DIR/log.applications.Allwmake 2>&1

if [ "$1" = doc ]
then
    doc/Allwmake
fi

# build ThirdParty sources that depend on main installation
export WM_NCOMPPROCS=1
( cd $WM_THIRD_PARTY_DIR && ./AllMake.post > $WM_PROJECT_DIR/log.AllMake.post 2>&1 )

and AllMake.pre

Code:

 

# Running stage 1
./AllMake.stage1 > $WM_PROJECT_DIR/log.AllMake.stage1 2>&1

# Running stage 2
./AllMake.stage2 > $WM_PROJECT_DIR/log.AllMake.stage2 2>&1

# Running stage 3
./AllMake.stage3 > $WM_PROJECT_DIR/log.AllMake.stage3 2>&1

# Running stage 4
./AllMake.stage4 > $WM_PROJECT_DIR/log.AllMake.stage4 2>&1

so I could follow along better - especially since I have been trying to 'step through' the make system manually. I hope it didn't screw anything up - apologies if it did.

As mentioned earlier, I am amenable to starting over and following anyone's suggestions.

Thank you

brett1 June 3, 2019 17:21

Started over with a few modifications
 
2 Attachment(s)
Here is my **prefs.sh** file (the only changes from the example version):

(I tried many different bison until i had no error, and between the bounds of 2.4 & <3)

Code:

export QT_BIN_DIR=/usr/bin/
export WM_THIRD_PARTY_USE_BISON_24=1

my changed **settings.sh** file;


Code:

# Load bison
# ~~~~~~~~~~
#[ -z "$BISON_SYSTEM" ] && [ ! -z $WM_THIRD_PARTY_USE_BISON_27 ] && [ -e $WM_THIRD_PARTY_DIR/packages/bison-$
#    _foamSource $WM_THIRD_PARTY_DIR/packages/bison-2.7/platforms/$WM_OPTIONS/etc/bison-2.7.sh
#}
#[ "$FOAM_VERBOSE" -a "$PS1" ] && echo "    BISON_DIR is initialized to: $BISON_DIR"

# Load bison
# ~~~~~~~~~~
[ -z "$BISON_SYSTEM" ] && [ ! -z $WM_THIRD_PARTY_USE_BISON_24 ] && [ -e $WM_THIRD_PARTY_DIR/packages/bison-2$
    _foamSource $WM_THIRD_PARTY_DIR/packages/bison-2.4/platforms/$WM_OPTIONS/etc/bison-2.4.sh
}
[ "$FOAM_VERBOSE" -a "$PS1" ] && echo "    BISON_DIR is initialized to: $BISON_DIR"

I also "made" a SPEC file (just copied bison-2.4.7 and changed the revision to 2.4) to make bison-2.4.spec


and my **AllMake.stage1** has changes;


Code:

# bison 2.7
#
[ ! -z "$WM_THIRD_PARTY_USE_BISON_27" ] && {
    echo "Building bison 2.7"
    # You need a recent version of m4 in order to compile a recent version of bison
    ( rpm_make -p bison-2.7 -s bison-2.7.spec -u http://ftpmirror.gnu.org/bison/bison-2.7.tar.gz          )
}

# bison 2.4
#
[ ! -z "$WM_THIRD_PARTY_USE_BISON_24" ] && {
    echo "Building bison 2.4 fool!"
    ( rpm_make -p bison-2.4 -s bison-2.4.spec -u http://ftpmirror.gnu.org/bison/bison-2.4.tar.gz          )
}

I no longer have bison/fseterr.c/gnulib problems (that I know of haha), but now I have this one:


Code:

sbh@sbh:~/foam/foam-extend-4.0/src$ wmakeLnInclude foam
sbh@sbh:~/foam/foam-extend-4.0/src$ wmakeLnInclude meshTools/
sbh@sbh:~/foam/foam-extend-4.0/src$ wmakeLnInclude OSspecific//$WM_OSTYPE
sbh@sbh:~/foam/foam-extend-4.0/src$ wmake libso OSspecific/$WM_OSTYPE
'/home/sbh/foam/foam-extend-4.0/lib/linux64GccDPOpt/libOSspecific.so' is up to date.
sbh@sbh:~/foam/foam-extend-4.0/src$ wmake libso foam
SOURCE=global/global.Cver ; sed -e 's/VERSION_STRING/4.0/' -e 's/BUILD_STRING/4.0-268bb07d15d8/' $SOURCE > Make/linux64GccDPOpt/global.C; g++ -m64 -Dlinux64 -DWM_DP -Wall -Wextra -Wno-unused-parameter -Wold-style-cast -Wnon-virtual-dtor -O3  -DNoRepository -ftemplate-depth-200 -DOMPI_SKIP_MPICXX -I/home/sbh/foam/foam-extend-4.0/ThirdParty/packages/openmpi-1.8.8/platforms/linux64GccDPOpt/include    -I/home/sbh/foam/foam-extend-4.0/ThirdParty/zlib-1.2.3 -IlnInclude -I. -I/home/sbh/foam/foam-extend-4.0/src/foam/lnInclude -I/home/sbh/foam/foam-extend-4.0/src/OSspecific/POSIX/lnInclude  -fPIC -c Make/linux64GccDPOpt/global.C -o Make/linux64GccDPOpt/global.o
'/home/sbh/foam/foam-extend-4.0/lib/linux64GccDPOpt/libfoam.so' is up to date.
sbh@sbh:~/foam/foam-extend-4.0/src$ decompositionMethods/AllwmakeLnInclude
+ wmakeLnInclude decompositionMethods
+ wmakeLnInclude metisDecomp
+ wmakeLnInclude parMetisDecomp
+ wmakeLnInclude scotchDecomp
sbh@sbh:~/foam/foam-extend-4.0/src$ ls decompositionMethods/
Allwmake  AllwmakeLnInclude  decompositionMethods  metisDecomp  parMetisDecomp  scotchDecomp
sbh@sbh:~/foam/foam-extend-4.0/src$ cat decompositionMethods/Allwmake
#!/bin/sh
cd ${0%/*} || exit 1    # run from this directory
set -x

wmakeLnInclude decompositionMethods

wmake libso decompositionMethods
wmake libso metisDecomp
wmake libso parMetisDecomp
wmake libso scotchDecomp


# ----------------------------------------------------------------- end-of-file
sbh@sbh:~/foam/foam-extend-4.0/src$ cd decompositionMethods/
sbh@sbh:~/foam/foam-extend-4.0/src/decompositionMethods$ wmake libso decompositionMethods/
'/home/sbh/foam/foam-extend-4.0/lib/linux64GccDPOpt/libdecompositionMethods.so' is up to date.
sbh@sbh:~/foam/foam-extend-4.0/src/decompositionMethods$ wmake libso metisDecomp/
'/home/sbh/foam/foam-extend-4.0/lib/linux64GccDPOpt/libmetisDecomp.so' is up to date.
sbh@sbh:~/foam/foam-extend-4.0/src/decompositionMethods$ wmake libso parMetisDecomp/
SOURCE=parMetisDecomp.C ;  g++ -m64 -Dlinux64 -DWM_DP -Wall -Wextra -Wno-unused-parameter -Wold-style-cast -Wnon-virtual-dtor -O3  -DNoRepository -ftemplate-depth-200 -DOMPI_SKIP_MPICXX -I/home/sbh/foam/foam-extend-4.0/ThirdParty/packages/openmpi-1.8.8/platforms/linux64GccDPOpt/include    -I    -I../decompositionMethods/lnInclude    -I../metisDecomp/lnInclude    -I../scotchDecomp/lnInclude -IlnInclude -I. -I/home/sbh/foam/foam-extend-4.0/src/foam/lnInclude -I/home/sbh/foam/foam-extend-4.0/src/OSspecific/POSIX/lnInclude  -fPIC -c $SOURCE -o Make/linux64GccDPOpt/parMetisDecomp.o
In file included from parMetisDecomp.C:26:0:
parMetisDecomp.H:38:10: fatal error: decompositionMethod.H: No such file or directory
 #include <decompositionMethod.H>
          ^~~~~~~~~~~~~~~~~~~~~~~
compilation terminated.
make: *** [parMetisDecomp.dep:342: Make/linux64GccDPOpt/parMetisDecomp.o] Error 1

From the **AllMake.pre** file, it is from the **src/Allwmake** line. Inside that latter file, it (the error) happens at;


Code:


# Decomposition methods needed by meshTools
decompositionMethods/AllwmakeLnInclude
decompositionMethods/Allwmake

Throughout the whole build I only see 2 errors, right consecutive. Here they are with 20 lines before and after each. Erros at 3427 and 3438.


Code:

sbh@sbh:~/foam/foam-extend-4.0/src/decompositionMethods$ grep -nw ~/foam/log.src.Allwmake -e "Error" -C 20
3407-Making dependency list for source file hierarchGeomDecomp/hierarchGeomDecomp.C
3408-Making dependency list for source file simpleGeomDecomp/simpleGeomDecomp.C
3409-Making dependency list for source file patchConstrainedDecomp/patchConstrainedDecomp.C
3410-SOURCE=decompositionMethod/decompositionMethod.C ;  g++ -m64 -Dlinux64 -DWM_DP -Wall -Wextra -Wno-unused-parameter -Wold-style-cast -Wnon-virtual-dtor -O3  -DNoRepository -ftemplate-depth-200  -IlnInclude -I. -I/home/sbh/foam/foam-extend-4.0/src/foam/lnInclude -I/home/sbh/foam/foam-extend-4.0/src/OSspecific/POSIX/lnInclude  -fPIC -c $SOURCE -o Make/linux64GccDPOpt/decompositionMethod.o
3411-SOURCE=manualDecomp/manualDecomp.C ;  g++ -m64 -Dlinux64 -DWM_DP -Wall -Wextra -Wno-unused-parameter -Wold-style-cast -Wnon-virtual-dtor -O3  -DNoRepository -ftemplate-depth-200  -IlnInclude -I. -I/home/sbh/foam/foam-extend-4.0/src/foam/lnInclude -I/home/sbh/foam/foam-extend-4.0/src/OSspecific/POSIX/lnInclude  -fPIC -c $SOURCE -o Make/linux64GccDPOpt/manualDecomp.o
3412-SOURCE=geomDecomp/geomDecomp.C ;  g++ -m64 -Dlinux64 -DWM_DP -Wall -Wextra -Wno-unused-parameter -Wold-style-cast -Wnon-virtual-dtor -O3  -DNoRepository -ftemplate-depth-200  -IlnInclude -I. -I/home/sbh/foam/foam-extend-4.0/src/foam/lnInclude -I/home/sbh/foam/foam-extend-4.0/src/OSspecific/POSIX/lnInclude  -fPIC -c $SOURCE -o Make/linux64GccDPOpt/geomDecomp.o
3413-SOURCE=simpleGeomDecomp/simpleGeomDecomp.C ;  g++ -m64 -Dlinux64 -DWM_DP -Wall -Wextra -Wno-unused-parameter -Wold-style-cast -Wnon-virtual-dtor -O3  -DNoRepository -ftemplate-depth-200  -IlnInclude -I. -I/home/sbh/foam/foam-extend-4.0/src/foam/lnInclude -I/home/sbh/foam/foam-extend-4.0/src/OSspecific/POSIX/lnInclude  -fPIC -c $SOURCE -o Make/linux64GccDPOpt/simpleGeomDecomp.o
3414-SOURCE=hierarchGeomDecomp/hierarchGeomDecomp.C ;  g++ -m64 -Dlinux64 -DWM_DP -Wall -Wextra -Wno-unused-parameter -Wold-style-cast -Wnon-virtual-dtor -O3  -DNoRepository -ftemplate-depth-200  -IlnInclude -I. -I/home/sbh/foam/foam-extend-4.0/src/foam/lnInclude -I/home/sbh/foam/foam-extend-4.0/src/OSspecific/POSIX/lnInclude  -fPIC -c $SOURCE -o Make/linux64GccDPOpt/hierarchGeomDecomp.o
3415-SOURCE=patchConstrainedDecomp/patchConstrainedDecomp.C ;  g++ -m64 -Dlinux64 -DWM_DP -Wall -Wextra -Wno-unused-parameter -Wold-style-cast -Wnon-virtual-dtor -O3  -DNoRepository -ftemplate-depth-200  -IlnInclude -I. -I/home/sbh/foam/foam-extend-4.0/src/foam/lnInclude -I/home/sbh/foam/foam-extend-4.0/src/OSspecific/POSIX/lnInclude  -fPIC -c $SOURCE -o Make/linux64GccDPOpt/patchConstrainedDecomp.o
3416-'/home/sbh/foam/foam-extend-4.0/lib/linux64GccDPOpt/libdecompositionMethods.so' is up to date.
3417-+ wmake libso metisDecomp
3418-wmakeLnInclude: linking include files to ./lnInclude
3419-Making dependency list for source file metisDecomp.C
3420-could not open file metis.h for source file metisDecomp.C
3421-SOURCE=metisDecomp.C ;  g++ -m64 -Dlinux64 -DWM_DP -Wall -Wextra -Wno-unused-parameter -Wold-style-cast -Wnon-virtual-dtor -O3  -DNoRepository -ftemplate-depth-200 -I    -I../decompositionMethods/lnInclude    -I../scotchDecomp/lnInclude -IlnInclude -I. -I/home/sbh/foam/foam-extend-4.0/src/foam/lnInclude -I/home/sbh/foam/foam-extend-4.0/src/OSspecific/POSIX/lnInclude  -fPIC -c $SOURCE -o Make/linux64GccDPOpt/metisDecomp.o
3422-In file included from metisDecomp.C:26:0:
3423-metisDecomp.H:38:10: fatal error: decompositionMethod.H: No such file or directory
3424- #include "decompositionMethod.H"
3425-          ^~~~~~~~~~~~~~~~~~~~~~~
3426-compilation terminated.
3427:make: *** [metisDecomp.dep:319: Make/linux64GccDPOpt/metisDecomp.o] Error 1
3428-+ wmake libso parMetisDecomp
3429-wmakeLnInclude: linking include files to ./lnInclude
3430-Making dependency list for source file parMetisDecomp.C
3431-could not open file parmetis.h for source file parMetisDecomp.C
3432-SOURCE=parMetisDecomp.C ;  g++ -m64 -Dlinux64 -DWM_DP -Wall -Wextra -Wno-unused-parameter -Wold-style-cast -Wnon-virtual-dtor -O3  -DNoRepository -ftemplate-depth-200 -DOMPI_SKIP_MPICXX -I/home/sbh/foam/foam-extend-4.0/ThirdParty/packages/openmpi-1.8.8/platforms/linux64GccDPOpt/include    -I    -I../decompositionMethods/lnInclude    -I../metisDecomp/lnInclude    -I../scotchDecomp/lnInclude -IlnInclude -I. -I/home/sbh/foam/foam-extend-4.0/src/foam/lnInclude -I/home/sbh/foam/foam-extend-4.0/src/OSspecific/POSIX/lnInclude  -fPIC -c $SOURCE -o Make/linux64GccDPOpt/parMetisDecomp.o
3433-In file included from parMetisDecomp.C:26:0:
3434-parMetisDecomp.H:37:10: fatal error: decompositionMethod.H: No such file or directory
3435- #include "decompositionMethod.H"
3436-          ^~~~~~~~~~~~~~~~~~~~~~~
3437-compilation terminated.
3438:make: *** [parMetisDecomp.dep:342: Make/linux64GccDPOpt/parMetisDecomp.o] Error 1
3439-+ wmake libso scotchDecomp
3440-wmakeLnInclude: linking include files to ./lnInclude
3441-Making dependency list for source file scotchDecomp/scotchDecomp.C
3442-Making dependency list for source file engineScotchDecomp/engineScotchDecomp.C
3443-SOURCE=scotchDecomp/scotchDecomp.C ;  g++ -m64 -Dlinux64 -DWM_DP -Wall -Wextra -Wno-unused-parameter -Wold-style-cast -Wnon-virtual-dtor -O3  -DNoRepository -ftemplate-depth-200 -I/home/sbh/foam/foam-extend-4.0/ThirdParty/packages/scotch-6.0.4/platforms/linux64GccDPOpt/include    -I../decompositionMethods/lnInclude -IlnInclude -I. -I/home/sbh/foam/foam-extend-4.0/src/foam/lnInclude -I/home/sbh/foam/foam-extend-4.0/src/OSspecific/POSIX/lnInclude  -fPIC -c $SOURCE -o Make/linux64GccDPOpt/scotchDecomp.o
3444-SOURCE=engineScotchDecomp/engineScotchDecomp.C ;  g++ -m64 -Dlinux64 -DWM_DP -Wall -Wextra -Wno-unused-parameter -Wold-style-cast -Wnon-virtual-dtor -O3  -DNoRepository -ftemplate-depth-200 -I/home/sbh/foam/foam-extend-4.0/ThirdParty/packages/scotch-6.0.4/platforms/linux64GccDPOpt/include    -I../decompositionMethods/lnInclude -IlnInclude -I. -I/home/sbh/foam/foam-extend-4.0/src/foam/lnInclude -I/home/sbh/foam/foam-extend-4.0/src/OSspecific/POSIX/lnInclude  -fPIC -c $SOURCE -o Make/linux64GccDPOpt/engineScotchDecomp.o
3445-'/home/sbh/foam/foam-extend-4.0/lib/linux64GccDPOpt/libscotchDecomp.so' is up to date.
3446-+ wmake libso lagrangian/basic
3447-wmakeLnInclude: linking include files to ./lnInclude
3448-Making dependency list for source file passiveParticle/passiveParticleCloud.C
3449-Making dependency list for source file indexedParticle/indexedParticleCloud.C
3450-SOURCE=passiveParticle/passiveParticleCloud.C ;  g++ -m64 -Dlinux64 -DWM_DP -Wall -Wextra -Wno-unused-parameter -Wold-style-cast -Wnon-virtual-dtor -O3  -DNoRepository -ftemplate-depth-200  -IlnInclude -I. -I/home/sbh/foam/foam-extend-4.0/src/foam/lnInclude -I/home/sbh/foam/foam-extend-4.0/src/OSspecific/POSIX/lnInclude  -fPIC -c $SOURCE -o Make/linux64GccDPOpt/passiveParticleCloud.o
3451-SOURCE=indexedParticle/indexedParticleCloud.C ;  g++ -m64 -Dlinux64 -DWM_DP -Wall -Wextra -Wno-unused-parameter -Wold-style-cast -Wnon-virtual-dtor -O3  -DNoRepository -ftemplate-depth-200  -IlnInclude -I. -I/home/sbh/foam/foam-extend-4.0/src/foam/lnInclude -I/home/sbh/foam/foam-extend-4.0/src/OSspecific/POSIX/lnInclude  -fPIC -c $SOURCE -o Make/linux64GccDPOpt/indexedParticleCloud.o
3452-'/home/sbh/foam/foam-extend-4.0/lib/linux64GccDPOpt/liblagrangian.so' is up to date.
3453-+ wmake libso edgeMesh
3454-wmakeLnInclude: linking include files to ./lnInclude
3455-Making dependency list for source file edgeMesh.C
3456-Making dependency list for source file edgeMeshIO.C
3457-Making dependency list for source file featureEdgeMesh.C
3458-SOURCE=edgeMesh.C ;  g++ -m64 -Dlinux64 -DWM_DP -Wall -Wextra -Wno-unused-parameter -Wold-style-cast -Wnon-virtual-dtor -O3  -DNoRepository -ftemplate-depth-200  -IlnInclude -I. -I/home/sbh/foam/foam-extend-4.0/src/foam/lnInclude -I/home/sbh/foam/foam-extend-4.0/src/OSspecific/POSIX/lnInclude  -fPIC -c $SOURCE -o Make/linux64GccDPOpt/edgeMesh.o

I also attached the log file from running **src/Allwmake** - on my editor, the 2 errors are in line ranges 3417-3446.


Thank you.


PS. I also changed the url to pull parmetis-3.0.4.tar.gz. as the umn.edu site was down. Hope this isn't the source of the error, but the ubuntu package repository says it is the "original"...

https://www.isitdownrightnow.com/gla...c.umn.edu.html



From **AllMake.stage3**;


Code:

# ParMetis
if [ -z "$PARMETIS_SYSTEM" ]
then
    # ParMetis 4.0.3
    #
    [ ! -z "$WM_THIRD_PARTY_USE_PARMETIS_403" ] && {
        echo "Building ParMetis 4.0.3"
        ( rpm_make -p parmetis-4.0.3 -s parmetis-4.0.3.spec -u http://archive.ubuntu.com/ubuntu/pool/multive$
#      ( rpm_make -p parmetis-4.0.3 -s parmetis-4.0.3.spec -u http://glaros.dtc.umn.edu/gkhome/fetch/sw/par$
    }
else
    echo "Using system installed ParMetis"
    echo ""
fi


wyldckat June 7, 2019 18:31

Greetings brett1,

:eek: Wow, that's a hell of a fight! I didn't study what you've done specifically so far, but I'll address at least the latest post.
And I have no idea if GCC 8 can be used with foam-extend 4.0 or not, but I believe that foam-extend 4.1 (which is development) should be compatible with it... but first let's hold off on that...

... Because the "src" folder seems to have built mostly without errors. Even if Scotch and Metis are not compiled, you can still mostly use foam-extend 4.0 as it is right now, namely if you proceed with building the "applications" folder and build the rest. The downside is having to use the other less dynamic decomposition methods, such as "simple" and "hierarchical"...

The problem with "stage3" is essentially this:
Code:

error: unpacking of archive failed on file /usr/lib/.build-id: cpio: mkdir failed - Inappropriate ioctl for device
It's not able to install when using the RPM files due to some weird reason that I can't find online a quick answer for it, however, you can still use the TGZ files that it was able to generate.
Please try using the following commands to unpack said TGZ files:
Code:

cd $WM_THIRD_PARTY
for file in rpmBuild/TGZS/x86_64/*.tgz; do tar -xf $file; done

Then update the foam-extend shell environment by running:
Code:

source $WM_PROJECT_DIR/etc/bashrc
Then try proceeding with running the main Allwmake, namely:
Code:

foam
./Allwmake > log.make 2>&1

Hopefully it will finish up building the missing decomposition libraries for Metis and Scotch and then build the "applications" folder without problems.


If by any chance you want to try and build the ongoing development version 4.1, then run:
Code:

cd ~
mkdir foam
cd foam
git clone git://git.code.sf.net/p/foam-extend/foam-extend-4.1 foam-extend-4.1
cd foam-extend-4.1
git checkout nextRelease

Then proceed with the installation instructions you've done so far.

Best regards,
Bruno

brett1 June 15, 2019 12:35

resolved foam-extend-4.0 & 4.1 on Debian Testing
 
3 Attachment(s)
Hello and apologies for the delay - i can only work on this on weekends.


So summarily, the prescription that Bruno suggested worked fine - on both 4.0 & 4.1. There were some PyFoam associated SyntaxError but so far the first example works fine.


It is noteworthy that the 4.1 version has this exact error:



https://www.cfd-online.com/Forums/op...ary-print.html


and it was easily resolved by (my only attempt) adding the pFinal{} to the system/fvSolution file. I have not studied foam enough to begin to understand why this error occurs but not in 4.0. Hopefully errors for future examples or my own work will be as easily resolved. Here is the modified system/fvSolution file;


Code:

/*--------------------------------*- C++ -*----------------------------------*\
 2 | =========                |                                                |
 3 | \\      /  F ield        | foam-extend: Open Source CFD                    |
 4 |  \\    /  O peration    | Version:    4.1                                |
 5 |  \\  /    A nd          | Web:        http://www.foam-extend.org        |
 6 |    \\/    M anipulation  |                                                |
 7 \*---------------------------------------------------------------------------*/
 8 FoamFile
 9 {
10    version    2.0;
11    format      ascii;
12    class      dictionary;
13    object      fvSolution;
14 }
15 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
16
17 solvers
18 {
19    p
20    {
21        solver          PCG;
22        preconditioner  DIC;
23        tolerance        1e-06;
24        relTol          0;
25    }
26
27    pFinal
28    {
29        solver          PCG;
30        preconditioner  DIC;
31        tolerance        1e-06;
32        relTol          0;
33    }
34
35    U
36    {
37        solver          BiCGStab;
38        preconditioner  DILU;
39        tolerance        1e-05;
40        relTol          0;
41    }
42 }
43
44 PISO
45 {
46    nCorrectors    2;
47    nNonOrthogonalCorrectors 0;
48    pRefCell        0;
49    pRefValue      0;
50 }
51
52
53 // ************************************************************************* //
54

(the numbers are from my bash)


Thanks again Bruno!


PS log... & log2... are only up to leaving the ThirdParty work, before and after Bruno's prescription. log3... is the complete Allwmake.firstInstall


PPS I did install gcc-7 and friends - from oldstable

Saleh Abuhanieh June 16, 2019 04:14

Install FOAM-extend-4.1 (actually nextRelease branch of 4.0)
 
Hi,


I will recommend the below installation guide prepared by Chalmers university:
https://pingpong.chalmers.se/public/...o?item=4764601


Regards,

wyldckat June 16, 2019 14:39

Quick answers:
Quote:

Originally Posted by brett1 (Post 736353)
It is noteworthy that the 4.1 version has this exact error:

https://www.cfd-online.com/Forums/op...ary-print.html

and it was easily resolved by (my only attempt) adding the pFinal{} to the system/fvSolution file. I have not studied foam enough to begin to understand why this error occurs but not in 4.0. Hopefully errors for future examples or my own work will be as easily resolved. Here is the modified system/fvSolution file;

In foam-extend 4.1 is likely being updated to follow the same conventions as the latest OpenFOAM versions.



Quote:

Originally Posted by brett1 (Post 736353)
Thanks again Bruno!


PS log... & log2... are only up to leaving the ThirdParty work, before and after Bruno's prescription. log3... is the complete Allwmake.firstInstall


PPS I did install gcc-7 and friends - from oldstable

You're welcome!

The only thing that wasn't build was swak4Foam, but that is likely because Mercurial (Hg) wasn't installed. But it's only needed if you're planning on using swak4Foam.

brett1 June 16, 2019 16:47

swaq4Foam
 
Hello,

Thanks for looking at it again!



I actually do have mercurial installed.... 4.8.2-1. (not sure of this .hg file yet...) I am interested in using that library so, since it is in ThirdParty I think I'll get the source in tgz format and try your trick again.



I'll post my attempts and hopefully positive result,

Thanks,

Brett


EDIT


I notice from AllMake.stage5 that it pulls a clone, not a tgz for swaq4Foam. Anyways, will post soonish...

brett1 June 16, 2019 23:01

swaq4Foam
 
2 Attachment(s)
Hello again,



Apparently (maybe a Debian thing) mercurial didn't have the "server" packages installed, just a "bin" and "common"...


So the only errors I saw were two regarding something 'HUGE' - here it is in the log file at around line 2350 & 2353. Haven't spent much time seeing if it is of concern yet... ?


Code:

Objects/unitCylinderSearchableSurface.C: In member function ‘void Foam::unitCylinderSearchableSurface::findLineAll(const point&, const point&, Foam::List<Foam::PointIndexHit<Foam::Vector<double> > >&) const’:
Objects/unitCylinderSearchableSurface.C:129:27: error: ‘HUGE’ was not declared in this scope
        mag(topIntersect)>HUGE
                          ^~~~
Objects/unitCylinderSearchableSurface.C:141:30: error: ‘HUGE’ was not declared in this scope
        mag(bottomIntersect)>HUGE
                              ^~~~
make: *** [Objects/unitCylinderSearchableSurface.dep:282: Make/linux64GccDPInt32Opt/unitCylinderSearchableSurface.o] Error 1
wmakeLnInclude: linking include files to ./lnInclude

I sourced bashrc and ran it again (log2..) and it seems fine. Will continue to run samples etc.


Thanks
Brett

XJ_Wang September 30, 2019 22:36

Quote:

Originally Posted by brett1 (Post 736427)
Hello again,



Apparently (maybe a Debian thing) mercurial didn't have the "server" packages installed, just a "bin" and "common"...


So the only errors I saw were two regarding something 'HUGE' - here it is in the log file at around line 2350 & 2353. Haven't spent much time seeing if it is of concern yet... ?


Code:

Objects/unitCylinderSearchableSurface.C: In member function ‘void Foam::unitCylinderSearchableSurface::findLineAll(const point&, const point&, Foam::List<Foam::PointIndexHit<Foam::Vector<double> > >&) const’:
Objects/unitCylinderSearchableSurface.C:129:27: error: ‘HUGE’ was not declared in this scope
        mag(topIntersect)>HUGE
                          ^~~~
Objects/unitCylinderSearchableSurface.C:141:30: error: ‘HUGE’ was not declared in this scope
        mag(bottomIntersect)>HUGE
                              ^~~~
make: *** [Objects/unitCylinderSearchableSurface.dep:282: Make/linux64GccDPInt32Opt/unitCylinderSearchableSurface.o] Error 1
wmakeLnInclude: linking include files to ./lnInclude

I sourced bashrc and ran it again (log2..) and it seems fine. Will continue to run samples etc.


Thanks
Brett

I encountered the same problem and haven't solved it.

https://www.cfd-online.com/Forums/op...tml#post745817

This is what gschaider replied.

I hope it will be helpful.

Best wishes.
Xiangjie


All times are GMT -4. The time now is 15:11.