o
odin.langpkg.dev
packages / library / odin-toys

odin-toys

c985edclibrary

Small experiments with Odin

No license · updated 6 months ago

Odin toys

Little experiments with the Odin programming language.

Examples

  • Pongs
  • Node interface
  • cat command
  • UI Toolbar with rect cut
  • Calling a C library (imagemagick)

Running

To compile and run examples you will need to have Odin installed and on your path.

After you git clone this repo, change to an specific example directory and run make.

cd <example>
make

This will build the <example> executable in the /bin/ directory. On Linux, this can then be run with ./bin/<example>.

Note that the makefile invokes odin with a -o:speed flag to optimise for performance:

odin build . -o:speed -out:bin/<example>

If you want to develop with the code just run:

odin run . -out:bin/<example>

This will compile faster and also run the executable.