PyProd is a Python script that can be used as an alternative to Makefile. By leveraging Python’s versatility, it enables you to define build rules and dependencies programmatically, allowing for dynamic configurations, integration with existing Python libraries, and custom build logic not easily achievable with traditional Makefiles. For detailed documentation, please refer to the official documentation.
Features
Define build rules in Python: Use Python functions to create clear and concise build logic.
Specify dependencies for each rule: Automatically track and resolve dependencies between files, such as source files and headers.
Easily extendable with custom Python functions: Integrate custom logic for specialized tasks, like code linting or deployment.
Manages virtual environments: Automatically create and manage virtual environments for each project, ensuring a clean and isolated build environment.
Installation
To install PyProd, simply use pip:
pip install pyprod
Usage
With PyProd, a traditional Makefile for C can be expressed as a Python script like this:
CC = "gcc"
CFLAGS = "-c -I."
DEPS = "hello.h"
OBJS = "hello.o main.o".split()
EXE = "hello.exe"
@rule("%.o", depends=("%.c", DEPS))
def compile(target, src, *deps):
run(CC, "-o", target, src, CFLAGS)
@rule(EXE, depends=OBJS)
def link(target, *objs):
run(CC, "-o", target, objs)
@task
def clean():
run("rm -f", OBJS, "hello.exe")
@task
def rebuild():
build(clean, EXE)
To run the build script, simply execute:
$ cd project
$ pyprod
Other examples can be found in the samples directory.
License
PyProd is licensed under the MIT License. See the LICENSE file for more details.
Metadata
Release files for PyProd 0.10.2
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| pyprod-0.10.2.tar.gz | 384.8 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| pyprod-0.10.2-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 396.2 kB
Release files / pyprod-0.10.2.tar.gz
| Download URL | pyprod-0.10.2.tar.gz |
|---|---|
| Size | 384.8 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
383e41132e2ce625e4c696a27fce6ab9e1c69fd1f7d953ff7f01afed7032396c
|
|
BLAKE2b-256 checksum How to use checksums |
8ea16581cea12694cc0725ba0b13f2f7dd57300fb2322edc2567f51e8b3b8dab
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/6.1.0 CPython/3.12.9
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Jun 16, 2025.
Transparency logRelease files / pyprod-0.10.2-py3-none-any.whl
| Download URL | pyprod-0.10.2-py3-none-any.whl |
|---|---|
| Size | 11.4 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
25a700b9ffc8c59429c4ff0130b96eb671d56d92712d1f191bd7668d26378226
|
|
BLAKE2b-256 checksum How to use checksums |
d8d2e7e79e2dd2c4067ca6d2d6b285d386408b3dfe2126f0ae8862be3acdf510
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/6.1.0 CPython/3.12.9
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Jun 16, 2025.
Transparency log