Help creatModule form dependency

hello

	const match = b.createModule(.{
		.root_source_file = b.path("./deps/curse/match.zig"),
	});
	match.addIncludePath(b.path( "./lib/"));

	
	const cursed = b.createModule(.{
		.root_source_file = b.path( "./deps/curse/cursed.zig"),
	});

	const utils = b.createModule(.{
		.root_source_file = b.path( "./deps/curse/utils.zig"),
	});


	const forms = b.createModule(.{
		.root_source_file = b.path("./deps/curse/forms.zig"),
		.imports= &.{
		.{ .name = "cursed", .module = cursed },
		.{ .name = "utils",  .module = utils },
		.{ .name = "match",  .module = match },
		},

	});


	const grid = b.createModule(.{
		.root_source_file = b.path("./deps/curse/grid.zig" ),
		.imports= &.{
		.{ .name = "cursed", .module = cursed },
		.{ .name = "utils",  .module = utils },
		},
	});

	
	const menu = b.createModule(.{
		.root_source_file = b.path( "./deps/curse/menu.zig" ),
		.imports= &.{
		.{ .name = "cursed", .module = cursed },
		.{ .name = "utils",  .module = utils },
		},
	});



	//const library_dep = b.dependency("library", .{});

// ===========================================================
	
	const mdlPanel = b.createModule(.{
		.root_source_file = b.path( "./mdlPanel.zig" ),
		??????? 
		.imports= &.{
			.{ .name = "cursed", .module = cursed },
			.{ .name = "utils",  .module = utils },
			.{ .name = "forms",  .module = forms },
			.{ .name = "grid",   .module = grid  },
			.{ .name = "menu",   .module = menu  },
			.{ .name = "match",  .module = match },
		},
	});

I would like to use my library instead of having hard sources

so import is improper in my createmodule

Can you help me please

réponse:

    const cursed = b.dependency("library", .{}).module("cursed");
    const utils  = b.dependency("library", .{}).module("utils");
    const forms  = b.dependency("library", .{}).module("forms");
    const grid   = b.dependency("library", .{}).module("grid");
    const menu   = b.dependency("library", .{}).module("menu");
    const match  = b.dependency("library", .{}).module("match");


	    const mdlPanel = b.createModule(.{
		.root_source_file = b.path( "./mdlPanel.zig" ),
		.imports= &.{
			.{ .name = "cursed", .module = cursed},
			.{ .name = "utils",  .module = utils },
			.{ .name = "forms",  .module = forms },
			.{ .name = "grid",   .module = grid  },
			.{ .name = "menu",   .module = menu  },
			.{ .name = "match",  .module = match },
		},
	});