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
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
|
.Dd October 17, 2026
.Dt RAWNIX 7
.Os
.Sh NAME
.Nm rawnix
.Nd what rawnix is, and what it is not
.Sh DESCRIPTION
rawnix is a source-based Linux system built around musl, Clang/LLVM,
LibreSSL and runit.
There is no glibc, no systemd, no OpenSSL and no X server.
Packages are built from recipes with
.Xr mkpkg 8
and installed with
.Xr pkg 8 ,
and the whole system is meant to be read: every tool is small enough to
follow, and the configuration is files you edit.
.Pp
What follows is the shape of the system.
To install it, see
.Xr installation 7 ;
for what to do afterwards, see
.Xr post-install 7 .
.Ss UEFI, and BIOS where there is no choice
rawnix boots with Limine from a FAT partition mounted at
.Pa /boot/efi ,
and
.Xr limine-sync 8
writes the boot menu there.
UEFI is the path everything is built for: the firmware loads
.Pa EFI/BOOT/BOOTX64.EFI
itself, and the shipped image needs nothing else.
Which one a machine offers is one command:
.Dl $ ls /sys/firmware/efi
On a UEFI system that directory exists.
.Pp
Legacy BIOS works as well, for the machines that give no choice:
a Hetzner Cloud server, qemu without OVMF.
The limine port is built with
.Fl -enable-bios
and
.Fl -enable-bios-cd ,
and
.Ic mkinstall.sh --bios
writes an image that SeaBIOS can boot: a 1 MiB BIOS boot partition
ahead of the ESP, with
.Pa limine-bios.sys
and a
.Pa limine.conf
on the FAT partition and Limine's stage 1 in the image.
Under UEFI that
.Pa limine.conf
is never read.
.Pp
On a BIOS target the bootloader is finished by hand, in the chroot:
.Bd -literal -offset indent
# limine bios-install /dev/sdX 1
# cp /usr/share/limine/limine-bios.sys /boot/efi/
# vi /etc/limine-sync.conf # console=tty0 console=ttyS0,115200
# limine-sync
.Ed
.Pp
.Xr limine-sync 8
prunes only the files it manages, so the copied
.Pa limine-bios.sys
survives every later run.
After upgrading limine, redo the install and the copy together: stage 1
on the disk and
.Pa limine-bios.sys
on the partition have to come from the same version.
.Ss Wayland, with sway and labwc
There is no X server in the ports tree.
The compositors are
.Xr sway 1
and
.Xr labwc 1 ,
both on wlroots, and the terminal is
.Xr foot 1 .
X11 applications run under
.Li xwayland
if the compositor is built with it.
.Pp
The X11 stack was retired when rawnix moved to Wayland.
The ports still exist, unmaintained, and can be fetched from
.Lk https://git.rawnix.org/attic/xorg/ :
the libraries, the server, the input and video drivers, and the small
utilities that go with them.
They are kept as a reference, not as a supported path: nothing in the
live tree depends on them, and they are not built for the binary
repository.
.Ss runit, with services in /service
Process supervision is runit, in its original layout.
A service is a directory holding a
.Pa run
script, and a service is enabled by linking it into
.Pa /service :
.Bd -literal -offset indent
# ln -s /etc/sv/nginx /service/nginx # enable
# rm /service/nginx # disable
# sv status /service/* # what is running
# sv restart nginx # restart one
.Ed
.Pp
.Pa /service
is a real directory on the root file system, not
.Pa /var/service ,
not
.Pa /run/runit/service ,
and not a symbolic link to either.
Documentation written for other distributions often says otherwise;
on rawnix the path is the one above.
.Pp
A package that ships a service declares it in its recipe, and
.Xr addpkg 8
makes the link at install time, so a newly installed daemon starts by
itself.
.Ss musl, and what follows from it
The C library is musl.
Glibc-only interfaces are absent, so some software needs patching, and
some needs the small compatibility ports
.Li musl-fts ,
.Li argp-standalone
and
.Li libucontext .
Binaries from other distributions do not run: they ask for
.Pa /lib/ld-linux-x86-64.so.2 ,
which does not exist here.
.Pp
There is no
.Li ldd ;
.Xr revdep 8
reports what is missing instead, reading the package database rather
than running the program.
.Ss Clang and LLVM
Everything is built with clang, and the LLVM package is the toolchain:
compiler, linker
.Pq Li lld ,
C++ library
.Pq Li libc++ ,
and the usual tools.
There is no GCC;
.Li gcc-compat
exists only for configure scripts that insist on the name.
.Pp
LLVM is built for the targets a desktop needs and no more:
.Bd -literal -offset indent
-DLLVM_TARGETS_TO_BUILD="X86;AMDGPU"
.Ed
.Pp
.Li X86
is the machine itself.
.Li AMDGPU
is there for Mesa's shader compiler on AMD graphics, and for ROCm.
On a machine with other graphics, change it:
.Bl -tag -width "nouveau (NVIDIA)"
.It AMD
.Li "X86;AMDGPU" ,
the default.
.It Intel
.Li X86
alone: Mesa's Intel drivers use their own compiler and need no LLVM
target.
.It NVIDIA
.Li "X86;NVPTX"
for nouveau, whose Gallium driver can use it.
.It a virtual machine
.Li X86
alone.
.El
.Pp
Leaving out AMDGPU makes the package markedly smaller and the build
markedly shorter; adding a target you do not have costs both for
nothing.
The setting is in the llvm port's
.Pa MAKEPKG ;
changing it means rebuilding llvm and then Mesa.
.Ss A monolithic kernel, with two exceptions
The kernel is built with everything a machine needs to boot, mount its
disks and reach the network compiled in, not as modules: no initramfs
guesswork, nothing to load before the root file system appears.
.Pp
Two kinds of driver are modules, because which one is needed cannot be
known when the kernel is built: wireless and graphics.
They are loaded at boot from
.Pa /etc/rc.modules ;
see
.Xr post-install 7 ,
.Sx KERNEL MODULES .
.Ss Signed ports, and a binary repository
Every port is signed with
.Xr signify 1 ,
and
.Xr mkpkg 8
verifies the signature against a key in
.Pa /etc/ports/keys/
before it builds anything.
.Xr bulk 8
fetches prebuilt packages for the same ports, so a machine without a
compiler can still be kept up to date; see
.Xr pkg 8
.Fl b .
.Ss The tools
.Bl -tag -width "mkpkg(8)" -compact
.It Xr mkpkg 8
builds a package from a
.Xr MAKEPKG 5
recipe
.It Xr pkg 8
installs, upgrades and removes, with dependencies
.It Xr addpkg 8 , Xr delpkg 8 , Xr infopkg 8
the package database itself
.It Xr ports 8
syncs the ports tree
.It Xr bulk 8
fetches prebuilt packages
.It Xr revdep 8
finds broken library dependencies
.It Xr stik 8
mounts removable devices as an ordinary user
.El
.Pp
Their source is at
.Lk https://git.rawnix.org/ ,
their manual pages at
.Lk https://man.rawnix.org/ ,
and
.Lk https://audit.rawnix.org/
shows which ports are outdated and which carry open CVEs.
.Sh FILES
.Bl -tag -width Ds -compact
.It Pa /service/
Enabled services, linked from
.Pa /etc/sv/ .
.It Pa /etc/rc.modules
Wireless and graphics modules, loaded at boot.
.It Pa /etc/pkg.conf
Where the ports are; see
.Xr pkg.conf 5 .
.It Pa /etc/ports/
Collection configuration and trusted keys; see
.Xr ports 8 .
.It Pa /etc/mkpkg.conf
Build settings; see
.Xr mkpkg.conf 5 .
.El
.Sh SEE ALSO
.Xr installation 7 ,
.Xr post-install 7 ,
.Xr limine-sync 8 ,
.Xr mkpkg 8 ,
.Xr pkg 8 ,
.Xr ports 8 ,
.Xr revdep 8
.Sh AUTHORS
.An zorz Aq Mt zorz@rawnix.org
|