[Dune] CMake to link an executable

Aleksejs Fomins aleksejs.fomins at lspr.ch
Wed Jul 29 14:24:09 CEST 2015


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Dear Dune,

I am currently testing the performance of integration in our curvilinear code, and for that purpose I need to temporarily integrate an external library into a dummy dune module.

The library I am trying out is
http://ab-initio.mit.edu/wiki/index.php/Cubature

To use this library, one needs to include a corresponding .h file, and to link a corresponding .c file, namely

cc -DHCUBATURE -o htest hcubature.c test.c -lm

Could somebody suggest how I can link a .c file to my program in CMake?

Greetings,
Aleksejs
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.12 (GNU/Linux)

iQIcBAEBAgAGBQJVuMXpAAoJEDkNM7UOEwMZ0vQQAN1FBwtT2tEAvmi51zHEj+RV
CluSi1SvzXo72083QoICIrdSS9Eu3KD/U0MQlNtqNlIHewB+6uQEvN6zR0gnXJd2
c+LkI7GBF9fuA0UAO4luIXjEbmZ+nLBioIUoqgWaeQrxifcXXcVcQbMIUmVwjG7Q
o4Etmwfg85O+SJ1PnJckhVRJwaGRxaQ9qHKsk3U6A0IeD5Ny4MZcsrwhZBROdW86
Q0GEd55Cf5OMKSWxIh5bfMhnIJYXRLVc2QEmPCxsRvB8V4F8pW7whFthIwj/z1zc
5exr3MmsSinIF54b562MU5Dt6dLvnWUTmxBJRgY+La5E/3CUL4uolNX+OY56zNcZ
m/BPH3vV5AuQTQ++00016VmPY73x3eCA+zbGw3dWFHXkHL1dS4PcZOgecJToPHqX
plOnDxd//oa438KHNU7n5bj6/TO805qeSUHfyd4P1GzDAE5iSXO0sB9Cr+Lghm6H
RtzFr1q0Nqg0XNwVMm5+gzctiyFeIlROIVuXtPNj6Dp5DDAqcgdgv5QIFCTiwuHT
b8rSYP69D1m0CRlwJEZEClhH4Yx79j6+HgKqNRWA+HGIbPtSe7SEblt8ESbo9w/4
i3AOrYtNhQqCJPXgE1+CpyRbKM9wy14NXqIfxCmnC3gY+YFIviOdbqP4GeXbTIzR
AMWfk5RbBzO1JGcC0vL2
=6cxt
-----END PGP SIGNATURE-----




More information about the Dune mailing list