Skip to content

What is you License and how open are you to working with others? #1

Description

@frog-o

I am relay confuse what you are trying to do here.

What license is ZBuild going to use?

How open are you to new idea?

Zig has it own build system which I am obviously aware of since you are trying to work with it(so am I) and I do agree it need enhancements and I did read your todo list. It was relay short. I am trying to learn zig right now and currently trying to port cowasm to a new build system wich I am tring to create it is BSD 3-Clause License. Here my Goals

  • Improved config handling of multiple config type
  • Add function similar to other build tools
  • Optionally use existing config package.json pyscript.toml etc.
  • Short learning curve
  • Easily expand ( the config should allow to import other config)
  • No dependency by default
  • Runs in browser
  • have built in python engine( py-script or cowasm-python) when in browser when on server use python
  • have build in javascript engine (do not now if possible)

Build a new build system is a relay complex thing to do and I think the more though I get on it the better it would be nice to work with someone else with similar goal and share code when possible. I want to create a library called coQuery for complicate common build task that you can import into build.zig file. I wanted it to do more then that but that what I wanted to start with.

I think our goal differ thou from mine. You do not seem to mind the ugly looking zon(At least to me) style.

I think most Build system config syn-text is just ugly hard to understand with high learning curve my goal is to change that. I want to use as much as existing ideas as i can and follow kiss(keep it simple stupid) principle. I do not have thing figured out yet what I am going to do but I have a huge interest in using .toml for handling things. I been spending a lot of time chat on perplexity ai. Here an example that perplexity gave me which I modified a bit to show you what I am think things should look like.


[ project ]
name = "coBuild"
version = "0.0.0"
[project.import}



# load more config from  env/my/env.toml and put it in the env section 
"env" = "./env/my/env.toml" 

[script]
"build" = "/my/project.py"
# =============================================================================
# Environment Variables for Building Cowasm Packages
# =============================================================================

[env]
# The directory containing the package where the makefile is run, e.g., core/bzip2
CWD = "."

# The directory containing all of the packages.
PACKAGES = "${CWD}/.."

# Where the upstream sources are cached
UPSTREAM = "${CWD}/../../upstream/sources"

# Binaries useful for building, e.g., node, zig, cowasm
BIN = "${CWD}/../../bin"

# Where sources, e.g., patches, customizations, new code, etc., are stored for this build.
SRC = "${CWD}/src"

# Temporary path where we do the build. These files can always be deleted without impacting
# the artifact in dist.
BUILD = "${CWD}/build"
BUILD_NATIVE = "${BUILD}/native"
BUILD_WASM = "${BUILD}/wasm"

# Where we put the result of the build, e.g., --prefix=${DIST_WASM}
DIST = "${CWD}/dist"
DIST_NATIVE = "${DIST}/native"
DIST_WASM = "${DIST}/wasm"

# Include the BIN directory at front of path.
# See https://stackoverflow.com/questions/8941110/how-i-could-add-dir-to-path-in-makefile
PATH = "${BIN}:${PATH}"

# Use a custom shell with the modified PATH
SHELL = "env PATH='${PATH}' /bin/bash"

# System info (to be set at runtime by the build script)
UNAME_S = "" # e.g., Linux, Darwin, etc.
UNAME_M = "" # e.g., x86_64, arm64, etc.

# Compiler flags (to be set below or at runtime)
ZIG_NATIVE_CFLAGS = ""
ZIG_NATIVE_CFLAGS_GNU = ""

# =============================================================================
# OS-Specific Compiler Flags (to be merged into env by build script)
# =============================================================================

[env.compiler_flags.linux]
# On Linux we explicitly always build for musl
# See https://github.com/ziglang/zig/issues/12797
ZIG_NATIVE_CFLAGS = "--target=${UNAME_M}-linux-musl"
ZIG_NATIVE_CFLAGS_GNU = "--target=${UNAME_M}-linux-gnu.2.31"

[env.compiler_flags.other]
ZIG_NATIVE_CFLAGS = ""
ZIG_NATIVE_CFLAGS_GNU = ""

# =============================================================================
# (Optional) You can add more OS-specific sections, e.g.:
# [env.compiler_flags.windows]
# ZIG_NATIVE_CFLAGS = "--target=${UNAME_M}-windows-gnu"
# ZIG_NATIVE_CFLAGS_GNU = ""
# =============================================================================

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions