blob: b0b9cf43c147875cdee76fddb3768d7142d45500 [file] [log] [blame]
# Copyright 2020 Google LLC
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# https://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
# Build platform specific wheel files for the pyiree.rt package.
# Built artifacts are per-platform and build out of the build tree.
import os
from setuptools import setup, find_namespace_packages, Extension
import sysconfig
README = """# IREE Python Runtime Components
This package provides an API for running compiled IREE binaries and interfacing
with the hardware-abstraction-layer.
"""
setup(
name="iree-runtime@IREE_RELEASE_PACKAGE_SUFFIX@",
version="@IREE_RELEASE_VERSION@",
author="The IREE Team",
author_email="iree-discuss@googlegroups.com",
license="Apache",
description="IREE Python Runtime Components",
long_description=README,
long_description_content_type="text/markdown",
url="https://github.com/google/iree",
classifiers=[
"Programming Language :: Python :: 3",
"License :: OSI Approved :: Apache License",
"Operating System :: OS Independent",
"Development Status :: 3 - Alpha",
],
python_requires=">=3.6",
packages=find_namespace_packages(include=["pyiree.rt", "pyiree.rt.*"]),
ext_modules=[
Extension(name="pyiree.rt.binding", sources=[]),
],
# Matching the native extension as a data file keeps setuptools from
# "building" it (i.e. turning it into a static binary).
package_data={
"": [f"*{sysconfig.get_config_var('EXT_SUFFIX')}"],
},
zip_safe=False,
)