changeset 661: |
39170f311b8c |
parent: |
b499d4bcfc39
|
child: |
a53be64410c5 |
author: |
Richard Westhaver <ellis@rwest.io> |
date: |
Sat, 21 Sep 2024 00:04:33 -0400 |
permissions: |
-rwxr-xr-x |
description: |
add sk-def and sk-bind |
1 ;;; skelfile --- CC/core skelfile -*- mode: skel; -*- 3 :author ("Richard Westhaver" . "ellis@rwest.io") 8 :description "The Compiler Company Core" 9 :tags ("core" "lisp" "rust" "emacs" "c") 10 :include ("lisp.sk" "rust.sk" "emacs.sk") 11 :vc (:hg "https://vc.compiler.company/core") 15 :components ((:dir-locals ".dir-locals") 19 psl.dat parquet.json rgb.txt 20 save-std save-prelude save-user 21 save-infra save-core save-tests 22 build-tree-sitter-alien build-core fasls 23 ;; build-skel build-organ build-homer build-packy build-rdb 28 #$find emacs -name '*.elc' -type f -delete$# 29 #$find lisp -name '*.fasl' -type f -delete$# 30 #$echo 'cargo clean:' && cd rust && cargo clean$#) 32 (:build () #$cd lisp/ffi/tree-sitter && 33 clang -g -O2 -Wall -Wno-unused-value -ltree-sitter -shared \
34 alien.c -o ../../../.stash/libtree-sitter-alien.so$#) 35 (:install () #$cp .stash/libtree-sitter-alien.so /usr/local/lib/$#)) 37 (download "https://publicsuffix.org/list/public_suffix_list.dat" 38 :output (merge-pathnames 42 (download "https://packy.compiler.company/data/rgb.txt" 43 :output (merge-pathnames 47 (color::parse-x11-color-definitions 48 :input ".stash/rgb.txt" 49 :output (merge-pathnames "color/x11.lisp" *skel-path*))) 50 (parquet.thrift (%stash) 52 "https://raw.githubusercontent.com/apache/parquet-format/master/src/main/thrift/parquet.thrift" 53 :output (merge-pathnames ".stash/parquet.thrift" *skel-path*)) 54 #$thrift --gen json -out .stash .stash/parquet.thrift$#) 55 (parquet.json (%stash) 56 (download "https://packy.compiler.company/data/parquet.json" 57 :output (merge-pathnames ".stash/parquet.json" *skel-path*))) 58 (freedesktop.org.xml (%stash) 59 (download "https://packy.compiler.company/data/freedesktop.org.xml" 60 :output (merge-pathnames ".stash/freedesktop.org.xml" *skel-path*))) 61 (parquet-test-data (%stash) (download "https://packy.compiler.company/data/test/alltypes_plain.parquet" 62 :output (merge-pathnames ".stash/alltypes_plain.parquet" *skel-path*))) 64 (%stash () #$mkdir -pv .stash$#) 67 (with-sbcl (:noinform t :quit t) 68 (ql:quickload :bin/rdb) 70 #$mv lisp/bin/rdb .stash/rdb$#) 71 (:install () #$install -C -m 755 .stash/rdb /usr/local/bin/rdb$#)) 74 (with-sbcl (:noinform t :quit t) 75 (ql:quickload :bin/skel) 76 (asdf:make :bin/skel)) 77 #$mv lisp/bin/skel .stash/skel$#) 79 (with-sbcl (:noinform t :quit t) 80 (push :tools *features*) 81 (ql:quickload :bin/skel) 82 (asdf:make :bin/skel)) 83 #$mv lisp/bin/skel .stash/skel$#) 84 (:install () #$install -C -m 755 .stash/skel /usr/local/bin/skel$#)) 86 (:build () (with-sbcl (:noinform t :quit t) 87 (ql:quickload :bin/organ) 88 (asdf:make :bin/organ)) 89 #$mv lisp/bin/organ .stash/organ$#)) 91 (:build () (with-sbcl (:noinform t :quit t) 92 (ql:quickload :bin/homer) 93 (asdf:make :bin/homer)) 94 #$mv lisp/bin/homer .stash/homer$#)) 96 (:build () (with-sbcl (:noinform t :quit t) 97 (ql:quickload :bin/packy) 98 (asdf:make :bin/packy)) 99 #$mv lisp/bin/packy .stash/packy$#)) 100 (std () (:save () (with-sbcl (:noinform t :quit t) 102 (in-package :std-user) 103 (compile-lisp :std :save ".stash/std.core")))) 105 (:save () (with-sbcl (:noinform t :quit t) 106 (ql:quickload :prelude) 107 (in-package :std-user) 108 (compile-lisp :prelude :save ".stash/prelude.core"))) 109 (:compile () (compile-lisp :prelude :force t :verbose t))) 111 (:save () (with-sbcl (:noinform t :quit t) 114 (compile-lisp :user :save ".stash/user.core"))) 115 (:compile () (compile-lisp :user :force t :verbose t))) 116 (infra () (:save () (with-sbcl (:noinform t :quit t) 119 (compile-lisp :user :save ".stash/infra.core" :compression 22)))) 121 (:build () (with-sbcl (:noinform t :quit t) 122 (ql:quickload :bin/core) 123 (asdf:make :bin/core)) 124 #$mv lisp/bin/core .stash/core$#) 125 (:save () (with-sbcl (:noinform t :quit t) 126 (ql:quickload (list :std :core)) 127 (in-package :std-user) 128 (compile-lisp :core :save ".stash/core.core"))) 129 (:compile () (compile-lisp :core :force t :verbose t)) 130 (:install () #$install -C -m 755 .stash/core /usr/local/bin/core 131 echo "core -> /usr/local/bin/" 132 links="skel homer packy rdb organ" 134 ln -sf /usr/local/bin/core /usr/local/bin/$i 135 echo "$i -> core -> /usr/local/bin/" 138 (:save () (with-sbcl (:noinform t :quit t) 139 (ql:quickload :core/tests) 140 (in-package :core/tests) 141 (compile-lisp :core/tests :save ".stash/tests.core"))) 143 (compile-lisp :core/tests :force t :verbose t))) 144 (bench () (:compile () (compile-lisp :core/bench :force t :verbose t))) 145 (fasls (compile-core #+nil compile-tests compile-bench compile-user compile-prelude)) 147 (mailman () #$cd rust && cargo build -Z unstable-options --bin mailman --artifact-dir ../.stash/$#) 148 (alik () #$cd rust && cargo build -Z unstable-options --bin alik --artifact-dir ../.stash/$#) 149 (rust-bin (mailman alik)) 150 (alik-ui () #$trunk build --config rust/ui/alik/Trunk.toml$#) 152 (install (install-core) 153 #$d=/usr/local/share/lisp/ 157 for f in $(find . -type f -name "*.core") 158 do echo "$(basename $f) -> $d" 159 install -C -m 755 $f $d 161 (emacs () #$make -C emacs$#) 163 (core-syms.sxp () (with-open-file (f ".stash/symbols.sxp" :direction :output))) 165 mkdir -pv core core/bin core/share/lisp/fasl core/lib 166 mv *.core core/share/lisp/ 167 mv *.fasl core/share/lisp/fasl/ 169 mv $(find -maxdepth 1 -type f ! -name "*.*") core/bin/ 170 tar -I 'zstd' -cf core.tar.zst core/*$#) 171 (dist-clean (clean) #$cd .. && tar -I 'zstd' -cf core/core-source.tar.zst core/* && cd core 173 mv core-source.tar.zst .stash/$#))