Skip to content

Commit 9a30333

Browse files
committed
build: clarify shared libraries
1 parent d916457 commit 9a30333

File tree

2 files changed

+23
-16
lines changed

2 files changed

+23
-16
lines changed

BUILD.md

Lines changed: 16 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -41,10 +41,15 @@ Quickshell has a set of base dependencies you will always need, names vary by di
4141
- `cmake`
4242
- `qt6base`
4343
- `qt6declarative`
44-
- `qtshadertools` (build-time only)
45-
- `spirv-tools` (build-time only)
46-
- `pkg-config` (build-time only)
47-
- `cli11` (build-time only)
44+
- `qtshadertools` (build-time)
45+
- `spirv-tools` (build-time)
46+
- `pkg-config` (build-time)
47+
- `cli11` (static library)
48+
49+
Build time dependencies and static libraries don't have to exist at runtime,
50+
however build time dependencies must be compiled for the architecture of
51+
the builder, while static libraries must be compiled for the architecture
52+
of the target.
4853

4954
On some distros, private Qt headers are in separate packages which you may have to install.
5055
We currently require private headers for the following libraries:
@@ -66,7 +71,7 @@ enable us to fix bugs far more easily.
6671

6772
To disable: `-DCRASH_REPORTER=OFF`
6873

69-
Dependencies: `google-breakpad`
74+
Dependencies: `google-breakpad` (static library)
7075

7176
### Jemalloc
7277
We recommend leaving Jemalloc enabled as it will mask memory fragmentation caused
@@ -101,8 +106,11 @@ To disable: `-DWAYLAND=OFF`
101106
Dependencies:
102107
- `qt6wayland`
103108
- `wayland` (libwayland-client)
104-
- `wayland-scanner` (may be part of your distro's wayland package)
105-
- `wayland-protocols`
109+
- `wayland-scanner` (build time)
110+
- `wayland-protocols` (static library)
111+
112+
Note that one or both of `wayland-scanner` and `wayland-protocols` may be bundled
113+
with you distro's wayland package.
106114

107115
#### Wlroots Layershell
108116
Enables wlroots layershell integration through the [zwlr-layer-shell-v1] protocol,
@@ -220,7 +228,7 @@ To disable: `-DI3_IPC=OFF`
220228
## Building
221229
*For developers and prospective contributors: See [CONTRIBUTING.md](CONTRIBUTING.md).*
222230

223-
We highly recommend using `ninja` to run the build, but you can use makefiles if you must.
231+
Only `ninja` builds are tested, but makefiles may work.
224232

225233
#### Configuring the build
226234
```sh

default.nix

Lines changed: 7 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -46,29 +46,28 @@
4646
}: buildStdenv.mkDerivation {
4747
pname = "quickshell${lib.optionalString debug "-debug"}";
4848
version = "0.1.0";
49-
src = nix-gitignore.gitignoreSource "/docs\n/examples\n" ./.;
49+
src = nix-gitignore.gitignoreSource [] ./.;
5050

5151
nativeBuildInputs = [
5252
cmake
5353
ninja
5454
qt6.qtshadertools
5555
spirv-tools
56-
cli11
5756
qt6.wrapQtAppsHook
5857
pkg-config
59-
] ++ (lib.optionals withWayland [
60-
wayland-protocols
61-
wayland-scanner
62-
]);
58+
]
59+
++ lib.optional withWayland wayland-scanner;
6360

6461
buildInputs = [
6562
qt6.qtbase
6663
qt6.qtdeclarative
64+
cli11
6765
]
66+
++ lib.optional withQtSvg qt6.qtsvg
6867
++ lib.optional withCrashReporter breakpad
6968
++ lib.optional withJemalloc jemalloc
70-
++ lib.optional withQtSvg qt6.qtsvg
71-
++ lib.optionals withWayland ([ qt6.qtwayland wayland ] ++ (if libgbm != null then [ libdrm libgbm ] else []))
69+
++ lib.optionals withWayland [ qt6.qtwayland wayland wayland-protocols ]
70+
++ lib.optionals (withWayland && libgbm != null) [ libdrm libgbm ]
7271
++ lib.optional withX11 xorg.libxcb
7372
++ lib.optional withPam pam
7473
++ lib.optional withPipewire pipewire;

0 commit comments

Comments
 (0)