%global _empty_manifest_terminate_build 0 Name: pytorch3D Version: 0.7.6 Release: 1 Summary: 3D deep learning in Python with strong GPU acceleration License: BSD-3 URL: https://pytorch3d.org/ Source0: https://openi.pcl.ac.cn/JunJun-Liu/pytorch3D/pytorch3d-0.7.6.tar.gz BuildRequires: g++ Requires: python3-future Requires: python3-numpy %description PyTorch3D is an extension of PyTorch designed to provide tools for 3D deep learning. It enables users to leverage the PyTorch ecosystem for developing, training, and deploying 3D deep learning models with strong GPU acceleration. %package -n python3-pytorch3D Summary: 3D deep learning in Python with strong GPU acceleration Provides: python3-pytorch3d BuildRequires: python3-devel BuildRequires: python3-setuptools BuildRequires: python3-setuptools_scm BuildRequires: python3-pbr BuildRequires: python3-pip BuildRequires: python3-wheel BuildRequires: python3-torch BuildRequires: python3-astunparse BuildRequires: python3-numpy BuildRequires: python3-pyyaml BuildRequires: cmake BuildRequires: python3-typing-extensions BuildRequires: python3-requests %description -n python3-pytorch3D PyTorch3D is an extension of PyTorch designed to provide tools for 3D deep learning. It integrates seamlessly with PyTorch and provides specialized modules and functions for 3D data processing and model development. %package help Summary: Development documents and examples for PyTorch3D Provides: python3-pytorch3d-doc %description help This package contains development documents and examples for PyTorch3D. It provides comprehensive guides and examples to help users understand and utilize the features of PyTorch3D for 3D deep learning tasks. %prep %autosetup -p1 -n pytorch3d-0.7.6 %build export CFLAGS+=" -Wno-error=maybe-uninitialized -Wno-error=uninitialized -Wno-error=restrict -fPIC" export CXXFLAGS+=" -Wno-error=maybe-uninitialized -Wno-error=uninitialized -Wno-error=restrict -fPIC" python3 setup.py build %install python3 setup.py install --skip-build --root %{buildroot} install -d -m755 %{buildroot}/%{_pkgdocdir} if [ -d doc ]; then cp -arf doc %{buildroot}/%{_pkgdocdir}; fi if [ -d docs ]; then cp -arf docs %{buildroot}/%{_pkgdocdir}; fi if [ -d example ]; then cp -arf example %{buildroot}/%{_pkgdocdir}; fi if [ -d examples ]; then cp -arf examples %{buildroot}/%{_pkgdocdir}; fi pushd %{buildroot} touch doclist.lst if [ -d usr/share/man ]; then find usr/share/man -type f -printf "/%h/%f.gz\n" >> doclist.lst fi popd mv %{buildroot}/doclist.lst . %files -n python3-pytorch3D %doc *.md %license LICENSE %{python3_sitearch}/* %files help -f doclist.lst %{_docdir}/* %changelog * Wed Feb 28 2024 Junjun Liu <172074482@qq.com> - 0.7.6-1 - Initial RPM release of PyTorch3D version 0.7.6. - Modified build and install process to accommodate non-pyproject environments. - Updated documentation and examples installation in package section.