Skip to content

Commit 916ab6a

Browse files
committed
Merge dists GRAALPYTHON_(JNI/CAPI) into *_NATIVE_LIBS
1 parent f80c79f commit 916ab6a

File tree

2 files changed

+46
-53
lines changed

2 files changed

+46
-53
lines changed

mx.graalpython/mx_graalpython.py

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -131,11 +131,10 @@ def _get_stdlib_home():
131131

132132

133133
def _get_capi_home():
134-
return mx.dependency("com.oracle.graal.python.cext").get_output_root()
134+
return mx.distribution("GRAALPYTHON_NATIVE_LIBS").get_output()
135135

136136

137-
def _get_jni_home():
138-
return mx.distribution("GRAALPYTHON_JNI").get_output()
137+
_get_jni_home = _get_capi_home
139138

140139

141140
def _extract_graalpython_internal_options(args):

mx.graalpython/suite.py

Lines changed: 44 additions & 50 deletions
Original file line numberDiff line numberDiff line change
@@ -345,7 +345,7 @@
345345
# a bit ugly, we need the same dist dependencies as the full GRAALPYTHON dist + python-lib
346346
"com.oracle.graal.python",
347347
"GRAALPYTHON-LAUNCHER",
348-
"GRAALPYTHON_JNI",
348+
"GRAALPYTHON_NATIVE_LIBS",
349349
"truffle:TRUFFLE_API",
350350
"tools:TRUFFLE_COVERAGE",
351351
"tools:TRUFFLE_PROFILER",
@@ -770,7 +770,7 @@
770770
"description": "GraalPython launcher",
771771
},
772772

773-
"GRAALPYTHON_JNI" : {
773+
"GRAALPYTHON_NATIVE_LIBS" : {
774774
"native": True,
775775
"platformDependent": True,
776776
"platforms": [
@@ -782,28 +782,58 @@
782782
"os_arch": {
783783
"windows": {
784784
"<others>": {
785+
"dependencies": [
786+
"com.oracle.graal.python.cext",
787+
"python-libzsupport",
788+
"python-libposix",
789+
"python-libbz2",
790+
"python-liblzma",
791+
"com.oracle.graal.python.hpy.llvm"
792+
],
785793
"layout": {
786-
"./": "file:graalpython/com.oracle.graal.python.jni/JNI-WINDOWS-README.md",
794+
"./": [
795+
"file:graalpython/com.oracle.graal.python.jni/JNI-WINDOWS-README.md",
796+
"dependency:com.oracle.graal.python.cext/bin/*",
797+
"dependency:python-libzsupport/*",
798+
"dependency:python-libposix/*",
799+
"dependency:com.oracle.graal.python.hpy.llvm/bin/*",
800+
"dependency:python-libbz2/bin/*",
801+
"dependency:python-liblzma/bin/*"
802+
]
787803
},
788804
},
789805
},
790806
"<others>": {
791807
"<others>": {
792808
"dependencies": [
809+
"com.oracle.graal.python.cext",
793810
"com.oracle.graal.python.jni",
811+
"python-libzsupport",
812+
"python-libposix",
813+
"python-libbz2",
814+
"python-liblzma",
815+
"com.oracle.graal.python.hpy.llvm"
794816
],
795817
"layout": {
796-
"./": {
797-
"source_type": "dependency",
798-
"dependency": "com.oracle.graal.python.jni",
799-
"path": "*",
800-
"exclude": ["JNI-WINDOWS-README.md"],
801-
},
818+
"./": [
819+
{
820+
"source_type": "dependency",
821+
"dependency": "com.oracle.graal.python.jni",
822+
"path": "*",
823+
"exclude": ["JNI-WINDOWS-README.md"],
824+
},
825+
"dependency:com.oracle.graal.python.cext/bin/*",
826+
"dependency:python-libzsupport/*",
827+
"dependency:python-libposix/*",
828+
"dependency:com.oracle.graal.python.hpy.llvm/bin/*",
829+
"dependency:python-libbz2/bin/*",
830+
"dependency:python-liblzma/bin/*",
831+
]
802832
},
803833
},
804834
},
805835
},
806-
"description": "Contains the native library needed by HPy JNI backend.",
836+
"description": "Contains the JNI native lib, the C API and support libs.",
807837
"maven": True,
808838
},
809839

@@ -825,7 +855,7 @@
825855
],
826856
"distDependencies": [
827857
"GRAALPYTHON-LAUNCHER",
828-
"GRAALPYTHON_JNI",
858+
"GRAALPYTHON_NATIVE_LIBS",
829859
"truffle:TRUFFLE_API",
830860
"tools:TRUFFLE_COVERAGE",
831861
"tools:TRUFFLE_PROFILER",
@@ -909,14 +939,10 @@
909939
"fileListPurpose": 'native-image-resources',
910940
"description": "GraalVM Python support distribution for the GraalVM",
911941
"distDependencies": [
912-
"GRAALPYTHON_JNI",
942+
"GRAALPYTHON_NATIVE_LIBS",
913943
],
914944
"dependencies": [
915945
"com.oracle.graal.python.cext",
916-
"python-libzsupport",
917-
"python-libposix",
918-
"python-libbz2",
919-
"python-liblzma",
920946
"com.oracle.graal.python.hpy.llvm"
921947
],
922948
"os_arch": {
@@ -931,24 +957,9 @@
931957
],
932958
"./lib-graalpython/": [
933959
"file:graalpython/lib-graalpython/*",
934-
"extracted-dependency:GRAALPYTHON_JNI/*",
935-
{
936-
"source_type": "dependency",
937-
"dependency": "graalpython:python-libzsupport",
938-
"path": "*",
939-
},
940-
{
941-
"source_type": "dependency",
942-
"dependency": "graalpython:python-libposix",
943-
"path": "*",
944-
},
945-
"dependency:com.oracle.graal.python.hpy.llvm/bin/*",
946-
"dependency:com.oracle.graal.python.cext/bin/*",
960+
"extracted-dependency:GRAALPYTHON_NATIVE_LIBS/*",
947961
"file:com.oracle.graal.python.cext/CEXT-WINDOWS-README.md",
948962
],
949-
"./lib-graalpython/modules/": [
950-
"dependency:com.oracle.graal.python.cext/bin/modules/*",
951-
],
952963
"./lib-graalpython/modules/graalpy_virtualenv": [
953964
"file:graalpy_virtualenv/graalpy_virtualenv",
954965
],
@@ -970,24 +981,7 @@
970981
],
971982
"./lib/graalpy<graal_ver:major_minor>/": [
972983
"file:graalpython/lib-graalpython/*",
973-
"extracted-dependency:GRAALPYTHON_JNI/*",
974-
"dependency:com.oracle.graal.python.cext/bin/*",
975-
{
976-
"source_type": "dependency",
977-
"dependency": "graalpython:python-libzsupport",
978-
"path": "*",
979-
},
980-
{
981-
"source_type": "dependency",
982-
"dependency": "graalpython:python-libposix",
983-
"path": "*",
984-
},
985-
"dependency:com.oracle.graal.python.hpy.llvm/bin/*",
986-
"dependency:python-libbz2/bin/*",
987-
"dependency:python-liblzma/bin/*",
988-
],
989-
"./lib/graalpy<graal_ver:major_minor>/modules/": [
990-
"dependency:com.oracle.graal.python.cext/bin/modules/*",
984+
"extracted-dependency:GRAALPYTHON_NATIVE_LIBS/*",
991985
],
992986
"./lib/graalpy<graal_ver:major_minor>/modules/graalpy_virtualenv": [
993987
"file:graalpy_virtualenv/graalpy_virtualenv",

0 commit comments

Comments
 (0)