{"id":13667265,"url":"https://github.com/kyx0r/tinycc","last_synced_at":"2026-03-05T14:35:31.654Z","repository":{"id":119537332,"uuid":"243372070","full_name":"kyx0r/tinycc","owner":"kyx0r","description":"Single header C99 compiler (TCC)","archived":false,"fork":false,"pushed_at":"2025-04-03T16:35:03.000Z","size":5368,"stargazers_count":30,"open_issues_count":1,"forks_count":2,"subscribers_count":3,"default_branch":"master","last_synced_at":"2025-04-03T17:33:49.043Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"C","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"lgpl-2.1","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/kyx0r.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":"2020-02-26T21:43:21.000Z","updated_at":"2025-04-03T16:35:07.000Z","dependencies_parsed_at":null,"dependency_job_id":"ac2e70ec-6afa-49ad-8ffb-0378d8aa300a","html_url":"https://github.com/kyx0r/tinycc","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/kyx0r%2Ftinycc","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/kyx0r%2Ftinycc/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/kyx0r%2Ftinycc/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/kyx0r%2Ftinycc/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/kyx0r","download_url":"https://codeload.github.com/kyx0r/tinycc/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":251008799,"owners_count":21522180,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","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":[],"created_at":"2024-08-02T07:00:34.133Z","updated_at":"2026-03-05T14:35:31.602Z","avatar_url":"https://github.com/kyx0r.png","language":"C","funding_links":[],"categories":["C"],"sub_categories":[],"readme":"# Tinycc\nSingle header C99 compiler (TCC)\n\nEntire core of TCC compiler in one file. Including all architectures. 52000 LOC\n\nIncluding my modifications and improvements. \n\n# Why?\n\nIt may be painful to deal with complex build systems and files may harm code navigation and/or understanding. \nMany people prefer single header libraries, and this is just that, entire compiler is here. \n\n# Compiling Tcc \n\nThe most simple command will be\n\nFor Unix\n\n```\ngcc tinycc.c -ldl -lpthread\nor bootstrap:\ntcc tinycc.c -ldl -lpthread\n```\n\nFor win32\n\n```\ngcc tinycc.c \nor more explicit, both commands equalent, x86 is default.\ngcc tinycc.c -DTCC_TARGET_PE -DTCC_TARGET_I386\n```\n\nFor win64\n\n```\ngcc tinycc.c -DTCC_TARGET_PE -DTCC_TARGET_X86_64\n```\n\nYou can add compile defines options youself, look into the file and see what is available or what you need.\n\n# Using Tcc\n\n```cpp\n#include \u003cwindows.h\u003e /*or on unix*/ #include \u003cstdlib.h\u003e\n\n//This declaration is required to make printf external.\nint printf(char *format, ...);\n\n//See tinycc.c on how to do argc and argv\nint _start()\n{\n\tMessageBox(NULL, NULL, \"Hello World\", 0); //windows only\n\tprintf(\"Hello World\\n\"); //crt is usable\n\treturn 1;\n}\n```\n\nTo include CRT on windows link library using -luser32 for example. This will link to a dll using user32.def file in ./lib\nFor reference refer to tinycc.c file. \n```\ntcc test.c -luser32\n```\n\n------------------------------------------------------------------------\n# Notes \u0026 TODO\nHave not tested on Arm, riscv64 but it should work unless i screwed up.\n\n- Add intel assembly support (initial parser done)\n- Add vector instructions support. \n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fkyx0r%2Ftinycc","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fkyx0r%2Ftinycc","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fkyx0r%2Ftinycc/lists"}