Skip to content
Snippets Groups Projects
Verified Commit 5f3c8521 authored by João Magalhães's avatar João Magalhães :rocket:
Browse files

chore: initial setup support for python

parent c8454b7d
No related branches found
No related tags found
1 merge request!36Support for Python
Pipeline #3594 passed
*.pyc
.DS_Store
Cargo.lock
......@@ -5,6 +7,7 @@ Cargo.lock
/.idea
/ndk
/build
/target
/aarch64-linux-gnu
/res/roms.prop
......@@ -13,3 +16,5 @@ Cargo.lock
/src/gen/build.rs
/src/gen/_build.rs
/src/python/boytacean.egg-info
[bdist_wheel]
universal = 1
setup.py 0 → 100644
import sys
try:
import setuptools
except ImportError:
import subprocess
errno = subprocess.call([sys.executable, "-m", "pip", "install", "setuptools"])
if errno:
print("Please install setuptools package")
raise SystemExit(errno)
else:
import setuptools
try:
import setuptools_rust
except ImportError:
import subprocess
errno = subprocess.call(
[sys.executable, "-m", "pip", "install", "setuptools-rust"]
)
if errno:
print("Please install setuptools-rust package")
raise SystemExit(errno)
else:
import setuptools_rust
setuptools.setup(
name="boytacean",
version="0.9.16",
author="João Magalhães",
author_email="joamag@gmail.com",
description="A Game Boy emulator that is written in Rust",
license="Apache License, Version 2.0",
keywords="gameboy emulator rust",
url="https://boytacean.joao.me",
packages=["boytacean"],
package_dir = {
"" : os.path.normpath("src/python")
},
rust_extensions=[
setuptools_rust.RustExtension(
"boytacean.boytacean",
binding=setuptools_rust.Binding.PyO3,
features=["python"],
)
],
install_requires=[],
setup_requires=["setuptools-rust", "wheel"],
include_package_data=True,
zip_safe=False,
classifiers=[
"Development Status :: 5 - Production/Stable",
"Topic :: Utilities",
"License :: OSI Approved :: Apache Software License",
"Operating System :: OS Independent",
"Programming Language :: Python",
"Programming Language :: Python :: 3.5",
"Programming Language :: Python :: 3.6",
"Programming Language :: Python :: 3.7",
"Programming Language :: Python :: 3.8",
"Programming Language :: Python :: 3.9",
"Programming Language :: Python :: 3.10",
"Programming Language :: Python :: 3.11",
],
)
from .boytacean import *
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment