Revert "Switch to standard pep517 sdist generation (#152098)"

This reverts commit f16053f0c9a09fa337fbf85aaf64f88712b8dcdb.

Reverted https://github.com/pytorch/pytorch/pull/152098 on behalf of https://github.com/malfet due to IMO this PR needs to be split into few helper ones, with better test plan ([comment](https://github.com/pytorch/pytorch/pull/152098#issuecomment-3024223880))
This commit is contained in:
PyTorch MergeBot
2025-07-01 14:14:52 +00:00
parent 1586521461
commit 023887fc5a
17 changed files with 106 additions and 193 deletions

View File

@ -1,91 +1,31 @@
# Include individual top-level files
include MANIFEST.in
include BUCK.oss
include BUILD.bazel
include CMakeLists.txt
include CITATION.cff
include CODEOWNERS
include Dockerfile
include LICENSE
include Makefile
include NOTICE
include WORKSPACE
include .bazelignore .bazelrc .bazelversion
include .clang-format .clang-tidy
include .cmakelintrc
include .coveragerc
include .dockerignore
include .flake8
include .gdbinit
include .lintrunner.toml
include .lldbinit
include docker.Makefile
include ubsan.supp
# Include bazel related files
include *.bzl
# Include general configuration files
include *.ini
# Include important top-level information
include *.md
# Include technical text files
include *.txt
# Include ctags configuration
include .ctags.d/*.ctags
# Include subfolders completely
graft .devcontainer
graft .vscode
graft android
# The following folder (assets) is empty except for a .gitignore file, which
# will not be included in the sdist, hence we include the directory explicitly.
include android/test_app/app/src/main/assets
graft aten
graft binaries
graft c10
graft caffe2
graft cmake
graft torch
graft tools
graft test
graft docs
graft ios
graft third_party
graft test
graft benchmarks
graft scripts
graft mypy_plugins
graft modules
graft functorch
graft torchgen
# The following exclusions omit parts from third-party dependencies that
# contain invalid symlinks[1] and that are not needed for pytorch, such as
# bindings for unused languages
prune third_party/ittapi/rust
prune third_party/flatbuffers/java
prune third_party/flatbuffers/kotlin
prune third_party/nccl/pkg/debian
prune third_party/opentelemetry-cpp/third_party/prometheus-cpp/cmake/project-import-*
# The following document is also an invalid symlink[1] and superfluous
exclude third_party/flatbuffers/docs/source/CONTRIBUTING.md
# Omit autogenerated code
prune torchgen/packaged
# Omit caches, compiled, and scm related content
include .gitmodules
include build_variables.bzl
include mypy.ini
include requirements.txt
include ufunc_defs.bzl
include version.txt
recursive-include android *.*
recursive-include aten *.*
recursive-include binaries *.*
recursive-include c10 *.*
recursive-include caffe2 *.*
recursive-include cmake *.*
recursive-include torch *.*
recursive-include tools *.*
recursive-include test *.*
recursive-include docs *.*
recursive-include ios *.*
recursive-include third_party *
recursive-include test *.*
recursive-include benchmarks *.*
recursive-include scripts *.*
recursive-include mypy_plugins *.*
recursive-include modules *.*
recursive-include functorch *.*
prune */__pycache__
prune **/.github
prune **/.gitlab
global-exclude *.o *.so *.dylib *.a
global-exclude *.pyc *.swp
global-exclude .git .git-blame-ignore-revs .gitattributes .gitignore .gitmodules
global-exclude .gitlab-ci.yml
# [1] Invalid symlinks for the purposes of Python source distributions are,
# according to the source distribution format[2] links pointing outside the
# destination directory or links with a `..` component, which is those of
# concern here.
# [2] https://packaging.python.org/en/latest/specifications/source-distribution-format/#source-distribution-archive-features
global-exclude *.o *.so *.dylib *.a .git *.pyc *.swp