Skip to content

Commit

Permalink
fix: include scripts during build
Browse files Browse the repository at this point in the history
  • Loading branch information
joshua-auchincloss committed Feb 18, 2024
1 parent 16461cf commit c95a588
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 4 deletions.
4 changes: 4 additions & 0 deletions test_libraries/src_structure/hatch.toml
Original file line number Diff line number Diff line change
Expand Up @@ -104,7 +104,11 @@ index = [
templated_mac = {supported = ["int", "float"]}
templated_win = {supported = ["int", "float", "complex"]}

[build.targets.sdist]
include = ["scripts/", "include/"]

[build.targets.wheel]
include = ["scripts/", "include/"]
packages = ["src/example_lib"]

[[envs.all.matrix]]
Expand Down
4 changes: 2 additions & 2 deletions test_libraries/src_structure/include/something.cc
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
typedef long long int64_t;
typedef long long int wide_int;

namespace pyutil
{
int64_t bwf(int64_t *val)
wide_int bwf(wide_int *val)
{
auto inter = ((*val) << 2);
return inter + (*val);
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,9 @@
# distutils: language=c++

ctypedef long long int wide_int

cdef extern from "something.cc" namespace "pyutil":
cdef long long bwf(long long *b)
cdef wide_int bwf(wide_int *b)

cpdef long long bwfpy(long long b):
cpdef wide_int bwfpy(wide_int b):
return bwf(&b)

0 comments on commit c95a588

Please sign in to comment.