[aspect-devel] compile error on MAC OSX

Wolfgang Bangerth bangerth at math.tamu.edu
Fri Jul 4 01:05:49 PDT 2014


> The real problem is that we do not explicitly instantiate this function:
>
>    template <class DH>
>    void
>    extract_boundary_dofs (const DH                      &dof_handler,
>                           const ComponentMask       &component_mask,
>                           IndexSet             &selected_dofs,
>                           const std::set<types::boundary_id> &boundary_ids)
>
> in dof_tools.inst.in. Magali's compiler decides simply not to export the
> implicit instantiation from the shared library. We need to add an explicit
> instantiation to the .inst.in file to make this work reliably.

Magali -- can you try to apply the attached patch to your local deal.II 
installation, re-compile the library (no need to re-run cmake if you still 
have the build directory around) and then see if you can link Aspect?

Best
  Wolfgang


-- 
------------------------------------------------------------------------
Wolfgang Bangerth               email:            bangerth at math.tamu.edu
                                 www: http://www.math.tamu.edu/~bangerth/

-------------- next part --------------
Index: source/dofs/dof_tools.inst.in
===================================================================
--- source/dofs/dof_tools.inst.in	(revision 33105)
+++ source/dofs/dof_tools.inst.in	(working copy)
@@ -168,6 +168,7 @@
  const ComponentMask                  &,
  std::vector<bool>                        &,
  const std::set<types::boundary_id> &);
+
 template
 void
 DoFTools::extract_boundary_dofs<hp::DoFHandler<deal_II_dimension> >
@@ -178,6 +179,22 @@
 
 template
 void
+DoFTools::extract_boundary_dofs<DoFHandler<deal_II_dimension> >
+(const DoFHandler<deal_II_dimension> &,
+ const ComponentMask                  &,
+ IndexSet                        &,
+ const std::set<types::boundary_id> &);
+
+template
+void
+DoFTools::extract_boundary_dofs<hp::DoFHandler<deal_II_dimension> >
+(const hp::DoFHandler<deal_II_dimension> &,
+ const ComponentMask                  &,
+ IndexSet                        &,
+ const std::set<types::boundary_id> &);
+
+template
+void
 DoFTools::extract_dofs_with_support_on_boundary<DoFHandler<deal_II_dimension> >
 (const DoFHandler<deal_II_dimension> &,
  const ComponentMask                  &,
@@ -326,11 +343,21 @@
    const ComponentMask                  &,
    std::vector<bool>                        &,
    const std::set<types::boundary_id> &);
+
 template
+void
+DoFTools::extract_boundary_dofs<DoFHandler<deal_II_dimension,deal_II_dimension+1> >
+  (const DoFHandler<deal_II_dimension,deal_II_dimension+1> &,
+   const ComponentMask                  &,
+   IndexSet                        &,
+   const std::set<types::boundary_id> &);
+
+template
 unsigned int
 DoFTools::count_dofs_with_subdomain_association<DoFHandler<deal_II_dimension,deal_II_dimension+1> >
 (const DoFHandler<deal_II_dimension,deal_II_dimension+1> &,
  const types::subdomain_id);
+
 template
 IndexSet
 DoFTools::dof_indices_with_subdomain_association<DoFHandler<deal_II_dimension,deal_II_dimension+1> >
@@ -385,6 +412,14 @@
 
 template
 void
+DoFTools::extract_boundary_dofs<DoFHandler<1,3> >
+  (const DoFHandler<1,3> &,
+   const ComponentMask                  &,
+   IndexSet                        &,
+   const std::set<types::boundary_id> &);
+
+template
+void
 DoFTools::get_subdomain_association<DoFHandler<1,3> >
 (const DoFHandler<1,3> &dof_handler,
  std::vector<types::subdomain_id>           &subdomain_association);


More information about the Aspect-devel mailing list