Repository navigation
Expand file tree
/
Copy pathMakefile
More file actions
48 lines (42 loc) · 1.84 KB
/
Copy pathMakefile
File metadata and controls
48 lines (42 loc) · 1.84 KB
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
# Lean Quiet: `make install && make run` builds the desktop app and opens it.
# Linux (x86-64, X11 or XWayland; Debian, Ubuntu and their kin) today;
# macOS prints that it is not yet supported.
#
# make install any missing system packages (apt-get, after saying so),
# Lean (elan) and Rust (rustup) in your home folder, the
# app's assets (a pinned download), then the build
# make run open the app with a demo: two seeded communities, no network
# make online open the app with networking on, its own database
# make demo two apps side by side, as two devices (Alice's laptop and
# Bob's), joined over TCP on this computer: Bob joins
# Alice's community and they chat. ARGS=--auto does the
# join for you (needs xdotool)
# make check list what make install still needs; installs nothing
# make assets only the app's assets
# make verify lake check and lake comparator (they need Lean 4.35)
#
# The build stays in this folder (.lake, out, assets). ELAN_HOME, CARGO_HOME,
# RUSTUP_HOME and TMPDIR are honoured if set; ARGS passes more arguments to
# the app.
UNAME := $(shell uname -s)
ifeq ($(UNAME),Linux)
PLATFORM := tools/make/linux.sh
else ifeq ($(UNAME),Darwin)
PLATFORM := tools/make/macos.sh
else
PLATFORM := printf 'make: Lean Quiet builds on Linux (x86-64); this is %s.\n' "$(UNAME)" >&2; false
endif
export ELAN_HOME ?= $(HOME)/.elan
export CARGO_HOME ?= $(HOME)/.cargo
export RUSTUP_HOME ?= $(HOME)/.rustup
export TMPDIR ?= /tmp
.DEFAULT_GOAL := help
.PHONY: help install run online demo check assets
install run online demo check assets:
@$(PLATFORM) $@ $(ARGS)
# Lean's checkers, on every platform: tools/make/verify.sh says what it needs.
.PHONY: verify
verify:
@tools/make/verify.sh
help:
@sed -n '1,/^$$/{s/^# \{0,1\}//;p;}' Makefile