about summary refs log tree commit diff
path: root/third_party/lisp/postmodern.nix
blob: 25e0625c20bc9df9fed757a27ed8e3af50200944 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
{ depot, pkgs, ... }:

let
  inherit (depot.nix.buildLisp) bundled;
  src = with pkgs; srcOnly lispPackages.postmodern;

  cl-postgres = depot.nix.buildLisp.library {
    name = "cl-postgres";
    deps = with depot.third_party.lisp; [
      md5
      split-sequence
      ironclad
      cl-base64
      uax-15
      usocket
    ];

    srcs = map (f: src + ("/cl-postgres/" + f)) [
      "package.lisp"
      "features.lisp"
      "config.lisp"
      "oid.lisp"
      "errors.lisp"
      "data-types.lisp"
      "sql-string.lisp"
      "trivial-utf-8.lisp"
      "strings-utf-8.lisp"
      "communicate.lisp"
      "messages.lisp"
      "ieee-floats.lisp"
      "interpret.lisp"
      "saslprep.lisp"
      "scram.lisp"
      "protocol.lisp"
      "public.lisp"
      "bulk-copy.lisp"
    ];
  };

  s-sql = depot.nix.buildLisp.library {
    name = "s-sql";
    deps = with depot.third_party.lisp; [
      cl-postgres
      alexandria
    ];

    srcs = map (f: src + ("/s-sql/" + f)) [
      "package.lisp"
      "config.lisp"
      "s-sql.lisp"
    ];
  };

  postmodern = depot.nix.buildLisp.library {
    name = "postmodern";

    deps = with depot.third_party.lisp; [
      alexandria
      cl-postgres
      s-sql
      global-vars
      split-sequence
      cl-unicode
      closer-mop
      bordeaux-threads
    ];

    srcs = [
      "${src}/postmodern.asd"
    ] ++ (map (f: src + ("/postmodern/" + f)) [
      "package.lisp"
      "config.lisp"
      "connect.lisp"
      "json-encoder.lisp"
      "query.lisp"
      "prepare.lisp"
      "roles.lisp"
      "util.lisp"
      "transaction.lisp"
      "namespace.lisp"
      "execute-file.lisp"
      "table.lisp"
      "deftable.lisp"
    ]);

    brokenOn = [
      "ecl" # TODO(sterni): https://gitlab.com/embeddable-common-lisp/ecl/-/issues/651
    ];
  };

in
postmodern // {
  inherit s-sql cl-postgres;
}