Files
rapidocr/python/pyproject.toml
T
SWHL 86b48d2c96 feat: optimize the wheel packaging process (#687)
* chore: add pyproject toml configuration

* build: migrate RapidOCR wheel packaging to pyproject.toml

- add PEP 517 setuptools build configuration
- derive package version from git tags via setuptools-scm
- move wheel model preparation into an explicit tools script
- generate MANIFEST.in for default model assets before building
- avoid importing rapidocr during package metadata generation

* ci: build release wheels from validated git tags

* build: align package runtime support with Python 3.8

- set Requires-Python to >=3.8
- remove Python 3.6 and 3.7 classifiers
- make wheel asset preparation script type hints Python 3.8 compatible
- clarify split between build-time and wheel runtime support
2026-06-12 17:19:53 +08:00

68 lines
1.5 KiB
TOML

[build-system]
requires = [
"setuptools>=77",
"wheel",
"setuptools-scm>=8",
]
build-backend = "setuptools.build_meta"
[project]
name = "rapidocr"
dynamic = ["version", "dependencies"]
description = "Awesome OCR Library"
readme = { file = "README.md", content-type = "text/markdown" }
requires-python = ">=3.8,<4"
license = "Apache-2.0"
authors = [
{ name = "SWHL", email = "liekkaskono@163.com" },
]
keywords = [
"ocr",
"text_detection",
"text_recognition",
"db",
"onnxruntime",
"paddleocr",
"openvino",
"rapidocr",
]
classifiers = [
"Programming Language :: Python :: 3.8",
"Programming Language :: Python :: 3.9",
"Programming Language :: Python :: 3.10",
"Programming Language :: Python :: 3.11",
"Programming Language :: Python :: 3.12",
"Programming Language :: Python :: 3.13",
]
[project.urls]
Documentation = "https://rapidai.github.io/RapidOCRDocs"
Changelog = "https://github.com/RapidAI/RapidOCR/releases"
[project.scripts]
rapidocr = "rapidocr.main:main"
[tool.setuptools]
include-package-data = true
platforms = ["Any"]
[tool.setuptools.dynamic]
dependencies = { file = ["requirements.txt"] }
[tool.setuptools.packages.find]
where = ["."]
include = ["rapidocr*"]
exclude = ["tests*"]
namespaces = false
[tool.setuptools.package-data]
rapidocr = [
"**/*.yaml",
]
[tool.setuptools_scm]
root = ".."
tag_regex = "^v?(?P<version>[0-9]+(?:\\.[0-9]+)*.*)$"
version_file = "rapidocr/_version.py"
local_scheme = "no-local-version"