Skip to content

Commit

Permalink
Merge pull request #26 from pallene-lang/spice-up-readme
Browse files Browse the repository at this point in the history
Spice up the README
  • Loading branch information
singul4ri7y authored Aug 22, 2024
2 parents 9aa8606 + d91dad6 commit 7eb64c8
Showing 1 changed file with 45 additions and 2 deletions.
47 changes: 45 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,2 +1,45 @@
# pallene-tracer
Pallene Tracer is a mechanism and protocol for Lua C modules to have proper tracebacks
<h1 align="center">The Pallene Tracer</h1>

Pallene Tracer allows Lua libraries written in C to have proper function tracebacks, without changing a single code in Lua!

Pallene Tracer was created to address the need for function tracebacks in [Pallene](https://github.com/pallene-lang/pallene), an Ahead-of-Time compiled sister language to Lua. Pallene is intermediately compiled to C, hence protocols and mechanism used can be ported to broader Lua C libraries.

> **Note:** Pallene Tracer is independent of Pallene but not vice versa.
## Installing Pallene Tracer

### Prerequisites

You need to have **_atleast Lua 5.4_** installed in your system at any location.

### Building

To build against `/usr` Lua prefix (system Lua), just simply run:
```
make
```

To build against local Lua with `/usr/local` prefix (or any prefix):
```
make LUA_PREFIX=/usr/local
```

> **Note:** Default `LUA_PREFIX` is `/usr`.
Pallene Tracer sometime fails to build if Lua is built with address sanitizer (ASan) enabled. To get around the issue use:
```
make LDFLAGS=-lasan LUA_PREFIX=<preferred_prefix>
```

### Installing

To install Pallene Tracer to `/usr/local`, simply run:
```
sudo make install
```

Pallene Tracer supplies a custom Lua frontend `pt-lua` and `ptracer.h` header (including source).

### How to use Pallene Tracer

The developers manual on how Pallene Tracer works and used can be found in [docs](https://github.com/pallene-lang/pallene-tracer/blob/main/docs/MANUAL.md). Also feel free to look at the `examples` directory for further intuition.

0 comments on commit 7eb64c8

Please sign in to comment.