Code Monkey home page Code Monkey logo

jank's Introduction

The jank programming language Build codecov Sponsor

jank is a general-purpose programming language which embraces the interactive, functional, value-oriented nature of Clojure, the desire for native compilation and minimal runtimes of C++, and the gradual, structural typing of languages like TypeScript. jank aims to be strongly compatible with Clojure. While Clojure's default host is the JVM and its interop is with Java, jank's host is LLVM and its interop is with C++ or LLVM IR.

https://jank-lang.org

For the current progress of jank and its usability, see the tables here: https://jank-lang.org/progress/

The current tl;dr for jank's usability is: not usable for anything useful.

Building locally

Dependencies

For Debian-based distros, this should be all you need:

$ sudo apt-get install -y curl git zip build-essential entr libssl-dev libdouble-conversion-dev pkg-config ninja-build python3-pip cmake debhelper devscripts gnupg zlib1g-dev clang-14

For macOS, try this:

$ brew install curl git zip entr openssl double-conversion pkg-config ninja python cmake gnupg zlib llvm@14

Clone the repo as follows:

$ git clone --recurse-submodules https://github.com/jank-lang/jank.git

# If you don't recurse submodules when cloning, you'll need to run this.
$ git submodule update --recursive --init

Compiling

  • ./bin/configure -- For setting up the project.
  • ./bin/compile -- For one-off compilation.
  • ./bin/test -- For one-off testing.
  • ./bin/watch-tests -- For hot reloading tests on save.
  • ./bin/install -- For packaging.

Cling

Note that, by default, jank will compile Cling/Clang/LLVM for you, as part of your build directory. This can take an hour or two, depending on your machine. Building jank itself should take less than a minute. If you want to build it yourself, or want it outside of jank's build dir, you can use the bin/build-cling [cling-dir] script.

If you build your own Cling, or if you get it from somewhere else, you can provide it to ./bin/configure by using -Dcling_dir=[cling-dir]/builddir.

Release

A typical release build just needs the following:

$ ./bin/configure -GNinja -DCMAKE_BUILD_TYPE=Release
$ ./bin/compile

Debug

To make a debug build, specify the build type when configuring.

$ ./bin/configure -GNinja -DCMAKE_BUILD_TYPE=Debug -Djank_tests=on
$ ./bin/compile
$ ./bin/watch-tests

Packaging

There's also a script for installing jank and all its necessary dependencies. Note that this includes a lot of header files, which are necessary for jank's JIT compilation.

$ ./bin/configure -GNinja -DCMAKE_BUILD_TYPE=Release
$ ./bin/install

Sponsors

If you'd like your name, company, or logo here, you can sponsor this project. Sponsor

In the news

The REPL Interview devmio Interview Compiler Spotlight

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.