Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Create a driver for the compiler framework #54

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

GlowingScrewdriver
Copy link
Contributor

The pressing need of the hour is a single command that can be used to compile code, instead of a messy command line with multiple commands and pipes. For the time being, llama.lisp.sh serves that purpose. Below is the built-in help message, just to give the reader an idea of what this is:

$ ./llama.lisp.sh -h
C-Lisp compiler driver

Usage: ./llama.lisp.sh -i <input filename> [ -s <stage> ] [ -c <clang options> ] [ -h ]
Options:
  -i: Specify the source file
  -s: Specify the stage to run
      supported stages: clisp, brilisp, llvm
  -c: Supply arguments to clang (note that you will have to quote
      them if there are multiple arguments)
      Defaults to: '<script directory>/tests/brilisp/runtime.c -Wno-override-module -O2'
  -h: Display this message

Each "stage" above is one compilation step: clisp is C-Lisp to Brilisp, brilisp is Brilisp to LLVM, and llvm is from LLVM to the executable. Running without an -s argument will run all stages from C-Lisp to executable.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant