Skip to content

Commit ce84ebd

Browse files
committed
python scripts are in tools/python3
1 parent da50e97 commit ce84ebd

File tree

4 files changed

+37
-12
lines changed

4 files changed

+37
-12
lines changed
Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
diff --git a/Modules/_ctypes/malloc_closure.c b/Modules/_ctypes/malloc_closure.c
2+
index 788bae6a9..3938f79db 100644
3+
--- a/Modules/_ctypes/malloc_closure.c
4+
+++ b/Modules/_ctypes/malloc_closure.c
5+
@@ -11,6 +11,9 @@
6+
#endif
7+
#include "ctypes.h"
8+
9+
+#undef Py_ffi_closure_alloc
10+
+#undef Py_ffi_closure_free
11+
+
12+
/* BLOCKSIZE can be adjusted. Larger blocksize will take a larger memory
13+
overhead, but allocate less blocks from the system. It may be that some
14+
systems have a limit of how many mmap'd blocks can be open.
Lines changed: 13 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,18 @@
11
diff --git a/Lib/sysconfig.py b/Lib/sysconfig.py
2-
index ebe371182..e351df7da 100644
2+
index ebe3711..b127603 100644
33
--- a/Lib/sysconfig.py
44
+++ b/Lib/sysconfig.py
5-
@@ -51,8 +51,8 @@
6-
'platstdlib': '{base}/Lib',
7-
'purelib': '{base}/Lib/site-packages',
8-
'platlib': '{base}/Lib/site-packages',
9-
- 'include': '{installed_base}/Include',
10-
- 'platinclude': '{installed_base}/Include',
11-
+ 'include': '{installed_base}/../../include/python{py_version_short}{abiflags}',
12-
+ 'platinclude': '{installed_base}/../../include/python{py_version_short}{abiflags}',
13-
'scripts': '{base}/Scripts',
5+
@@ -30,10 +30,10 @@
6+
'purelib': '{base}/lib/python{py_version_short}/site-packages',
7+
'platlib': '{platbase}/{platlibdir}/python{py_version_short}/site-packages',
8+
'include':
9+
- '{installed_base}/include/python{py_version_short}{abiflags}',
10+
+ '{installed_base}/../../include/python{py_version_short}{abiflags}',
11+
'platinclude':
12+
- '{installed_platbase}/include/python{py_version_short}{abiflags}',
13+
- 'scripts': '{base}/bin',
14+
+ '{installed_platbase}/../../include/python{py_version_short}{abiflags}',
15+
+ 'scripts': '{base}/tools/python3',
1416
'data': '{base}',
1517
},
18+
'posix_home': {

ports/python3/portfile.cmake

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,7 @@ set(PATCHES
3333
0012-force-disable-modules.patch
3434
0014-fix-get-python-inc-output.patch
3535
0015-dont-use-WINDOWS-def.patch
36+
0016-undup-ffi-symbols.patch # Required for lld-link.
3637
0018-fix-sysconfig-include.patch
3738
)
3839

@@ -376,4 +377,11 @@ if (NOT VCPKG_TARGET_IS_WINDOWS)
376377
endif()
377378
endif()
378379

379-
configure_file("${CMAKE_CURRENT_LIST_DIR}/vcpkg-port-config.cmake" "${CURRENT_PACKAGES_DIR}/share/python3/vcpkg-port-config.cmake" @ONLY)
380+
if(VCPKG_TARGET_IS_WINDOWS)
381+
vcpkg_replace_string("${CURRENT_PACKAGES_DIR}/tools/python3/Lib/distutils/command/build_ext.py" "'libs'" "'../../lib'")
382+
else()
383+
vcpkg_replace_string("${CURRENT_PACKAGES_DIR}/lib/python3.${PYTHON_VERSION_MINOR}/distutils/command/build_ext.py" "'libs'" "'../../lib'")
384+
file(COPY_FILE "${CURRENT_PACKAGES_DIR}/tools/python3/python3.${PYTHON_VERSION_MINOR}" "${CURRENT_PACKAGES_DIR}/tools/python3/python3")
385+
endif()
386+
387+
configure_file("${CMAKE_CURRENT_LIST_DIR}/vcpkg-port-config.cmake" "${CURRENT_PACKAGES_DIR}/share/python3/vcpkg-port-config.cmake" @ONLY)

ports/python3/vcpkg.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
{
22
"name": "python3",
33
"version": "3.11.5",
4-
"port-version": 3,
4+
"port-version": 5,
55
"description": "The Python programming language",
66
"homepage": "https://github.com/python/cpython",
77
"license": "Python-2.0",

0 commit comments

Comments
 (0)