{"id":17818696,"url":"https://github.com/eudisd/c-compiler","last_synced_at":"2025-11-09T14:04:43.836Z","repository":{"id":1538018,"uuid":"1839972","full_name":"eudisd/c-compiler","owner":"eudisd","description":"A C Compiler.  Executables runs on a stack based VM.","archived":false,"fork":false,"pushed_at":"2014-01-14T04:09:12.000Z","size":1889,"stargazers_count":77,"open_issues_count":1,"forks_count":22,"subscribers_count":8,"default_branch":"develop","last_synced_at":"2025-02-28T07:36:12.837Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","language":"C","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"gpl-3.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/eudisd.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}},"created_at":"2011-06-02T23:34:44.000Z","updated_at":"2024-12-30T08:09:00.000Z","dependencies_parsed_at":"2022-07-24T22:16:34.502Z","dependency_job_id":null,"html_url":"https://github.com/eudisd/c-compiler","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/eudisd%2Fc-compiler","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/eudisd%2Fc-compiler/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/eudisd%2Fc-compiler/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/eudisd%2Fc-compiler/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/eudisd","download_url":"https://codeload.github.com/eudisd/c-compiler/tar.gz/refs/heads/develop","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":243905992,"owners_count":20366952,"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-10-27T16:55:09.630Z","updated_at":"2025-11-09T14:04:38.779Z","avatar_url":"https://github.com/eudisd.png","language":"C","funding_links":[],"categories":["C"],"sub_categories":[],"readme":"C Compiler\n==========\nBy Eudis Duran\n--------------\n\n## Compiling\n\n### Linux:\n\nYou can build the source with a single command.\nMake sure you are in the root src directory, and \ntype: \"make all\"  This will build both the compiler\nand virtual machine.  The resulting executables will\nbe placed in the root binary folder for the project.\nThe programs are named \"c\" for the compiler, and \"cvm\" for \nthe virtual machine.\n\n### Example Programs/Tests\nOnce you have built the compiler and virtual machine, both\nexecutables are also copied to the bin folder under 'examples.'\nThe example programs can be built in a similar fasion.\nChange directory to examples/ and execute a \"make\"\ncall.  That will build all the examples for execution.\nIn this case however, the Makefile will use my C compiler\nto build the examples, and will produce VM executables \nin the bin folder under the examples folders.\n\n### Windows:\nNot tested.  \n\n\n## Usage:\nTo compile a source file, first make sure that it adheres\nto the small C subset that is specified in the Documentation\nfile, as not all of C is implemented yet.\n\nOnce you have checked that off, locate the compiler and VM\nexecutable in the bin directory and change to that directory\nthrough the command line.  Assuming you have a test\nfile, say test.c, you could type in the following to compile\nthe file:\n\n```bash\n$ ./c test.c -o test.vm\n```\n\nThat would compile the c source and produce a virtual machine\nbytecode executable.  To run that exectuable, type in the\nfollowing:\n\n```bash\n$ ./cvm test.vm\n```\n\nThat would execute the program.\n\nYou can display a help screen by typing in --help in either of the\nprogram's command line arguments, like so:\n\n```bash\n$ ./c --help\n```\n\nor\n\n```bash\n$ ./cvm --help\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Feudisd%2Fc-compiler","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Feudisd%2Fc-compiler","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Feudisd%2Fc-compiler/lists"}