Repository navigation
Expand file tree
/
Copy pathMakefile
More file actions
executable file
·60 lines (51 loc) · 2.13 KB
/
Copy pathMakefile
File metadata and controls
executable file
·60 lines (51 loc) · 2.13 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
49
50
51
52
53
54
55
56
57
58
59
60
# wip-openbsd-src -- standalone fork of OpenBSD userland utilities
# Targets OpenBSD 7.9 / 8.0-beta. Binaries replace system versions.
#
# Standalone components built from this directory:
# pax -- pax(1) with tar(1)/cpio(1) multicall links
# fvwm -- FVWM 2.2.5 with privilege separation and hardening
#
# Targets (via bsd.subdir.mk):
# make build everything (default)
# make pax build only pax
# make fvwm build only fvwm
# make install install both components (run as root or via doas)
# make install-pax install only pax
# make install-fvwm install only fvwm
# make clean remove build artifacts
# make obj create objdirs (pax only; fvwm builds in place)
# make debug build each component as <prog>_debug and run it under lldb
# make test run the host-side test suite
# make rebuild clean and rebuild everything
#
# Requires OpenBSD make(1) and /usr/share/mk. fvwm additionally
# requires Xenocara/X11 development files.
#
# The ext4fs component is not built here; it stores files at
# OpenBSD source-tree-relative paths for copying into a checkout.
# Toolchain: clang compiles, lldb debugs.
CC = clang
DEBUGGER = lldb
# Sources in this tree are ISO C23. Declared here as well so that tooling
# which scans build metadata (scripts/tests-format/clang-format-all.sh)
# recognises the standard for files under components that carry no
# declaration of their own (ext4fs, stdckdint). Source-tree Makefiles must
# not inject -std= flags, so the standalone driver is the anchor.
CFLAGS += -std=c23
SUBDIR = pax fvwm
.include <bsd.subdir.mk>
# Recurse into each component, build <prog>_debug and start it under lldb.
debug: _SUBDIRUSE
# Install a single component; the recursive install target would
# otherwise reach both pax and fvwm. Run as root or via doas.
.for dir in ${SUBDIR}
install-${dir}:
@echo "===> ${dir} (install)"
@${MAKE} -C ${.CURDIR}/${dir} ${MAKE_FLAGS} install
.endfor
# Run the host-side test suite.
test:
@${MAKE} -C ${.CURDIR}/tests test
# Clean and rebuild everything from scratch.
rebuild: clean .WAIT all
.PHONY: debug test rebuild ${SUBDIR:S/^/install-/}