Update to CFDEM 2.5.1: compile error

Submitted by keepfit on Mon, 02/25/2013 - 01:12

While compiling CFDEM 2.5.1, there are many error info when comes to "compile solvers"

---> mkdir: cannot create directory `': No such file or directory......

..........
removing all .dep files ...
Making dependency list for source file cfdemPostproc.C
could not open file RASModel.H for source file cfdemPostproc.C
SOURCE=cfdemPostproc.C ; g++ -m32 -Dlinux -DWM_DP -Wall -Wextra -Wno-unused-parameter -Wold-style-cast -O3 -DNoRepository -ftemplate-depth-100 -I/home/dao/OpenFOAM/OpenFOAM-2.1.1/src/turbulenceModels/incompressible/turbulenceModel -I/home/dao/OpenFOAM/OpenFOAM-2.1.1/src/transportModels -I/home/dao/OpenFOAM/OpenFOAM-2.1.1/src/transportModels/incompressible/singlePhaseTransportModel -I/home/dao/OpenFOAM/OpenFOAM-2.1.1/src/finiteVolume/lnInclude -I/home/dao/CFDEM/CFDEMcoupling-PUBLIC-2.1.1/src/lagrangian/cfdemParticle/lnInclude -I/home/dao/OpenFOAM/OpenFOAM-2.1.1/src/meshTools/lnInclude -IlnInclude -I. -I/home/dao/OpenFOAM/OpenFOAM-2.1.1/src/OpenFOAM/lnInclude -I/home/dao/OpenFOAM/OpenFOAM-2.1.1/src/OSspecific/POSIX/lnInclude -fPIC -c $SOURCE -o Make/linuxGccDPOpt/cfdemPostproc.o
In file included from cfdemPostproc.C:44:0:
/home/dao/CFDEM/CFDEMcoupling-PUBLIC-2.1.1/src/lagrangian/cfdemParticle/lnInclude/forceModel.H:137:34: warning: type qualifiers ignored on function return type [-Wignored-qualifiers]
/home/dao/CFDEM/CFDEMcoupling-PUBLIC-2.1.1/src/lagrangian/cfdemParticle/lnInclude/forceModel.H:139:37: warning: type qualifiers ignored on function return type [-Wignored-qualifiers]
mkdir: cannot create directory `': No such file or directory
make: *** [/cfdemPostproc] Error 1
Note: the list of utilities compiled might be incomplete.
...

____________________________________

The directory `' seems not existing.

So how to figure this out?

Cheers,
David

eddie | Mon, 02/25/2013 - 01:16

It seems there is any syntax mistake. Did you modify any installation related file?

Research Assistant,
Mechanical and Aerospace Engineering,
University of Missouri - Columbia, USA

keepfit | Mon, 02/25/2013 - 01:26

no, I just downloaded the src file via "git clone git://github.com/CFDEMproject/CFDEMcoupling-PUBLIC.git CFDEMcoupling-PUBLIC-$WM_PROJECT_VERSION"

and the old .bashrc setting.

Maybe I should go back to CFDEM 2.5, but could not find a link to get old SRC files.

cgoniva's picture

cgoniva | Wed, 02/27/2013 - 19:33

Hi,

I've seen a similar error ...
please try to opne a new terminal, change to the solver path and do manually:

rmdepall
wclean
wmake

please keep us posted about the progress.
Cheers,
Chris

AnnetteV | Wed, 07/09/2014 - 20:55

Hi Chris,

Was wondering if you could help - I am experiencing the same error. I am attempting to compile CFDEM 2.7.1 but I get the same error:

mkdir: cannot create directory `': No such file or directory
make: *** [/cfdemSolverIB] Error 1

I tried the alternate method you proposed (go to solver path -> rmdepall -> wclean -> wmake) but I get the same error.
I followed the installation instructions and have repeated the process twice with no resolution to the problem.

Any help would be greatly appreciated!
Thanks!
Annette

cgoniva's picture

cgoniva | Wed, 07/16/2014 - 20:25

Hi Annette,

could you please tell us what is the output of:
cfdemSysTest

could you successfully compile the src directory, or is it just the solvers which fail to compile?

can you compile a std OF solver (go to the dir, do rmdepall, wclean, wmake)

Cheers,
Chris

AnnetteV | Thu, 07/17/2014 - 19:31

Hi Chris,

The cfdemSysTest results are as shown:
check if paths are set correctly
valid:yes critical:yes - $CFDEM_PROJECT_DIR = /home/annette/CFDEM/CFDEMcoupling-PUBLIC-2.3.x
valid:yes critical:no - $CFDEM_PROJECT_USER_DIR = /home/annette/CFDEM/annette-PUBLIC-2.3.x
valid:yes critical:yes - $CFDEM_SRC_DIR = /home/annette/CFDEM/CFDEMcoupling-PUBLIC-2.3.x/src
valid:yes critical:yes - $CFDEM_SOLVER_DIR = /home/annette/CFDEM/CFDEMcoupling-PUBLIC-2.3.x/applications/solvers
valid:yes critical:yes - $CFDEM_TUT_DIR = /home/annette/CFDEM/CFDEMcoupling-PUBLIC-2.3.x/tutorials
valid:yes critical:yes - $CFDEM_LIGGGHTS_SRC_DIR = /home/annette/LIGGGHTS/LIGGGHTS-PUBLIC/src
valid:yes critical:yes - $CFDEM_LPP_DIR = /home/annette/LIGGGHTS/mylpp/src
valid:NO critical:no - $CFDEM_PIZZA_DIR = /home/annette/LIGGGHTS/PIZZA/gran_pizza_17Aug10/src does not exist
valid:yes critical:no - $CFDEM_TEST_HARNESS_PATH = /home/annette/CFDEM/annette-PUBLIC-2.3.x/log/logFilesCFDEM-PUBLIC-2.3.x

library names
$CFDEM_LIGGGHTS_LIB_NAME = lmp_fedora_fpic
$CFDEM_LIB_NAME = lagrangianCFDEM-PUBLIC-2.3.x
$LD_LIBRARY_PATH = /usr/lib64/openmpi/lib/:/home/annette/OpenFOAM/ThirdParty-2.3.x/platforms/linuxGcc/gperftools-svn/lib:/home/annette/OpenFOAM/ThirdParty-2.3.x/platforms/linuxGcc/ParaView-4.1.0/lib/paraview-4.1:/home/annette/OpenFOAM/OpenFOAM-2.3.x/platforms/linuxGccDPOpt/lib/openmpi-1.6.5:/home/annette/OpenFOAM/ThirdParty-2.3.x/platforms/linuxGccDPOpt/lib/openmpi-1.6.5:/home/annette/OpenFOAM/ThirdParty-2.3.x/platforms/linuxGcc/openmpi-1.6.5/lib:/home/annette/OpenFOAM/annette-2.3.x/platforms/linuxGccDPOpt/lib:/home/annette/OpenFOAM/site/2.3.x/platforms/linuxGccDPOpt/lib:/home/annette/OpenFOAM/OpenFOAM-2.3.x/platforms/linuxGccDPOpt/lib:/home/annette/OpenFOAM/ThirdParty-2.3.x/platforms/linuxGccDPOpt/lib:/home/annette/OpenFOAM/OpenFOAM-2.3.x/platforms/linuxGccDPOpt/lib/dummy
$WM_NCOMPPROCS =
*******************
g++:
/usr/bin/g++
g++ (Ubuntu/Linaro 4.6.3-1ubuntu5) 4.6.3
Copyright (C) 2011 Free Software Foundation, Inc.
This is free software; see the source for copying conditions. There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

gcc:
/usr/bin/gcc
gcc (Ubuntu/Linaro 4.6.3-1ubuntu5) 4.6.3
Copyright (C) 2011 Free Software Foundation, Inc.
This is free software; see the source for copying conditions. There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

mpic++:
/home/annette/OpenFOAM/ThirdParty-2.3.x/platforms/linuxGcc/openmpi-1.6.5/bin/mpic++
--------------------------------------------------------------------------
The Open MPI wrapper compiler was unable to find the specified compiler
no in your PATH.

Note that this compiler was either specified at configure time or in
one of several possible environment variables.
--------------------------------------------------------------------------
mpirun:
/home/annette/OpenFOAM/ThirdParty-2.3.x/platforms/linuxGcc/openmpi-1.6.5/bin/mpirun
mpirun (Open MPI) 1.6.5

When I attempted to compile the coupling, the source directory was copiled successfully. The first issue I had when running the full compile was with cfdemPostproc in the applications/utilities. And then attempting the solvers on their own also resulted in the same error.

Also I was able to compile pisoFoam with no issues:
Making dependency list for source file pisoFoam.C
SOURCE=pisoFoam.C ; g++ -m32 -Dlinux -DWM_DP -Wall -Wextra -Wno-unused-parameter -Wold-style-cast -O3 -DNoRepository -ftemplate-depth-100 -I/home/annette/OpenFOAM/OpenFOAM-2.3.x/src/turbulenceModels/incompressible/turbulenceModel -I/home/annette/OpenFOAM/OpenFOAM-2.3.x/src/transportModels -I/home/annette/OpenFOAM/OpenFOAM-2.3.x/src/transportModels/incompressible/singlePhaseTransportModel -I/home/annette/OpenFOAM/OpenFOAM-2.3.x/src/finiteVolume/lnInclude -IlnInclude -I. -I/home/annette/OpenFOAM/OpenFOAM-2.3.x/src/OpenFOAM/lnInclude -I/home/annette/OpenFOAM/OpenFOAM-2.3.x/src/OSspecific/POSIX/lnInclude -fPIC -c $SOURCE -o Make/linuxGccDPOpt/pisoFoam.o
/home/annette/OpenFOAM/OpenFOAM-2.3.x/src/finiteVolume/lnInclude/readPISOControls.H: In function ‘int main(int, char**)’:
/home/annette/OpenFOAM/OpenFOAM-2.3.x/src/finiteVolume/lnInclude/readPISOControls.H:3:15: warning: unused variable ‘nOuterCorr’ [-Wunused-variable]
/home/annette/OpenFOAM/OpenFOAM-2.3.x/src/finiteVolume/lnInclude/readPISOControls.H:15:16: warning: unused variable ‘transonic’ [-Wunused-variable]
g++ -m32 -Dlinux -DWM_DP -Wall -Wextra -Wno-unused-parameter -Wold-style-cast -O3 -DNoRepository -ftemplate-depth-100 -I/home/annette/OpenFOAM/OpenFOAM-2.3.x/src/turbulenceModels/incompressible/turbulenceModel -I/home/annette/OpenFOAM/OpenFOAM-2.3.x/src/transportModels -I/home/annette/OpenFOAM/OpenFOAM-2.3.x/src/transportModels/incompressible/singlePhaseTransportModel -I/home/annette/OpenFOAM/OpenFOAM-2.3.x/src/finiteVolume/lnInclude -IlnInclude -I. -I/home/annette/OpenFOAM/OpenFOAM-2.3.x/src/OpenFOAM/lnInclude -I/home/annette/OpenFOAM/OpenFOAM-2.3.x/src/OSspecific/POSIX/lnInclude -fPIC -Xlinker --add-needed -Xlinker --no-as-needed Make/linuxGccDPOpt/pisoFoam.o -L/home/annette/OpenFOAM/OpenFOAM-2.3.x/platforms/linuxGccDPOpt/lib \
-lincompressibleTurbulenceModel -lincompressibleRASModels -lincompressibleLESModels -lincompressibleTransportModels -lfiniteVolume -lmeshTools -lOpenFOAM -ldl -lm -o /home/annette/OpenFOAM/OpenFOAM-2.3.x/platforms/linuxGccDPOpt/bin/pisoFoam

Thanks!
Annette

AnnetteV | Fri, 07/18/2014 - 15:44

Hi Chris,

After I posted this, I saw the error in the cfdemSysTest results for mpic++. I have fixed it now, so the output for that section of the cfdemSysTest output is:

mpic++:
/home/annette/OpenFOAM/ThirdParty-2.3.x/platforms/linuxGcc/openmpi-1.6.5/bin/mpic++
g++ (Ubuntu/Linaro 4.6.3-1ubuntu5) 4.6.3
Copyright (C) 2011 Free Software Foundation, Inc.
This is free software; see the source for copying conditions. There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

But the same error as before (mkdir: cannot create directory) is returned when I attempt to compile the CFDEM solvers.

Thanks!
Annette

keepfit | Fri, 07/18/2014 - 17:35

Hi Annette,

as the OpenFoam version is 2.3.x, it might not be compatible to the latest version CFDEM. The official OpenFOAM 2.2.2 source code is a good choice.

cheers,
David

AnnetteV | Fri, 07/18/2014 - 17:47

Hi David,

Thanks for the response. I previously used OpenFOAM 2.2.x (was thinking along the same lines as you that the new openfoam was causing the error). However, when compiling the coupling the same error occured.

Thanks!
Annette

cgoniva's picture

cgoniva | Tue, 07/22/2014 - 10:00

Hi Annette,

so what happens if you try to compile icoFoam?

Cheers,
Chris

AnnetteV | Tue, 07/22/2014 - 20:43

Hi Chris,

The compilation of icoFoam does not appear to have any issues:
annette@Ubuntu:~/OpenFOAM/OpenFOAM-2.3.x/applications/solvers/incompressible/icoFoam$ wmake
Making dependency list for source file icoFoam.C
SOURCE=icoFoam.C ; g++ -m32 -Dlinux -DWM_DP -Wall -Wextra -Wno-unused-parameter -Wold-style-cast -O3 -DNoRepository -ftemplate-depth-100 -I/home/annette/OpenFOAM/OpenFOAM-2.3.x/src/finiteVolume/lnInclude -I/home/annette/OpenFOAM/OpenFOAM-2.3.x/src/sampling/lnInclude -IlnInclude -I. -I/home/annette/OpenFOAM/OpenFOAM-2.3.x/src/OpenFOAM/lnInclude -I/home/annette/OpenFOAM/OpenFOAM-2.3.x/src/OSspecific/POSIX/lnInclude -fPIC -c $SOURCE -o Make/linuxGccDPOpt/icoFoam.o
/home/annette/OpenFOAM/OpenFOAM-2.3.x/src/finiteVolume/lnInclude/readPISOControls.H: In function ‘int main(int, char**)’:
/home/annette/OpenFOAM/OpenFOAM-2.3.x/src/finiteVolume/lnInclude/readPISOControls.H:3:15: warning: unused variable ‘nOuterCorr’ [-Wunused-variable]
/home/annette/OpenFOAM/OpenFOAM-2.3.x/src/finiteVolume/lnInclude/readPISOControls.H:12:16: warning: unused variable ‘momentumPredictor’ [-Wunused-variable]
/home/annette/OpenFOAM/OpenFOAM-2.3.x/src/finiteVolume/lnInclude/readPISOControls.H:15:16: warning: unused variable ‘transonic’ [-Wunused-variable]
g++ -m32 -Dlinux -DWM_DP -Wall -Wextra -Wno-unused-parameter -Wold-style-cast -O3 -DNoRepository -ftemplate-depth-100 -I/home/annette/OpenFOAM/OpenFOAM-2.3.x/src/finiteVolume/lnInclude -I/home/annette/OpenFOAM/OpenFOAM-2.3.x/src/sampling/lnInclude -IlnInclude -I. -I/home/annette/OpenFOAM/OpenFOAM-2.3.x/src/OpenFOAM/lnInclude -I/home/annette/OpenFOAM/OpenFOAM-2.3.x/src/OSspecific/POSIX/lnInclude -fPIC -Xlinker --add-needed -Xlinker --no-as-needed Make/linuxGccDPOpt/icoFoam.o -L/home/annette/OpenFOAM/OpenFOAM-2.3.x/platforms/linuxGccDPOpt/lib \
-lfiniteVolume -lsampling -lOpenFOAM -ldl -lm -o /home/annette/OpenFOAM/OpenFOAM-2.3.x/platforms/linuxGccDPOpt/bin/icoFoam

Thanks!
Annette

AnnetteV | Tue, 07/22/2014 - 22:35

Hi Chris,

I looked more into the compiling of the CFDEM src directory and it appears it is throwing the same error. When using cfdemCompCFDEM the error was output and then the solver compilation began, so I didn't notice the error right away. I went back and attempted to just build the src directory and the result is below:

SOURCE=subModels/smoothingModel/constDiffSmoothing/constDiffSmoothing.C ; g++ -m32 -Dlinux -DWM_DP -Wall -Wextra -Wno-unused-parameter -Wold-style-cast -O3 -DNoRepository -ftemplate-depth-100 -DOMPI_SKIP_MPICXX -I/home/annette/OpenFOAM/ThirdParty-2.3.x/platforms/linuxGcc/openmpi-1.6.5/include -I ./cfdemParticle -I/home/annette/OpenFOAM/OpenFOAM-2.3.x/src/finiteVolume/lnInclude -I/home/annette/OpenFOAM/OpenFOAM-2.3.x/src/transportModels -I/home/annette/OpenFOAM/OpenFOAM-2.3.x/src/turbulenceModels/incompressible/turbulenceModel -I/home/annette/OpenFOAM/OpenFOAM-2.3.x/src/meshTools/lnInclude -I/home/annette/OpenFOAM/OpenFOAM-2.3.x/src/lagrangian/basic/lnInclude -I/home/annette/OpenFOAM/OpenFOAM-2.3.x/src/OpenFOAM/containers/HashTables/labelHashSet -I/home/annette/LIGGGHTS/LIGGGHTS-PUBLIC/src -I/home/annette/CFDEM/CFDEMcoupling-PUBLIC-2.3.x/src/cfdTools -IlnInclude -I. -I/home/annette/OpenFOAM/OpenFOAM-2.3.x/src/OpenFOAM/lnInclude -I/home/annette/OpenFOAM/OpenFOAM-2.3.x/src/OSspecific/POSIX/lnInclude -fPIC -c $SOURCE -o Make/linuxGccDPOpt/constDiffSmoothing.o
mkdir: cannot create directory `': No such file or directory
make: *** [/liblagrangianCFDEM-PUBLIC-2.3.x.so] Error 1

Thanks again for the help!
Annette

AnnetteV | Thu, 07/24/2014 - 22:01

Hi Chris,

I can't see how it can be a permissions issue. From that link it looks like the "Permission Denied" is always output when there is a permission issue. In this case it looks like something in the code is trying to create a directory with no name... I'm trying to look into the sequence of the compiling to find where the error occurs, but no luck so far. I have looked through the OpenFoam documentation on wmake as a guide but it is not very specific on the compilation order. The error I am receiving appears to occur after the 'files' file in wmake is executed (messing a bit with this file revealed that the error definitely is not caused by anything in the file, but whatever is compiled afterwards). Do you have the information of what occurs next in the compilation?

Thanks!
Annette

AnnetteV | Fri, 07/25/2014 - 00:46

Hi Chris,

Thank you for all of your help - I ended up finding the error. I had the wrong locations for CFDEM_LIB_DIR and CFDEM_APP_DIR in the src/lagrangian/cfdemParticle/etc/bashrc file. These were originally set to FOAM_USER_LIBBIN and FOAM_USER_APPBIN and I fixed them to point to FOAM_LIBBIN and FOAM_APPBIN respectively. After sourcing the bashrc file it works!

Thanks again!
Annette

cgoniva's picture

cgoniva | Wed, 08/20/2014 - 10:10

Hello Annette,

great to hear that you could fix the problem - thank you for sharing your solution!

I guess you do not have the necessary rights to write to FOAM_USER_LIBBIN and FOAM_USER_APPBIN?

Cheers,
Chris

rodolpho101 | Sun, 01/17/2016 - 17:52

Could you help me please? I had this same error and I tried to change FOAM_LIBBIN and FOAM_APPBIN and the error persists... Do you have any ideas?

j-kerbl's picture

j-kerbl | Mon, 01/18/2016 - 13:44

Hi Rodolpho,

I wouldn't change the direct settings FOAM_LIBBIN and FOAM_APPBIN, since OpenFOAM itself should stop working afterwards. And since there seems to be a permission issue, you probably won't be able to recompile OpenFOAM. I would change WM_PROJECT_USER_DIR in OpenFOAMs bashrc to a location where you definitely have permissions to.
Normally the CFDEM binaries and libraries are store in FOAM_USER_APPBIN and FOAM_USER_LIBBIN which are defined as:
# user executables/libraries
export FOAM_USER_APPBIN=$WM_PROJECT_USER_DIR/platforms/$WM_OPTIONS/bin
export FOAM_USER_LIBBIN=$WM_PROJECT_USER_DIR/platforms/$WM_OPTIONS/lib

Within settings.sh in the OpenFOAM config.
So this might do the trick.

Cheers
Josef