changeset 675: | 176715089769 |
parent: | b499d4bcfc39 |
author: | Richard Westhaver <ellis@rwest.io> |
date: | Tue, 24 Sep 2024 16:47:38 -0400 |
permissions: | -rwxr-xr-x |
description: | ensure graphviz-dot-mode |
287
609931bd65ba
organ updates, readme.org
Richard Westhaver <ellis@rwest.io>
parents:
187
diff
changeset
|
1 | #+title: core |
609931bd65ba
organ updates, readme.org
Richard Westhaver <ellis@rwest.io>
parents:
187
diff
changeset
|
2 | #+description: The Compiler Company Core |
406 | 3 | #+author: Richard Westhaver |
4 | #+email: richard.westhaver@gmail.com |
|
444 | 5 | #+setupfile: https://cdn.compiler.company/org/clean.theme |
604
74a55d5decce
emacs org libraries and upgrades
Richard Westhaver <ellis@rwest.io>
parents:
585
diff
changeset
|
6 | #+property: header-args :eval no-export |
637
b88bf15f60d0
parquet tweaks, import ox-man
Richard Westhaver <ellis@rwest.io>
parents:
604
diff
changeset
|
7 | - [[https://compiler.company/docs/core][Documentation]] |
473 | 8 | |
604
74a55d5decce
emacs org libraries and upgrades
Richard Westhaver <ellis@rwest.io>
parents:
585
diff
changeset
|
9 | This repository contains the monolothic core of [[comp:][The Compiler Company]]. |
444 | 10 | |
643
f901de70a80e
opt fixes and test updates
Richard Westhaver <ellis@rwest.io>
parents:
637
diff
changeset
|
11 | * Overview |
f901de70a80e
opt fixes and test updates
Richard Westhaver <ellis@rwest.io>
parents:
637
diff
changeset
|
12 | The CC core is categorized into language-specific modules. Our |
f901de70a80e
opt fixes and test updates
Richard Westhaver <ellis@rwest.io>
parents:
637
diff
changeset
|
13 | languages at time of writing are Common Lisp, Rust, and Emacs Lisp. |
f901de70a80e
opt fixes and test updates
Richard Westhaver <ellis@rwest.io>
parents:
637
diff
changeset
|
14 | |
f901de70a80e
opt fixes and test updates
Richard Westhaver <ellis@rwest.io>
parents:
637
diff
changeset
|
15 | The top-level modules are contained in the directories =lisp=, =rust=, |
f901de70a80e
opt fixes and test updates
Richard Westhaver <ellis@rwest.io>
parents:
637
diff
changeset
|
16 | and =emacs= respectively. At the root directory you will also find a |
f901de70a80e
opt fixes and test updates
Richard Westhaver <ellis@rwest.io>
parents:
637
diff
changeset
|
17 | =skelfile= and a =sk= file for each module. These files contain |
f901de70a80e
opt fixes and test updates
Richard Westhaver <ellis@rwest.io>
parents:
637
diff
changeset
|
18 | project definitions which are used by our =skel= program to perform a |
f901de70a80e
opt fixes and test updates
Richard Westhaver <ellis@rwest.io>
parents:
637
diff
changeset
|
19 | variety of actions on the core such as running tests and building |
f901de70a80e
opt fixes and test updates
Richard Westhaver <ellis@rwest.io>
parents:
637
diff
changeset
|
20 | binaries. |
f901de70a80e
opt fixes and test updates
Richard Westhaver <ellis@rwest.io>
parents:
637
diff
changeset
|
21 | |
f901de70a80e
opt fixes and test updates
Richard Westhaver <ellis@rwest.io>
parents:
637
diff
changeset
|
22 | * Bootstrap |
444 | 23 | To bootstrap the core you will need recent versions of [[https://www.rust-lang.org/][Rust]], [[http://www.sbcl.org/][SBCL]], and |
24 | a C compiler (clang or gcc). Only Unix systems are explicitly |
|
25 | supported. |
|
26 | ||
27 | Many parts of the core depend on additional libraries which may or may |
|
28 | not be provided by your system's package manager. See the dependency |
|
29 | matrix below for details. |
|
30 | ||
31 | In any case, it is always preferred to make use of the [[https://vc.compiler.company/comp/infra][infra]] project |
|
32 | to reliably provision the host either from source or pre-built |
|
33 | platform-specific [[https://packy.compiler.company/dist][binary distributions]]. |
|
22 | 34 | |
637
b88bf15f60d0
parquet tweaks, import ox-man
Richard Westhaver <ellis@rwest.io>
parents:
604
diff
changeset
|
35 | #+NAME: Dependencies |
b88bf15f60d0
parquet tweaks, import ox-man
Richard Westhaver <ellis@rwest.io>
parents:
604
diff
changeset
|
36 | | dependency | required by | src | |
604
74a55d5decce
emacs org libraries and upgrades
Richard Westhaver <ellis@rwest.io>
parents:
585
diff
changeset
|
37 | |-------------+------------------------+-----------------------------------------------| |
74a55d5decce
emacs org libraries and upgrades
Richard Westhaver <ellis@rwest.io>
parents:
585
diff
changeset
|
38 | | Blake3 | ffi/blake3 | https://vc.compiler.company/packy/blake3 | |
74a55d5decce
emacs org libraries and upgrades
Richard Westhaver <ellis@rwest.io>
parents:
585
diff
changeset
|
39 | | Tree-sitter | ffi/tree-sitter | https://vc.compiler.company/packy/tree-sitter | |
74a55d5decce
emacs org libraries and upgrades
Richard Westhaver <ellis@rwest.io>
parents:
585
diff
changeset
|
40 | | Uring | ffi/uring | https://vc.compiler.company/packy/uring | |
74a55d5decce
emacs org libraries and upgrades
Richard Westhaver <ellis@rwest.io>
parents:
585
diff
changeset
|
41 | | Btrfs | ffi/btrfs | https://vc.compiler.company/packy/btrfs | |
74a55d5decce
emacs org libraries and upgrades
Richard Westhaver <ellis@rwest.io>
parents:
585
diff
changeset
|
42 | | Ublksrv | ffi/ublk | https://vc.compiler.company/packy/ublksrv | |
74a55d5decce
emacs org libraries and upgrades
Richard Westhaver <ellis@rwest.io>
parents:
585
diff
changeset
|
43 | | OpenSSL | lib/net | [[https://vc.compiler.company/packy/openssl]] | |
74a55d5decce
emacs org libraries and upgrades
Richard Westhaver <ellis@rwest.io>
parents:
585
diff
changeset
|
44 | | RocksDB | ffi/rocksdb | https://vc.compiler.company/packy/rocksdb | |
74a55d5decce
emacs org libraries and upgrades
Richard Westhaver <ellis@rwest.io>
parents:
585
diff
changeset
|
45 | | Git | lib/vc/git | https://vc.compiler.company/packy/git | |
74a55d5decce
emacs org libraries and upgrades
Richard Westhaver <ellis@rwest.io>
parents:
585
diff
changeset
|
46 | | Hg | lib/vc/hg | https://vc.compiler.company/packy/hg | |
74a55d5decce
emacs org libraries and upgrades
Richard Westhaver <ellis@rwest.io>
parents:
585
diff
changeset
|
47 | | Zstd | ffi/zstd | https://vc.compiler.company/packy/zstd | |
74a55d5decce
emacs org libraries and upgrades
Richard Westhaver <ellis@rwest.io>
parents:
585
diff
changeset
|
48 | | Qemu | lib/box | https://vc.compiler.company/packy/qemu | |
74a55d5decce
emacs org libraries and upgrades
Richard Westhaver <ellis@rwest.io>
parents:
585
diff
changeset
|
49 | | Podman | lib/pod | https://vc.compiler.company/packy/podman | |
74a55d5decce
emacs org libraries and upgrades
Richard Westhaver <ellis@rwest.io>
parents:
585
diff
changeset
|
50 | | Emacs | emacs | https://vc.compiler.company/packy/emacs | |
74a55d5decce
emacs org libraries and upgrades
Richard Westhaver <ellis@rwest.io>
parents:
585
diff
changeset
|
51 | | StumpWM | lib/gui/wm/x11/stumpwm | https://vc.compiler.company/packy/stumpwm | |
74a55d5decce
emacs org libraries and upgrades
Richard Westhaver <ellis@rwest.io>
parents:
585
diff
changeset
|
52 | | Readline | ffi/readline | [[https://vc.compiler.company/packy/readline]] | |
74a55d5decce
emacs org libraries and upgrades
Richard Westhaver <ellis@rwest.io>
parents:
585
diff
changeset
|
53 | | Keyutils | ffi/keyutils | [[https://vc.compiler.company/packy/libkeyutils]] | |
74a55d5decce
emacs org libraries and upgrades
Richard Westhaver <ellis@rwest.io>
parents:
585
diff
changeset
|
54 | | Mpd | lib/aud/mpd | https://vc.compiler.company/packy/mpd | |
287
609931bd65ba
organ updates, readme.org
Richard Westhaver <ellis@rwest.io>
parents:
187
diff
changeset
|
55 | |
473 | 56 | * Build |
472 | 57 | The Core consists of two major system: the *lisp* system and the |
58 | *rust* system. There is also an auxiliary *emacs* system containing a |
|
59 | complete Emacs IDE configuration which serves as the base for user |
|
60 | customizations. |
|
61 | ||
473 | 62 | Building the core will produce its output to the =.stash= directory by |
63 | default. You can then test, run, and install the resulting files or |
|
64 | package them up to be shipped elsewhere. |
|
444 | 65 | ** From Source |
472 | 66 | *** Lisp |
67 | The Lisp Core can be found under the =lisp= directory. It is the |
|
68 | largest system, most actively developed, and is intended to cover the |
|
69 | complete surface of the user-facing APIs contained in the core. |
|
70 | ||
656 | 71 | The core is self-hosted in the sense that it is intended to be built |
72 | from one of its own programs - the =skel= project compiler. You may |
|
73 | also load any part of the core individually as long as you have [[https://www.sbcl.org/][SBCL]] |
|
74 | and [[https://www.quicklisp.org/beta/][Quicklisp]] installed. |
|
75 | *** Rust |
|
76 | Today, the Rust components of the core are quite small and |
|
77 | isolated. We like Rust right now for the reasonable memory safety |
|
78 | guarantees, as an interface to (W)GPU, WASM, LLVM, etc, and because it |
|
79 | has an industry-sponsored ecosystem (guaranteed future). |
|
472 | 80 | |
656 | 81 | Our Rust code is far less concerned with being completely from |
82 | scratch - dependencies are imported freely and at will - adapting to |
|
83 | whatever FOTM is hot right now. |
|
472 | 84 | |
85 | A workspace is configured such that you can build all components with |
|
86 | the following command (~NOTE~ - takes a long time): |
|
444 | 87 | #+begin_src shell :exports both :results output |
656 | 88 | cd rust && cargo build |
444 | 89 | #+end_src |
90 | ||
472 | 91 | *** Emacs |
92 | The core contains a collection of Emacs Lisp libraries under =emacs= |
|
93 | which may be installed for the current user using the corresponding |
|
94 | Makefile. |