Skip to content

Commit

Permalink
Test Python module to reproduce TRIQS/cpp2py#7
Browse files Browse the repository at this point in the history
  • Loading branch information
krivenko committed Nov 17, 2017
1 parent b535177 commit e6c1a67
Show file tree
Hide file tree
Showing 2 changed files with 18 additions and 0 deletions.
5 changes: 5 additions & 0 deletions python/cthyb/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,11 @@ target_link_libraries(solver_core cthyb_c)
# We need to include the convertes.hxx files
target_include_directories(solver_core PRIVATE ${CMAKE_CURRENT_SOURCE_DIR})

# Test module
add_cpp2py_module(test_module)
target_link_libraries(test_module cthyb_c)
target_include_directories(test_module PRIVATE ${CMAKE_CURRENT_SOURCE_DIR})

# Configure the version
configure_file(version.py.in version.py)

Expand Down
13 changes: 13 additions & 0 deletions python/cthyb/test_module_desc.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
from cpp2py.wrap_generator import *

# The module
module = module_(full_name = "test_module", doc = "The cthyb solver", app_name = "solver_core")

# Imports
import pytriqs.gf
import pytriqs.operators
import pytriqs.statistics.histograms
import pytriqs.atom_diag
import solver_core

module.generate_code()

0 comments on commit e6c1a67

Please sign in to comment.