deal.II cmake stuck at "Performing Test DEAL_II_HAVE_USABLE_FLAGS_DEBUG"

264 views
Skip to first unread message

Praveen C

unread,
Dec 15, 2016, 10:54:48 AM12/15/16
to Deal.II Googlegroup
Dear all

I am trying to install on a new machine running opensuse tumbleweed.

I installed packages using spack

$ spack find

==> 37 installed packages.

-- linux-opensuse20161212-x86_64 / gcc@6 ------------------------

arpack-ng@3.4.0      m4@1.4.17               pkg-config@0.29.1

autoconf@2.69        matio@1.5.9             python@2.7.12

automake@1.15        metis@5.1.0             readline@6.3

boost@1.62.0         mumps@5.0.2             slepc@3.7.3

bzip2@1.0.6          ncurses@6.0             sqlite@3.8.5

cmake@3.6.1          netcdf@4.4.1            suite-sparse@4.5.3

glm@0.9.7.1          netlib-scalapack@2.0.2  superlu-dist@5.1.1

hdf5@1.10.0-patch1   openblas@0.2.19         tbb@4.4.4

hwloc@1.11.4         openmpi@2.0.1           trilinos@12.10.1

hypre@2.11.1         openssl@1.0.2j          util-macros@1.19.0

libpciaccess@0.13.4  p4est@1.1               zlib@1.2.8

libsigsegv@2.10      parmetis@4.0.3

libtool@2.4.6        petsc@3.7.4


I would like to compile deal.II from git on my own. I configure deal.II like this

DEAL_II_DIR=/opt/deal.II

TRILINOS_DIR=`spack location -i trilinos`

P4EST_DIR=`spack location -i p4est`

METIS_DIR=`spack location -i metis`

HDF5_DIR=`spack location -i hdf5`

PETSC_DIR=`spack location -i petsc`

SLEPC_DIR=`spack location -i slepc`

UMFPACK_DIR=`spack location -i suitesparse`


cmake -DCMAKE_INSTALL_PREFIX=$DEAL_II_DIR \

      -DCMAKE_C_COMPILER="mpicc" \

      -DCMAKE_CXX_COMPILER="mpicxx" \

      -DDEAL_II_COMPONENT_DOCUMENTATION=OFF \

      -DDEAL_II_WITH_UMFPACK=ON \

      -DUMFPACK_DIR=$UMFPACK_DIR \

      -DDEAL_II_WITH_THREADS=ON \

      -DDEAL_II_WITH_TRILINOS=ON \

      -DTRILINOS_DIR=$TRILINOS_DIR \

      -DDEAL_II_WITH_PETSC=ON \

      -DPETSC_DIR=$PETSC_DIR \

      -DDEAL_II_WITH_SLEPC=ON \

      -DSLEPC_DIR=$SLEPC_DIR \

      -DDEAL_II_WITH_MPI=ON \

      -DDEAL_II_WITH_P4EST=ON \

      -DP4EST_DIR=$P4EST_DIR \

      -DDEAL_II_WITH_METIS=ON \

      -DMETIS_DIR=$METIS_DIR \

      -DDEAL_II_WITH_HDF5=ON \

      -DHDF5_DIR=$HDF5_DIR \

      -DDEAL_II_WITH_NETCDF=OFF \

      -DDEAL_II_WITH_OPENCASCADE=OFF \

      -DOPENCASCADE_DIR=$CASROOT \

      -DDEAL_II_WITH_GSL=OFF \

      ..


While running cmake, it is stuck at

-- Performing Test DEAL_II_HAVE_USABLE_FLAGS_DEBUG


Do you know what could be the problem ?

Thanks
praveen

Praveen C

unread,
Dec 15, 2016, 10:34:29 PM12/15/16
to Deal.II Googlegroup
Additionally I added Fortran compiler and fixed "suitesparse" to "suite-sparse", but I am still stuck at the same place as before.

Should I use "Filesystem View" to compile my own dealii with spack packages ?

If I install dealii@develop using spack, how do I update dealii in future ?

Thanks
praveen

Jean-Paul Pelteret

unread,
Dec 16, 2016, 2:42:27 AM12/16/16
to deal.II User Group
Dear Praveen,

Unfortunately I don't have any suggestions about CMake hanging. I've just reinstalled deal.II through Spack on both my Apple and Linux machines and I didn't run into the problem you're experiencing. Denis has some experience with installing deal.II though spack on a number of different systems/architectures, so perhaps he has some additional advice for you. Maybe you could try to work out where in the test its stuck? 

On your other point, I personally use filesystem views because I find modules and `spack location -i` to be far too slow when you're loading many packages. The views also ensure a consistent library path for all of the dependencies. I know that you can build your own "custom" local package thats easily updated. There's a post on the spack forum about it, and its definitely a discussion worth having there instead of here because it might be quite involved. My current work-around for this complexity is to install dealii@develop through spack, to make sure that I've got all of the possible dependencies for a feature-complete deal.II installed, and then build my own cloned version of deal.II somewhere else. With the filesystem views, one simply points deal.II to a single directory to find all of the packages:

cmake \

-DDEAL_II_COMPONENT_DOCUMENTATION=OFF \

-DDEAL_II_WITH_BOOST=ON \

-DBOOST_DIR=$SPACK_VIEW_DIR \

-DDEAL_II_WITH_BZIP2=TRUE \

-DBZIP2_DIR=$SPACK_VIEW_DIR \

-DDEAL_II_WITH_UMFPACK=ON \

-DUMFPACK_DIR=$SPACK_VIEW_DIR \

-DDEAL_II_WITH_MPI=ON \

-DMPI_DIR=$SPACK_VIEW_DIR \

-DDEAL_II_WITH_METIS=ON \

-DMETIS_DIR=$SPACK_VIEW_DIR \

-DDEAL_II_WITH_P4EST=ON \

-DP4EST_DIR=$SPACK_VIEW_DIR \

-DDEAL_II_WITH_PETSC=ON \

-DPETSC_DIR=$SPACK_VIEW_DIR \

-DDEAL_II_WITH_TRILINOS=ON \

-DTRILINOS_DIR=$SPACK_VIEW_DIR \

-DCMAKE_INSTALL_PREFIX=<PATH>/install \

../dealii


Best,
Jean-Paul

Denis Davydov

unread,
Dec 16, 2016, 7:57:33 AM12/16/16
to deal.II User Group
Hi Praveen,

I am glad that you at least have the whole stack of packages installed via Spack (although with minor issues due to missing "patch" on the system).
As for the compilation of your own deal.II from github, the simplest way is supposed to be `spack setup dealii@develop` (see http://spack.readthedocs.io/en/latest/workflows.html#build-with-spack), but a recent PRs broke it, see https://github.com/LLNL/spack/issues/2597
The next simplest way is described in the WiKi page of deal.II: https://github.com/dealii/dealii/wiki/deal.II-in-Spack#develop-using-spack
You would essentially symlink the whole stack into some folder and work with (it is similar using `/usr/local`).

As for your original problem, I can only speculate that there could be some issues with wrong MPI compiler wrappers being picked up.
I presume that `spack install dealii@develop` works for you and you additionally want to have a self-compiled version with some private changes?

Let use know if using FilesystemViews solves the problem. You can also do `spack load openmpi` to make sure that <prefix/bin> of OpenMPI is before your other paths like `/usr/bin`.
Otherwise we need to dig deeper and see why config does not work...

Regards,
Denis.

Denis Davydov

unread,
Dec 16, 2016, 7:58:29 AM12/16/16
to deal.II User Group


On Friday, December 16, 2016 at 4:34:29 AM UTC+1, Praveen C wrote:
spack uninstall dealii@develop
spack install dealii@develop

is the way to do it for now.

Praveen C

unread,
Dec 16, 2016, 9:22:45 AM12/16/16
to Deal.II Googlegroup
Hello Jean-Paul, Denis

Thanks for the tips. I had huge problems with linuxbrew but spack installed everything without any problem. Now I will try to install dealii. I will be switching to spack on all my other linux machines.

I think I can manage with filesystem view for own dealii compilation.

Best
praveen

--
The deal.II project is located at http://www.dealii.org/
For mailing list/forum options, see https://groups.google.com/d/forum/dealii?hl=en
---
You received this message because you are subscribed to the Google Groups "deal.II User Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email to dealii+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Denis Davydov

unread,
Dec 17, 2016, 6:52:44 AM12/17/16
to deal.II User Group
To clarify with FileSystem views, you would need to do 

${DEAL_II_VIEW}/bin/mpicc

to make sure MPI is picked up the view, and not the one from the system.

To unsubscribe from this group and stop receiving emails from it, send an email to dealii+un...@googlegroups.com.

Denis Davydov

unread,
Dec 17, 2016, 6:56:33 AM12/17/16
to deal.II User Group
Alternative, is to add the view to your path, i.e. 

PATH=${DEAL_II_VIEW}/bin:${PATH}

then

-DCMAKE_C_COMPILER="mpicc"

would also be ok.

Praveen C

unread,
Dec 17, 2016, 7:00:21 AM12/17/16
to Deal.II Googlegroup

On Sat, Dec 17, 2016 at 5:26 PM, Denis Davydov <davy...@gmail.com> wrote:
Alternative, is to add the view to your path, i.e. 

PATH=${DEAL_II_VIEW}/bin:${PATH}

then

-DCMAKE_C_COMPILER="mpicc"

would also be ok.

I used instructions on wiki like this

DEAL_II_VIEW=/home/soft


cmake  \

-DCMAKE_FIND_FRAMEWORK=LAST  \

-DCMAKE_INSTALL_RPATH_USE_LINK_PATH=FALSE  \

-DCMAKE_INSTALL_RPATH=${DEAL_II_VIEW}  \

-DCMAKE_BUILD_TYPE=DebugRelease  \

-DDEAL_II_COMPONENT_EXAMPLES=ON  \

-DDEAL_II_WITH_THREADS:BOOL=ON  \

-DBOOST_DIR=${DEAL_II_VIEW}  \

-DBZIP2_DIR=${DEAL_II_VIEW}  \

-DMUPARSER_DIR=${DEAL_II_VIEW}  \

-DUMFPACK_DIR=${DEAL_II_VIEW}  \

-DTBB_DIR=${DEAL_II_VIEW}  \

-DZLIB_DIR=${DEAL_II_VIEW}  \

-DDEAL_II_WITH_MPI:BOOL=ON  \

-DCMAKE_C_COMPILER=${DEAL_II_VIEW}/bin/mpicc  \

-DCMAKE_CXX_COMPILER=${DEAL_II_VIEW}/bin/mpic++  \

-DCMAKE_Fortran_COMPILER=${DEAL_II_VIEW}/bin/mpif90  \

-DGSL_DIR=${DEAL_II_VIEW}  \

-DDEAL_II_WITH_GSL:BOOL=ON  \

-DHDF5_DIR=${DEAL_II_VIEW}  \

-DDEAL_II_WITH_HDF5:BOOL=ON  \

-DP4EST_DIR=${DEAL_II_VIEW}  \

-DDEAL_II_WITH_P4EST:BOOL=ON  \

-DPETSC_DIR=${DEAL_II_VIEW}  \

-DDEAL_II_WITH_PETSC:BOOL=ON  \

-DSLEPC_DIR=${DEAL_II_VIEW}  \

-DDEAL_II_WITH_SLEPC:BOOL=ON  \

-DTRILINOS_DIR=${DEAL_II_VIEW}  \

-DDEAL_II_WITH_TRILINOS:BOOL=ON  \

-DMETIS_DIR=${DEAL_II_VIEW}  \

-DDEAL_II_WITH_METIS:BOOL=ON  \

-DDEAL_II_COMPONENT_DOCUMENTATION=OFF  \

-DARPACK_DIR=${DEAL_II_VIEW}  \

-DDEAL_II_WITH_ARPACK=ON  \

-DDEAL_II_ARPACK_WITH_PARPACK=ON  \

-DNETCDF_DIR=${DEAL_II_VIEW}  \

-DOPENCASCADE_DIR=${DEAL_II_VIEW}  \

-DDEAL_II_WITH_OPENCASCADE=ON  \

../


Thanks
praveen

Denis Davydov

unread,
Dec 17, 2016, 7:11:30 AM12/17/16
to dea...@googlegroups.com
That all looks fine, with an exception of missing Lapack. I presume you installed with the default Openblas? If so, add

-DLAPACK_FOUND=true -DLAPACK_INCLUDE_DIRS=${DEAL_II_VIEW}/include -DLAPACK_LIBRARIES=${DEAL_II_VIEW}/lib/libopenblas.so

As for the original question, do still have the issue? If so, can you upload here CMakeError.log and CMakeOutput.log ?

p.s. the versions of those files you uploaded to Spack do not correspond to the manual build via FilesystemView.
Some of the errors there are due to the wrong path to Netcdf libs, which shall be fixed by https://github.com/LLNL/spack/pull/2616


Regards,
Denis.





Praveen C

unread,
Dec 17, 2016, 8:00:11 AM12/17/16
to Deal.II Googlegroup
I am now again trying

spack install dealii@develop

It is here

==> gsl is already installed in /home/spack/opt/spack/linux-opensuse20161212-x86_64/gcc-6/gsl-2.2.1-rqhjfsomxyrou5mdrtedrtbamhh5msic

==> openblas is already installed in /home/spack/opt/spack/linux-opensuse20161212-x86_64/gcc-6/openblas-0.2.19-i6qy7tgdqwl3i4vfkl2ao6e4rxg5ylyt

==> Already fetched /home/spack/var/spack/stage/dealii-develop-2rljl3eutxbdurgdrk656j3hutisl7a5/dealii

==> No checksum needed when fetching with git

==> Already staged dealii-develop-2rljl3eutxbdurgdrk656j3hutisl7a5 in /home/spack/var/spack/stage/dealii-develop-2rljl3eutxbdurgdrk656j3hutisl7a5

==> No patches needed for dealii

==> Building dealii [CMakePackage]

==> Executing phase : 'cmake'


and after more than 20 min, there is no progress. I can see python and ld running in top. There is no log/error file so far. I attach spack output.

Best
praveen

--
The deal.II project is located at http://www.dealii.org/
For mailing list/forum options, see https://groups.google.com/d/forum/dealii?hl=en
---
You received this message because you are subscribed to the Google Groups "deal.II User Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email to dealii+unsubscribe@googlegroups.com.
spack-build.out.txt
spack-build.env.txt

Praveen C

unread,
Dec 17, 2016, 8:18:34 AM12/17/16
to Deal.II Googlegroup
After 45 min, cmake is still at

-- Performing Test DEAL_II_HAVE_USABLE_FLAGS_DEBUG
so I killed it. Let me know if you want me to wait longer with hope of getting some error message.

Thanks
praveen

Denis Davydov

unread,
Dec 17, 2016, 10:11:30 AM12/17/16
to deal.II User Group
That looks like something is wrong in deal.II configuration tests.
Correct me if I am wrong, but 8.4.2 installs ok for you with Spack but the current @develop fails, 
so the changes must have been introduced after 8.4.2 release.

@all: any ideas on how to debug it further or what could be the problem? 
It must be related to cmake/setup_finalize.cmake


Regards,
Denis.

Praveen C

unread,
Dec 17, 2016, 10:16:08 AM12/17/16
to Deal.II Googlegroup
On Sat, Dec 17, 2016 at 8:41 PM, Denis Davydov <davy...@gmail.com> wrote:
That looks like something is wrong in deal.II configuration tests.
Correct me if I am wrong, but 8.4.2 installs ok for you with Spack but the current @develop fails, 
so the changes must have been introduced after 8.4.2 release.

Yes, 8.4.2 install fine with spack but develop does not.

Best
praveen

Denis Davydov

unread,
Dec 18, 2016, 10:30:34 AM12/18/16
to deal.II User Group
Hi Praveen,

It looks like it hands up in cmake/setup_finalize.cmake, more precisely in "CHECK_COMPILER_SETUP" inside:

FOREACH(build ${DEAL_II_BUILD_TYPES})

  CHECK_COMPILER_SETUP(

    "${DEAL_II_CXX_FLAGS} ${DEAL_II_CXX_FLAGS_${build}}"

    "${DEAL_II_LINKER_FLAGS} ${DEAL_II_LINKER_FLAGS_${build}}"

    DEAL_II_HAVE_USABLE_FLAGS_${build}

    ${DEAL_II_LIBRARIES} ${DEAL_II_LIBRARIES_${build}}

    )


    ...
ENDFOREACH()


For now I would suggest to debug it as follows:
(i) use FilesystemViews to setup build from a locally checkout .git folder of deal.II@develop
(ii) add some output (MESSAGE()) to CMake scripts to determine where exactly it hangs.
I would start with putting 
(and remove "FATAL_ERROR") 
If you see that it hangs indeed in CHECK_COMPILER_SETUP, then start putting messages in

That should eventually lead to to a single line which hangs on your system.

Regards,
Denis.

Praveen C

unread,
Dec 19, 2016, 1:55:44 AM12/19/16
to Deal.II Googlegroup
Dear all

I am trying to to this debugging, but I need to clean my spack installation. I ended up with multiple installations of some packages. E.g., I have two versions of open...@0.2.19.

Maybe I will uninstall everything and do a fresh install of dealii@develop.

Best
praveen

--

Praveen C

unread,
Dec 19, 2016, 9:08:59 AM12/19/16
to Deal.II Googlegroup
Looking at "ps -ef" I can see which process cmake is stuck at. I have attached the currently running processes during "Performing Test DEAL_II_HAVE_USABLE_FLAGS_DEBUG".

i.e., output of "ps -ef | grep spack"

The test seems to be with this file

cmTC_4e156

It was stuck at process 71700 which is "ld".

Does this give any clue ?

Best
praveen
cmake_procs.txt

Denis Davydov

unread,
Dec 19, 2016, 9:15:37 AM12/19/16
to dea...@googlegroups.com
That’s obviously a linking stage of a simple “int main(){ return0;}”, see https://github.com/dealii/dealii/blob/master/cmake/macros/macro_check_compiler_setup.cmake

# This macro tries to compile and link a simple "int main(){ return 0; }
# with the given set of provided compiler and linker flags  and an optional
# list of libraries to link against.

I have no idea why linker hangs, I never saw such issues (ideas anyone?).

I would still suggest adding extra CMake output, just move https://github.com/dealii/dealii/blob/master/cmake/setup_finalize.cmake#L95-L102
infront of `CHECK_COMPILER_SETUP` to see what are the final values of all flags and if they make any sense.

Kind regards,
Denis 

You received this message because you are subscribed to a topic in the Google Groups "deal.II User Group" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/dealii/eG75p2TVNNQ/unsubscribe.
To unsubscribe from this group and all its topics, send an email to dealii+un...@googlegroups.com.

For more options, visit https://groups.google.com/d/optout.
<cmake_procs.txt>

Praveen C

unread,
Dec 19, 2016, 9:26:35 AM12/19/16
to Deal.II Googlegroup
Denis, I am here

$ pwd

/home/spack/var/spack/stage/dealii-develop-hrrbqysxwyuio7nj3aqsdpgkk7zrbkiz/dealii/spack-build/CMakeFiles/CMakeTmp

$ ls

CMakeCache.txt  CMakeFiles  cmake_install.cmake  CMakeLists.txt  macro_configure_feature.tmp  Makefile  src.cxx

$ ls CMakeFiles/

cmake.check_cache  CMakeDirectoryInformation.cmake  cmTC_4e156.dir  Makefile2  Makefile.cmake  Progress  progress.marks  TargetDirectories.txt


If I type "make" here, it tries to do this

[ 50%] Linking CXX executable cmTC_4e156

/home/spack/opt/spack/linux-opensuse20161217-x86_64/gcc-6/cmake-3.7.1-erobxw7bh6cbnaqfzaqwvzk6crnj5ojy/bin/cmake -E cmake_link_script CMakeFiles/cmTC_4e156.dir/link.txt --verbose=1

/home/spack/opt/spack/linux-opensuse20161217-x86_64/gcc-6/openmpi-2.0.1-asdjmd22cnyktv2athcx3ouhrozknk22/bin/mpic++    -DDEAL_II_HAVE_USABLE_FLAGS_DEBUG -pedantic -fPIC -Wall -Wextra -Wpointer-arith -Wwrite-strings -Wsynth -Wsign-compare -Wswitch -Woverloaded-virtual -Wno-long-long -Wno-placement-new -Wno-deprecated-declarations -Wno-literal-suffix -fopenmp-simd -std=c++14 -Wno-unused-local-typedefs -Og -ggdb -Wa,--compress-debug-sections    CMakeFiles/cmTC_4e156.dir/src.cxx.o  -o cmTC_4e156 ......


and never finishes.

All the flags should be available in these files, right ? Would it help to look into these ?

Best
praveen



Kind regards,
Denis 

To unsubscribe from this group and all its topics, send an email to dealii+unsubscribe@googlegroups.com.

For more options, visit https://groups.google.com/d/optout.
<cmake_procs.txt>

Denis Davydov

unread,
Dec 19, 2016, 9:35:56 AM12/19/16
to dea...@googlegroups.com
Hi Praveen,

that output looks reasonable. I hope that other developers with more experience  in this area can comment on this topic.

Meanwhile, what comes to mind is you can try building 

spack install dealii@develop~gsl

and also 

spack install dealii@develop~python+mpi^boost+python

Both commands shall NOT rebuild any dependencies, but will just turn off extra features added to deal.II since 8.4.2, namely `GSL` and `Python` bindings.
It’s just to make sure that the issue you have is not related.


Kind regards,
Denis 

To unsubscribe from this group and all its topics, send an email to dealii+un...@googlegroups.com.

Praveen C

unread,
Dec 19, 2016, 11:03:04 AM12/19/16
to Deal.II Googlegroup

On Mon, Dec 19, 2016 at 8:05 PM, Denis Davydov <davy...@gmail.com> wrote:
spack install dealii@develop~gsl

and also 

spack install dealii@develop~python+mpi^boost+python

No luck with both of these, same problem as before.

Best
praveen

Denis Davydov

unread,
Dec 19, 2016, 11:06:28 AM12/19/16
to dea...@googlegroups.com
Ok, at least we know they are not a part of the equation…

Denis Davydov

unread,
Dec 19, 2016, 11:14:07 AM12/19/16
to dea...@googlegroups.com
Another suggestion, build from source under Git and do 
`git bisect` https://git-scm.com/docs/git-bisect to find out which commit breaks it for you.
and can be a rough guess if you don’t want to do bisection blindly between the current devevelop and 8.4.2 (which is in dealii-8.4 branch).

Kind regards,
Denis 

On 19 Dec 2016, at 17:02, Praveen C <cpra...@gmail.com> wrote:

Praveen C

unread,
Dec 19, 2016, 11:40:07 AM12/19/16
to Deal.II Googlegroup
Disabling Trilinos

spack install dealii@develop~trilinos

I am getting past the "cmake" stage and onto "build". But I need Trilinos :-(

Since the test DEAL_II_HAVE_USABLE_FLAGS_DEBUG does not finish, does not give error, will git-bisect be able to help ?

Best
praveen


Kind regards,
Denis 

To unsubscribe from this group and all its topics, send an email to dealii+unsubscribe@googlegroups.com.

For more options, visit https://groups.google.com/d/optout.

--
The deal.II project is located at http://www.dealii.org/
For mailing list/forum options, see https://groups.google.com/d/forum/dealii?hl=en
---
You received this message because you are subscribed to the Google Groups "deal.II User Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email to dealii+unsubscribe@googlegroups.com.

Denis Davydov

unread,
Dec 19, 2016, 11:41:37 AM12/19/16
to dea...@googlegroups.com

> On 19 Dec 2016, at 17:39, Praveen C <cpra...@gmail.com> wrote:
>
> Since the test DEAL_II_HAVE_USABLE_FLAGS_DEBUG does not finish, does not give error, will git-bisect be able to help ?

sure, you just do bisect between current develop and 8.4.2. (which works for you) to see at which point
DEAL_II_HAVE_USABLE_FLAGS_DEBUG hangs.

Wolfgang Bangerth

unread,
Dec 19, 2016, 12:10:00 PM12/19/16
to dea...@googlegroups.com
On 12/19/2016 07:26 AM, Praveen C wrote:
>
> [ 50%] Linking CXX executable cmTC_4e156
>
> /home/spack/opt/spack/linux-opensuse20161217-x86_64/gcc-6/cmake-3.7.1-erobxw7bh6cbnaqfzaqwvzk6crnj5ojy/bin/cmake
> -E cmake_link_script CMakeFiles/cmTC_4e156.dir/link.txt --verbose=1
>
> /home/spack/opt/spack/linux-opensuse20161217-x86_64/gcc-6/openmpi-2.0.1-asdjmd22cnyktv2athcx3ouhrozknk22/bin/mpic++
> -DDEAL_II_HAVE_USABLE_FLAGS_DEBUG -pedantic -fPIC -Wall -Wextra
> -Wpointer-arith -Wwrite-strings -Wsynth -Wsign-compare -Wswitch
> -Woverloaded-virtual -Wno-long-long -Wno-placement-new
> -Wno-deprecated-declarations -Wno-literal-suffix -fopenmp-simd -std=c++14
> -Wno-unused-local-typedefs -Og -ggdb -Wa,--compress-debug-sections
> CMakeFiles/cmTC_4e156.dir/src.cxx.o -o cmTC_4e156 ......
>
>
> and never finishes.

I've only been following this thread with half an eye, but this seems like the
key to your problem. I you type this command onto the command line (or better,
copy-paste), does it hang as well? That would give you an indication that the
problem is actually with your mpic++ compiler, not with deal.II's cmake command.

If it does hang for more than just a couple seconds, remove one flag after the
other until you've found what the problem is. That should relatively easy to
do on the command line.

Best
W>

--
------------------------------------------------------------------------
Wolfgang Bangerth email: bang...@colostate.edu
www: http://www.math.colostate.edu/~bangerth/

Denis Davydov

unread,
Dec 19, 2016, 12:12:11 PM12/19/16
to dea...@googlegroups.com

> On 19 Dec 2016, at 18:09, Wolfgang Bangerth <bang...@colostate.edu> wrote:
>
> On 12/19/2016 07:26 AM, Praveen C wrote:
>>
>> [ 50%] Linking CXX executable cmTC_4e156
>>
>> /home/spack/opt/spack/linux-opensuse20161217-x86_64/gcc-6/cmake-3.7.1-erobxw7bh6cbnaqfzaqwvzk6crnj5ojy/bin/cmake
>> -E cmake_link_script CMakeFiles/cmTC_4e156.dir/link.txt --verbose=1
>>
>> /home/spack/opt/spack/linux-opensuse20161217-x86_64/gcc-6/openmpi-2.0.1-asdjmd22cnyktv2athcx3ouhrozknk22/bin/mpic++
>> -DDEAL_II_HAVE_USABLE_FLAGS_DEBUG -pedantic -fPIC -Wall -Wextra
>> -Wpointer-arith -Wwrite-strings -Wsynth -Wsign-compare -Wswitch
>> -Woverloaded-virtual -Wno-long-long -Wno-placement-new
>> -Wno-deprecated-declarations -Wno-literal-suffix -fopenmp-simd -std=c++14
>> -Wno-unused-local-typedefs -Og -ggdb -Wa,--compress-debug-sections
>> CMakeFiles/cmTC_4e156.dir/src.cxx.o -o cmTC_4e156 ......
>>
>>
>> and never finishes.
>
> I've only been following this thread with half an eye, but this seems like the key to your problem. I you type this command onto the command line (or better, copy-paste), does it hang as well? That would give you an indication that the problem is actually with your mpic++ compiler, not with deal.II's cmake command.

I doubt that it is related with compiler anyhow. Remember that the whole build works with 8.4.2 (same compiler, same MPI, same dependencies apart from GSL added in current master).


Praveen C

unread,
Dec 19, 2016, 12:31:48 PM12/19/16
to Deal.II Googlegroup
I replace mpic++ with /usr/bin/g++ but the command goes on forever. mpi is also from spack and I have only one mpi on this machine. gcc/g++ are from suse.

Best
praveen

Denis Davydov

unread,
Dec 19, 2016, 1:41:08 PM12/19/16
to dea...@googlegroups.com
I second Wolfagng’s suggestion to remove flags one-by-one from the command line and see which one make ld hang.
That’s also bisection in a sense, instead of working out which commit breaks it, you investigate which flag breaks it. 

My best guess is that some extra checks have been added to CMake scripts of deal.II which break usage on this OS/version of compiler.
It may as well be a compiler bug, either way we need to find out which flag it is and then we can dig into where exactly and why this flag gets added.

Kind regards,
Denis 

You received this message because you are subscribed to a topic in the Google Groups "deal.II User Group" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/dealii/eG75p2TVNNQ/unsubscribe.
To unsubscribe from this group and all its topics, send an email to dealii+un...@googlegroups.com.

Praveen C

unread,
Dec 19, 2016, 11:20:20 PM12/19/16
to Deal.II Googlegroup
I removed all the libraries and do

/home/spack/opt/spack/linux-opensuse20161217-x86_64/gcc-6/openmpi-2.0.1-asdjmd22cnyktv2athcx3ouhrozknk22/bin/mpic++    -DDEAL_II_HAVE_USABLE_FLAGS_DEBUG -pedantic -fPIC -Wall -Wextra -Wpointer-arith -Wwrite-strings -Wsynth -Wsign-compare -Wswitch -Woverloaded-virtual -Wno-long-long -Wno-placement-new -Wno-deprecated-declarations -Wno-literal-suffix -fopenmp-simd -std=c++14 -Wno-unused-local-typedefs -Og -ggdb -Wa,--compress-debug-sections    CMakeFiles/cmTC_427e9.dir/src.cxx.o  -o cmTC_427e9


which works. There are whole bunch of libraries that are being linked and one of them seems to be causing the problem. As I mentioned before, disabling Trilinos, I pass the cmake stage.

Best
praveen

Denis Davydov

unread,
Dec 20, 2016, 12:52:26 AM12/20/16
to deal.II User Group
I think that's wrong direction to dig because you said 8.4.2 works for you WITH Trilinos, right? 
So I would say the fact that current master builds without Trilinos is coincidental.

Did you try removing flags or doing git bisection?

Regards,
Denis.

Wolfgang Bangerth

unread,
Dec 20, 2016, 2:38:55 AM12/20/16
to dea...@googlegroups.com
On 12/19/2016 09:19 PM, Praveen C wrote:
> I removed all the libraries and do
>
> /home/spack/opt/spack/linux-opensuse20161217-x86_64/gcc-6/openmpi-2.0.1-asdjmd22cnyktv2athcx3ouhrozknk22/bin/mpic++
> -DDEAL_II_HAVE_USABLE_FLAGS_DEBUG -pedantic -fPIC -Wall -Wextra
> -Wpointer-arith -Wwrite-strings -Wsynth -Wsign-compare -Wswitch
> -Woverloaded-virtual -Wno-long-long -Wno-placement-new
> -Wno-deprecated-declarations -Wno-literal-suffix -fopenmp-simd -std=c++14
> -Wno-unused-local-typedefs -Og -ggdb -Wa,--compress-debug-sections
> CMakeFiles/cmTC_427e9.dir/src.cxx.o -o cmTC_427e9
>
>
> which works. There are whole bunch of libraries that are being linked and one
> of them seems to be causing the problem.

You need to find out which one it is. Just start with the original command
line and remove things one by one until you can't remove anything any more
without the problem happening.

Best
W.

Praveen C

unread,
Dec 20, 2016, 5:33:09 AM12/20/16
to Deal.II Googlegroup
Without Trilinos, the linking takes 0.307s

So I am adding one library from Trilinos after another. I find that as I add more Trilinos libraries, the linking takes increasing time.

until libifpack.so ==> 3m 47s
until libzoltan2.so ==> 3m 54s
until libaztecoo.so ==> 10m 6s

These times are already too high. So there is no single library in Trilinos that is causing problem. Whole of Trilinos seems to be problematic.

I added --verbose to the linking step and here are some flags used

$ sh CMakeFiles/cmTC_a2bf5.dir/link.txt 

Using built-in specs.

COLLECT_GCC=/usr/bin/g++

COLLECT_LTO_WRAPPER=/usr/lib64/gcc/x86_64-suse-linux/6/lto-wrapper

Target: x86_64-suse-linux

Configured with: ../configure --prefix=/usr --infodir=/usr/share/info --mandir=/usr/share/man --libdir=/usr/lib64 --libexecdir=/usr/lib64 --enable-languages=c,c++,objc,fortran,obj-c++,java,ada,go --enable-offload-targets=hsa --enable-checking=release --with-gxx-include-dir=/usr/include/c++/6 --enable-ssp --disable-libssp --disable-libvtv --disable-libcc1 --enable-plugin --with-bugurl=http://bugs.opensuse.org/ --with-pkgversion='SUSE Linux' --disable-libgcj --with-slibdir=/lib64 --with-system-zlib --enable-__cxa_atexit --enable-libstdcxx-allocator=new --disable-libstdcxx-pch --enable-version-specific-runtime-libs --enable-linker-build-id --enable-linux-futex --enable-gnu-indirect-function --program-suffix=-6 --without-system-libunwind --enable-multilib --with-arch-32=x86-64 --with-tune=generic --build=x86_64-suse-linux --host=x86_64-suse-linux

Thread model: posix

gcc version 6.2.1 20161209 [gcc-6-branch revision 243481] (SUSE Linux) 

COMPILER_PATH=/usr/lib64/gcc/x86_64-suse-linux/6/:/usr/lib64/gcc/x86_64-suse-linux/6/:/usr/lib64/gcc/x86_64-suse-linux/:/usr/lib64/gcc/x86_64-suse-linux/6/:/usr/lib64/gcc/x86_64-suse-linux/:/usr/lib64/gcc/x86_64-suse-linux/6/../../../../x86_64-suse-linux/bin/

LIBRARY_PATH=/usr/lib64/gcc/x86_64-suse-linux/6/:/usr/lib64/gcc/x86_64-suse-linux/6/../../../../lib64/:/lib/../lib64/:/usr/lib/../lib64/:/usr/lib64/gcc/x86_64-suse-linux/6/../../../../x86_64-suse-linux/lib/:/usr/lib64/gcc/x86_64-suse-linux/6/../../../:/lib/:/usr/lib/

COLLECT_GCC_OPTIONS='-v' '-D' 'DEAL_II_HAVE_USABLE_FLAGS_DEBUG' '-Wpedantic' '-fPIC' '-Wall' '-Wextra' '-Wpointer-arith' '-Wwrite-strings' '-Wsynth' '-Wsign-compare' '-Wswitch' '-Woverloaded-virtual' '-Wno-long-long' '-Wplacement-new=0' '-Wno-deprecated-declarations' '-Wno-literal-suffix' '-fopenmp-simd' '-std=c++14' '-Wno-unused-local-typedefs' '-Og' '-ggdb' '-o' 'cmTC_a2bf5' '-L/home/spack/opt/spack/linux-opensuse20161217-x86_64/gcc-6/tbb-2017.3-zeacdx23pi4h4lrlo5xxg7p3ihx5qt4q/lib' '-rdynamic' '-rdynamic' '-ggdb' '-I' '/home/spack/opt/spack/linux-opensuse20161217-x86_64/gcc-6/openmpi-2.0.1-asdjmd22cnyktv2athcx3ouhrozknk22/include' '-pthread' '-L/home/spack/opt/spack/linux-opensuse20161217-x86_64/gcc-6/hwloc-1.11.4-7osold4o3nkppdzghwo5fjlgmxpsqb4h/lib' '-L/home/spack/opt/spack/linux-opensuse20161217-x86_64/gcc-6/openmpi-2.0.1-asdjmd22cnyktv2athcx3ouhrozknk22/lib64' '-shared-libgcc' '-mtune=generic' '-march=x86-64'


Best
praveen


Praveen C

unread,
Dec 20, 2016, 5:55:57 AM12/20/16
to Deal.II Googlegroup
Denis, I observe that dea...@8.4.2 and dealii@develop install their own separate Boost, same version but maybe different variants/flags. Trilinos also needs Boost. Could there be some issue with dependencies like Boost ?

Best
praveen

Denis Davydov

unread,
Dec 20, 2016, 6:12:11 AM12/20/16
to dea...@googlegroups.com

> On 20 Dec 2016, at 11:55, Praveen C <cpra...@gmail.com> wrote:
>
> Denis, I observe that dea...@8.4.2 and dealii@develop install their own separate Boost, same version but maybe different variants/flags. Trilinos also needs Boost. Could there be some issue with

that’s correct observation and expected behaviour.
This happens because @develop has `python` wrappers turned on by default, and therefore requires boost with `+python` module.
This requirement is given in

depends_on(
"bo...@1.59.0:+thread+system+serialization+iostreams+mpi+python",
when='@8.5.0:+mpi+python’)

consequently, when the graph of packages is concretised, boost will have `+python`, and of course both `trilinos` and `dealii@develop` will use it.

You can disable python wrappers and consequently use `boost~python` run doing

`spack install dealii@develop~python`

To make sure Python part of the boost will not be used, you can double check `spack spec dealii@develop~python | grep boost`
which will show you all info about `boost` to be used (compiler, architecture, variants).

> dependencies like Boost ?


Regards,
Denis.

Denis Davydov

unread,
Dec 20, 2016, 6:15:15 AM12/20/16
to dea...@googlegroups.com
On 20 Dec 2016, at 11:32, Praveen C <cpra...@gmail.com> wrote:

Without Trilinos, the linking takes 0.307s

So I am adding one library from Trilinos after another. I find that as I add more Trilinos libraries, the linking takes increasing time.

until libifpack.so ==> 3m 47s
until libzoltan2.so ==> 3m 54s
until libaztecoo.so ==> 10m 6s

These times are already too high. So there is no single library in Trilinos that is causing problem. Whole of Trilinos seems to be problematic.

I fail to imagine how building boost+python may break Trilinos, whereas boost~python works without any problems in dea...@8.4.2 .
I still think it’s not related to Trilinos anyhow…

Regards,
Denis.

Praveen C

unread,
Dec 20, 2016, 7:53:19 AM12/20/16
to Deal.II Googlegroup
Hello Denis

I am not able to do either

spack install dealii@develop~python

or

spack install dea...@8.4.2

It fails at Boost

==> Using cached archive: /home/spack/var/spack/cache/boost/boost-1.62.0.tar.bz2

==> Already staged boost-1.62.0-iha4a5u6hustzchy6iglss5gbz2ujrvc in /home/spack/var/spack/stage/boost-1.62.0-iha4a5u6hustzchy6iglss5gbz2ujrvc

==> No patches needed for boost

==> Building boost [Package]

==> Executing phase : 'install'

==> Error: ProcessError: ./bootstrap.sh: No such file or directory

    Command: './bootstrap.sh' '--prefix=/home/spack/opt/spack/linux-opensuse20161217-x86_64/gcc-6/boost-1.62.0-iha4a5u6hustzchy6iglss5gbz2ujrvc' '--with-toolset=gcc' '--with-libraries=locale,random,wave,atomic,serialization,mpi,iostreams,regex,date_time,log,thread,chrono,system,timer,signals,program_options,filesystem,test,math'

/home/spack/var/spack/repos/builtin/packages/boost/package.py:309, in install:


Last time I tried some days back, I could install dea...@8.4.2 :-(

Best

praveen

Denis Davydov

unread,
Dec 20, 2016, 9:52:05 AM12/20/16
to dea...@googlegroups.com
Hi Praveen,

Now we are back to Spack land…

For starters, make sure you delete all temporary build folders in 

/home/spack/var/spack/stage/

and re-try.

If this does not help, then do `git pull` in /home/spack/ so that we are on the same Spack version.
In order to double check that Spack works as expected, 
I just wiped my deal.II on Ubuntu 16.04 and successfully re-installed dea...@8.4.2  with g...@5.4.0 (from Ubuntu) using 
Spack’s commit 3f1cdbf5efb6092d806a25f35c87b7b6b3b78364 (HEAD of develop branch at the time of writing).

Regards,
Denis.

Praveen C

unread,
Dec 20, 2016, 10:14:32 AM12/20/16
to Deal.II Googlegroup
Denis, thanks, I had to delete boost directory in spack to get this to work.

Since this thread is becoming too long, and may no be of interest to all, I opened an issue here


Best
praveen

Reply all
Reply to author
Forward
0 new messages