{"id":24164612,"url":"https://github.com/wtrsltnk/cppbuild","last_synced_at":"2026-02-19T11:02:01.955Z","repository":{"id":77223092,"uuid":"112791837","full_name":"wtrsltnk/cppbuild","owner":"wtrsltnk","description":"An alternative build system where you write your build script in c++. Something like this could be in the c++ standard for simple programs.","archived":false,"fork":false,"pushed_at":"2024-08-05T22:35:04.000Z","size":22,"stargazers_count":2,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-10-21T14:49:52.381Z","etag":null,"topics":["build-system","cpp"],"latest_commit_sha":null,"homepage":null,"language":"C++","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/wtrsltnk.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2017-12-01T22:11:18.000Z","updated_at":"2024-08-05T22:35:07.000Z","dependencies_parsed_at":null,"dependency_job_id":"c715cada-c091-4873-bdab-ac990454b6bc","html_url":"https://github.com/wtrsltnk/cppbuild","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/wtrsltnk/cppbuild","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/wtrsltnk%2Fcppbuild","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/wtrsltnk%2Fcppbuild/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/wtrsltnk%2Fcppbuild/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/wtrsltnk%2Fcppbuild/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/wtrsltnk","download_url":"https://codeload.github.com/wtrsltnk/cppbuild/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/wtrsltnk%2Fcppbuild/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":29611002,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-02-19T10:52:55.328Z","status":"ssl_error","status_checked_at":"2026-02-19T10:52:26.323Z","response_time":117,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.6:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["build-system","cpp"],"created_at":"2025-01-12T19:18:02.550Z","updated_at":"2026-02-19T11:02:01.918Z","avatar_url":"https://github.com/wtrsltnk.png","language":"C++","readme":"# CppBuild\n\nAn alternative build system where you write your build script in c++. Something like this could be in the c++ standard for simple programs.\n\nYou can use this file on Windows with the MinGW compiler. Put the files ``cppbuild.cmd`` and ``cppbuild.hpp`` in any folder from your PATH. Then create your build file with the name ``__build__.cpp`` and add the following code to this file:\n\n```c++\n\n#include \u003ccppbuild.hpp\u003e\n\nint main(int argc, char* argv[])\n{\n    cppbuild::init(argc, argv);\n\n    cppbuild::Target target(\"program\");\n\n    target.files({\n                \"program.cpp\",\n                \"library.cpp\",\n            });\n\n    target.includeDirs({\n        \"include\",\n    });\n\n    return 0;\n}\n\n```\n\nThis will create one target with the name ``program`` that will compile and link the files ``program.cpp`` and ``library.cpp`` into ``program.exe``. It will add the ``include`` directory as -I parameter to the compiler.\n\nThe following methods can be used on the cppbuild::Target class:\n\n* ``files`` - Adds files to compile\n* ``includeDirs`` - Adds directories with the ``-I`` parameter\n* ``libraries`` - Adds libraries with the ``-l`` parameter\n* ``libraryDirs`` - Adds directories with the ``-L`` parameter\n* ``compilerFlags`` - Adds compiler flags\n* ``linkerFlags`` - Adds linker flags\n* ``installDir`` - Adds directory to install build artifacts into\n* ``installFiles`` - Adds files to install\n\n## Cppbuild command and its parameters\n\nTo build your program open a commandline window at the folder containing the ``__build__.cpp`` and type ``cppbuild``.\n\nThe following parameters can be passed to the ``cppbuild`` command:\n\n* ``clean`` - Cleans all build files\n* ``build`` - Builds all project targets\n* ``test`` - Runs all project tests\n* ``run`` - Runs project target\n* ``install`` - Installs the project\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fwtrsltnk%2Fcppbuild","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fwtrsltnk%2Fcppbuild","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fwtrsltnk%2Fcppbuild/lists"}