Skip to content

Build System written exclusively for C developers from C developers

Notifications You must be signed in to change notification settings

DaStoopidGuy/bob

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

10 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

bob - the build system

Bob is a build system written exclusively, for C projects.
Get the hell out of here c++ (middle finger emoji)

and yes, i do see the irony in using Make (another build system) for my new build system (i better not get any emails about this...😭)

Quickstart

Figuring out lol

in bob.c file:

    #define BOB_STRIP_PREFIXES
    #define BOB_IMPL
    #include "bob.h"

    int main(int argc, char **argv) {
        rebuild_yourself(argc, argv);
        printf("Bob says Hi!\n");
        Cmd cmd = {0};

        cmd_append(&cmd, "gcc", "src/main.c", "-o", "build/main");
        cmd_run(&cmd);

        cmd_destroy(&cmd);
        return 0;
    }

now in your terminal:

    $ gcc bob.c -o bob
    $ ./bob

your target executable is ./build/main:

    $ ./build/main

The bob.c file uses the bob.h header-only library functions to build your C project

So effectively all you'll need to build your C project is just a C compiler

Todo

  • run shell commands
  • strip prefix macro for individual components (like string builder, cmd, etc...)
  • strip prefix macro for all components (for usage in build script .c file bob.c)
  • rebuild itself if the build script is changed
  • functions to check if files/dirs exist
  • function to make dir
  • abstract away the specific compiler, especially in bob_rebuild_yourself()

About

Build System written exclusively for C developers from C developers

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published