python静态代码编译工具nuitka

nuitka

# test.py
def add(x: int, y: int) -> int:
    return x + y


print(add(2, 3))
nuitka test.py --onefile --clang --static-libpython=yes
# justfile
build:
    #!/bin/env bash
    # export LDFLAGS="-static"
    nuitka test.py --onefile --clang --static-libpython=yes
posted @ 2024-10-27 10:57  卓能文  阅读(9)  评论(0编辑  收藏  举报