ADD_SUBDIRECTORY(cmake/config) # has to be included after source
ADD_SUBDIRECTORY(examples)
+ADD_SUBDIRECTORY(contrib/python-bindings/source)
+
IF(DEAL_II_HAVE_TESTS_DIRECTORY)
ADD_SUBDIRECTORY(tests)
ENDIF()
#ifndef dealii__triangulation_wrapper_h
#define dealii__triangulation_wrapper_h
+#include <point_wrapper.h>
#include <boost/python.hpp>
-#include <deal.II/python/point_wrapper.h>
#include <string>
#include <vector>
INCLUDE(FindPythonLibs)
INCLUDE(FindPythonInterp)
INCLUDE_DIRECTORIES(BEFORE ${CMAKE_CURRENT_BINARY_DIR})
+INCLUDE_DIRECTORIES(
+ ${CMAKE_BINARY_DIR}/include/
+ ${CMAKE_SOURCE_DIR}/include/
+ ${DEAL_II_BUNDLED_INCLUDE_DIRS}
+ ${DEAL_II_INCLUDE_DIRS}
+ ${CMAKE_SOURCE_DIR}/contrib/python-bindings/include/
+ )
INCLUDE_DIRECTORIES(SYSTEM ${PYTHON_INCLUDE_DIRS})
SET(_src
triangulation_wrapper.cc
)
-FILE(GLOB _header
- ${CMAKE_SOURCE_DIR}/include/deal.II/python/*.h
- )
-
-
PYTHON_ADD_MODULE(PyDealII ${_src})
SET(PYTHON_INSTALL_PREFIX ${CMAKE_INSTALL_PREFIX}/lib/python${PYTHON_VERSION_MAJOR}.${PYTHON_VERSION_MINOR}/site-packages)
SET(PYTHON_SOURCES
__init__.py
- dummy.py
)
+
FOREACH(PYTHON_SOURCE ${PYTHON_SOURCES})
ADD_CUSTOM_COMMAND(
OUTPUT ${CMAKE_BINARY_DIR}/python/pydealii/${PYTHON_SOURCE}
- DEPENDS ${CMAKE_SOURCE_DIR}/source/python/${PYTHON_SOURCE}
+ DEPENDS ${CMAKE_SOURCE_DIR}/contrib/python-bindings/source/${PYTHON_SOURCE}
COMMAND ${CMAKE_COMMAND}
- ARGS -E copy ${CMAKE_SOURCE_DIR}/source/python/${PYTHON_SOURCE} ${CMAKE_BINARY_DIR}/python/pydealii/${PYTHON_SOURCE}
+ ARGS -E copy ${CMAKE_SOURCE_DIR}/contrib/python-bindings/source/${PYTHON_SOURCE} ${CMAKE_BINARY_DIR}/python/pydealii/${PYTHON_SOURCE}
COMMENT "Copying ${PYTHON_SOURCE}"
)
ADD_CUSTOM_TARGET(
# ---------------------------------------------------------------------
from .PyDealII import *
-from .dummy import *
-__all__ = ['PyDealII', 'dummy']
+__all__ = ['PyDealII']
__doc__ = PyDealII.__doc__
//
// ---------------------------------------------------------------------
+#include <point_wrapper.h>
+#include <triangulation_wrapper.h>
+#include <cell_accessor_wrapper.h>
#include <boost/python.hpp>
-#include <deal.II/python/point_wrapper.h>
-#include <deal.II/python/triangulation_wrapper.h>
-#include <deal.II/python/cell_accessor_wrapper.h>
DEAL_II_NAMESPACE_OPEN
//
// ---------------------------------------------------------------------
+#include <cell_accessor_wrapper.h>
+#include <triangulation_wrapper.h>
#include <boost/python.hpp>
-#include <deal.II/python/cell_accessor_wrapper.h>
-#include <deal.II/python/triangulation_wrapper.h>
DEAL_II_NAMESPACE_OPEN
//
// ---------------------------------------------------------------------
-#include <boost/python.hpp>
-#include <deal.II/python/point_wrapper.h>
+#include <point_wrapper.h>
#include <deal.II/base/point.h>
#include <deal.II/base/exceptions.h>
+#include <boost/python.hpp>
DEAL_II_NAMESPACE_OPEN
//
// ---------------------------------------------------------------------
+#include <triangulation_wrapper.h>
+#include <cell_accessor_wrapper.h>
#include <boost/python.hpp>
-#include <deal.II/python/triangulation_wrapper.h>
-#include <deal.II/python/cell_accessor_wrapper.h>
DEAL_II_NAMESPACE_OPEN
//
// ---------------------------------------------------------------------
-#include <deal.II/python/point_wrapper.h>
+#include <point_wrapper.h>
#include <deal.II/base/point.h>
DEAL_II_NAMESPACE_OPEN
//
// ---------------------------------------------------------------------
-#include <deal.II/python/triangulation_wrapper.h>
-#include <deal.II/python/cell_accessor_wrapper.h>
+#include <triangulation_wrapper.h>
+#include <cell_accessor_wrapper.h>
#include <deal.II/grid/tria.h>
#include <deal.II/grid/grid_generator.h>
#include <deal.II/grid/grid_out.h>
ADD_SUBDIRECTORY(matrix_free)
ADD_SUBDIRECTORY(meshworker)
ADD_SUBDIRECTORY(opencascade)
-IF(DEAL_II_WITH_PYTHON)
- ADD_SUBDIRECTORY(python)
-ENDIF()
FOREACH(build ${DEAL_II_BUILD_TYPES})
STRING(TOLOWER ${build} build_lowercase)
+++ /dev/null
-# ---------------------------------------------------------------------
-#
-# Copyright (C) 2016 by the deal.II authors
-#
-# This file is part of the deal.II library.
-#
-# The deal.II library is free software; you can use it, redistribute
-# it, and/or modify it under the terms of the GNU Lesser General
-# Public License as published by the Free Software Foundation; either
-# version 2.1 of the License, or (at your option) any later version.
-# The full text of the license can be found in the file LICENSE at
-# the top level of the deal.II distribution.
-#
-# ---------------------------------------------------------------------
-
-"""This a dummy module that contains a global function and a class."""
-
-__all__ = ['Dummy', 'bar']
-
-def bar():
- """Print bar."""
- print('bar')
-
-class Dummy:
- """This a dummy class that has only one member function."""
-
- def foo(self):
- """Print foo."""
- print('foo')