summaryrefslogtreecommitdiff
path: root/tvm-vendor.spec
diff options
context:
space:
mode:
authorCoprDistGit <infra@openeuler.org>2026-10-22 10:34:01 +0000
committerCoprDistGit <infra@openeuler.org>2026-10-22 10:34:01 +0000
commit8e3d5bbee85eb75d1c14e7cf2896c10c1cd7da9c (patch)
treeecb57f6e6b0a4d94be26f6e96425a0b1dd491edb /tvm-vendor.spec
parentb5301cdf557089bb3e87ce82413bc9a893c5e2cb (diff)
automatic import of ros-humble-tvm-vendor
Diffstat (limited to 'tvm-vendor.spec')
-rw-r--r--tvm-vendor.spec78
1 files changed, 78 insertions, 0 deletions
diff --git a/tvm-vendor.spec b/tvm-vendor.spec
new file mode 100644
index 0000000..4f4edde
--- /dev/null
+++ b/tvm-vendor.spec
@@ -0,0 +1,78 @@
+%define ros_distro humble
+%define RosPkgName tvm-vendor
+%define src_version 0.9.1-1
+
+Name: ros-%{ros_distro}-%{RosPkgName}
+Version: 0.9.1
+Release: 1%{?dist}
+Summary: Wrapper around Apache TVM to make it available to the ROS ecosystem.
+License: Apache License 2.0
+URL: https://github.com/autowarefoundation/tvm_vendor/tree/main
+Source0: %{RosPkgName}-%{src_version}.tar.gz
+
+%global debug_package %{nil}
+%global __os_install_post %(echo '%{__os_install_post}' | sed -e 's!/usr/lib[^[:space:]]*/brp-python-bytecompile[[:space:]].*$!!g')
+%global __provides_exclude_from ^/opt/ros/%{ros_distro}/.*$
+%global __requires_exclude_from ^/opt/ros/%{ros_distro}/.*$
+
+BuildRequires: cmake
+BuildRequires: ros-%{ros_distro}-ament-cmake
+BuildRequires: ros-%{ros_distro}-ros-environment
+BuildRequires: spirv-headers-devel
+BuildRequires: vulkan-loader-devel
+BuildRequires: git
+BuildRequires: openblas-devel
+BuildRequires: libxml2
+BuildRequires: ocl-icd-devel
+BuildRequires: opencl-headers
+BuildRequires: spirv-tools
+
+Requires: ros-%{ros_distro}-ros-workspace
+Requires: ros-%{ros_distro}-ament-cmake
+Requires: spirv-headers-devel
+Requires: vulkan-loader-devel
+Requires: git
+Requires: openblas-devel
+Requires: libxml2
+Requires: ocl-icd-devel
+Requires: opencl-headers
+Requires: spirv-tools
+
+Provides: %{name}-devel = %{version}-%{release}
+Provides: %{name}-doc = %{version}-%{release}
+Provides: %{name}-runtime = %{version}-%{release}
+
+%description
+Wrapper around Apache TVM to make it available to the ROS ecosystem.
+
+%prep
+%autosetup -n %{RosPkgName}-%{src_version}
+
+%build
+[ -f /opt/ros/%{ros_distro}/setup.sh ] && source /opt/ros/%{ros_distro}/setup.sh || true
+export PYTHONPATH=/opt/ros/%{ros_distro}/lib/python%{python3_version}/site-packages${PYTHONPATH:+:$PYTHONPATH}
+export PKG_CONFIG_PATH=/opt/ros/%{ros_distro}/lib/pkgconfig${PKG_CONFIG_PATH:+:$PKG_CONFIG_PATH}
+mkdir -p .obj && cd .obj
+%cmake3 \
+ -DCMAKE_INSTALL_PREFIX="/opt/ros/%{ros_distro}" \
+ -DAMENT_PREFIX_PATH="/opt/ros/%{ros_distro}" \
+ -DCMAKE_PREFIX_PATH="/opt/ros/%{ros_distro}" \
+ -UINCLUDE_INSTALL_DIR -ULIB_INSTALL_DIR -USYSCONF_INSTALL_DIR -USHARE_INSTALL_PREFIX -ULIB_SUFFIX \
+ -DSETUPTOOLS_DEB_LAYOUT=OFF \
+ -DBUILD_TESTING=OFF -DTESTING=OFF -DCMAKE_SUPPRESS_REGENERATION=ON \
+ ..
+make %{?_smp_mflags}
+
+%install
+[ -f /opt/ros/%{ros_distro}/setup.sh ] && source /opt/ros/%{ros_distro}/setup.sh || true
+export PYTHONPATH=/opt/ros/%{ros_distro}/lib/python%{python3_version}/site-packages${PYTHONPATH:+:$PYTHONPATH}
+export PKG_CONFIG_PATH=/opt/ros/%{ros_distro}/lib/pkgconfig${PKG_CONFIG_PATH:+:$PKG_CONFIG_PATH}
+cd .obj
+make install DESTDIR=%{buildroot}
+
+%files
+/opt/ros/%{ros_distro}
+
+%changelog
+* Thu Oct 22 2026 ai-importer <ai-importer@openeuler.org> - 0.9.1-1
+- Initial import (ROS batch)