Nuitka-winsvc 1.8__cp311-cp311-win_amd64.whl → 2.4.8__cp311-cp311-win_amd64.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Potentially problematic release.
This version of Nuitka-winsvc might be problematic. Click here for more details.
- Nuitka_winsvc-1.8.data/scripts/nuitka-run.bat → Nuitka_winsvc-2.4.8.data/scripts/nuitka-run.cmd +9 -9
- Nuitka_winsvc-1.8.data/scripts/nuitka.bat → Nuitka_winsvc-2.4.8.data/scripts/nuitka.cmd +15 -15
- {Nuitka_winsvc-1.8.dist-info → Nuitka_winsvc-2.4.8.dist-info}/METADATA +4 -3
- Nuitka_winsvc-2.4.8.dist-info/RECORD +954 -0
- {Nuitka_winsvc-1.8.dist-info → Nuitka_winsvc-2.4.8.dist-info}/WHEEL +1 -1
- nuitka/Builtins.py +18 -17
- nuitka/BytecodeCaching.py +24 -20
- nuitka/Bytecodes.py +23 -19
- nuitka/CacheCleanup.py +28 -23
- nuitka/Constants.py +19 -17
- nuitka/Errors.py +23 -17
- nuitka/HardImportRegistry.py +400 -0
- nuitka/MainControl.py +200 -112
- nuitka/ModuleRegistry.py +83 -20
- nuitka/OptionParsing.py +368 -175
- nuitka/Options.py +632 -213
- nuitka/OutputDirectories.py +40 -21
- nuitka/PostProcessing.py +73 -50
- nuitka/Progress.py +58 -24
- nuitka/PythonFlavors.py +141 -32
- nuitka/PythonOperators.py +18 -17
- nuitka/PythonVersions.py +106 -19
- nuitka/Serialization.py +68 -55
- nuitka/SourceCodeReferences.py +19 -17
- nuitka/Tracing.py +108 -70
- nuitka/TreeXML.py +31 -26
- nuitka/Variables.py +39 -41
- nuitka/Version.py +21 -7
- nuitka/__init__.py +5 -4
- nuitka/__main__.py +95 -29
- nuitka/__past__.py +44 -34
- nuitka/build/Backend.scons +202 -140
- nuitka/build/CCompilerVersion.scons +39 -31
- nuitka/build/DataComposerInterface.py +20 -17
- nuitka/build/Onefile.scons +50 -54
- nuitka/build/SconsCaching.py +93 -90
- nuitka/build/SconsCompilerSettings.py +157 -69
- nuitka/build/SconsHacks.py +25 -19
- nuitka/build/SconsInterface.py +154 -54
- nuitka/build/SconsProgress.py +19 -18
- nuitka/build/SconsSpawn.py +62 -33
- nuitka/build/SconsUtils.py +147 -55
- nuitka/build/__init__.py +5 -4
- nuitka/build/include/nuitka/allocator.h +105 -22
- nuitka/build/include/nuitka/builtins.h +17 -17
- nuitka/build/include/nuitka/calling.h +18 -18
- nuitka/build/include/nuitka/checkers.h +17 -18
- nuitka/build/include/nuitka/checksum_tools.h +14 -19
- nuitka/build/include/nuitka/compiled_asyncgen.h +18 -18
- nuitka/build/include/nuitka/compiled_cell.h +33 -18
- nuitka/build/include/nuitka/compiled_coroutine.h +18 -18
- nuitka/build/include/nuitka/compiled_frame.h +91 -53
- nuitka/build/include/nuitka/compiled_function.h +42 -20
- nuitka/build/include/nuitka/compiled_generator.h +24 -18
- nuitka/build/include/nuitka/compiled_method.h +17 -18
- nuitka/build/include/nuitka/constants.h +29 -18
- nuitka/build/include/nuitka/constants_blob.h +17 -17
- nuitka/build/include/nuitka/environment_variables.h +30 -0
- nuitka/build/include/nuitka/environment_variables_system.h +45 -0
- nuitka/build/include/nuitka/exception_groups.h +23 -26
- nuitka/build/include/nuitka/exceptions.h +593 -190
- nuitka/build/include/nuitka/filesystem_paths.h +26 -20
- nuitka/build/include/nuitka/freelists.h +38 -18
- nuitka/build/include/nuitka/helper/attributes.h +24 -18
- nuitka/build/include/nuitka/helper/boolean.h +17 -17
- nuitka/build/include/nuitka/helper/bytearrays.h +17 -17
- nuitka/build/include/nuitka/helper/bytes.h +14 -15
- nuitka/build/include/nuitka/helper/calling_generated.h +17 -17
- nuitka/build/include/nuitka/helper/comparisons_eq.h +17 -17
- nuitka/build/include/nuitka/helper/comparisons_ge.h +17 -17
- nuitka/build/include/nuitka/helper/comparisons_gt.h +17 -17
- nuitka/build/include/nuitka/helper/comparisons_le.h +17 -17
- nuitka/build/include/nuitka/helper/comparisons_lt.h +17 -17
- nuitka/build/include/nuitka/helper/comparisons_ne.h +17 -17
- nuitka/build/include/nuitka/helper/complex.h +17 -17
- nuitka/build/include/nuitka/helper/dictionaries.h +24 -22
- nuitka/build/include/nuitka/helper/floats.h +17 -18
- nuitka/build/include/nuitka/helper/import_hard.h +25 -17
- nuitka/build/include/nuitka/helper/indexes.h +17 -18
- nuitka/build/include/nuitka/helper/ints.h +32 -20
- nuitka/build/include/nuitka/helper/iterators.h +17 -17
- nuitka/build/include/nuitka/helper/lists.h +26 -24
- nuitka/build/include/nuitka/helper/lists_generated.h +22 -22
- nuitka/build/include/nuitka/helper/mappings.h +17 -18
- nuitka/build/include/nuitka/helper/operations.h +17 -17
- nuitka/build/include/nuitka/helper/operations_binary_add.h +17 -17
- nuitka/build/include/nuitka/helper/operations_binary_bitand.h +17 -17
- nuitka/build/include/nuitka/helper/operations_binary_bitor.h +17 -17
- nuitka/build/include/nuitka/helper/operations_binary_bitxor.h +17 -17
- nuitka/build/include/nuitka/helper/operations_binary_divmod.h +17 -17
- nuitka/build/include/nuitka/helper/operations_binary_floordiv.h +17 -17
- nuitka/build/include/nuitka/helper/operations_binary_lshift.h +17 -17
- nuitka/build/include/nuitka/helper/operations_binary_matmult.h +17 -17
- nuitka/build/include/nuitka/helper/operations_binary_mod.h +17 -17
- nuitka/build/include/nuitka/helper/operations_binary_mult.h +17 -17
- nuitka/build/include/nuitka/helper/operations_binary_olddiv.h +17 -17
- nuitka/build/include/nuitka/helper/operations_binary_pow.h +17 -17
- nuitka/build/include/nuitka/helper/operations_binary_rshift.h +17 -17
- nuitka/build/include/nuitka/helper/operations_binary_sub.h +17 -17
- nuitka/build/include/nuitka/helper/operations_binary_truediv.h +17 -17
- nuitka/build/include/nuitka/helper/operations_builtin_types.h +17 -17
- nuitka/build/include/nuitka/helper/operations_inplace_add.h +17 -17
- nuitka/build/include/nuitka/helper/operations_inplace_bitand.h +17 -17
- nuitka/build/include/nuitka/helper/operations_inplace_bitor.h +17 -17
- nuitka/build/include/nuitka/helper/operations_inplace_bitxor.h +17 -17
- nuitka/build/include/nuitka/helper/operations_inplace_floordiv.h +17 -17
- nuitka/build/include/nuitka/helper/operations_inplace_lshift.h +17 -17
- nuitka/build/include/nuitka/helper/operations_inplace_matmult.h +17 -17
- nuitka/build/include/nuitka/helper/operations_inplace_mod.h +17 -17
- nuitka/build/include/nuitka/helper/operations_inplace_mult.h +17 -17
- nuitka/build/include/nuitka/helper/operations_inplace_olddiv.h +17 -17
- nuitka/build/include/nuitka/helper/operations_inplace_pow.h +17 -17
- nuitka/build/include/nuitka/helper/operations_inplace_rshift.h +17 -17
- nuitka/build/include/nuitka/helper/operations_inplace_sub.h +17 -17
- nuitka/build/include/nuitka/helper/operations_inplace_truediv.h +17 -17
- nuitka/build/include/nuitka/helper/raising.h +29 -17
- nuitka/build/include/nuitka/helper/rangeobjects.h +17 -17
- nuitka/build/include/nuitka/helper/richcomparisons.h +14 -14
- nuitka/build/include/nuitka/helper/sequences.h +19 -13
- nuitka/build/include/nuitka/helper/sets.h +11 -12
- nuitka/build/include/nuitka/helper/slices.h +31 -25
- nuitka/build/include/nuitka/helper/strings.h +16 -17
- nuitka/build/include/nuitka/helper/subscripts.h +18 -201
- nuitka/build/include/nuitka/helper/tuples.h +64 -52
- nuitka/build/include/nuitka/helpers.h +38 -20
- nuitka/build/include/nuitka/importing.h +28 -21
- nuitka/build/include/nuitka/jit_sources.h +25 -0
- nuitka/build/include/nuitka/prelude.h +128 -46
- nuitka/build/include/nuitka/printing.h +22 -17
- nuitka/build/include/nuitka/python_pgo.h +19 -18
- nuitka/build/include/nuitka/safe_string_ops.h +20 -18
- nuitka/build/include/nuitka/threading.h +32 -33
- nuitka/build/include/nuitka/tracing.h +28 -18
- nuitka/build/include/nuitka/type_aliases.h +27 -0
- nuitka/build/include/nuitka/unfreezing.h +29 -23
- nuitka/build/inline_copy/bin/scons.py +14 -0
- nuitka/build/inline_copy/lib/scons-4.3.0/SCons/Variables/ListVariable.py +6 -6
- nuitka/build/inline_copy/pkg_resources/pkg_resources/__init__.py +0 -3
- nuitka/build/inline_copy/python_hacl/LICENSE.txt +201 -0
- nuitka/build/inline_copy/python_hacl/hacl_312/Hacl_Hash_MD5.c +1430 -0
- nuitka/build/inline_copy/python_hacl/hacl_312/Hacl_Hash_MD5.h +66 -0
- nuitka/build/inline_copy/python_hacl/hacl_312/Hacl_Hash_SHA1.c +463 -0
- nuitka/build/inline_copy/python_hacl/hacl_312/Hacl_Hash_SHA1.h +66 -0
- nuitka/build/inline_copy/python_hacl/hacl_312/Hacl_Hash_SHA2.c +1273 -0
- nuitka/build/inline_copy/python_hacl/hacl_312/Hacl_Hash_SHA2.h +204 -0
- nuitka/build/inline_copy/python_hacl/hacl_312/Hacl_Hash_SHA3.c +734 -0
- nuitka/build/inline_copy/python_hacl/hacl_312/Hacl_Hash_SHA3.h +131 -0
- nuitka/build/inline_copy/python_hacl/hacl_312/Hacl_Streaming_Types.h +83 -0
- nuitka/build/inline_copy/python_hacl/hacl_312/include/krml/FStar_UInt128_Verified.h +346 -0
- nuitka/build/inline_copy/python_hacl/hacl_312/include/krml/FStar_UInt_8_16_32_64.h +107 -0
- nuitka/build/inline_copy/python_hacl/hacl_312/include/krml/fstar_uint128_struct_endianness.h +68 -0
- nuitka/build/inline_copy/python_hacl/hacl_312/include/krml/internal/target.h +293 -0
- nuitka/build/inline_copy/python_hacl/hacl_312/include/krml/lowstar_endianness.h +231 -0
- nuitka/build/inline_copy/python_hacl/hacl_312/include/krml/types.h +14 -0
- nuitka/build/inline_copy/python_hacl/hacl_312/internal/Hacl_Hash_MD5.h +56 -0
- nuitka/build/inline_copy/python_hacl/hacl_312/internal/Hacl_Hash_SHA1.h +56 -0
- nuitka/build/inline_copy/python_hacl/hacl_312/internal/Hacl_Hash_SHA2.h +164 -0
- nuitka/build/inline_copy/python_hacl/hacl_312/internal/Hacl_Hash_SHA3.h +65 -0
- nuitka/build/inline_copy/python_hacl/hacl_312/python_hacl_namespaces.h +89 -0
- nuitka/build/inline_copy/tqdm/tqdm/__init__.py +2 -2
- nuitka/build/inline_copy/tqdm/tqdm/_monitor.py +4 -1
- nuitka/build/inline_copy/tqdm/tqdm/utils.py +14 -8
- nuitka/build/inline_copy/tqdm/tqdm/version.py +1 -8
- nuitka/build/inline_copy/zlib/LICENSE +22 -0
- nuitka/build/inline_copy/zlib/crc32.c +1049 -0
- nuitka/build/inline_copy/zlib/crc32.h +9446 -0
- nuitka/build/inline_copy/zlib/zconf.h +551 -0
- nuitka/build/inline_copy/zlib/zlib.h +1938 -0
- nuitka/build/inline_copy/zlib/zutil.h +275 -0
- nuitka/build/static_src/CompiledAsyncgenType.c +176 -182
- nuitka/build/static_src/CompiledCellType.c +63 -40
- nuitka/build/static_src/CompiledCodeHelpers.c +181 -128
- nuitka/build/static_src/CompiledCoroutineType.c +196 -203
- nuitka/build/static_src/CompiledFrameType.c +287 -133
- nuitka/build/static_src/CompiledFunctionType.c +389 -95
- nuitka/build/static_src/CompiledGeneratorType.c +376 -252
- nuitka/build/static_src/CompiledGeneratorTypeUncompiledIntegration.c +185 -198
- nuitka/build/static_src/CompiledMethodType.c +83 -71
- nuitka/build/static_src/HelpersAllocator.c +88 -19
- nuitka/build/static_src/HelpersAttributes.c +33 -54
- nuitka/build/static_src/HelpersBuiltin.c +43 -33
- nuitka/build/static_src/HelpersBuiltinTypeMethods.c +17 -17
- nuitka/build/static_src/HelpersBytes.c +19 -20
- nuitka/build/static_src/HelpersCalling.c +33 -30
- nuitka/build/static_src/HelpersCallingGenerated.c +1000 -181
- nuitka/build/static_src/HelpersChecksumTools.c +35 -21
- nuitka/build/static_src/HelpersClasses.c +17 -17
- nuitka/build/static_src/HelpersComparisonEq.c +518 -492
- nuitka/build/static_src/HelpersComparisonEqUtils.c +21 -19
- nuitka/build/static_src/HelpersComparisonGe.c +513 -497
- nuitka/build/static_src/HelpersComparisonGt.c +512 -496
- nuitka/build/static_src/HelpersComparisonLe.c +513 -497
- nuitka/build/static_src/HelpersComparisonLt.c +512 -496
- nuitka/build/static_src/HelpersComparisonNe.c +520 -492
- nuitka/build/static_src/HelpersConsole.c +96 -0
- nuitka/build/static_src/HelpersConstantsBlob.c +542 -519
- nuitka/build/static_src/HelpersDeepcopy.c +33 -33
- nuitka/build/static_src/HelpersDictionaries.c +51 -29
- nuitka/build/static_src/HelpersDictionariesGenerated.c +177 -68
- nuitka/build/static_src/HelpersDumpBacktraces.c +63 -0
- nuitka/build/static_src/HelpersEnvironmentVariables.c +65 -0
- nuitka/build/static_src/HelpersEnvironmentVariablesSystem.c +93 -0
- nuitka/build/static_src/HelpersExceptions.c +161 -50
- nuitka/build/static_src/HelpersFiles.c +37 -17
- nuitka/build/static_src/HelpersFilesystemPaths.c +292 -181
- nuitka/build/static_src/HelpersFloats.c +37 -31
- nuitka/build/static_src/HelpersHeapStorage.c +21 -17
- nuitka/build/static_src/HelpersImport.c +48 -20
- nuitka/build/static_src/HelpersImportHard.c +53 -17
- nuitka/build/static_src/HelpersJitSources.c +46 -0
- nuitka/build/static_src/HelpersLists.c +140 -50
- nuitka/build/static_src/HelpersListsGenerated.c +41 -41
- nuitka/build/static_src/HelpersMappings.c +17 -17
- nuitka/build/static_src/HelpersMatching.c +137 -51
- nuitka/build/static_src/HelpersOperationBinaryAdd.c +173 -146
- nuitka/build/static_src/HelpersOperationBinaryAddUtils.c +99 -52
- nuitka/build/static_src/HelpersOperationBinaryBitand.c +50 -50
- nuitka/build/static_src/HelpersOperationBinaryBitor.c +50 -50
- nuitka/build/static_src/HelpersOperationBinaryBitxor.c +50 -50
- nuitka/build/static_src/HelpersOperationBinaryDivmod.c +41 -41
- nuitka/build/static_src/HelpersOperationBinaryDivmodUtils.c +17 -17
- nuitka/build/static_src/HelpersOperationBinaryFloordiv.c +41 -41
- nuitka/build/static_src/HelpersOperationBinaryInplaceAdd.c +20 -21
- nuitka/build/static_src/HelpersOperationBinaryLshift.c +47 -47
- nuitka/build/static_src/HelpersOperationBinaryMatmult.c +24 -24
- nuitka/build/static_src/HelpersOperationBinaryMod.c +107 -107
- nuitka/build/static_src/HelpersOperationBinaryMult.c +81 -75
- nuitka/build/static_src/HelpersOperationBinaryMultUtils.c +33 -30
- nuitka/build/static_src/HelpersOperationBinaryOlddiv.c +41 -41
- nuitka/build/static_src/HelpersOperationBinaryPow.c +44 -44
- nuitka/build/static_src/HelpersOperationBinaryPowUtils.c +12 -12
- nuitka/build/static_src/HelpersOperationBinaryRshift.c +47 -47
- nuitka/build/static_src/HelpersOperationBinarySub.c +80 -80
- nuitka/build/static_src/HelpersOperationBinaryTruediv.c +41 -41
- nuitka/build/static_src/HelpersOperationInplaceAdd.c +171 -153
- nuitka/build/static_src/HelpersOperationInplaceAddUtils.c +24 -22
- nuitka/build/static_src/HelpersOperationInplaceBitand.c +53 -53
- nuitka/build/static_src/HelpersOperationInplaceBitor.c +53 -53
- nuitka/build/static_src/HelpersOperationInplaceBitxor.c +53 -53
- nuitka/build/static_src/HelpersOperationInplaceFloordiv.c +62 -62
- nuitka/build/static_src/HelpersOperationInplaceLshift.c +44 -44
- nuitka/build/static_src/HelpersOperationInplaceMatmult.c +37 -37
- nuitka/build/static_src/HelpersOperationInplaceMod.c +134 -134
- nuitka/build/static_src/HelpersOperationInplaceMult.c +78 -78
- nuitka/build/static_src/HelpersOperationInplaceOlddiv.c +62 -62
- nuitka/build/static_src/HelpersOperationInplacePow.c +62 -62
- nuitka/build/static_src/HelpersOperationInplaceRshift.c +44 -44
- nuitka/build/static_src/HelpersOperationInplaceSub.c +112 -112
- nuitka/build/static_src/HelpersOperationInplaceTruediv.c +62 -62
- nuitka/build/static_src/HelpersProfiling.c +24 -23
- nuitka/build/static_src/HelpersPythonPgo.c +22 -22
- nuitka/build/static_src/HelpersRaising.c +88 -20
- nuitka/build/static_src/HelpersSafeStrings.c +34 -22
- nuitka/build/static_src/HelpersSequences.c +18 -19
- nuitka/build/static_src/HelpersSlices.c +29 -23
- nuitka/build/static_src/HelpersStrings.c +234 -37
- nuitka/build/static_src/HelpersTuples.c +46 -34
- nuitka/build/static_src/HelpersTypes.c +68 -23
- nuitka/build/static_src/InspectPatcher.c +108 -27
- nuitka/build/static_src/MainProgram.c +359 -263
- nuitka/build/static_src/MetaPathBasedLoader.c +367 -242
- nuitka/build/static_src/MetaPathBasedLoaderImportlibMetadataDistribution.c +39 -26
- nuitka/build/static_src/MetaPathBasedLoaderResourceReader.c +17 -18
- nuitka/build/static_src/MetaPathBasedLoaderResourceReaderFiles.c +97 -22
- nuitka/build/static_src/OnefileBootstrap.c +276 -164
- nuitka/build/static_src/OnefileSplashScreen.cpp +51 -27
- nuitka/code_generation/AsyncgenCodes.py +19 -17
- nuitka/code_generation/AttributeCodes.py +31 -27
- nuitka/code_generation/BinaryOperationHelperDefinitions.py +24 -20
- nuitka/code_generation/BranchCodes.py +19 -17
- nuitka/code_generation/BuiltinCodes.py +20 -17
- nuitka/code_generation/CallCodes.py +19 -17
- nuitka/code_generation/ClassCodes.py +19 -17
- nuitka/code_generation/CodeGeneration.py +48 -27
- nuitka/code_generation/CodeHelperSelection.py +19 -17
- nuitka/code_generation/CodeHelpers.py +24 -20
- nuitka/code_generation/CodeObjectCodes.py +34 -24
- nuitka/code_generation/ComparisonCodes.py +38 -20
- nuitka/code_generation/ComparisonHelperDefinitions.py +19 -17
- nuitka/code_generation/ConditionalCodes.py +19 -17
- nuitka/code_generation/ConstantCodes.py +82 -28
- nuitka/code_generation/Contexts.py +152 -26
- nuitka/code_generation/CoroutineCodes.py +19 -17
- nuitka/code_generation/CtypesCodes.py +19 -17
- nuitka/code_generation/DictCodes.py +25 -23
- nuitka/code_generation/Emission.py +21 -18
- nuitka/code_generation/ErrorCodes.py +27 -33
- nuitka/code_generation/EvalCodes.py +24 -20
- nuitka/code_generation/ExceptionCodes.py +27 -18
- nuitka/code_generation/ExpressionCTypeSelectionHelpers.py +20 -17
- nuitka/code_generation/ExpressionCodes.py +19 -17
- nuitka/code_generation/FrameCodes.py +24 -20
- nuitka/code_generation/FunctionCodes.py +24 -21
- nuitka/code_generation/GeneratorCodes.py +23 -20
- nuitka/code_generation/GlobalConstants.py +43 -23
- nuitka/code_generation/GlobalsLocalsCodes.py +21 -19
- nuitka/code_generation/IdCodes.py +19 -17
- nuitka/code_generation/ImportCodes.py +90 -50
- nuitka/code_generation/Indentation.py +23 -22
- nuitka/code_generation/IndexCodes.py +19 -17
- nuitka/code_generation/InjectCCodes.py +14 -12
- nuitka/code_generation/IntegerCodes.py +19 -17
- nuitka/code_generation/IteratorCodes.py +19 -17
- nuitka/code_generation/JitCodes.py +44 -0
- nuitka/code_generation/LabelCodes.py +19 -17
- nuitka/code_generation/LineNumberCodes.py +19 -17
- nuitka/code_generation/ListCodes.py +32 -36
- nuitka/code_generation/LoaderCodes.py +22 -17
- nuitka/code_generation/LocalsDictCodes.py +56 -32
- nuitka/code_generation/LoopCodes.py +19 -17
- nuitka/code_generation/MatchCodes.py +42 -22
- nuitka/code_generation/ModuleCodes.py +43 -25
- nuitka/code_generation/Namify.py +27 -23
- nuitka/code_generation/NetworkxCodes.py +51 -0
- nuitka/code_generation/OperationCodes.py +29 -31
- nuitka/code_generation/PackageResourceCodes.py +59 -23
- nuitka/code_generation/PrintCodes.py +19 -17
- nuitka/code_generation/PythonAPICodes.py +19 -17
- nuitka/code_generation/RaisingCodes.py +19 -17
- nuitka/code_generation/Reports.py +19 -17
- nuitka/code_generation/ReturnCodes.py +19 -17
- nuitka/code_generation/SetCodes.py +19 -17
- nuitka/code_generation/SliceCodes.py +22 -20
- nuitka/code_generation/StringCodes.py +19 -17
- nuitka/code_generation/SubscriptCodes.py +24 -30
- nuitka/code_generation/TensorflowCodes.py +54 -0
- nuitka/code_generation/TryCodes.py +19 -17
- nuitka/code_generation/TupleCodes.py +20 -18
- nuitka/code_generation/TypeAliasCodes.py +71 -0
- nuitka/code_generation/VariableCodes.py +26 -22
- nuitka/code_generation/VariableDeclarations.py +20 -17
- nuitka/code_generation/YieldCodes.py +22 -20
- nuitka/code_generation/__init__.py +5 -4
- nuitka/code_generation/c_types/CTypeBases.py +19 -17
- nuitka/code_generation/c_types/CTypeBooleans.py +19 -17
- nuitka/code_generation/c_types/CTypeCFloats.py +19 -17
- nuitka/code_generation/c_types/CTypeCLongs.py +19 -18
- nuitka/code_generation/c_types/CTypeModuleDictVariables.py +19 -17
- nuitka/code_generation/c_types/CTypeNuitkaBooleans.py +19 -17
- nuitka/code_generation/c_types/CTypeNuitkaInts.py +19 -18
- nuitka/code_generation/c_types/CTypeNuitkaVoids.py +19 -17
- nuitka/code_generation/c_types/CTypePyObjectPointers.py +27 -25
- nuitka/code_generation/c_types/CTypeVoids.py +20 -17
- nuitka/code_generation/c_types/__init__.py +5 -4
- nuitka/code_generation/templates/CodeTemplatesAsyncgens.py +18 -17
- nuitka/code_generation/templates/CodeTemplatesConstants.py +132 -36
- nuitka/code_generation/templates/CodeTemplatesCoroutines.py +18 -17
- nuitka/code_generation/templates/CodeTemplatesExceptions.py +19 -18
- nuitka/code_generation/templates/CodeTemplatesFrames.py +18 -17
- nuitka/code_generation/templates/CodeTemplatesFunction.py +18 -17
- nuitka/code_generation/templates/CodeTemplatesGeneratorFunction.py +19 -17
- nuitka/code_generation/templates/CodeTemplatesIterators.py +18 -18
- nuitka/code_generation/templates/CodeTemplatesLoader.py +25 -19
- nuitka/code_generation/templates/CodeTemplatesModules.py +244 -165
- nuitka/code_generation/templates/CodeTemplatesVariables.py +42 -27
- nuitka/code_generation/templates/TemplateDebugWrapper.py +19 -18
- nuitka/code_generation/templates/__init__.py +5 -4
- nuitka/code_generation/templates_c/CodeTemplateCallsMethodPositional.c.j2 +19 -19
- nuitka/code_generation/templates_c/CodeTemplateCallsMixed.c.j2 +18 -18
- nuitka/code_generation/templates_c/CodeTemplateCallsPositional.c.j2 +76 -25
- nuitka/code_generation/templates_c/CodeTemplateCallsPositionalMethodDescr.c.j2 +22 -22
- nuitka/code_generation/templates_c/CodeTemplateMakeListHinted.c.j2 +19 -19
- nuitka/code_generation/templates_c/CodeTemplateMakeListSmall.c.j2 +19 -19
- nuitka/code_generation/templates_c/HelperBuiltinMethodOperation.c.j2 +17 -17
- nuitka/code_generation/templates_c/HelperDictionaryCopy.c.j2 +121 -48
- nuitka/code_generation/templates_c/HelperImportHard.c.j2 +18 -18
- nuitka/code_generation/templates_c/HelperLongTools.c.j2 +18 -18
- nuitka/code_generation/templates_c/HelperObjectTools.c.j2 +6 -6
- nuitka/code_generation/templates_c/HelperOperationBinary.c.j2 +23 -23
- nuitka/code_generation/templates_c/HelperOperationComparison.c.j2 +35 -35
- nuitka/code_generation/templates_c/HelperOperationComparisonBytes.c.j2 +28 -28
- nuitka/code_generation/templates_c/HelperOperationComparisonFloat.c.j2 +17 -17
- nuitka/code_generation/templates_c/HelperOperationComparisonInt.c.j2 +18 -18
- nuitka/code_generation/templates_c/HelperOperationComparisonList.c.j2 +44 -32
- nuitka/code_generation/templates_c/HelperOperationComparisonLong.c.j2 +20 -20
- nuitka/code_generation/templates_c/HelperOperationComparisonStr.c.j2 +28 -28
- nuitka/code_generation/templates_c/HelperOperationComparisonTuple.c.j2 +24 -24
- nuitka/code_generation/templates_c/HelperOperationComparisonUnicode.c.j2 +33 -29
- nuitka/code_generation/templates_c/HelperOperationInplace.c.j2 +20 -20
- nuitka/code_generation/templates_c/HelperSlotsBinary.c.j2 +27 -27
- nuitka/code_generation/templates_c/HelperSlotsBytes.c.j2 +17 -17
- nuitka/code_generation/templates_c/HelperSlotsCommon.c.j2 +17 -17
- nuitka/code_generation/templates_c/HelperSlotsFloat.c.j2 +17 -17
- nuitka/code_generation/templates_c/HelperSlotsInt.c.j2 +17 -17
- nuitka/code_generation/templates_c/HelperSlotsList.c.j2 +21 -18
- nuitka/code_generation/templates_c/HelperSlotsLong.c.j2 +26 -24
- nuitka/code_generation/templates_c/HelperSlotsSet.c.j2 +17 -17
- nuitka/code_generation/templates_c/HelperSlotsStr.c.j2 +17 -17
- nuitka/code_generation/templates_c/HelperSlotsTuple.c.j2 +21 -18
- nuitka/code_generation/templates_c/HelperSlotsUnicode.c.j2 +17 -17
- nuitka/containers/Namedtuples.py +19 -18
- nuitka/containers/OrderedSetsFallback.py +19 -17
- nuitka/containers/__init__.py +5 -4
- nuitka/distutils/Build.py +19 -18
- nuitka/distutils/DistutilCommands.py +34 -23
- nuitka/distutils/__init__.py +5 -4
- nuitka/finalizations/Finalization.py +20 -17
- nuitka/finalizations/FinalizeMarkups.py +21 -41
- nuitka/finalizations/__init__.py +5 -4
- nuitka/freezer/DependsExe.py +48 -28
- nuitka/freezer/DllDependenciesCommon.py +47 -20
- nuitka/freezer/DllDependenciesMacOS.py +147 -57
- nuitka/freezer/DllDependenciesPosix.py +29 -19
- nuitka/freezer/DllDependenciesWin32.py +29 -21
- nuitka/freezer/ImportDetection.py +20 -17
- nuitka/freezer/IncludedDataFiles.py +118 -47
- nuitka/freezer/IncludedEntryPoints.py +102 -38
- nuitka/freezer/Onefile.py +32 -22
- nuitka/freezer/Standalone.py +105 -50
- nuitka/freezer/__init__.py +5 -4
- nuitka/importing/IgnoreListing.py +19 -17
- nuitka/importing/ImportCache.py +24 -21
- nuitka/importing/ImportResolving.py +103 -95
- nuitka/importing/Importing.py +286 -92
- nuitka/importing/PreloadedPackages.py +21 -18
- nuitka/importing/Recursion.py +131 -47
- nuitka/importing/StandardLibrary.py +46 -28
- nuitka/importing/__init__.py +5 -4
- nuitka/nodes/AsyncgenNodes.py +19 -17
- nuitka/nodes/AttributeLookupNodes.py +19 -17
- nuitka/nodes/AttributeNodes.py +19 -17
- nuitka/nodes/AttributeNodesGenerated.py +49 -24
- nuitka/nodes/BuiltinAllNodes.py +19 -17
- nuitka/nodes/BuiltinAnyNodes.py +19 -17
- nuitka/nodes/BuiltinComplexNodes.py +20 -17
- nuitka/nodes/BuiltinDecodingNodes.py +19 -17
- nuitka/nodes/BuiltinDecoratorNodes.py +19 -17
- nuitka/nodes/BuiltinDictNodes.py +19 -17
- nuitka/nodes/BuiltinFormatNodes.py +20 -17
- nuitka/nodes/BuiltinHashNodes.py +19 -17
- nuitka/nodes/BuiltinInputNodes.py +19 -17
- nuitka/nodes/BuiltinIntegerNodes.py +19 -17
- nuitka/nodes/BuiltinIteratorNodes.py +24 -20
- nuitka/nodes/BuiltinLenNodes.py +19 -17
- nuitka/nodes/BuiltinNextNodes.py +19 -17
- nuitka/nodes/BuiltinOpenNodes.py +52 -18
- nuitka/nodes/BuiltinOperationNodeBasesGenerated.py +40 -23
- nuitka/nodes/BuiltinRangeNodes.py +21 -19
- nuitka/nodes/BuiltinRefNodes.py +68 -19
- nuitka/nodes/BuiltinSumNodes.py +20 -18
- nuitka/nodes/BuiltinTypeNodes.py +19 -17
- nuitka/nodes/BuiltinVarsNodes.py +19 -18
- nuitka/nodes/BytesNodes.py +19 -17
- nuitka/nodes/CallNodes.py +19 -17
- nuitka/nodes/Checkers.py +19 -17
- nuitka/nodes/ChildrenHavingMixins.py +1250 -302
- nuitka/nodes/ClassNodes.py +49 -29
- nuitka/nodes/CodeObjectSpecs.py +29 -18
- nuitka/nodes/ComparisonNodes.py +19 -17
- nuitka/nodes/ConditionalNodes.py +21 -23
- nuitka/nodes/ConstantRefNodes.py +57 -17
- nuitka/nodes/ContainerMakingNodes.py +19 -17
- nuitka/nodes/ContainerOperationNodes.py +19 -17
- nuitka/nodes/CoroutineNodes.py +19 -17
- nuitka/nodes/CtypesNodes.py +19 -18
- nuitka/nodes/DictionaryNodes.py +19 -18
- nuitka/nodes/ExceptionNodes.py +29 -17
- nuitka/nodes/ExecEvalNodes.py +19 -17
- nuitka/nodes/ExpressionBases.py +34 -26
- nuitka/nodes/ExpressionBasesGenerated.py +54 -32
- nuitka/nodes/ExpressionShapeMixins.py +19 -17
- nuitka/nodes/FrameNodes.py +19 -17
- nuitka/nodes/FunctionAttributeNodes.py +19 -17
- nuitka/nodes/FunctionNodes.py +81 -35
- nuitka/nodes/FutureSpecs.py +35 -20
- nuitka/nodes/GeneratorNodes.py +21 -19
- nuitka/nodes/GlobalsLocalsNodes.py +22 -17
- nuitka/nodes/HardImportNodesGenerated.py +545 -129
- nuitka/nodes/ImportHardNodes.py +46 -38
- nuitka/nodes/ImportNodes.py +436 -446
- nuitka/nodes/IndicatorMixins.py +19 -17
- nuitka/nodes/InjectCNodes.py +19 -18
- nuitka/nodes/IterationHandles.py +55 -34
- nuitka/nodes/KeyValuePairNodes.py +19 -17
- nuitka/nodes/ListOperationNodes.py +33 -21
- nuitka/nodes/LocalsDictNodes.py +19 -17
- nuitka/nodes/LocalsScopes.py +41 -41
- nuitka/nodes/LoopNodes.py +28 -17
- nuitka/nodes/MatchNodes.py +37 -24
- nuitka/nodes/ModuleAttributeNodes.py +18 -35
- nuitka/nodes/ModuleNodes.py +90 -31
- nuitka/nodes/NetworkxNodes.py +45 -0
- nuitka/nodes/NodeBases.py +45 -43
- nuitka/nodes/NodeMakingHelpers.py +21 -19
- nuitka/nodes/NodeMetaClasses.py +45 -28
- nuitka/nodes/OperatorNodes.py +28 -26
- nuitka/nodes/OperatorNodesUnary.py +20 -17
- nuitka/nodes/OsSysNodes.py +66 -18
- nuitka/nodes/OutlineNodes.py +22 -20
- nuitka/nodes/PackageMetadataNodes.py +37 -27
- nuitka/nodes/PackageResourceNodes.py +29 -23
- nuitka/nodes/PrintNodes.py +19 -17
- nuitka/nodes/ReturnNodes.py +20 -18
- nuitka/nodes/SideEffectNodes.py +19 -17
- nuitka/nodes/SliceNodes.py +20 -18
- nuitka/nodes/StatementBasesGenerated.py +125 -77
- nuitka/nodes/StatementNodes.py +19 -17
- nuitka/nodes/StrNodes.py +19 -17
- nuitka/nodes/StringConcatenationNodes.py +20 -17
- nuitka/nodes/SubscriptNodes.py +26 -24
- nuitka/nodes/TensorflowNodes.py +38 -0
- nuitka/nodes/TryNodes.py +19 -17
- nuitka/nodes/TypeMatchNodes.py +19 -17
- nuitka/nodes/TypeNodes.py +40 -17
- nuitka/nodes/VariableAssignNodes.py +122 -64
- nuitka/nodes/VariableDelNodes.py +19 -17
- nuitka/nodes/VariableNameNodes.py +19 -17
- nuitka/nodes/VariableRefNodes.py +63 -26
- nuitka/nodes/VariableReleaseNodes.py +19 -17
- nuitka/nodes/YieldNodes.py +21 -19
- nuitka/nodes/__init__.py +5 -4
- nuitka/nodes/shapes/BuiltinTypeShapes.py +145 -39
- nuitka/nodes/shapes/ControlFlowDescriptions.py +19 -17
- nuitka/nodes/shapes/ShapeMixins.py +40 -17
- nuitka/nodes/shapes/StandardShapes.py +27 -20
- nuitka/nodes/shapes/__init__.py +5 -4
- nuitka/optimizations/BytecodeDemotion.py +19 -17
- nuitka/optimizations/FunctionInlining.py +22 -23
- nuitka/optimizations/Graphs.py +19 -17
- nuitka/optimizations/Optimization.py +39 -35
- nuitka/optimizations/OptimizeBuiltinCalls.py +31 -27
- nuitka/optimizations/Tags.py +19 -18
- nuitka/optimizations/TraceCollections.py +67 -24
- nuitka/optimizations/ValueTraces.py +92 -25
- nuitka/optimizations/__init__.py +5 -4
- nuitka/pgo/PGO.py +33 -23
- nuitka/pgo/__init__.py +5 -4
- nuitka/plugins/PluginBase.py +610 -109
- nuitka/plugins/Plugins.py +241 -58
- nuitka/plugins/YamlPluginBase.py +121 -0
- nuitka/plugins/__init__.py +5 -4
- nuitka/plugins/standard/AntiBloatPlugin.py +357 -129
- nuitka/plugins/standard/ConsiderPyLintAnnotationsPlugin.py +20 -19
- nuitka/plugins/standard/DataFilesPlugin.py +65 -29
- nuitka/plugins/standard/DelvewheelPlugin.py +32 -24
- nuitka/plugins/standard/DillPlugin/DillPlugin.c +37 -0
- nuitka/plugins/standard/DillPlugin/dill-postLoad.py +256 -0
- nuitka/plugins/standard/DillPlugin.py +42 -134
- nuitka/plugins/standard/DllFilesPlugin.py +125 -42
- nuitka/plugins/standard/EnumPlugin.py +19 -17
- nuitka/plugins/standard/EventletPlugin.py +19 -17
- nuitka/plugins/standard/GeventPlugin.py +19 -17
- nuitka/plugins/standard/GiPlugin.py +44 -28
- nuitka/plugins/standard/GlfwPlugin.py +20 -17
- nuitka/plugins/standard/ImplicitImports.py +407 -46
- nuitka/plugins/standard/KivyPlugin.py +30 -17
- nuitka/plugins/standard/MatplotlibPlugin.py +88 -42
- nuitka/plugins/standard/MultiprocessingPlugin.py +25 -20
- nuitka/plugins/standard/NumpyPlugin.py +19 -17
- nuitka/plugins/standard/OptionsNannyPlugin.py +48 -76
- nuitka/plugins/standard/PbrPlugin.py +21 -19
- nuitka/plugins/standard/PkgResourcesPlugin.py +34 -23
- nuitka/plugins/standard/PmwPlugin.py +30 -27
- nuitka/plugins/standard/PySidePyQtPlugin.py +74 -80
- nuitka/plugins/standard/PywebViewPlugin.py +19 -17
- nuitka/plugins/standard/SpacyPlugin.py +136 -0
- nuitka/plugins/standard/TensorflowPlugin.py +20 -17
- nuitka/plugins/standard/TkinterPlugin.py +103 -53
- nuitka/plugins/standard/TorchPlugin.py +20 -17
- nuitka/plugins/standard/TransformersPlugin.py +94 -30
- nuitka/plugins/standard/TrioPlugin.py +18 -15
- nuitka/plugins/standard/UpxPlugin.py +21 -19
- nuitka/plugins/standard/__init__.py +5 -4
- nuitka/plugins/standard/standard.nuitka-package.config.yml +3449 -1299
- nuitka/plugins/standard/stdlib2.nuitka-package.config.yml +14 -14
- nuitka/plugins/standard/stdlib3.nuitka-package.config.yml +121 -66
- nuitka/reports/CompilationReportReader.py +67 -0
- nuitka/reports/LicenseReport.rst.j2 +21 -21
- nuitka/reports/Reports.py +352 -76
- nuitka/reports/__init__.py +5 -4
- nuitka/specs/BuiltinBytesOperationSpecs.py +18 -17
- nuitka/specs/BuiltinDictOperationSpecs.py +18 -17
- nuitka/specs/BuiltinListOperationSpecs.py +18 -17
- nuitka/specs/BuiltinParameterSpecs.py +30 -20
- nuitka/specs/BuiltinStrOperationSpecs.py +19 -18
- nuitka/specs/BuiltinTypeOperationSpecs.py +18 -18
- nuitka/specs/BuiltinUnicodeOperationSpecs.py +18 -17
- nuitka/specs/HardImportSpecs.py +67 -22
- nuitka/specs/ParameterSpecs.py +56 -41
- nuitka/specs/__init__.py +5 -4
- nuitka/tools/Basics.py +20 -18
- nuitka/tools/__init__.py +5 -4
- nuitka/tools/commercial/__init__.py +7 -6
- nuitka/tools/data_composer/DataComposer.py +78 -62
- nuitka/tools/data_composer/__init__.py +5 -4
- nuitka/tools/data_composer/__main__.py +18 -17
- nuitka/tools/environments/CreateEnvironment.py +20 -17
- nuitka/tools/environments/Virtualenv.py +60 -32
- nuitka/tools/environments/__init__.py +5 -4
- nuitka/tools/general/__init__.py +5 -4
- nuitka/tools/general/dll_report/__init__.py +5 -4
- nuitka/tools/general/dll_report/__main__.py +19 -21
- nuitka/tools/general/find_module/FindModuleCode.py +35 -22
- nuitka/tools/general/find_module/__init__.py +5 -4
- nuitka/tools/onefile_compressor/OnefileCompressor.py +213 -131
- nuitka/tools/onefile_compressor/__init__.py +5 -4
- nuitka/tools/onefile_compressor/__main__.py +18 -17
- nuitka/tools/podman/Podman.py +19 -17
- nuitka/tools/podman/__init__.py +5 -4
- nuitka/tools/podman/__main__.py +35 -19
- nuitka/tools/profiler/__init__.py +5 -4
- nuitka/tools/profiler/__main__.py +18 -17
- nuitka/tools/scanning/DisplayPackageDLLs.py +47 -22
- nuitka/tools/scanning/DisplayPackageData.py +31 -19
- nuitka/tools/scanning/__init__.py +5 -4
- nuitka/tools/specialize/CTypeDescriptions.py +93 -71
- nuitka/tools/specialize/Common.py +18 -17
- nuitka/tools/specialize/SpecializeC.py +31 -27
- nuitka/tools/specialize/SpecializePython.py +108 -45
- nuitka/tools/specialize/__init__.py +5 -4
- nuitka/tools/testing/Common.py +106 -52
- nuitka/tools/testing/Constructs.py +19 -17
- nuitka/tools/testing/OutputComparison.py +54 -18
- nuitka/tools/testing/Pythons.py +19 -18
- nuitka/tools/testing/RuntimeTracing.py +20 -19
- nuitka/tools/testing/SearchModes.py +26 -20
- nuitka/tools/testing/Valgrind.py +19 -17
- nuitka/tools/testing/__init__.py +5 -4
- nuitka/tools/testing/check_reference_counts/__init__.py +5 -4
- nuitka/tools/testing/check_reference_counts/__main__.py +18 -18
- nuitka/tools/testing/compare_with_cpython/__init__.py +5 -4
- nuitka/tools/testing/compare_with_cpython/__main__.py +36 -29
- nuitka/tools/testing/find_sxs_modules/__init__.py +5 -4
- nuitka/tools/testing/find_sxs_modules/__main__.py +17 -17
- nuitka/tools/testing/measure_construct_performance/__init__.py +5 -4
- nuitka/tools/testing/measure_construct_performance/__main__.py +22 -25
- nuitka/tools/testing/run_nuitka_tests/__init__.py +5 -4
- nuitka/tools/testing/run_nuitka_tests/__main__.py +57 -40
- nuitka/tools/watch/AutoStage.py +144 -0
- nuitka/tools/watch/GitHub.py +113 -0
- nuitka/tools/watch/__init__.py +5 -4
- nuitka/tools/watch/__main__.py +322 -91
- nuitka/tree/Building.py +176 -147
- nuitka/tree/ComplexCallHelperFunctions.py +80 -58
- nuitka/tree/Extractions.py +19 -17
- nuitka/tree/InternalModule.py +29 -20
- nuitka/tree/Operations.py +19 -17
- nuitka/tree/ReformulationAssertStatements.py +20 -17
- nuitka/tree/ReformulationAssignmentStatements.py +92 -91
- nuitka/tree/ReformulationBooleanExpressions.py +19 -17
- nuitka/tree/ReformulationCallExpressions.py +20 -18
- nuitka/tree/ReformulationClasses.py +45 -39
- nuitka/tree/ReformulationClasses3.py +146 -98
- nuitka/tree/ReformulationComparisonExpressions.py +29 -35
- nuitka/tree/ReformulationContractionExpressions.py +58 -55
- nuitka/tree/ReformulationDictionaryCreation.py +40 -35
- nuitka/tree/ReformulationExecStatements.py +42 -39
- nuitka/tree/ReformulationForLoopStatements.py +30 -34
- nuitka/tree/ReformulationFunctionStatements.py +58 -54
- nuitka/tree/ReformulationImportStatements.py +34 -29
- nuitka/tree/ReformulationLambdaExpressions.py +23 -24
- nuitka/tree/ReformulationMatchStatements.py +244 -92
- nuitka/tree/ReformulationMultidist.py +22 -18
- nuitka/tree/ReformulationNamespacePackages.py +55 -46
- nuitka/tree/ReformulationPrintStatements.py +23 -24
- nuitka/tree/ReformulationSequenceCreation.py +50 -49
- nuitka/tree/ReformulationSubscriptExpressions.py +19 -17
- nuitka/tree/ReformulationTryExceptStatements.py +19 -17
- nuitka/tree/ReformulationTryFinallyStatements.py +34 -17
- nuitka/tree/ReformulationWhileLoopStatements.py +19 -17
- nuitka/tree/ReformulationWithStatements.py +39 -41
- nuitka/tree/ReformulationYieldExpressions.py +21 -19
- nuitka/tree/SourceHandling.py +76 -31
- nuitka/tree/SyntaxErrors.py +19 -17
- nuitka/tree/TreeHelpers.py +33 -20
- nuitka/tree/VariableClosure.py +35 -39
- nuitka/tree/__init__.py +5 -4
- nuitka/utils/AppDirs.py +41 -20
- nuitka/utils/CStrings.py +66 -21
- nuitka/utils/CommandLineOptions.py +84 -19
- nuitka/utils/Distributions.py +445 -54
- nuitka/utils/Download.py +89 -57
- nuitka/utils/Execution.py +73 -34
- nuitka/utils/FileOperations.py +318 -74
- nuitka/utils/Hashing.py +55 -33
- nuitka/utils/Images.py +26 -19
- nuitka/utils/Importing.py +118 -24
- nuitka/utils/InstalledPythons.py +80 -75
- nuitka/utils/InstanceCounters.py +20 -17
- nuitka/utils/Jinja2.py +30 -22
- nuitka/utils/Json.py +19 -17
- nuitka/utils/MacOSApp.py +26 -18
- nuitka/utils/MemoryUsage.py +20 -18
- nuitka/utils/ModuleNames.py +42 -26
- nuitka/utils/ReExecute.py +50 -28
- nuitka/utils/Rest.py +20 -17
- nuitka/utils/SharedLibraries.py +161 -75
- nuitka/utils/Shebang.py +20 -17
- nuitka/utils/Signing.py +63 -18
- nuitka/utils/SlotMetaClasses.py +57 -0
- nuitka/utils/StaticLibraries.py +83 -56
- nuitka/utils/ThreadedExecutor.py +18 -17
- nuitka/utils/Timing.py +22 -20
- nuitka/utils/Utils.py +115 -25
- nuitka/utils/WindowsFileUsage.py +22 -20
- nuitka/utils/WindowsResources.py +25 -18
- nuitka/utils/Yaml.py +62 -24
- nuitka/utils/__init__.py +5 -4
- Nuitka_winsvc-1.8.dist-info/RECORD +0 -905
- nuitka/build/inline_copy/tqdm/tqdm/_tqdm_gui.py +0 -9
- nuitka/build/inline_copy/tqdm/tqdm/gui.py +0 -191
- {Nuitka_winsvc-1.8.dist-info → Nuitka_winsvc-2.4.8.dist-info}/LICENSE.txt +0 -0
- {Nuitka_winsvc-1.8.dist-info → Nuitka_winsvc-2.4.8.dist-info}/entry_points.txt +0 -0
- {Nuitka_winsvc-1.8.dist-info → Nuitka_winsvc-2.4.8.dist-info}/top_level.txt +0 -0
nuitka/OptionParsing.py
CHANGED
|
@@ -1,20 +1,6 @@
|
|
|
1
|
-
# Copyright
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
# integrates with CPython, but also works on its own.
|
|
5
|
-
#
|
|
6
|
-
# Licensed under the Apache License, Version 2.0 (the "License");
|
|
7
|
-
# you may not use this file except in compliance with the License.
|
|
8
|
-
# You may obtain a copy of the License at
|
|
9
|
-
#
|
|
10
|
-
# http://www.apache.org/licenses/LICENSE-2.0
|
|
11
|
-
#
|
|
12
|
-
# Unless required by applicable law or agreed to in writing, software
|
|
13
|
-
# distributed under the License is distributed on an "AS IS" BASIS,
|
|
14
|
-
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
15
|
-
# See the License for the specific language governing permissions and
|
|
16
|
-
# limitations under the License.
|
|
17
|
-
#
|
|
1
|
+
# Copyright 2024, Kay Hayen, mailto:kay.hayen@gmail.com find license text at end of file
|
|
2
|
+
|
|
3
|
+
|
|
18
4
|
""" Command line options of Nuitka.
|
|
19
5
|
|
|
20
6
|
These provide only the optparse options to use, and the mechanic to actually
|
|
@@ -30,8 +16,10 @@ pretty good.
|
|
|
30
16
|
import os
|
|
31
17
|
import re
|
|
32
18
|
import sys
|
|
19
|
+
from string import Formatter
|
|
33
20
|
|
|
34
21
|
from nuitka.PythonFlavors import getPythonFlavorName
|
|
22
|
+
from nuitka.PythonVersions import isPythonWithGil
|
|
35
23
|
from nuitka.utils.CommandLineOptions import SUPPRESS_HELP, makeOptionsParser
|
|
36
24
|
from nuitka.utils.FileOperations import getFileContentByLine
|
|
37
25
|
from nuitka.utils.Utils import (
|
|
@@ -49,15 +37,18 @@ from nuitka.Version import getCommercialVersion, getNuitkaVersion
|
|
|
49
37
|
|
|
50
38
|
# Indicator if we were called as "nuitka-run" in which case we assume some
|
|
51
39
|
# other defaults and work a bit different with parameters.
|
|
52
|
-
|
|
40
|
+
_nuitka_binary_name = os.path.basename(sys.argv[0])
|
|
41
|
+
if _nuitka_binary_name == "__main__.py":
|
|
42
|
+
_nuitka_binary_name = "%s -m nuitka" % os.path.basename(sys.executable)
|
|
43
|
+
is_nuitka_run = _nuitka_binary_name.lower().endswith("-run")
|
|
53
44
|
|
|
54
45
|
if not is_nuitka_run:
|
|
55
|
-
|
|
46
|
+
usage_template = "usage: %s [--module] [--run] [options] main_module.py"
|
|
56
47
|
else:
|
|
57
|
-
|
|
48
|
+
usage_template = "usage: %s [options] main_module.py"
|
|
58
49
|
|
|
59
50
|
|
|
60
|
-
parser = makeOptionsParser(usage=
|
|
51
|
+
parser = makeOptionsParser(usage=usage_template % _nuitka_binary_name)
|
|
61
52
|
|
|
62
53
|
parser.add_option(
|
|
63
54
|
"--version",
|
|
@@ -75,7 +66,7 @@ parser.add_option(
|
|
|
75
66
|
dest="module_mode",
|
|
76
67
|
default=False,
|
|
77
68
|
help="""\
|
|
78
|
-
Create an extension module executable instead of a program. Defaults to off.""",
|
|
69
|
+
Create an importable binary extension module executable instead of a program. Defaults to off.""",
|
|
79
70
|
)
|
|
80
71
|
|
|
81
72
|
parser.add_option(
|
|
@@ -104,6 +95,7 @@ parser.add_option(
|
|
|
104
95
|
action="store_true",
|
|
105
96
|
dest="is_onefile",
|
|
106
97
|
default=False,
|
|
98
|
+
github_action_default=True,
|
|
107
99
|
help="""\
|
|
108
100
|
On top of standalone mode, enable onefile mode. This means not a folder,
|
|
109
101
|
but a compressed executable is created and used. Defaults to off.""",
|
|
@@ -117,16 +109,6 @@ parser.add_option(
|
|
|
117
109
|
help=SUPPRESS_HELP,
|
|
118
110
|
)
|
|
119
111
|
|
|
120
|
-
parser.add_option(
|
|
121
|
-
"--python-debug",
|
|
122
|
-
action="store_true",
|
|
123
|
-
dest="python_debug",
|
|
124
|
-
default=None,
|
|
125
|
-
help="""\
|
|
126
|
-
Use debug version or not. Default uses what you are using to run Nuitka, most
|
|
127
|
-
likely a non-debug version.""",
|
|
128
|
-
)
|
|
129
|
-
|
|
130
112
|
parser.add_option(
|
|
131
113
|
"--python-flag",
|
|
132
114
|
action="append",
|
|
@@ -144,17 +126,30 @@ load outside code) and "-m" (package mode, compile as "package.__main__").
|
|
|
144
126
|
Default empty.""",
|
|
145
127
|
)
|
|
146
128
|
|
|
129
|
+
parser.add_option(
|
|
130
|
+
"--python-debug",
|
|
131
|
+
action="store_true",
|
|
132
|
+
dest="python_debug",
|
|
133
|
+
default=None,
|
|
134
|
+
help="""\
|
|
135
|
+
Use debug version or not. Default uses what you are using to run Nuitka, most
|
|
136
|
+
likely a non-debug version. Only for debugging and testing purposes.""",
|
|
137
|
+
)
|
|
138
|
+
|
|
147
139
|
parser.add_option(
|
|
148
140
|
"--python-for-scons",
|
|
149
141
|
action="store",
|
|
150
142
|
dest="python_scons",
|
|
151
143
|
metavar="PATH",
|
|
152
144
|
default=None,
|
|
145
|
+
github_action=False,
|
|
153
146
|
help="""\
|
|
154
|
-
|
|
155
|
-
for Scons. Otherwise Nuitka can
|
|
156
|
-
|
|
157
|
-
|
|
147
|
+
When compiling with Python 3.4 provide the path of a
|
|
148
|
+
Python binary to use for Scons. Otherwise Nuitka can
|
|
149
|
+
use what you run Nuitka with, or find Python installation,
|
|
150
|
+
e.g. from Windows registry. On Windows, a Python 3.5 or
|
|
151
|
+
higher is needed. On non-Windows, a Python 2.6 or 2.7
|
|
152
|
+
will do as well.""",
|
|
158
153
|
)
|
|
159
154
|
|
|
160
155
|
parser.add_option(
|
|
@@ -180,6 +175,7 @@ parser.add_option(
|
|
|
180
175
|
action="store_true",
|
|
181
176
|
dest="github_workflow_options",
|
|
182
177
|
default=False,
|
|
178
|
+
github_action=False,
|
|
183
179
|
help=SUPPRESS_HELP,
|
|
184
180
|
)
|
|
185
181
|
|
|
@@ -292,8 +288,8 @@ follow_group.add_option(
|
|
|
292
288
|
default=[],
|
|
293
289
|
help="""\
|
|
294
290
|
Do not follow to that module name even if used, or if a package name, to the
|
|
295
|
-
whole package in any case, overrides all other options.
|
|
296
|
-
times. Default empty.""",
|
|
291
|
+
whole package in any case, overrides all other options. This can also contain
|
|
292
|
+
patterns, e.g. "*.tests". Can be given multiple times. Default empty.""",
|
|
297
293
|
)
|
|
298
294
|
|
|
299
295
|
follow_group.add_option(
|
|
@@ -329,9 +325,9 @@ onefile_group.add_option(
|
|
|
329
325
|
default=None,
|
|
330
326
|
help="""\
|
|
331
327
|
Use this as a folder to unpack to in onefile mode. Defaults to
|
|
332
|
-
'
|
|
328
|
+
'{TEMP}/onefile_{PID}_{TIME}', i.e. user temporary directory
|
|
333
329
|
and being non-static it's removed. Use e.g. a string like
|
|
334
|
-
'
|
|
330
|
+
'{CACHE_DIR}/{COMPANY}/{PRODUCT}/{VERSION}' which is a good
|
|
335
331
|
static cache path, this will then not be removed.""",
|
|
336
332
|
)
|
|
337
333
|
|
|
@@ -358,6 +354,16 @@ When creating the onefile, disable compression of the payload. This is
|
|
|
358
354
|
mostly for debug purposes, or to save time. Default is off.""",
|
|
359
355
|
)
|
|
360
356
|
|
|
357
|
+
onefile_group.add_option(
|
|
358
|
+
"--onefile-as-archive",
|
|
359
|
+
action="store_true",
|
|
360
|
+
dest="onefile_as_archive",
|
|
361
|
+
default=False,
|
|
362
|
+
help="""\
|
|
363
|
+
When creating the onefile, use an archive format, that can be unpacked
|
|
364
|
+
with "nuitka-onefile-unpack" rather than a stream that only the onefile
|
|
365
|
+
program itself unpacks. Default is off.""",
|
|
366
|
+
)
|
|
361
367
|
|
|
362
368
|
del onefile_group
|
|
363
369
|
|
|
@@ -409,9 +415,8 @@ data_group.add_option(
|
|
|
409
415
|
Include data files from complete directory in the distribution. This is
|
|
410
416
|
recursive. Check '--include-data-files' with patterns if you want non-recursive
|
|
411
417
|
inclusion. An example would be '--include-data-dir=/path/some_dir=data/some_dir'
|
|
412
|
-
for plain copy, of the whole directory. All files are copied, if you
|
|
413
|
-
|
|
414
|
-
option to remove them. Default empty.""",
|
|
418
|
+
for plain copy, of the whole directory. All non-code files are copied, if you
|
|
419
|
+
want to use '--noinclude-data-files' option to remove them. Default empty.""",
|
|
415
420
|
)
|
|
416
421
|
|
|
417
422
|
data_group.add_option(
|
|
@@ -423,8 +428,21 @@ data_group.add_option(
|
|
|
423
428
|
help="""\
|
|
424
429
|
Do not include data files matching the filename pattern given. This is against
|
|
425
430
|
the target filename, not source paths. So to ignore a file pattern from package
|
|
426
|
-
data for
|
|
427
|
-
whole directory simply use
|
|
431
|
+
data for 'package_name' should be matched as 'package_name/*.txt'. Or for the
|
|
432
|
+
whole directory simply use 'package_name'. Default empty.""",
|
|
433
|
+
)
|
|
434
|
+
|
|
435
|
+
data_group.add_option(
|
|
436
|
+
"--include-onefile-external-data",
|
|
437
|
+
action="append",
|
|
438
|
+
dest="data_files_external",
|
|
439
|
+
metavar="PATTERN",
|
|
440
|
+
default=[],
|
|
441
|
+
help="""\
|
|
442
|
+
Include the specified data file patterns outside of the onefile binary,
|
|
443
|
+
rather than on the inside. Makes only sense in case of '--onefile'
|
|
444
|
+
compilation. First files have to be specified as included somehow,
|
|
445
|
+
then this refers to target paths. Default empty.""",
|
|
428
446
|
)
|
|
429
447
|
|
|
430
448
|
data_group.add_option(
|
|
@@ -437,6 +455,18 @@ data_group.add_option(
|
|
|
437
455
|
Output the data files found for a given package name. Default not done.""",
|
|
438
456
|
)
|
|
439
457
|
|
|
458
|
+
data_group.add_option(
|
|
459
|
+
"--include-raw-dir",
|
|
460
|
+
action="append",
|
|
461
|
+
dest="raw_dirs",
|
|
462
|
+
metavar="DIRECTORY",
|
|
463
|
+
default=[],
|
|
464
|
+
help="""\
|
|
465
|
+
Include raw directories completely in the distribution. This is
|
|
466
|
+
recursive. Check '--include-data-dir' to use the sane option.
|
|
467
|
+
Default empty.""",
|
|
468
|
+
)
|
|
469
|
+
|
|
440
470
|
|
|
441
471
|
del data_group
|
|
442
472
|
|
|
@@ -468,8 +498,8 @@ dll_group.add_option(
|
|
|
468
498
|
default=[],
|
|
469
499
|
help="""\
|
|
470
500
|
Do not include DLL files matching the filename pattern given. This is against
|
|
471
|
-
the target filename, not source paths. So ignore a DLL
|
|
472
|
-
the package
|
|
501
|
+
the target filename, not source paths. So ignore a DLL 'someDLL' contained in
|
|
502
|
+
the package 'package_name' it should be matched as 'package_name/someDLL.*'.
|
|
473
503
|
Default empty.""",
|
|
474
504
|
)
|
|
475
505
|
|
|
@@ -512,6 +542,7 @@ warnings_group.add_option(
|
|
|
512
542
|
action="store_true",
|
|
513
543
|
dest="assume_yes_for_downloads",
|
|
514
544
|
default=False,
|
|
545
|
+
github_action_default=True,
|
|
515
546
|
help="""\
|
|
516
547
|
Allow Nuitka to download external code if necessary, e.g. dependency
|
|
517
548
|
walker, ccache, and even gcc on Windows. To disable, redirect input
|
|
@@ -559,18 +590,6 @@ Execute inside a debugger, e.g. "gdb" or "lldb" to automatically get a stack tra
|
|
|
559
590
|
Defaults to off.""",
|
|
560
591
|
)
|
|
561
592
|
|
|
562
|
-
execute_group.add_option(
|
|
563
|
-
"--execute-with-pythonpath",
|
|
564
|
-
action="store_true",
|
|
565
|
-
dest="keep_pythonpath",
|
|
566
|
-
default=False,
|
|
567
|
-
help="""\
|
|
568
|
-
When immediately executing the created binary or module using '--run',
|
|
569
|
-
don't reset 'PYTHONPATH' environment. When all modules are successfully
|
|
570
|
-
included, you ought to not need PYTHONPATH anymore, and definitely not
|
|
571
|
-
for standalone mode.""",
|
|
572
|
-
)
|
|
573
|
-
|
|
574
593
|
del execute_group
|
|
575
594
|
|
|
576
595
|
|
|
@@ -584,9 +603,9 @@ compilation_group.add_option(
|
|
|
584
603
|
metavar="YAML_FILENAME",
|
|
585
604
|
help="""\
|
|
586
605
|
User provided Yaml file with package configuration. You can include DLLs,
|
|
587
|
-
remove bloat, add hidden dependencies. Check
|
|
588
|
-
description of the format to use. Can be given
|
|
589
|
-
to empty.""",
|
|
606
|
+
remove bloat, add hidden dependencies. Check the Nuitka Package Configuration
|
|
607
|
+
Manual for a complete description of the format to use. Can be given
|
|
608
|
+
multiple times. Defaults to empty.""",
|
|
590
609
|
)
|
|
591
610
|
|
|
592
611
|
compilation_group.add_option(
|
|
@@ -654,8 +673,7 @@ choice, also not for standalone mode and using it will be an error. This may
|
|
|
654
673
|
include path information that needs to exist though. Defaults to '%s' on this
|
|
655
674
|
platform.
|
|
656
675
|
"""
|
|
657
|
-
% "<program_name>"
|
|
658
|
-
+ (".exe" if isWin32OrPosixWindows() else ".bin"),
|
|
676
|
+
% ("<program_name>" + (".exe" if isWin32OrPosixWindows() else ".bin")),
|
|
659
677
|
)
|
|
660
678
|
|
|
661
679
|
output_group.add_option(
|
|
@@ -687,13 +705,53 @@ output_group.add_option(
|
|
|
687
705
|
dest="pyi_file",
|
|
688
706
|
default=True,
|
|
689
707
|
help="""\
|
|
690
|
-
Do not create a
|
|
708
|
+
Do not create a '.pyi' file for extension modules created by Nuitka. This is
|
|
691
709
|
used to detect implicit imports.
|
|
692
710
|
Defaults to off.""",
|
|
693
711
|
)
|
|
694
712
|
|
|
695
713
|
del output_group
|
|
696
714
|
|
|
715
|
+
deployment_group = parser.add_option_group("Deployment control")
|
|
716
|
+
|
|
717
|
+
deployment_group.add_option(
|
|
718
|
+
"--deployment",
|
|
719
|
+
action="store_true",
|
|
720
|
+
dest="is_deployment",
|
|
721
|
+
default=False,
|
|
722
|
+
help="""\
|
|
723
|
+
Disable code aimed at making finding compatibility issues easier. This
|
|
724
|
+
will e.g. prevent execution with "-c" argument, which is often used by
|
|
725
|
+
code that attempts run a module, and causes a program to start itself
|
|
726
|
+
over and over potentially. Disable once you deploy to end users, for
|
|
727
|
+
finding typical issues, this is very helpful during development. Default
|
|
728
|
+
off.""",
|
|
729
|
+
)
|
|
730
|
+
|
|
731
|
+
deployment_group.add_option(
|
|
732
|
+
"--no-deployment-flag",
|
|
733
|
+
action="append",
|
|
734
|
+
dest="no_deployment_flags",
|
|
735
|
+
metavar="FLAG",
|
|
736
|
+
default=[],
|
|
737
|
+
help="""\
|
|
738
|
+
Keep deployment mode, but disable selectively parts of it. Errors from
|
|
739
|
+
deployment mode will output these identifiers. Default empty.""",
|
|
740
|
+
)
|
|
741
|
+
|
|
742
|
+
environment_group = parser.add_option_group("Environment control")
|
|
743
|
+
|
|
744
|
+
environment_group.add_option(
|
|
745
|
+
"--force-runtime-environment-variable",
|
|
746
|
+
action="append",
|
|
747
|
+
dest="forced_runtime_env_variables",
|
|
748
|
+
metavar="VARIABLE_SPEC",
|
|
749
|
+
default=[],
|
|
750
|
+
help="""\
|
|
751
|
+
Force an environment variables to a given value. Default empty.""",
|
|
752
|
+
)
|
|
753
|
+
|
|
754
|
+
del environment_group
|
|
697
755
|
|
|
698
756
|
debug_group = parser.add_option_group("Debug features")
|
|
699
757
|
|
|
@@ -707,6 +765,25 @@ Executing all self checks possible to find errors in Nuitka, do not use for
|
|
|
707
765
|
production. Defaults to off.""",
|
|
708
766
|
)
|
|
709
767
|
|
|
768
|
+
debug_group.add_option(
|
|
769
|
+
"--no-debug-immortal-assumptions",
|
|
770
|
+
action="store_false",
|
|
771
|
+
dest="debug_immortal",
|
|
772
|
+
default=None,
|
|
773
|
+
help="""\
|
|
774
|
+
Disable check normally done with "--debug". With Python3.12+ do not check known
|
|
775
|
+
immortal object assumptions. Some C libraries corrupt them. Defaults to check
|
|
776
|
+
being made if "--debug" is on.""",
|
|
777
|
+
)
|
|
778
|
+
|
|
779
|
+
debug_group.add_option(
|
|
780
|
+
"--debug-immortal-assumptions",
|
|
781
|
+
action="store_true",
|
|
782
|
+
dest="debug_immortal",
|
|
783
|
+
default=None,
|
|
784
|
+
help=SUPPRESS_HELP,
|
|
785
|
+
)
|
|
786
|
+
|
|
710
787
|
debug_group.add_option(
|
|
711
788
|
"--unstripped",
|
|
712
789
|
"--unstriped",
|
|
@@ -723,6 +800,7 @@ debug_group.add_option(
|
|
|
723
800
|
action="store_true",
|
|
724
801
|
dest="profile",
|
|
725
802
|
default=False,
|
|
803
|
+
github_action=False,
|
|
726
804
|
help="""\
|
|
727
805
|
Enable vmprof based profiling of time spent. Not working currently. Defaults to off.""",
|
|
728
806
|
)
|
|
@@ -732,6 +810,7 @@ debug_group.add_option(
|
|
|
732
810
|
action="store_true",
|
|
733
811
|
dest="internal_graph",
|
|
734
812
|
default=False,
|
|
813
|
+
github_action=False,
|
|
735
814
|
help="""\
|
|
736
815
|
Create graph of optimization process internals, do not use for whole programs, but only
|
|
737
816
|
for small test cases. Defaults to off.""",
|
|
@@ -752,6 +831,7 @@ debug_group.add_option(
|
|
|
752
831
|
action="store_true",
|
|
753
832
|
dest="recompile_c_only",
|
|
754
833
|
default=False,
|
|
834
|
+
github_action=False,
|
|
755
835
|
help="""\
|
|
756
836
|
This is not incremental compilation, but for Nuitka development only. Takes
|
|
757
837
|
existing files and simply compile them as C again. Allows compiling edited
|
|
@@ -769,29 +849,6 @@ debug_group.add_option(
|
|
|
769
849
|
help="Write the internal program structure, result of optimization in XML form to given filename.",
|
|
770
850
|
)
|
|
771
851
|
|
|
772
|
-
debug_group.add_option(
|
|
773
|
-
"--deployment",
|
|
774
|
-
action="store_true",
|
|
775
|
-
dest="is_deployment",
|
|
776
|
-
default=False,
|
|
777
|
-
help="""\
|
|
778
|
-
Disable code aimed at making finding compatibility issues easier. This
|
|
779
|
-
will e.g. prevent execution with "-c" argument, which is often used by
|
|
780
|
-
code that attempts run a module, and causes a program to start itself
|
|
781
|
-
over and over potentially. Default off.""",
|
|
782
|
-
)
|
|
783
|
-
|
|
784
|
-
debug_group.add_option(
|
|
785
|
-
"--no-deployment-flag",
|
|
786
|
-
action="append",
|
|
787
|
-
dest="no_deployment_flags",
|
|
788
|
-
metavar="FLAG",
|
|
789
|
-
default=[],
|
|
790
|
-
help="""\
|
|
791
|
-
Keep deployment mode, but disable selectively parts of it. Errors from
|
|
792
|
-
deployment mode will output these identifiers. Default empty.""",
|
|
793
|
-
)
|
|
794
|
-
|
|
795
852
|
debug_group.add_option(
|
|
796
853
|
"--experimental",
|
|
797
854
|
action="append",
|
|
@@ -839,6 +896,7 @@ debug_group.add_option(
|
|
|
839
896
|
action="store_true",
|
|
840
897
|
dest="generate_c_only",
|
|
841
898
|
default=False,
|
|
899
|
+
github_action=False,
|
|
842
900
|
help="""\
|
|
843
901
|
Generate only C source code, and do not compile it to binary or module. This
|
|
844
902
|
is for debugging and code coverage analysis that doesn't waste CPU. Defaults to
|
|
@@ -855,6 +913,7 @@ parser.add_option(
|
|
|
855
913
|
action="store_false",
|
|
856
914
|
dest="allow_reexecute",
|
|
857
915
|
default=True,
|
|
916
|
+
github_action=False,
|
|
858
917
|
help=SUPPRESS_HELP,
|
|
859
918
|
)
|
|
860
919
|
|
|
@@ -913,8 +972,9 @@ c_compiler_group.add_option(
|
|
|
913
972
|
metavar="N",
|
|
914
973
|
default=None,
|
|
915
974
|
help="""\
|
|
916
|
-
Specify the allowed number of parallel C compiler jobs.
|
|
917
|
-
system CPU
|
|
975
|
+
Specify the allowed number of parallel C compiler jobs. Negative values
|
|
976
|
+
are system CPU minus the given value. Defaults to the full system CPU
|
|
977
|
+
count unless low memory mode is activated, then it defaults to 1.""",
|
|
918
978
|
)
|
|
919
979
|
|
|
920
980
|
c_compiler_group.add_option(
|
|
@@ -942,12 +1002,26 @@ Use static link library of Python. Allowed values are "yes", "no",
|
|
|
942
1002
|
and "auto" (when it's known to work). Defaults to "auto".""",
|
|
943
1003
|
)
|
|
944
1004
|
|
|
1005
|
+
c_compiler_group.add_option(
|
|
1006
|
+
"--cf-protection",
|
|
1007
|
+
action="store",
|
|
1008
|
+
dest="cf_protection",
|
|
1009
|
+
metavar="PROTECTION_MODE",
|
|
1010
|
+
default="auto",
|
|
1011
|
+
choices=("auto", "full", "branch", "return", "none", "check"),
|
|
1012
|
+
help="""\
|
|
1013
|
+
This option is gcc specific. For the gcc compiler, select the
|
|
1014
|
+
"cf-protection" mode. Default "auto" is to use the gcc default
|
|
1015
|
+
value, but you can override it, e.g. to disable it with "none"
|
|
1016
|
+
value. Refer to gcc documentation for "-fcf-protection" for the
|
|
1017
|
+
details.""",
|
|
1018
|
+
)
|
|
945
1019
|
|
|
946
1020
|
del c_compiler_group
|
|
947
1021
|
|
|
948
1022
|
caching_group = parser.add_option_group("Cache Control")
|
|
949
1023
|
|
|
950
|
-
_cache_names = ("all", "ccache", "bytecode")
|
|
1024
|
+
_cache_names = ("all", "ccache", "bytecode", "compression")
|
|
951
1025
|
|
|
952
1026
|
if isWin32Windows():
|
|
953
1027
|
_cache_names += ("dll-dependencies",)
|
|
@@ -1029,7 +1103,7 @@ del caching_group
|
|
|
1029
1103
|
pgo_group = parser.add_option_group("PGO compilation choices")
|
|
1030
1104
|
|
|
1031
1105
|
pgo_group.add_option(
|
|
1032
|
-
"--pgo",
|
|
1106
|
+
"--pgo-c",
|
|
1033
1107
|
action="store_true",
|
|
1034
1108
|
dest="is_c_pgo",
|
|
1035
1109
|
default=False,
|
|
@@ -1136,7 +1210,7 @@ tracing_group.add_option(
|
|
|
1136
1210
|
metavar="REPORT_DESC",
|
|
1137
1211
|
default=[],
|
|
1138
1212
|
help="""\
|
|
1139
|
-
Report via template. Provide template and output filename
|
|
1213
|
+
Report via template. Provide template and output filename 'template.rst.j2:output.rst'. For
|
|
1140
1214
|
built-in templates, check the User Manual for what these are. Can be given multiple times.
|
|
1141
1215
|
Default is empty.""",
|
|
1142
1216
|
)
|
|
@@ -1168,6 +1242,7 @@ tracing_group.add_option(
|
|
|
1168
1242
|
action="store_false",
|
|
1169
1243
|
dest="progress_bar",
|
|
1170
1244
|
default=True,
|
|
1245
|
+
github_action=False,
|
|
1171
1246
|
help="""Disable progress bars. Defaults to off.""",
|
|
1172
1247
|
)
|
|
1173
1248
|
|
|
@@ -1176,6 +1251,7 @@ tracing_group.add_option(
|
|
|
1176
1251
|
action="store_true",
|
|
1177
1252
|
dest="show_progress",
|
|
1178
1253
|
default=False,
|
|
1254
|
+
github_action=False,
|
|
1179
1255
|
help="""Obsolete: Provide progress information and statistics.
|
|
1180
1256
|
Disables normal progress bar. Defaults to off.""",
|
|
1181
1257
|
)
|
|
@@ -1194,6 +1270,7 @@ tracing_group.add_option(
|
|
|
1194
1270
|
action="store_true",
|
|
1195
1271
|
dest="show_inclusion",
|
|
1196
1272
|
default=False,
|
|
1273
|
+
github_action=False,
|
|
1197
1274
|
help="""\
|
|
1198
1275
|
Provide information for included modules and DLLs
|
|
1199
1276
|
Obsolete: You should use '--report' file instead. Defaults to off.""",
|
|
@@ -1205,6 +1282,7 @@ tracing_group.add_option(
|
|
|
1205
1282
|
dest="show_inclusion_output",
|
|
1206
1283
|
metavar="PATH",
|
|
1207
1284
|
default=None,
|
|
1285
|
+
github_action=False,
|
|
1208
1286
|
help="""\
|
|
1209
1287
|
Where to output '--show-modules', should be a filename. Default is standard output.""",
|
|
1210
1288
|
)
|
|
@@ -1214,6 +1292,7 @@ tracing_group.add_option(
|
|
|
1214
1292
|
action="store_true",
|
|
1215
1293
|
dest="verbose",
|
|
1216
1294
|
default=False,
|
|
1295
|
+
github_action=False,
|
|
1217
1296
|
help="""\
|
|
1218
1297
|
Output details of actions taken, esp. in optimizations. Can become a lot.
|
|
1219
1298
|
Defaults to off.""",
|
|
@@ -1225,6 +1304,7 @@ tracing_group.add_option(
|
|
|
1225
1304
|
dest="verbose_output",
|
|
1226
1305
|
metavar="PATH",
|
|
1227
1306
|
default=None,
|
|
1307
|
+
github_action=False,
|
|
1228
1308
|
help="""\
|
|
1229
1309
|
Where to output from '--verbose', should be a filename. Default is standard output.""",
|
|
1230
1310
|
)
|
|
@@ -1234,29 +1314,6 @@ del tracing_group
|
|
|
1234
1314
|
|
|
1235
1315
|
os_group = parser.add_option_group("General OS controls")
|
|
1236
1316
|
|
|
1237
|
-
os_group.add_option(
|
|
1238
|
-
"--disable-console",
|
|
1239
|
-
"--macos-disable-console",
|
|
1240
|
-
"--windows-disable-console",
|
|
1241
|
-
action="store_true",
|
|
1242
|
-
dest="disable_console",
|
|
1243
|
-
default=None,
|
|
1244
|
-
help="""\
|
|
1245
|
-
When compiling for Windows or macOS, disable the console window and create a GUI
|
|
1246
|
-
application. Defaults to off.""",
|
|
1247
|
-
)
|
|
1248
|
-
|
|
1249
|
-
os_group.add_option(
|
|
1250
|
-
"--enable-console",
|
|
1251
|
-
action="store_false",
|
|
1252
|
-
dest="disable_console",
|
|
1253
|
-
default=None,
|
|
1254
|
-
help="""\
|
|
1255
|
-
When compiling for Windows or macOS, enable the console window and create a console
|
|
1256
|
-
application. This disables hints from certain modules, e.g. "PySide" that suggest
|
|
1257
|
-
to disable it. Defaults to true.""",
|
|
1258
|
-
)
|
|
1259
|
-
|
|
1260
1317
|
os_group.add_option(
|
|
1261
1318
|
"--force-stdout-spec",
|
|
1262
1319
|
"--windows-force-stdout-spec",
|
|
@@ -1267,7 +1324,7 @@ os_group.add_option(
|
|
|
1267
1324
|
help="""\
|
|
1268
1325
|
Force standard output of the program to go to this location. Useful for programs with
|
|
1269
1326
|
disabled console and programs using the Windows Services Plugin of Nuitka commercial.
|
|
1270
|
-
Defaults to not active, use e.g. '
|
|
1327
|
+
Defaults to not active, use e.g. '{PROGRAM_BASE}.out.txt', i.e. file near your program,
|
|
1271
1328
|
check User Manual for full list of available values.""",
|
|
1272
1329
|
)
|
|
1273
1330
|
|
|
@@ -1281,7 +1338,7 @@ os_group.add_option(
|
|
|
1281
1338
|
help="""\
|
|
1282
1339
|
Force standard error of the program to go to this location. Useful for programs with
|
|
1283
1340
|
disabled console and programs using the Windows Services Plugin of Nuitka commercial.
|
|
1284
|
-
Defaults to not active, use e.g. '
|
|
1341
|
+
Defaults to not active, use e.g. '{PROGRAM_BASE}.err.txt', i.e. file near your program,
|
|
1285
1342
|
check User Manual for full list of available values.""",
|
|
1286
1343
|
)
|
|
1287
1344
|
|
|
@@ -1291,17 +1348,24 @@ del os_group
|
|
|
1291
1348
|
windows_group = parser.add_option_group("Windows specific controls")
|
|
1292
1349
|
|
|
1293
1350
|
windows_group.add_option(
|
|
1294
|
-
"--windows-
|
|
1351
|
+
"--windows-console-mode",
|
|
1295
1352
|
action="store",
|
|
1296
|
-
dest="
|
|
1353
|
+
dest="console_mode",
|
|
1354
|
+
choices=("force", "disable", "attach"),
|
|
1355
|
+
metavar="CONSOLE_MODE",
|
|
1297
1356
|
default=None,
|
|
1298
|
-
help=
|
|
1357
|
+
help="""\
|
|
1358
|
+
Select console mode to use. Default mode is 'force' and creates a
|
|
1359
|
+
console window unless the program was started from one. With 'disable'
|
|
1360
|
+
it doesn't create or use a console at all. With 'attach' an existing
|
|
1361
|
+
console will be used for outputs. Default is 'force'.
|
|
1362
|
+
""",
|
|
1299
1363
|
)
|
|
1300
1364
|
|
|
1301
1365
|
windows_group.add_option(
|
|
1302
1366
|
"--windows-icon-from-ico",
|
|
1303
1367
|
action="append",
|
|
1304
|
-
dest="
|
|
1368
|
+
dest="windows_icon_path",
|
|
1305
1369
|
metavar="ICON_PATH",
|
|
1306
1370
|
default=[],
|
|
1307
1371
|
help="""\
|
|
@@ -1349,6 +1413,32 @@ Request Windows User Control, to enforce running from a few folders only, remote
|
|
|
1349
1413
|
desktop access. (Windows only). Defaults to off.""",
|
|
1350
1414
|
)
|
|
1351
1415
|
|
|
1416
|
+
windows_group.add_option(
|
|
1417
|
+
"--disable-console",
|
|
1418
|
+
"--macos-disable-console",
|
|
1419
|
+
"--windows-disable-console",
|
|
1420
|
+
action="store_true",
|
|
1421
|
+
dest="disable_console",
|
|
1422
|
+
default=None,
|
|
1423
|
+
help=SUPPRESS_HELP,
|
|
1424
|
+
)
|
|
1425
|
+
|
|
1426
|
+
windows_group.add_option(
|
|
1427
|
+
"--enable-console",
|
|
1428
|
+
action="store_false",
|
|
1429
|
+
dest="disable_console",
|
|
1430
|
+
default=None,
|
|
1431
|
+
help=SUPPRESS_HELP,
|
|
1432
|
+
)
|
|
1433
|
+
|
|
1434
|
+
windows_group.add_option(
|
|
1435
|
+
"--windows-dependency-tool",
|
|
1436
|
+
action="store",
|
|
1437
|
+
dest="dependency_tool",
|
|
1438
|
+
default=None,
|
|
1439
|
+
help=SUPPRESS_HELP,
|
|
1440
|
+
)
|
|
1441
|
+
|
|
1352
1442
|
windows_group.add_option(
|
|
1353
1443
|
"--windows-service",
|
|
1354
1444
|
action="store_true",
|
|
@@ -1417,6 +1507,18 @@ del windows_group
|
|
|
1417
1507
|
|
|
1418
1508
|
macos_group = parser.add_option_group("macOS specific controls")
|
|
1419
1509
|
|
|
1510
|
+
macos_group.add_option(
|
|
1511
|
+
"--macos-create-app-bundle",
|
|
1512
|
+
action="store_true",
|
|
1513
|
+
dest="macos_create_bundle",
|
|
1514
|
+
default=False,
|
|
1515
|
+
help="""\
|
|
1516
|
+
When compiling for macOS, create a bundle rather than a plain binary
|
|
1517
|
+
application. This is the only way to unlock the disabling of console,
|
|
1518
|
+
get high DPI graphics, etc. and implies standalone mode. Defaults to
|
|
1519
|
+
off.""",
|
|
1520
|
+
)
|
|
1521
|
+
|
|
1420
1522
|
macos_group.add_option(
|
|
1421
1523
|
"--macos-target-arch",
|
|
1422
1524
|
action="store",
|
|
@@ -1430,21 +1532,10 @@ is what the running Python allows for. Default is "native" which is
|
|
|
1430
1532
|
the architecture the Python is run with.""",
|
|
1431
1533
|
)
|
|
1432
1534
|
|
|
1433
|
-
macos_group.add_option(
|
|
1434
|
-
"--macos-create-app-bundle",
|
|
1435
|
-
action="store_true",
|
|
1436
|
-
dest="macos_create_bundle",
|
|
1437
|
-
default=False,
|
|
1438
|
-
help="""\
|
|
1439
|
-
When compiling for macOS, create a bundle rather than a plain binary
|
|
1440
|
-
application. Currently experimental and incomplete. Currently this
|
|
1441
|
-
is the only way to unlock disabling of console.Defaults to off.""",
|
|
1442
|
-
)
|
|
1443
|
-
|
|
1444
1535
|
macos_group.add_option(
|
|
1445
1536
|
"--macos-app-icon",
|
|
1446
1537
|
action="append",
|
|
1447
|
-
dest="
|
|
1538
|
+
dest="macos_icon_path",
|
|
1448
1539
|
metavar="ICON_PATH",
|
|
1449
1540
|
default=[],
|
|
1450
1541
|
help="Add icon for the application bundle to use. Can be given only one time. Defaults to Python icon if available.",
|
|
@@ -1498,7 +1589,8 @@ macos_group.add_option(
|
|
|
1498
1589
|
help="""\
|
|
1499
1590
|
When signing on macOS, by default an ad-hoc identify will be used, but with this
|
|
1500
1591
|
option your get to specify another identity to use. The signing of code is now
|
|
1501
|
-
mandatory on macOS and cannot be disabled.
|
|
1592
|
+
mandatory on macOS and cannot be disabled. Use "auto" to detect your only identity
|
|
1593
|
+
installed. Default "ad-hoc" if not given.""",
|
|
1502
1594
|
)
|
|
1503
1595
|
|
|
1504
1596
|
macos_group.add_option(
|
|
@@ -1549,7 +1641,7 @@ linux_group.add_option(
|
|
|
1549
1641
|
"--linux-icon",
|
|
1550
1642
|
"--linux-onefile-icon",
|
|
1551
1643
|
action="append",
|
|
1552
|
-
dest="
|
|
1644
|
+
dest="linux_icon_path",
|
|
1553
1645
|
metavar="ICON_PATH",
|
|
1554
1646
|
default=[],
|
|
1555
1647
|
help="Add executable icon for onefile binary to use. Can be given only one time. Defaults to Python icon if available.",
|
|
@@ -1623,7 +1715,7 @@ version_group.add_option(
|
|
|
1623
1715
|
metavar="COPYRIGHT_TEXT",
|
|
1624
1716
|
default=None,
|
|
1625
1717
|
help="""\
|
|
1626
|
-
Copyright used in version information. Windows only at this time. Defaults to not present.""",
|
|
1718
|
+
Copyright used in version information. Windows/macOS only at this time. Defaults to not present.""",
|
|
1627
1719
|
)
|
|
1628
1720
|
|
|
1629
1721
|
version_group.add_option(
|
|
@@ -1633,7 +1725,7 @@ version_group.add_option(
|
|
|
1633
1725
|
metavar="TRADEMARK_TEXT",
|
|
1634
1726
|
default=None,
|
|
1635
1727
|
help="""\
|
|
1636
|
-
Trademark used in version information. Windows only at this time. Defaults to not present.""",
|
|
1728
|
+
Trademark used in version information. Windows/macOS only at this time. Defaults to not present.""",
|
|
1637
1729
|
)
|
|
1638
1730
|
|
|
1639
1731
|
|
|
@@ -1660,6 +1752,7 @@ plugin_group.add_option(
|
|
|
1660
1752
|
dest="plugins_disabled",
|
|
1661
1753
|
metavar="PLUGIN_NAME",
|
|
1662
1754
|
default=[],
|
|
1755
|
+
github_action=False,
|
|
1663
1756
|
help="""\
|
|
1664
1757
|
Disabled plugins. Must be plug-in names. Use '--plugin-list' to query the
|
|
1665
1758
|
full list and exit. Most standard plugins are not a good idea to disable.
|
|
@@ -1667,16 +1760,12 @@ Default empty.""",
|
|
|
1667
1760
|
)
|
|
1668
1761
|
|
|
1669
1762
|
plugin_group.add_option(
|
|
1670
|
-
"--plugin
|
|
1671
|
-
action="
|
|
1672
|
-
dest="
|
|
1673
|
-
|
|
1674
|
-
|
|
1675
|
-
|
|
1676
|
-
via "--disable-plugin=plugin-that-warned", or you can use this option to disable
|
|
1677
|
-
the mechanism entirely, which also speeds up compilation slightly of course as
|
|
1678
|
-
this detection code is run in vain once you are certain of which plugins to
|
|
1679
|
-
use. Defaults to off.""",
|
|
1763
|
+
"--user-plugin",
|
|
1764
|
+
action="append",
|
|
1765
|
+
dest="user_plugins",
|
|
1766
|
+
metavar="PATH",
|
|
1767
|
+
default=[],
|
|
1768
|
+
help="The file name of user plugin. Can be given multiple times. Default empty.",
|
|
1680
1769
|
)
|
|
1681
1770
|
|
|
1682
1771
|
plugin_group.add_option(
|
|
@@ -1685,31 +1774,69 @@ plugin_group.add_option(
|
|
|
1685
1774
|
dest="plugin_list",
|
|
1686
1775
|
default=False,
|
|
1687
1776
|
require_compiling=False,
|
|
1777
|
+
github_action=False,
|
|
1688
1778
|
help="""\
|
|
1689
1779
|
Show list of all available plugins and exit. Defaults to off.""",
|
|
1690
1780
|
)
|
|
1691
1781
|
|
|
1692
1782
|
plugin_group.add_option(
|
|
1693
|
-
"--
|
|
1783
|
+
"--plugin-no-detection",
|
|
1784
|
+
action="store_false",
|
|
1785
|
+
dest="detect_missing_plugins",
|
|
1786
|
+
default=True,
|
|
1787
|
+
help="""\
|
|
1788
|
+
Plugins can detect if they might be used, and the you can disable the warning
|
|
1789
|
+
via "--disable-plugin=plugin-that-warned", or you can use this option to disable
|
|
1790
|
+
the mechanism entirely, which also speeds up compilation slightly of course as
|
|
1791
|
+
this detection code is run in vain once you are certain of which plugins to
|
|
1792
|
+
use. Defaults to off.""",
|
|
1793
|
+
)
|
|
1794
|
+
|
|
1795
|
+
plugin_group.add_option(
|
|
1796
|
+
"--module-parameter",
|
|
1694
1797
|
action="append",
|
|
1695
|
-
dest="
|
|
1696
|
-
metavar="PATH",
|
|
1798
|
+
dest="module_parameters",
|
|
1697
1799
|
default=[],
|
|
1698
|
-
help="
|
|
1800
|
+
help="""\
|
|
1801
|
+
Provide a module parameter. You are asked by some packages
|
|
1802
|
+
to provide extra decisions. Format is currently
|
|
1803
|
+
--module-parameter=module.name-option-name=value
|
|
1804
|
+
Default empty.""",
|
|
1699
1805
|
)
|
|
1700
1806
|
|
|
1701
1807
|
plugin_group.add_option(
|
|
1702
1808
|
"--show-source-changes",
|
|
1703
|
-
action="
|
|
1809
|
+
action="append",
|
|
1704
1810
|
dest="show_source_changes",
|
|
1705
|
-
default=
|
|
1811
|
+
default=[],
|
|
1812
|
+
github_action=False,
|
|
1706
1813
|
help="""\
|
|
1707
1814
|
Show source changes to original Python file content before compilation. Mostly
|
|
1708
|
-
intended for developing plugins.
|
|
1815
|
+
intended for developing plugins and Nuitka package configuration. Use e.g.
|
|
1816
|
+
'--show-source-changes=numpy.**' to see all changes below a given namespace
|
|
1817
|
+
or use '*' to see everything which can get a lot.
|
|
1818
|
+
Default empty.""",
|
|
1709
1819
|
)
|
|
1710
1820
|
|
|
1711
1821
|
del plugin_group
|
|
1712
1822
|
|
|
1823
|
+
target_group = parser.add_option_group("Cross compilation")
|
|
1824
|
+
|
|
1825
|
+
|
|
1826
|
+
target_group.add_option(
|
|
1827
|
+
"--target",
|
|
1828
|
+
action="store",
|
|
1829
|
+
dest="target_desc",
|
|
1830
|
+
metavar="TARGET_DESC",
|
|
1831
|
+
default=None,
|
|
1832
|
+
help="""\
|
|
1833
|
+
Cross compilation target. Highly experimental and in development, not
|
|
1834
|
+
supposed to work yet. We are working on '--target=wasi' and nothing
|
|
1835
|
+
else yet.""",
|
|
1836
|
+
)
|
|
1837
|
+
|
|
1838
|
+
del target_group
|
|
1839
|
+
|
|
1713
1840
|
|
|
1714
1841
|
def _considerPluginOptions(logger):
|
|
1715
1842
|
# Cyclic dependency on plugins during parsing of command line.
|
|
@@ -1748,6 +1875,33 @@ def _considerPluginOptions(logger):
|
|
|
1748
1875
|
addUserPluginCommandLineOptions(parser=parser, filename=plugin_name)
|
|
1749
1876
|
|
|
1750
1877
|
|
|
1878
|
+
run_time_variable_names = (
|
|
1879
|
+
"TEMP",
|
|
1880
|
+
"PID",
|
|
1881
|
+
"TIME",
|
|
1882
|
+
"PROGRAM",
|
|
1883
|
+
"PROGRAM_BASE",
|
|
1884
|
+
"CACHE_DIR",
|
|
1885
|
+
"COMPANY",
|
|
1886
|
+
"PRODUCT",
|
|
1887
|
+
"VERSION",
|
|
1888
|
+
"HOME",
|
|
1889
|
+
"NONE",
|
|
1890
|
+
"NULL",
|
|
1891
|
+
)
|
|
1892
|
+
|
|
1893
|
+
|
|
1894
|
+
class _RetainingFormatter(Formatter):
|
|
1895
|
+
def get_value(self, key, args, kwargs):
|
|
1896
|
+
if isinstance(key, str):
|
|
1897
|
+
try:
|
|
1898
|
+
return kwargs[key]
|
|
1899
|
+
except KeyError:
|
|
1900
|
+
return "{%s}" % key
|
|
1901
|
+
else:
|
|
1902
|
+
return Formatter.get_value(self, key, args, kwargs)
|
|
1903
|
+
|
|
1904
|
+
|
|
1751
1905
|
def _expandProjectArg(arg, filename_arg, for_eval):
|
|
1752
1906
|
def wrap(value):
|
|
1753
1907
|
if for_eval:
|
|
@@ -1762,6 +1916,7 @@ def _expandProjectArg(arg, filename_arg, for_eval):
|
|
|
1762
1916
|
"Version": getNuitkaVersion(),
|
|
1763
1917
|
"Commercial": wrap(getCommercialVersion()),
|
|
1764
1918
|
"MAIN_DIRECTORY": wrap(os.path.dirname(filename_arg) or "."),
|
|
1919
|
+
"GIL": isPythonWithGil(),
|
|
1765
1920
|
}
|
|
1766
1921
|
|
|
1767
1922
|
if isLinux():
|
|
@@ -1776,7 +1931,14 @@ def _expandProjectArg(arg, filename_arg, for_eval):
|
|
|
1776
1931
|
if isWin32OrPosixWindows():
|
|
1777
1932
|
values["WindowsRelease"] = getWindowsRelease()
|
|
1778
1933
|
|
|
1779
|
-
|
|
1934
|
+
values.update(
|
|
1935
|
+
(
|
|
1936
|
+
(run_time_variable_name, "{%s}" % run_time_variable_name)
|
|
1937
|
+
for run_time_variable_name in run_time_variable_names
|
|
1938
|
+
)
|
|
1939
|
+
)
|
|
1940
|
+
|
|
1941
|
+
arg = _RetainingFormatter().format(arg, **values)
|
|
1780
1942
|
|
|
1781
1943
|
return arg
|
|
1782
1944
|
|
|
@@ -1898,7 +2060,15 @@ def _considerGithubWorkflowOptions(phase):
|
|
|
1898
2060
|
|
|
1899
2061
|
import json
|
|
1900
2062
|
|
|
1901
|
-
early_names =
|
|
2063
|
+
early_names = (
|
|
2064
|
+
"main",
|
|
2065
|
+
"script-name",
|
|
2066
|
+
"enable-plugin",
|
|
2067
|
+
"enable-plugins",
|
|
2068
|
+
"disable-plugin",
|
|
2069
|
+
"disable-plugins",
|
|
2070
|
+
"user-plugin",
|
|
2071
|
+
)
|
|
1902
2072
|
|
|
1903
2073
|
def filterByName(key):
|
|
1904
2074
|
# Not for Nuitka at all.
|
|
@@ -1934,11 +2104,17 @@ def _considerGithubWorkflowOptions(phase):
|
|
|
1934
2104
|
|
|
1935
2105
|
option_name = "--%s" % key
|
|
1936
2106
|
|
|
1937
|
-
if parser.isBooleanOption(
|
|
2107
|
+
if parser.isBooleanOption(option_name):
|
|
1938
2108
|
if value == "false":
|
|
1939
2109
|
continue
|
|
1940
2110
|
|
|
1941
2111
|
options_added.append(option_name)
|
|
2112
|
+
elif parser.isListOption(option_name):
|
|
2113
|
+
for value in value.split("\n"):
|
|
2114
|
+
if not value.strip():
|
|
2115
|
+
continue
|
|
2116
|
+
|
|
2117
|
+
options_added.append("%s=%s" % (option_name, value))
|
|
1942
2118
|
else:
|
|
1943
2119
|
# Boolean disabled options from inactive plugins that default to off.
|
|
1944
2120
|
if value == "false":
|
|
@@ -1947,7 +2123,7 @@ def _considerGithubWorkflowOptions(phase):
|
|
|
1947
2123
|
options_added.append("%s=%s" % (option_name, value))
|
|
1948
2124
|
|
|
1949
2125
|
sys.argv = (
|
|
1950
|
-
sys.argv[: github_option_index + (
|
|
2126
|
+
sys.argv[: github_option_index + (1 if phase == "early" else 0)]
|
|
1951
2127
|
+ options_added
|
|
1952
2128
|
+ sys.argv[github_option_index + 1 :]
|
|
1953
2129
|
)
|
|
@@ -1955,8 +2131,7 @@ def _considerGithubWorkflowOptions(phase):
|
|
|
1955
2131
|
|
|
1956
2132
|
def parseOptions(logger):
|
|
1957
2133
|
# Pretty complex code, having a small options parser and many details as
|
|
1958
|
-
# well as integrating with plugins and run modes
|
|
1959
|
-
# mode executions, pylint: disable=too-many-branches,too-many-statements
|
|
2134
|
+
# well as integrating with plugins and run modes. pylint: disable=too-many-branches
|
|
1960
2135
|
|
|
1961
2136
|
# First, isolate the first non-option arguments.
|
|
1962
2137
|
extra_args = []
|
|
@@ -1983,12 +2158,15 @@ def parseOptions(logger):
|
|
|
1983
2158
|
filename_args = []
|
|
1984
2159
|
module_mode = False
|
|
1985
2160
|
|
|
2161
|
+
# Options may be coming from GitHub workflow configuration as well.
|
|
2162
|
+
_considerGithubWorkflowOptions(phase="early")
|
|
2163
|
+
|
|
1986
2164
|
for count, arg in enumerate(sys.argv):
|
|
1987
2165
|
if count == 0:
|
|
1988
2166
|
continue
|
|
1989
2167
|
|
|
1990
|
-
if arg.startswith("--main="):
|
|
1991
|
-
filename_args.append(arg)
|
|
2168
|
+
if arg.startswith(("--main=", "--script-name=")):
|
|
2169
|
+
filename_args.append(arg.split("=", 1)[1])
|
|
1992
2170
|
|
|
1993
2171
|
if arg == "--module":
|
|
1994
2172
|
module_mode = True
|
|
@@ -2004,9 +2182,6 @@ def parseOptions(logger):
|
|
|
2004
2182
|
+ sys.argv[1:]
|
|
2005
2183
|
)
|
|
2006
2184
|
|
|
2007
|
-
# Options may be coming from GitHub workflow configuration as well.
|
|
2008
|
-
_considerGithubWorkflowOptions(phase="early")
|
|
2009
|
-
|
|
2010
2185
|
# Next, lets activate plugins early, so they can inject more options to the parser.
|
|
2011
2186
|
_considerPluginOptions(logger)
|
|
2012
2187
|
|
|
@@ -2027,6 +2202,19 @@ def parseOptions(logger):
|
|
|
2027
2202
|
Error, need filename argument with python module or main program."""
|
|
2028
2203
|
)
|
|
2029
2204
|
|
|
2205
|
+
if not options.immediate_execution and len(positional_args) > 1:
|
|
2206
|
+
parser.print_help()
|
|
2207
|
+
|
|
2208
|
+
logger.sysexit(
|
|
2209
|
+
"""
|
|
2210
|
+
Error, specify only one positional argument unless "--run" is specified to
|
|
2211
|
+
pass them to the compiled program execution."""
|
|
2212
|
+
)
|
|
2213
|
+
|
|
2214
|
+
return is_nuitka_run, options, positional_args, extra_args
|
|
2215
|
+
|
|
2216
|
+
|
|
2217
|
+
def runSpecialCommandsFromOptions(options):
|
|
2030
2218
|
if options.plugin_list:
|
|
2031
2219
|
from nuitka.plugins.Plugins import listPlugins
|
|
2032
2220
|
|
|
@@ -2066,13 +2254,18 @@ Error, need filename argument with python module or main program."""
|
|
|
2066
2254
|
)
|
|
2067
2255
|
sys.exit(0)
|
|
2068
2256
|
|
|
2069
|
-
if not options.immediate_execution and len(positional_args) > 1:
|
|
2070
|
-
parser.print_help()
|
|
2071
2257
|
|
|
2072
|
-
|
|
2073
|
-
|
|
2074
|
-
|
|
2075
|
-
|
|
2076
|
-
|
|
2077
|
-
|
|
2078
|
-
|
|
2258
|
+
# Part of "Nuitka", an optimizing Python compiler that is compatible and
|
|
2259
|
+
# integrates with CPython, but also works on its own.
|
|
2260
|
+
#
|
|
2261
|
+
# Licensed under the Apache License, Version 2.0 (the "License");
|
|
2262
|
+
# you may not use this file except in compliance with the License.
|
|
2263
|
+
# You may obtain a copy of the License at
|
|
2264
|
+
#
|
|
2265
|
+
# http://www.apache.org/licenses/LICENSE-2.0
|
|
2266
|
+
#
|
|
2267
|
+
# Unless required by applicable law or agreed to in writing, software
|
|
2268
|
+
# distributed under the License is distributed on an "AS IS" BASIS,
|
|
2269
|
+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
2270
|
+
# See the License for the specific language governing permissions and
|
|
2271
|
+
# limitations under the License.
|