2021-04-02 21:52:36 +01:00
|
|
|
--- a/src/util/linux_util.c
|
|
|
|
+++ b/src/util/linux_util.c
|
2021-04-24 10:20:05 +01:00
|
|
|
@@ -125,6 +125,7 @@
|
|
|
|
"lib64",
|
|
|
|
"lib32",
|
|
|
|
"usr/lib", // needed for arch?
|
|
|
|
+ "run/booted-system/kernel-modules/lib", // NixOS
|
|
|
|
NULL};
|
|
|
|
int result = -1;
|
|
|
|
int ndx = 0;
|
|
|
|
@@ -204,14 +205,15 @@
|
|
|
|
if (debug)
|
|
|
|
printf("(%s) machine: %s", __func__, utsbuf.machine);
|
2021-04-02 21:52:36 +01:00
|
|
|
|
2021-04-24 10:20:05 +01:00
|
|
|
- char * libdirs[3];
|
|
|
|
+ char * libdirs[4];
|
|
|
|
libdirs[0] = "lib";
|
|
|
|
+ libdirs[1] = "run/booted-system/kernel-modules/lib";
|
|
|
|
if (streq(utsbuf.machine, "amd_64")){
|
|
|
|
- libdirs[1] = "lib64";
|
|
|
|
- libdirs[2] = NULL;
|
|
|
|
+ libdirs[2] = "lib64";
|
|
|
|
+ libdirs[3] = NULL;
|
|
|
|
}
|
|
|
|
else
|
|
|
|
- libdirs[1] = NULL;
|
|
|
|
+ libdirs[2] = NULL;
|
2021-04-02 21:52:36 +01:00
|
|
|
|
2021-04-24 10:20:05 +01:00
|
|
|
int libsndx = 0;
|
|
|
|
bool found = false;
|