Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

move python source in examples under python/ subdir #350

Merged
merged 1 commit into from
Aug 6, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions examples/hello-world-script/MANIFEST.in
Original file line number Diff line number Diff line change
@@ -1,2 +1,3 @@
include Cargo.toml
recursive-include src *
recursive-include python *
4 changes: 3 additions & 1 deletion examples/hello-world-script/setup.py
Original file line number Diff line number Diff line change
@@ -1,10 +1,12 @@
from setuptools import setup
from setuptools import find_packages, setup

from setuptools_rust import RustExtension, Binding

setup(
name="hello-world-script",
version="1.0",
packages=find_packages(where="python"),
package_dir={"": "python"},
rust_extensions=[
RustExtension(
{"hello-world-script": "hello_world.hello-world-script"},
Expand Down
1 change: 1 addition & 0 deletions examples/hello-world/MANIFEST.in
Original file line number Diff line number Diff line change
@@ -1,2 +1,3 @@
include Cargo.toml
recursive-include src *
recursive-include python *
4 changes: 3 additions & 1 deletion examples/hello-world/setup.py
Original file line number Diff line number Diff line change
@@ -1,10 +1,12 @@
from setuptools import setup
from setuptools import find_packages, setup

from setuptools_rust import RustBin

setup(
name="hello-world",
version="1.0",
packages=find_packages(where="python"),
package_dir={"": "python"},
rust_extensions=[
RustBin(
"hello-world",
Expand Down
1 change: 1 addition & 0 deletions examples/html-py-ever/MANIFEST.in
Original file line number Diff line number Diff line change
@@ -1,2 +1,3 @@
include Cargo.toml
recursive-include src *
recursive-include python *
5 changes: 3 additions & 2 deletions examples/html-py-ever/setup.py
Original file line number Diff line number Diff line change
@@ -1,10 +1,11 @@
#!/usr/bin/env python
import sys

from setuptools import setup
from setuptools import find_packages, setup

from setuptools_rust import RustExtension

setup(
packages=find_packages(where="python"),
package_dir={"": "python"},
rust_extensions=[RustExtension("html_py_ever.html_py_ever")],
)
1 change: 1 addition & 0 deletions examples/namespace_package/MANIFEST.in
Original file line number Diff line number Diff line change
@@ -1,2 +1,3 @@
include Cargo.toml
recursive-include src *
recursive-include python *
3 changes: 2 additions & 1 deletion examples/namespace_package/setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,8 @@
setup(
name="namespace_package",
version="0.1.0",
packages=find_namespace_packages(include=["namespace_package.*"]),
packages=find_namespace_packages(include=["namespace_package.*"], where="python"),
package_dir={"": "python"},
zip_safe=False,
rust_extensions=[
RustExtension(
Expand Down
1 change: 1 addition & 0 deletions examples/rust_with_cffi/MANIFEST.in
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
include Cargo.toml
include cffi_module.py
recursive-include src *
recursive-include python *
5 changes: 3 additions & 2 deletions examples/rust_with_cffi/setup.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
#!/usr/bin/env python
from setuptools import setup
from setuptools import find_packages, setup
from setuptools_rust import RustExtension

setup(
Expand All @@ -14,7 +14,8 @@
"Operating System :: POSIX",
"Operating System :: MacOS :: MacOS X",
],
packages=["rust_with_cffi"],
packages=find_packages(where="python"),
package_dir={"": "python"},
rust_extensions=[
RustExtension("rust_with_cffi.rust", py_limited_api="auto"),
],
Expand Down