Subject: [Unicorn-dev] problems compiling unicorn

From: Kristian Oelgaard <[email-masked]>
Date: Tue, 15 Jan 2008 20:15:30 +0100

Hi,

I cloned unicorn and tried to compile against dolfin-0.7.1

but when compiling:

oelgaard@mech028:~/fenics/unicorn$ ./scons.local
scons: Reading SConscript files ...
scons: done reading SConscript files.
scons: Building targets ...
g++ -o lib/ElasticFormFactory.o -c -g -O2 -Wall -Werror -pedantic -ansi
-Wno-long-long -std=c++98 -pthread -DHAVE_GTS_H=1 -DDEBUG -DNDEBUG
-I/home/oelgaard/fenics/dolfin-0.7.1/local/include -I/usr/include/libxml2
-I/usr/include/glib-2.0 -I/usr/lib/glib-2.0/include
-I/home/oelgaard/local/include -Ilib lib/ElasticFormFactory.cpp
g++ -o lib/ElasticSmoother.o -c -g -O2 -Wall -Werror -pedantic -ansi
-Wno-long-long -std=c++98 -pthread -DHAVE_GTS_H=1 -DDEBUG -DNDEBUG
-I/home/oelgaard/fenics/dolfin-0.7.1/local/include -I/usr/include/libxml2
-I/usr/include/glib-2.0 -I/usr/lib/glib-2.0/include
-I/home/oelgaard/local/include -Ilib lib/ElasticSmoother.cpp
cc1plus: warnings being treated as errors
lib/unicorn/TimeDependentPDE.h:28: warning: 'class
dolfin::unicorn::TimeDependentPDE' has virtual functions but non-virtual destructor
lib/unicorn/ElasticSmoother.h:259: warning: 'class
dolfin::unicorn::ElasticSmoother::ElasticityPDE' has virtual functions but
non-virtual destructor
lib/unicorn/ElasticSmoother.h: In constructor
'dolfin::unicorn::ElasticSmoother::Quality::Quality(dolfin::Mesh&)':
lib/unicorn/ElasticSmoother.h:108: warning: unused variable 'h'
lib/unicorn/ElasticSmoother.h: In member function 'virtual void
dolfin::unicorn::ElasticSmoother::Quality::eval(dolfin::real*, const
dolfin::real*) const':
lib/unicorn/ElasticSmoother.h:132: warning: unused variable 'd'
lib/unicorn/ElasticSmoother.h: In constructor
'dolfin::unicorn::ElasticSmoother::ElasticityPDE::ElasticityPDE(dolfin::Form*,
dolfin::Form*, dolfin::Form*, dolfin::Form*, dolfin::Form*, dolfin::Form*,
dolfin::Form*, dolfin::Mesh&, dolfin::BoundaryCondition&, dolfin::real,
dolfin::Function&, dolfin::Function&, dolfin::Function&, dolfin::real,
dolfin::MeshFunction<double>&)':
lib/unicorn/ElasticSmoother.h:515: warning:
'dolfin::unicorn::ElasticSmoother::ElasticityPDE::lastsample' will be
initialized after
lib/unicorn/ElasticSmoother.h:510: warning:   'dolfin::Form*
dolfin::unicorn::ElasticSmoother::ElasticityPDE::aP'
lib/unicorn/ElasticSmoother.h:270: warning:   when initialized here
lib/unicorn/ElasticSmoother.h:511: warning:
'dolfin::unicorn::ElasticSmoother::ElasticityPDE::LP' will be initialized after
lib/unicorn/ElasticSmoother.h:507: warning:   'dolfin::Form*
dolfin::unicorn::ElasticSmoother::ElasticityPDE::aS'
lib/unicorn/ElasticSmoother.h:270: warning:   when initialized here
lib/unicorn/ElasticSmoother.h:508: warning:
'dolfin::unicorn::ElasticSmoother::ElasticityPDE::LS' will be initialized after
lib/unicorn/ElasticSmoother.h:497: warning:   'dolfin::Function&
dolfin::unicorn::ElasticSmoother::ElasticityPDE::U'
lib/unicorn/ElasticSmoother.h:270: warning:   when initialized here
lib/unicorn/ElasticSmoother.h: In member function 'virtual void
dolfin::unicorn::ElasticSmoother::ElasticityPDE::u0(dolfin::uBlasVector&)':
lib/unicorn/ElasticSmoother.h:431: error: 'class dolfin::uBlasVector' has no
member named 'array'
lib/unicorn/ElasticSmoother.h:443: error: 'class dolfin::uBlasVector' has no
member named 'array'
lib/ElasticSmoother.cpp: In member function 'void
dolfin::unicorn::ElasticSmoother::maph0(dolfin::Mesh&, dolfin::Mesh&,
dolfin::MeshFunction<int>&, dolfin::MeshFunction<double>&,
dolfin::MeshFunction<double>&)':
lib/ElasticSmoother.cpp:23: warning: unused variable 'subid'
lib/ElasticSmoother.cpp: In member function 'void
dolfin::unicorn::ElasticSmoother::ElasticityPDE::deform(dolfin::Mesh&,
dolfin::Function&)':
lib/ElasticSmoother.cpp:365: warning: comparison between signed and unsigned
integer expressions
scons: *** [lib/ElasticSmoother.o] Error 1
scons: building terminated because of errors.

Kristian

---

From: Johan Jansson <[email-masked]>
Date: Wed, 16 Jan 2008 09:53:37 +0100

> scons: building terminated because of errors.
Hi!

Thanks for trying it out!

Some of the errors are due to me compiling against a dolfin repository 
changeset, I should also update DOLFIN with one or two changes I've done 
to the ODE interface. Some are new to me (from the debug flags), good 
that you found those. The uBlas errors are due to you not having 
compiled DOLFIN with PETSc I think. At this point Unicorn requires PETSc.

  Johan

---

From: Kristian Oelgaard <[email-masked]>
Date: Wed, 16 Jan 2008 10:26:20 +0100

> compiled DOLFIN with PETSc I think. At this point Unicorn requires PETSc.

OK, thanks.

Kristian

---

From: Kristian Oelgaard <[email-masked]>
Date: Wed, 16 Jan 2008 19:10:50 +0100

Quoting Kristian Oelgaard <[email-masked]>:

I just tried with the latest versions of Unicorn and DOLFIN. Everything seems to
be working, ran the convection demo without any problems.

Kristian

> > > 'dolfin::unicorn::ElasticSmoother::ElasticityPDE::LP' will be
> initialized
> > after
> > > 'dolfin::unicorn::ElasticSmoother::ElasticityPDE::LS' will be
> initialized
> > after
> > > lib/unicorn/ElasticSmoother.h:431: error: 'class dolfin::uBlasVector'
> has
> > no
> > > member named 'array'
> > > lib/unicorn/ElasticSmoother.h:443: error: 'class dolfin::uBlasVector'
> has
> > no
> > > member named 'array'
> _______________________________________________
> Unicorn-dev mailing list
> [email-masked]
> http://fenics.org/mailman/listinfo/unicorn-dev
>

---

From: Johan Jansson <[email-masked]>
Date: Thu, 17 Jan 2008 12:28:26 +0100

> be working, ran the convection demo without any problems.
Good! I still have some problems getting programs to run, perhaps I 
should look into my PETSc installation.

  Johan

---

From: Kristian Oelgaard <[email-masked]>
Date: Thu, 17 Jan 2008 13:03:34 +0100

> should look into my PETSc installation.

My configure options for PETSc 2.3.3-p7

Configure Options: --download-mpich=1 --with-clanguage=cxx --with-shared=1
--download-hypre=1 --download-f-blas-lapack=1 --download-umfpack=1 

I get warnings (treated as errors) because of uint/int comparison in
Coefficients.h (I configure DOLFIN with --enable-debug)

Kristian