- INSTALL=install -c -m 644
- INSTALL_BIN=install -c -m 755
---- a/workers/loader.c
-+++ b/workers/loader.c
-@@ -1,5 +1,23 @@
- #include "loader.h"
-
-+#ifdef STATIC_WORKER
-+
-+extern struct worker_module_t worker_module;
-+static struct loader_ctx_t static_ctx = {
-+ .module = &worker_module
-+};
-+
-+struct loader_ctx_t *worker_load(const char *name)
-+{
-+ return &static_ctx;
-+}
-+
-+void worker_free(struct loader_ctx_t *ctx)
-+{
-+}
-+
-+#else
-+
- struct loader_ctx_t *worker_load(const char *name) {
- struct loader_ctx_t *ctx;
-
-@@ -12,7 +30,7 @@ struct loader_ctx_t *worker_load(const c
- return NULL;
- }
-
-- ctx->module = dlsym(ctx->dl_handle, "module");
-+ ctx->module = dlsym(ctx->dl_handle, "worker_module");
- if (ctx->module == NULL) {
- fprintf(stderr, "Loader error: %s\n", dlerror());
- worker_free(ctx);
-@@ -31,3 +49,5 @@ void worker_free(struct loader_ctx_t *ct
-
- free(ctx);
- }
-+
-+#endif
---- a/hotplug2.c
-+++ b/hotplug2.c
-@@ -261,17 +261,21 @@ int main(int argc, char *argv[]) {
- }
-
- /* Load the worker. */
-+#ifndef STATIC_WORKER
- if (settings->worker_name == NULL) {
- fprintf(stderr, "Missing worker name.\n");
- settings_clear(settings);
- exit(1);
- }
-+#endif
- settings->worker = worker_load(settings->worker_name);
-+#ifndef STATIC_WORKER
- if (settings->worker == NULL) {
- fprintf(stderr, "Unable to load worker: %s\n", settings->worker_name);
- settings_clear(settings);
- exit(1);
- }
-+#endif
-
- /* Prepare a netlink connection to the kernel. */
- settings->netlink_socket = netlink_init();
---- a/workers/worker_example.c
-+++ b/workers/worker_example.c
-@@ -62,7 +62,7 @@ static int worker_example_process(void *
- return 0;
- }
-
--struct worker_module_t module = {
-+struct worker_module_t worker_module = {
- "Hotplug2 example module",
- worker_example_init,
- worker_example_deinit,
---- a/workers/worker_fork.c
-+++ b/workers/worker_fork.c
-@@ -443,7 +443,7 @@ static int worker_fork_process(void *in_
- return 0;
- }
-
--struct worker_module_t module = {
-+struct worker_module_t worker_module = {
- "Hotplug2 forking module",
- worker_fork_init,
- worker_fork_deinit,
---- a/workers/worker_single.c
-+++ b/workers/worker_single.c
-@@ -18,7 +18,7 @@ static int worker_single_process(void *s
- return 0;
- }