git: fe981541b1ee - main - misc/py-pytorch: update 2.7.1 → 2.8.0
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Tue, 19 Aug 2025 15:45:34 UTC
The branch main has been updated by yuri:
URL: https://cgit.FreeBSD.org/ports/commit/?id=fe981541b1ee5b111bd6330c09f4c615dd4a7c20
commit fe981541b1ee5b111bd6330c09f4c615dd4a7c20
Author: Yuri Victorovich <yuri@FreeBSD.org>
AuthorDate: 2025-08-19 14:59:01 +0000
Commit: Yuri Victorovich <yuri@FreeBSD.org>
CommitDate: 2025-08-19 15:45:30 +0000
misc/py-pytorch: update 2.7.1 → 2.8.0
---
misc/py-pytorch/Makefile | 7 +++----
misc/py-pytorch/distinfo | 6 +++---
misc/py-pytorch/files/patch-CMakeLists.txt | 10 +++++-----
...fbgemm_third__party_asmjit_src_asmjit_core_virtmem.cpp | 10 ----------
misc/py-pytorch/files/patch-tools_build__pytorch__libs.py | 15 ++++++++-------
5 files changed, 19 insertions(+), 29 deletions(-)
diff --git a/misc/py-pytorch/Makefile b/misc/py-pytorch/Makefile
index 19d73b755f1a..a0661e8a4413 100644
--- a/misc/py-pytorch/Makefile
+++ b/misc/py-pytorch/Makefile
@@ -1,7 +1,6 @@
PORTNAME= pytorch
DISTVERSIONPREFIX= v
-DISTVERSION= 2.7.1
-PORTREVISION= 2
+DISTVERSION= 2.8.0
CATEGORIES= misc # machine-learning
MASTER_SITES= https://github.com/pytorch/pytorch/releases/download/v${DISTVERSION}/
PKGNAMEPREFIX= ${PYTHON_PKGNAMEPREFIX}
@@ -79,9 +78,9 @@ USES+= llvm:max=15
post-patch:
@cd ${WRKSRC} && \
- ${RM} -r third_party/cpuinfo third_party/fbgemm/third_party/cpuinfo && \
+ ${RM} -r third_party/cpuinfo third_party/fbgemm/external/cpuinfo && \
${CP} -r cpuinfo-with-freebsd-support third_party/cpuinfo && \
- ${CP} -r cpuinfo-with-freebsd-support third_party/fbgemm/third_party/cpuinfo
+ ${CP} -r cpuinfo-with-freebsd-support third_party/fbgemm/external/cpuinfo
post-install: # strip binaries
@${STRIP_CMD} \
diff --git a/misc/py-pytorch/distinfo b/misc/py-pytorch/distinfo
index 40aad9e52cc9..83e007ea33e1 100644
--- a/misc/py-pytorch/distinfo
+++ b/misc/py-pytorch/distinfo
@@ -1,5 +1,5 @@
-TIMESTAMP = 1749972703
-SHA256 (pytorch/pytorch-v2.7.1.tar.gz) = 5befd2e540fd55ce4782d0ca7610ce5b572d756d7ea38090ef0f3c7c428fb20f
-SIZE (pytorch/pytorch-v2.7.1.tar.gz) = 285998076
+TIMESTAMP = 1755586021
+SHA256 (pytorch/pytorch-v2.8.0.tar.gz) = c70a2c9488f6f6e8af5982a10d1cc2c37b7df5e6506d839daa5d5e250953d7b5
+SIZE (pytorch/pytorch-v2.8.0.tar.gz) = 330943132
SHA256 (pytorch/pytorch-cpuinfo-1e83a2f_GH0.tar.gz) = b8945cf45d4f13054d7f52e8bd9314690ea840d4d0ff21febd95ff04de3c613e
SIZE (pytorch/pytorch-cpuinfo-1e83a2f_GH0.tar.gz) = 3541839
diff --git a/misc/py-pytorch/files/patch-CMakeLists.txt b/misc/py-pytorch/files/patch-CMakeLists.txt
index 2a92cee61cdc..f7b4af5cd8d0 100644
--- a/misc/py-pytorch/files/patch-CMakeLists.txt
+++ b/misc/py-pytorch/files/patch-CMakeLists.txt
@@ -1,6 +1,6 @@
---- CMakeLists.txt.orig 2025-04-23 16:19:35 UTC
+--- CMakeLists.txt.orig 2025-08-06 17:08:00 UTC
+++ CMakeLists.txt
-@@ -182,7 +182,7 @@ set(CPU_POWER OFF)
+@@ -173,7 +173,7 @@ set(CPU_POWER OFF)
set(CPU_INTEL OFF)
set(CPU_POWER OFF)
@@ -9,7 +9,7 @@
set(CPU_INTEL ON)
elseif(CMAKE_SYSTEM_PROCESSOR MATCHES "^(aarch64|arm64)")
set(CPU_AARCH64 ON)
-@@ -212,7 +212,7 @@ option(BUILD_CUSTOM_PROTOBUF
+@@ -203,7 +203,7 @@ option(BUILD_CUSTOM_PROTOBUF
option(ATEN_NO_TEST "Do not build ATen test binaries" OFF)
option(BUILD_BINARY "Build C++ binaries" OFF)
option(BUILD_CUSTOM_PROTOBUF
@@ -18,7 +18,7 @@
option(BUILD_PYTHON "Build Python binaries" ON)
option(BUILD_LITE_INTERPRETER "Master flag to build Lite Interpreter" OFF)
option(BUILD_SHARED_LIBS "Build libcaffe2.so" ON)
-@@ -263,7 +263,7 @@ option(USE_GLOG "Use GLOG" OFF)
+@@ -254,7 +254,7 @@ option(USE_GLOG "Use GLOG" OFF)
option(USE_FAKELOWP "Use FakeLowp operators" OFF)
option(USE_GFLAGS "Use GFLAGS" OFF)
option(USE_GLOG "Use GLOG" OFF)
@@ -27,7 +27,7 @@
option(USE_MAGMA "Use MAGMA" ON)
option(USE_PYTORCH_METAL "Use Metal for PyTorch iOS build" OFF)
option(USE_PYTORCH_METAL_EXPORT "Export Metal models on MacOSX desktop" OFF)
-@@ -453,15 +453,15 @@ option(USE_SYSTEM_CPUINFO "Use system-provided cpuinfo
+@@ -451,15 +451,15 @@ option(USE_SYSTEM_CPUINFO "Use system-provided cpuinfo
# USE_SYSTEM_LIBS being "OFF".
option(USE_SYSTEM_LIBS "Use all available system-provided libraries." OFF)
option(USE_SYSTEM_CPUINFO "Use system-provided cpuinfo." OFF)
diff --git a/misc/py-pytorch/files/patch-third__party_fbgemm_third__party_asmjit_src_asmjit_core_virtmem.cpp b/misc/py-pytorch/files/patch-third__party_fbgemm_third__party_asmjit_src_asmjit_core_virtmem.cpp
deleted file mode 100644
index 09a801db1dfc..000000000000
--- a/misc/py-pytorch/files/patch-third__party_fbgemm_third__party_asmjit_src_asmjit_core_virtmem.cpp
+++ /dev/null
@@ -1,10 +0,0 @@
---- third_party/fbgemm/third_party/asmjit/src/asmjit/core/virtmem.cpp.orig 2022-12-16 00:23:48 UTC
-+++ third_party/fbgemm/third_party/asmjit/src/asmjit/core/virtmem.cpp
-@@ -45,6 +45,7 @@
- #endif
-
- #include <atomic>
-+#include <sys/stat.h>
-
- #if defined(__APPLE__) || defined(__BIONIC__)
- #define ASMJIT_VM_SHM_DETECT 0
diff --git a/misc/py-pytorch/files/patch-tools_build__pytorch__libs.py b/misc/py-pytorch/files/patch-tools_build__pytorch__libs.py
index 2ab33dd899a4..7a421c1bd8e3 100644
--- a/misc/py-pytorch/files/patch-tools_build__pytorch__libs.py
+++ b/misc/py-pytorch/files/patch-tools_build__pytorch__libs.py
@@ -1,11 +1,12 @@
---- tools/build_pytorch_libs.py.orig 2025-04-24 16:28:33 UTC
+--- tools/build_pytorch_libs.py.orig 2025-08-06 17:08:06 UTC
+++ tools/build_pytorch_libs.py
-@@ -119,7 +119,7 @@ def build_pytorch(
- cmake: CMake,
- ) -> None:
- my_env = _create_build_env()
-- checkout_nccl()
-+ #checkout_nccl()
+@@ -91,7 +91,8 @@ def build_pytorch(
+ and not check_negative_env_flag("USE_NCCL")
+ and not check_env_flag("USE_SYSTEM_NCCL")
+ ):
+- checkout_nccl()
++ #checkout_nccl()
++ pass
build_test = not check_negative_env_flag("BUILD_TEST")
cmake.generate(
version, cmake_python_library, build_python, build_test, my_env, rerun_cmake