Browse Source

Sync contrib/tools/python3 layout with upstream

* Move src/ subdir contents to the top of the layout
* Rename self-written lib -> lib2 to avoid CaseFolding warning from the VCS
* Regenerate contrib/libs/python proxy-headers accordingly
4ccc62ac1511abcf0fed14ccade38e984e088f1e
thegeorg 1 year ago
parent
commit
d96fa07134

+ 2 - 2
build/conf/python.conf

@@ -467,7 +467,7 @@ macro PYTHON2_MODULE() {
 ### Use in PY_ANY_MODULE to set it up for Python 3.x.
 macro PYTHON3_MODULE() {
     when ($USE_ARCADIA_PYTHON == "yes" && $MSVC == "yes" || $IS_CROSS_TOOLS == "yes") {
-        PEERDIR+=contrib/tools/python3/lib
+        PEERDIR+=contrib/tools/python3/lib2
     }
 
     SET(ANTLR_PYTHON Python3)
@@ -664,7 +664,7 @@ module _BASE_PY3_PROGRAM: _BASE_PROGRAM {
     PYTHON_TYPE_FOR_CYTHON=PY3
     PEERDIR(library/python/runtime_py3/main)
     when ($PYTHON_SQLITE3 != "no") {
-        PEERDIR += contrib/tools/python3/src/Modules/_sqlite
+        PEERDIR += contrib/tools/python3/Modules/_sqlite
     }
 
     when ($SANITIZER_TYPE && $SANITIZER_TYPE != "no") {

+ 1 - 1
build/plugins/pybuild.py

@@ -239,7 +239,7 @@ def py_program(unit, py3):
     if py3:
         peers = ['library/python/runtime_py3/main']
         if unit.get('PYTHON_SQLITE3') != 'no':
-            peers.append('contrib/tools/python3/src/Modules/_sqlite')
+            peers.append('contrib/tools/python3/Modules/_sqlite')
     else:
         peers = ['library/python/runtime/main']
         if unit.get('PYTHON_SQLITE3') != 'no':

+ 1 - 1
build/sanitize-blacklist.txt

@@ -1,5 +1,5 @@
 src:*contrib/tools/python/src*
-src:*contrib/tools/python3/src*
+src:*contrib/tools/python3*
 src:*contrib/libs/luajit*
 type:std::__*::locale::id=init
 

+ 1 - 1
contrib/libs/python/Include/Python.h

@@ -1,7 +1,7 @@
 #pragma once
 
 #ifdef USE_PYTHON3
-#include <contrib/tools/python3/src/Include/Python.h>
+#include <contrib/tools/python3/Include/Python.h>
 #else
 #include <contrib/tools/python/src/Include/Python.h>
 #endif

+ 1 - 1
contrib/libs/python/Include/abstract.h

@@ -1,7 +1,7 @@
 #pragma once
 
 #ifdef USE_PYTHON3
-#include <contrib/tools/python3/src/Include/abstract.h>
+#include <contrib/tools/python3/Include/abstract.h>
 #else
 #include <contrib/tools/python/src/Include/abstract.h>
 #endif

+ 1 - 1
contrib/libs/python/Include/compile.h

@@ -1,7 +1,7 @@
 #pragma once
 
 #ifdef USE_PYTHON3
-#include <contrib/tools/python3/src/Include/compile.h>
+#include <contrib/tools/python3/Include/compile.h>
 #else
 #include <contrib/tools/python/src/Include/compile.h>
 #endif

+ 1 - 1
contrib/libs/python/Include/datetime.h

@@ -1,7 +1,7 @@
 #pragma once
 
 #ifdef USE_PYTHON3
-#include <contrib/tools/python3/src/Include/datetime.h>
+#include <contrib/tools/python3/Include/datetime.h>
 #else
 #include <contrib/tools/python/src/Include/datetime.h>
 #endif

+ 1 - 1
contrib/libs/python/Include/descrobject.h

@@ -1,7 +1,7 @@
 #pragma once
 
 #ifdef USE_PYTHON3
-#include <contrib/tools/python3/src/Include/descrobject.h>
+#include <contrib/tools/python3/Include/descrobject.h>
 #else
 #include <contrib/tools/python/src/Include/descrobject.h>
 #endif

+ 1 - 1
contrib/libs/python/Include/frameobject.h

@@ -1,7 +1,7 @@
 #pragma once
 
 #ifdef USE_PYTHON3
-#include <contrib/tools/python3/src/Include/frameobject.h>
+#include <contrib/tools/python3/Include/frameobject.h>
 #else
 #include <contrib/tools/python/src/Include/frameobject.h>
 #endif

+ 1 - 1
contrib/libs/python/Include/internal/pycore_frame.h

@@ -1,7 +1,7 @@
 #pragma once
 
 #ifdef USE_PYTHON3
-#include <contrib/tools/python3/src/Include/internal/pycore_frame.h>
+#include <contrib/tools/python3/Include/internal/pycore_frame.h>
 #else
 #error "No <internal/pycore_frame.h> in Python2"
 #endif

Some files were not shown because too many files changed in this diff