CFDEM compile error - mkdir: cannot create directory ‘’: No such file or directory

Submitted by John on Fri, 09/26/2014 - 16:52

Hi,

I have problems compiling CFDEM. The solution to a similar problem (http://www.cfdem.com/forums/update-cfdem-251-compile-error) did not help.
The first error of this kind happens at the end of the submodel compilation.

[...]
SOURCE=subModels/smoothingModel/constDiffSmoothing/constDiffSmoothing.C ; g++ -m64 -Dlinux64 -DWM_DP -Wall -Wextra -Wno-unused-parameter -Wold-style-cast -Wnon-virtual-dtor -O3 -DNoRepository -ftemplate-depth-100 -DOMPI_SKIP_MPICXX -I/usr/lib64/OpenFOAM/ThirdParty-2.3.0/platforms/linux64Gcc/openmpi-1.6.5/include -I ./cfdemParticle -I/usr/lib64/OpenFOAM/OpenFOAM-2.3.0/src/finiteVolume/lnInclude -I/usr/lib64/OpenFOAM/OpenFOAM-2.3.0/src/transportModels -I/usr/lib64/OpenFOAM/OpenFOAM-2.3.0/src/turbulenceModels/incompressible/turbulenceModel -I/usr/lib64/OpenFOAM/OpenFOAM-2.3.0/src/meshTools/lnInclude -I/usr/lib64/OpenFOAM/OpenFOAM-2.3.0/src/lagrangian/basic/lnInclude -I/usr/lib64/OpenFOAM/OpenFOAM-2.3.0/src/OpenFOAM/containers/HashTables/labelHashSet -I/home/john/LIGGGHTS/LIGGGHTS-PUBLIC/src -I/home/john/CFDEM/CFDEMcoupling-PUBLIC-joli-1.0/src/cfdTools -IlnInclude -I. -I/usr/lib64/OpenFOAM/OpenFOAM-2.3.0/src/OpenFOAM/lnInclude -I/usr/lib64/OpenFOAM/OpenFOAM-2.3.0/src/OSspecific/POSIX/lnInclude -fPIC -c $SOURCE -o Make/linux64GccDPOpt/constDiffSmoothing.o
mkdir: cannot create directory ‘’: No such file or directory
make: *** [/liblagrangianCFDEM-PUBLIC-joli-1.0.so] Error 1
rm: cannot remove ‘log/log_compile_results_success’: No such file or directory
[...]

I suppose this is some kind of environment variable problem. The output of cfdemSysTest shows no problems:


*******************
system settings:
*******************
CFDEM_VERSION=PUBLIC
couple to OF_VERSION=2.3.0
compile option=Opt
 
check if paths are set correctly
valid:yes critical:yes - $CFDEM_PROJECT_DIR = /home/john/CFDEM/CFDEMcoupling-PUBLIC-joli-1.0
valid:yes critical:no - $CFDEM_PROJECT_USER_DIR = /home/john/CFDEM/john-PUBLIC-joli-1.0
valid:yes critical:yes - $CFDEM_SRC_DIR = /home/john/CFDEM/CFDEMcoupling-PUBLIC-joli-1.0/src
valid:yes critical:yes - $CFDEM_SOLVER_DIR = /home/john/CFDEM/CFDEMcoupling-PUBLIC-joli-1.0/applications/solvers
valid:yes critical:yes - $CFDEM_TUT_DIR = /home/john/CFDEM/CFDEMcoupling-PUBLIC-joli-1.0/tutorials
valid:yes critical:yes - $CFDEM_LIGGGHTS_SRC_DIR = /home/john/LIGGGHTS/LIGGGHTS-PUBLIC/src
valid:yes critical:yes - $CFDEM_LPP_DIR = /home/john/LIGGGHTS/mylpp/src
valid:NO critical:no - $CFDEM_PIZZA_DIR = /home/john/LIGGGHTS/PIZZA/gran_pizza_17Aug10/src does not exist
valid:yes critical:no - $CFDEM_TEST_HARNESS_PATH = /home/john/CFDEM/john-PUBLIC-joli-1.0/log/logFilesCFDEM-PUBLIC-joli-1.0
 
library names
$CFDEM_LIGGGHTS_LIB_NAME = lmp_fedora_fpic
$CFDEM_LIB_NAME = lagrangianCFDEM-PUBLIC-joli-1.0
$LD_LIBRARY_PATH = /usr/lib64/OpenFOAM/ThirdParty-2.3.0/platforms/linux64Gcc/gperftools-svn/lib:/usr/lib/paraview-4.1:/usr/lib64/OpenFOAM/OpenFOAM-2.3.0/platforms/linux64GccDPOpt/lib/openmpi-1.6.5:/usr/lib64/OpenFOAM/ThirdParty-2.3.0/platforms/linux64GccDPOpt/lib/openmpi-1.6.5:/usr/lib64/OpenFOAM/ThirdParty-2.3.0/platforms/linux64Gcc/openmpi-1.6.5/lib:/usr/lib64/OpenFOAM/ThirdParty-2.3.0/platforms/linux64Gcc/openmpi-1.6.5/lib64:/home/john/OpenFOAM/john-2.3.0/platforms/linux64GccDPOpt/lib:/usr/lib64/OpenFOAM/site/2.3.0/platforms/linux64GccDPOpt/lib:/usr/lib64/OpenFOAM/OpenFOAM-2.3.0/platforms/linux64GccDPOpt/lib:/usr/lib64/OpenFOAM/ThirdParty-2.3.0/platforms/linux64GccDPOpt/lib:/usr/lib64/OpenFOAM/OpenFOAM-2.3.0/platforms/linux64GccDPOpt/lib/dummy
$WM_NCOMPPROCS =
*******************
g++:
/usr/bin/g++
g++ (Gentoo 4.8.3 p1.1, pie-0.5.9) 4.8.3
Copyright (C) 2013 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 (Gentoo 4.8.3 p1.1, pie-0.5.9) 4.8.3
Copyright (C) 2013 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++:
/usr/bin/mpic++
x86_64-pc-linux-gnu-g++ (Gentoo 4.8.3 p1.1, pie-0.5.9) 4.8.3
Copyright (C) 2013 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.
 
mpirun:
/usr/bin/mpirun
mpirun (Open MPI) 1.4.3
 
Report bugs to http://www.open-mpi.org/community/help/

Please help me with this problems.

Kind regards
John

j-kerbl's picture

j-kerbl | Mon, 09/29/2014 - 11:17

Hi John,

thanks for the detailed post!
Your paths look a little bit unusual, did you compile OpenFOAM yourself?
Is the "-joli-1.0" part of the CFDEM_PROJECT_DIR hardcoded in your bashrc, or did you replace the WM_PROJECT_VERSION variable?

Cheers
Josef

John | Mon, 09/29/2014 - 13:00

Hi Josef,

the OpenFOAM-2.3.0 is not self-compiled, but from gentoo's portage and installed to /usr/lib64/

I used the WM_PROJECT_VERSION variable.
This is my .bashrc. I had to add some OpenFOAM stuff to the PATH to try compiling without "startOF23"

alias startOF23='source /usr/lib64/OpenFOAM/OpenFOAM-2.3.0/etc/bashrc'
 
PATH=$PATH:/usr/lib64/OpenFOAM/OpenFOAM-2.3.0/bin:/usr/lib64/OpenFOAM/OpenFOAM-2.3.0/wmake/
 
export WM_PROJECT_VERSION=joli-1.0
 
#================================================#
#- source cfdem env vars
export CFDEM_VERSION=PUBLIC
export CFDEM_PROJECT_DIR=$HOME/CFDEM/CFDEMcoupling-$CFDEM_VERSION-$WM_PROJECT_VERSION
export CFDEM_SRC_DIR=$CFDEM_PROJECT_DIR/src
export CFDEM_SOLVER_DIR=$CFDEM_PROJECT_DIR/applications/solvers
export CFDEM_DOC_DIR=$CFDEM_PROJECT_DIR/doc
export CFDEM_UT_DIR=$CFDEM_PROJECT_DIR/applications/utilities
export CFDEM_TUT_DIR=$CFDEM_PROJECT_DIR/tutorials
export CFDEM_PROJECT_USER_DIR=$HOME/CFDEM/$LOGNAME-$CFDEM_VERSION-$WM_PROJECT_VERSION
export CFDEM_bashrc=$CFDEM_SRC_DIR/lagrangian/cfdemParticle/etc/bashrc
export CFDEM_LIGGGHTS_SRC_DIR=$HOME/LIGGGHTS/LIGGGHTS-PUBLIC/src
export CFDEM_LIGGGHTS_MAKEFILE_NAME=fedora_fpic
export CFDEM_LPP_DIR=$HOME/LIGGGHTS/mylpp/src
export CFDEM_PIZZA_DIR=$HOME/LIGGGHTS/PIZZA/gran_pizza_17Aug10/src
. $CFDEM_bashrc
#================================================#

Thanks for helping me with that problem!
Kind regards
John

j-kerbl's picture

j-kerbl | Tue, 09/30/2014 - 10:19

Hi John,

it is rather tough to say what went wrong, since the installation is non-standard.

1st I would not change the WM_PROJECT_VERSION, since it is set by the bashrc of OpenFOAM. (in your case it should be 2.3.0)
2nd since your OF is not in the home directiory, have you tried sudoing the compilation of CFDEM?

Cheers
Josef