Menu

#110 Installation-fatal error: utility/utility.h file not found.

dh_branch
closed-fixed
nobody
5
2014-04-08
2013-04-11
Anonymous
No

While installing moose_2.0.0_kalakand from the source tarball downloaded from the internet,I get the following error.

cs/ReadKkit.cpp -o build/temp.linux-x86_64-2.7/kinetics/ReadKkit.o -O0 -Wall -pedantic -Wno-long-long
In file included from /usr/include/c++/4.7/x86_64-suse-linux/bits/os_defines.h:40:0,
from /usr/include/c++/4.7/x86_64-suse-linux/bits/c++config.h:2058,
from /usr/include/c++/4.7/iomanip:40,
from kinetics/ReadKkit.cpp:11:
/usr/include/features.h:330:4: warning: #warning _FORTIFY_SOURCE requires compiling with optimization (-O) [-Wcpp]
kinetics/ReadKkit.cpp:14:29: fatal error: utility/utility.h: No such file or directory
compilation terminated.
error: command 'gcc' failed with exit status 1

I have resolved all dependencies before starting the installation process.

Discussion

  • Subhasis Ray

    Subhasis Ray - 2013-04-11

    Are you doing a debug build (make BUILD=debug)? The default is (make) release build and in that case optimization is enabled (-O3) and the warning you mentioned appears for compilation with optimization disabled (-O0). The warning is a known issue with gcc: https://www.wireshark.org/lists/wireshark-bugs/201207/msg00189.html

    The last error, "utility/utility.h: No such file or directory" should not occur either as kinetics/Makefile adds the parent directory of "utility" to include path.
    Modifying kinetics/ReadKkit.cpp: line # 14 from:

    #include "utility/utility.h"
    

    to

    #include "../utility/utility.h"
    

    should solve the issue in any case.

     
  • Anonymous

    Anonymous - 2013-04-11

    I tried the default make (make BUILD=release).I got the following output

    quinn@linux-43xu:~/setups/moose_2.0.0_kalakand> make BUILD=release
    make[1]: Entering directory /home/quinn/setups/moose_2.0.0_kalakand/basecode' g++ -O3 -pthread -fpermissive -fno-strict-aliasing -fPIC -Wall -Wno-long-long -pedantic -DNDEBUG -DUSE_GENESIS_PARSER -DSVN_REVISION=\"Unversioned directory\" -DLINUX -DUSE_GSL -DUSE_HDF5 -DH5_NO_DEPRECATED_SYMBOLS -I/usr/local/hdf5/include -I../msg consts.cpp -c g++: error: directory": No such file or directory make[1]: *** [consts.o] Error 1 make[1]: Leaving directory/home/quinn/setups/moose_2.0.0_kalakand/basecode'
    make[1]: Entering directory /home/quinn/setups/moose_2.0.0_kalakand/msg' g++ -O3 -pthread -fpermissive -fno-strict-aliasing -fPIC -Wall -Wno-long-long -pedantic -DNDEBUG -DUSE_GENESIS_PARSER -DSVN_REVISION=\"Unversioned directory\" -DLINUX -DUSE_GSL -DUSE_HDF5 -DH5_NO_DEPRECATED_SYMBOLS -I/usr/local/hdf5/include -I. -I../basecode Msg.cpp -c g++: error: directory": No such file or directory make[1]: *** [Msg.o] Error 1 make[1]: Leaving directory/home/quinn/setups/moose_2.0.0_kalakand/msg'
    make[1]: Entering directory /home/quinn/setups/moose_2.0.0_kalakand/shell' g++ -O3 -pthread -fpermissive -fno-strict-aliasing -fPIC -Wall -Wno-long-long -pedantic -DNDEBUG -DUSE_GENESIS_PARSER -DSVN_REVISION=\"Unversioned directory\" -DLINUX -DUSE_GSL -DUSE_HDF5 -DH5_NO_DEPRECATED_SYMBOLS -I/usr/local/hdf5/include -I. -I../basecode -I../msg Shell.cpp -c g++: error: directory": No such file or directory make[1]: *** [Shell.o] Error 1 make[1]: Leaving directory/home/quinn/setups/moose_2.0.0_kalakand/shell'
    make[1]: Entering directory /home/quinn/setups/moose_2.0.0_kalakand/biophysics' g++ -O3 -pthread -fpermissive -fno-strict-aliasing -fPIC -Wall -Wno-long-long -pedantic -DNDEBUG -DUSE_GENESIS_PARSER -DSVN_REVISION=\"Unversioned directory\" -DLINUX -DUSE_GSL -DUSE_HDF5 -DH5_NO_DEPRECATED_SYMBOLS -I/usr/local/hdf5/include -I. -I../basecode -I../msg SynBase.cpp -c g++: error: directory": No such file or directory make[1]: *** [SynBase.o] Error 1 make[1]: Leaving directory/home/quinn/setups/moose_2.0.0_kalakand/biophysics'
    make[1]: Entering directory /home/quinn/setups/moose_2.0.0_kalakand/hsolve' g++ -O3 -pthread -fpermissive -fno-strict-aliasing -fPIC -Wall -Wno-long-long -pedantic -DNDEBUG -DUSE_GENESIS_PARSER -DSVN_REVISION=\"Unversioned directory\" -DLINUX -DUSE_GSL -DUSE_HDF5 -DH5_NO_DEPRECATED_SYMBOLS -I/usr/local/hdf5/include -I. -I../basecode -I../msg HSolveStruct.cpp -c g++: error: directory": No such file or directory make[1]: *** [HSolveStruct.o] Error 1 make[1]: Leaving directory/home/quinn/setups/moose_2.0.0_kalakand/hsolve'
    make[1]: Entering directory /home/quinn/setups/moose_2.0.0_kalakand/randnum' g++ -O3 -pthread -fpermissive -fno-strict-aliasing -fPIC -Wall -Wno-long-long -pedantic -DNDEBUG -DUSE_GENESIS_PARSER -DSVN_REVISION=\"Unversioned directory\" -DLINUX -DUSE_GSL -DUSE_HDF5 -DH5_NO_DEPRECATED_SYMBOLS -I/usr/local/hdf5/include -I.. mt19937ar.cpp -c g++: error: directory": No such file or directory make[1]: *** [mt19937ar.o] Error 1 make[1]: Leaving directory/home/quinn/setups/moose_2.0.0_kalakand/randnum'
    make[1]: Entering directory /home/quinn/setups/moose_2.0.0_kalakand/scheduling' g++ -O3 -pthread -fpermissive -fno-strict-aliasing -fPIC -Wall -Wno-long-long -pedantic -DNDEBUG -DUSE_GENESIS_PARSER -DSVN_REVISION=\"Unversioned directory\" -DLINUX -DUSE_GSL -DUSE_HDF5 -DH5_NO_DEPRECATED_SYMBOLS -I/usr/local/hdf5/include -I. -I../basecode -I../msg Clock.cpp -c g++: error: directory": No such file or directory make[1]: *** [Clock.o] Error 1 make[1]: Leaving directory/home/quinn/setups/moose_2.0.0_kalakand/scheduling'
    make[1]: Entering directory /home/quinn/setups/moose_2.0.0_kalakand/builtins' g++ -O3 -pthread -fpermissive -fno-strict-aliasing -fPIC -Wall -Wno-long-long -pedantic -DNDEBUG -DUSE_GENESIS_PARSER -DSVN_REVISION=\"Unversioned directory\" -DLINUX -DUSE_GSL -DUSE_HDF5 -DH5_NO_DEPRECATED_SYMBOLS -I/usr/local/hdf5/include -I. -I../basecode -I../msg Arith.cpp -c g++: error: directory": No such file or directory make[1]: *** [Arith.o] Error 1 make[1]: Leaving directory/home/quinn/setups/moose_2.0.0_kalakand/builtins'
    make[1]: Entering directory /home/quinn/setups/moose_2.0.0_kalakand/device' g++ -O3 -pthread -fpermissive -fno-strict-aliasing -fPIC -Wall -Wno-long-long -pedantic -DNDEBUG -DUSE_GENESIS_PARSER -DSVN_REVISION=\"Unversioned directory\" -DLINUX -DUSE_GSL -DUSE_HDF5 -DH5_NO_DEPRECATED_SYMBOLS -I/usr/local/hdf5/include -I. -I../basecode -I../msg PulseGen.cpp -c g++: error: directory": No such file or directory make[1]: *** [PulseGen.o] Error 1 make[1]: Leaving directory/home/quinn/setups/moose_2.0.0_kalakand/device'
    make[1]: Entering directory /home/quinn/setups/moose_2.0.0_kalakand/kinetics' g++ -O3 -pthread -fpermissive -fno-strict-aliasing -fPIC -Wall -Wno-long-long -pedantic -DNDEBUG -DUSE_GENESIS_PARSER -DSVN_REVISION=\"Unversioned directory\" -DLINUX -DUSE_GSL -DUSE_HDF5 -DH5_NO_DEPRECATED_SYMBOLS -I/usr/local/hdf5/include -I.. -I../basecode -I../msg PoolBase.cpp -c g++: error: directory": No such file or directory make[1]: *** [PoolBase.o] Error 1 make[1]: Leaving directory/home/quinn/setups/moose_2.0.0_kalakand/kinetics'
    make[1]: Entering directory /home/quinn/setups/moose_2.0.0_kalakand/ksolve' g++ -O3 -pthread -fpermissive -fno-strict-aliasing -fPIC -Wall -Wno-long-long -pedantic -DNDEBUG -DUSE_GENESIS_PARSER -DSVN_REVISION=\"Unversioned directory\" -DLINUX -DUSE_GSL -DUSE_HDF5 -DH5_NO_DEPRECATED_SYMBOLS -I/usr/local/hdf5/include -I.. -I../basecode -I../msg -I../kinetics -I../mesh Port.cpp -c g++: error: directory": No such file or directory make[1]: *** [Port.o] Error 1 make[1]: Leaving directory/home/quinn/setups/moose_2.0.0_kalakand/ksolve'
    make[1]: Entering directory /home/quinn/setups/moose_2.0.0_kalakand/regressionTests' g++ -O3 -pthread -fpermissive -fno-strict-aliasing -fPIC -Wall -Wno-long-long -pedantic -DNDEBUG -DUSE_GENESIS_PARSER -DSVN_REVISION=\"Unversioned directory\" -DLINUX -DUSE_GSL -DUSE_HDF5 -DH5_NO_DEPRECATED_SYMBOLS -I/usr/local/hdf5/include -I. -I../basecode -I../msg -I../shell regressionTest.cpp -c g++: error: directory": No such file or directory make[1]: *** [regressionTest.o] Error 1 make[1]: Leaving directory/home/quinn/setups/moose_2.0.0_kalakand/regressionTests'
    make[1]: Entering directory /home/quinn/setups/moose_2.0.0_kalakand/utility' g++ -O3 -pthread -fpermissive -fno-strict-aliasing -fPIC -Wall -Wno-long-long -pedantic -DNDEBUG -DUSE_GENESIS_PARSER -DSVN_REVISION=\"Unversioned directory\" -DLINUX -DUSE_GSL -DUSE_HDF5 -DH5_NO_DEPRECATED_SYMBOLS -I/usr/local/hdf5/include -I.. -I.. -I../basecode strutil.cpp -c g++: error: directory": No such file or directory make[1]: *** [strutil.o] Error 1 make[1]: Leaving directory/home/quinn/setups/moose_2.0.0_kalakand/utility'
    make[1]: Entering directory /home/quinn/setups/moose_2.0.0_kalakand/geom' g++ -O3 -pthread -fpermissive -fno-strict-aliasing -fPIC -Wall -Wno-long-long -pedantic -DNDEBUG -DUSE_GENESIS_PARSER -DSVN_REVISION=\"Unversioned directory\" -DLINUX -DUSE_GSL -DUSE_HDF5 -DH5_NO_DEPRECATED_SYMBOLS -I/usr/local/hdf5/include -I.. -I../basecode -I../msg Geometry.cpp -c g++: error: directory": No such file or directory make[1]: *** [Geometry.o] Error 1 make[1]: Leaving directory/home/quinn/setups/moose_2.0.0_kalakand/geom'
    make[1]: Entering directory /home/quinn/setups/moose_2.0.0_kalakand/mesh' g++ -O3 -pthread -fpermissive -fno-strict-aliasing -fPIC -Wall -Wno-long-long -pedantic -DNDEBUG -DUSE_GENESIS_PARSER -DSVN_REVISION=\"Unversioned directory\" -DLINUX -DUSE_GSL -DUSE_HDF5 -DH5_NO_DEPRECATED_SYMBOLS -I/usr/local/hdf5/include -I.. -I../basecode ChemMesh.cpp -c g++: error: directory": No such file or directory make[1]: *** [ChemMesh.o] Error 1 make[1]: Leaving directory/home/quinn/setups/moose_2.0.0_kalakand/mesh'
    make[1]: Entering directory /home/quinn/setups/moose_2.0.0_kalakand/manager' g++ -O3 -pthread -fpermissive -fno-strict-aliasing -fPIC -Wall -Wno-long-long -pedantic -DNDEBUG -DUSE_GENESIS_PARSER -DSVN_REVISION=\"Unversioned directory\" -DLINUX -DUSE_GSL -DUSE_HDF5 -DH5_NO_DEPRECATED_SYMBOLS -I/usr/local/hdf5/include -I.. -I../basecode -I../msg SimManager.cpp -c g++: error: directory": No such file or directory make[1]: *** [SimManager.o] Error 1 make[1]: Leaving directory/home/quinn/setups/moose_2.0.0_kalakand/manager'
    make[1]: Entering directory /home/quinn/setups/moose_2.0.0_kalakand/signeur' g++ -O3 -pthread -fpermissive -fno-strict-aliasing -fPIC -Wall -Wno-long-long -pedantic -DNDEBUG -DUSE_GENESIS_PARSER -DSVN_REVISION=\"Unversioned directory\" -DLINUX -DUSE_GSL -DUSE_HDF5 -DH5_NO_DEPRECATED_SYMBOLS -I/usr/local/hdf5/include -I.. -I../basecode Adaptor.cpp -c g++: error: directory": No such file or directory make[1]: *** [Adaptor.o] Error 1 make[1]: Leaving directory/home/quinn/setups/moose_2.0.0_kalakand/signeur'
    make: *** [libs] Error 2

    I am not able to proceed to the "sudo make install" point.

     
  • Subhasis Ray

    Subhasis Ray - 2013-04-11

    Can you please do a "make clean" and try passing SVN=0 to make, like this:

    make SVN=0

    This seems to be a bug in the Makefile for released package. In line # 66 of main Makefile,

    ifndef BUILD
    BUILD=release
    endif
    

    should have been

    ifndef BUILD
    BUILD=release
    SVN=0
    endif
    
     
  • Anonymous

    Anonymous - 2013-04-11

    Is openSUSE not preferred to install and use Moose ? Most of the errors which I am encountering is because of some or the other package or configuration problem in openSUSE.

    On executing make SVN=0,I get the following error where the execution stops and returns back to the terminal.

    g++ -O3 -pthread -fpermissive -fno-strict-aliasing -fPIC -Wall -Wno-long-long -pedantic -DNDEBUG -DUSE_GENESIS_PARSER -DLINUX -DUSE_GSL -DUSE_HDF5 -DH5_NO_DEPRECATED_SYMBOLS -I/usr/local/hdf5/include basecode/_basecode.o msg/_msg.o shell/_shell.o biophysics/_biophysics.o hsolve/_hsolve.o randnum/_randnum.o scheduling/_scheduling.o builtins/_builtins.o device/_device.o kinetics/_kinetics.o ksolve/_ksolve.o regressionTests/_rt.o utility/_utility.o geom/_geom.o mesh/_mesh.o manager/_manager.o signeur/_signeur.o -L/usr/lib -L/usr/local/lib -lpthread -L/lib64 -L/usr/lib64 -L/usr/lib -lgsl -lgslcblas -lm -lhdf5 -o moose
    /usr/lib64/gcc/x86_64-suse-linux/4.7/../../../../x86_64-suse-linux/bin/ld: skipping incompatible /usr/lib/libpthread.so when searching for -lpthread
    /usr/lib64/gcc/x86_64-suse-linux/4.7/../../../../x86_64-suse-linux/bin/ld: skipping incompatible /usr/lib/libpthread.a when searching for -lpthread
    /usr/lib64/gcc/x86_64-suse-linux/4.7/../../../../x86_64-suse-linux/bin/ld: cannot find -lhdf5
    /usr/lib64/gcc/x86_64-suse-linux/4.7/../../../../x86_64-suse-linux/bin/ld: skipping incompatible /usr/lib/libm.so when searching for -lm
    /usr/lib64/gcc/x86_64-suse-linux/4.7/../../../../x86_64-suse-linux/bin/ld: skipping incompatible /usr/lib/libm.a when searching for -lm
    /usr/lib64/gcc/x86_64-suse-linux/4.7/../../../../x86_64-suse-linux/bin/ld: skipping incompatible /usr/lib/libpthread.so when searching for -lpthread
    /usr/lib64/gcc/x86_64-suse-linux/4.7/../../../../x86_64-suse-linux/bin/ld: skipping incompatible /usr/lib/libpthread.a when searching for -lpthread
    collect2: error: ld returned 1 exit status
    make: *** [moose] Error 1

    The make process stops here.I tried installing the pthread 32bit devel headers and files,using the glib-32bit,still stuck.

     
  • Subhasis Ray

    Subhasis Ray - 2013-04-12

    The error message

    /usr/lib64/gcc/x86_64-suse-linux/4.7/../../../../x86_64-suse-linux/bin/ld: cannot find -lhdf5

    tells you that libhdf5 was not available in the standard library path. You may want to add -L{directory containing libhdf5.so} in line # 165 of the toplevel Makefile:

    LIBS = -L/usr/lib -L/usr/local/lib -lpthread -L{location of libhdf5.so}

     

    Last edit: Subhasis Ray 2013-04-12
  • Anonymous

    Anonymous - 2013-04-16

    After I added the line "SVN=0" (as suggested in the earlier reply)to the make file, I tried the "make BUILD=release" with the following output

    All Libs compiled
    g++ -O3 -pthread -fpermissive -fno-strict-aliasing -fPIC -Wall -Wno-long-long -pedantic -DNDEBUG -DUSE_GENESIS_PARSER -DSVN_REVISION=\"Unversioned directory\" -DLINUX -DUSE_GSL -DUSE_HDF5 -DH5_NO_DEPRECATED_SYMBOLS -I/usr/local/hdf5/include basecode/_basecode.o msg/_msg.o shell/_shell.o biophysics/_biophysics.o hsolve/_hsolve.o randnum/_randnum.o scheduling/_scheduling.o builtins/_builtins.o device/_device.o kinetics/_kinetics.o ksolve/_ksolve.o regressionTests/_rt.o utility/_utility.o geom/_geom.o mesh/_mesh.o manager/_manager.o signeur/_signeur.o -L/usr/lib -L/usr/local/lib -lpthread -L/usr/lib64 -L/lib64 -L/usr/lib64 -L/usr/lib -lgsl -lgslcblas -lm -lhdf5 -o moose
    g++: error: directory": No such file or directory
    make: *** [moose] Error 1

    Platform : openSUSE 12.3

    What might just be the point where this happens ?

    The code in starting from line 326 being

    moose: libs $(OBJLIBS) $(PARALLEL_LIB)
    $(CXX) $(CXXFLAGS) $(OBJLIBS) $(PARALLEL_LIB) $(LIBS) -o moose
    @echo "Moose compilation finished"

    is accepting all parameters specified. Is there any problems in the libs passed ?

     
  • Subhasis Ray

    Subhasis Ray - 2013-04-17

    Sorry, my instructions were not accurate. It should work when you do not pass any further command line arguments to make (just make). The simplest solution is to do

    make SVN=0 without any further arguments (BUILD defaults to release in the released version).

    Another solution for the released source (not from svn repo) will be: around line # 150

    ifndef SVN
    SVN?=1
    endif
    

    changed to

    ifndef SVN
    SVN?=0
    endif
    

    A bit of explanation:
    The SVN argument indicates whether we want to add the svn revision number as part of the version number compiled into MOOSE. This uses the svnversion command to determine the current svn version. When it is not an svn check-out code, the directory does not have any svn version number and svnrevision prints the string Unversioned directory. Now the unescaped space in the middle messes up the command line and g++ thinks that it has to compile a file called directory".

    But the appropriate fix will be to check for Unversioned directory in the string printed by svnversion. I'll commit the fix in svn repo.

     
  • Subhasis Ray

    Subhasis Ray - 2013-04-17

    This fix was committed in revision: 4487. The fix is as follows (around line# 150 in top level Makefile):

    replace

    # Insert the svn revision no. into the code as a preprocessor macro.
    # Only for release versions we want to pass SVN=0 to make.
    ifndef SVN
    SVN?=1
    endif
    ifneq ($(SVN),0)
    SVN_REVISION=$(shell svnversion)
    ifneq ($(SVN_REVISION),export)
    CXXFLAGS+=-DSVN_REVISION=\"$(SVN_REVISION)\"
    endif
    endif
    

    with

    # Insert the svn revision no. into the code as a preprocessor macro.
    # Only for release versions we want to pass SVN=0 to make.
    ifndef SVN
    SVN?=1
    endif
    empty :=
    space := $(empty) $(empty)
    ifneq ($(SVN),0)
    # Some versions of svnrevision return "Unversioned directory" which causes confusion to gcc
    SVN_REVISION := $(shell svnversion)
    SVN_REVISION := $(subst space,_,$(SVN_REVISION))
    # SVN_REVISION := $(subst :,_,$(SVN_REVISION))
    ifneq ($(SVN_REVISION),export)
    CXXFLAGS+=-DSVN_REVISION=\"$(SVN_REVISION)\"
    endif
    endif
    
     
  • Anonymous

    Anonymous - 2013-04-17

    I was able to successfully execute the makefile on OpenSUSE 12.3. This is the following error that comes to when I execute the command "sudo make install"

    ## copy icon to /usr/share/icons/hicolor/<size>/apps (hicolor is the fallback theme)
    mkdir -p /usr/share/icons/hicolor/scalable/apps
    cp gui/icons/moose_icon.png /usr/share/icons/hicolor/scalable/apps/
    cp gui/icons/squid.png /usr/share/icons/hicolor/scalable/apps/
    ## need to update the icon cache to show the icon
    update-icon-caches /usr/share/icons/hicolor/
    make: update-icon-caches: Command not found
    make: *** [install] Error 127
    
     

    Last edit: Subhasis Ray 2013-04-18
  • Subhasis Ray

    Subhasis Ray - 2013-04-18

    This is an issue with the installation script. On debian based systems libgtk provides that command, but KDE being the primary desktop environment for SUSE, it may not exist there. The script should not fail due to this. Creating a new issue: https://sourceforge.net/p/moose/bugs/112/.

     

    Last edit: Subhasis Ray 2013-04-18
  • Subhasis Ray

    Subhasis Ray - 2013-04-18
    • status: open --> closed-fixed
     

Anonymous
Anonymous

Add attachments
Cancel





MongoDB Logo MongoDB