diff options
author | Christopher James Halse Rogers <christopher.halse.rogers@canonical.com> | 2012-05-23 22:05:53 +1000 |
---|---|---|
committer | Christopher James Halse Rogers <christopher.halse.rogers@canonical.com> | 2012-06-13 15:26:21 +1000 |
commit | b13c547133f57e8bf16049152163102b0c41a47f (patch) | |
tree | 6b02dc52c14b501dc4585e8c5a734fbf31cc1075 | |
parent | c13becb2b8b470ba17e907c5d2c027d7896e8424 (diff) |
xwayland: Automatically load module if wayland support requested
This makes life a bit easier for the drivers
Signed-off-by: Christopher James Halse Rogers <christopher.halse.rogers@canonical.com>
-rw-r--r-- | hw/xfree86/common/xf86Config.c | 14 |
1 files changed, 13 insertions, 1 deletions
diff --git a/hw/xfree86/common/xf86Config.c b/hw/xfree86/common/xf86Config.c index 5abe12e51..3934ff0c4 100644 --- a/hw/xfree86/common/xf86Config.c +++ b/hw/xfree86/common/xf86Config.c @@ -125,7 +125,8 @@ static ModuleDefault ModuleDefaults[] = { #ifdef DRI2 {.name = "dri2",.toLoad = TRUE,.load_opt = NULL}, #endif - {.name = NULL,.toLoad = FALSE,.load_opt = NULL} + {.name = "xwayland",.toLoad = FALSE,.load_opt=NULL}, + {.name = NULL,.toLoad = FALSE,.load_opt=NULL} }; /* Forward declarations */ @@ -267,6 +268,17 @@ xf86ModulelistFromConfig(pointer **optlist) return NULL; } + /* + * Set the xwayland module to autoload if requested. + */ + if (xorgWayland) { + for (i=0 ; ModuleDefaults[i].name != NULL ; i++) { + if (strcmp(ModuleDefaults[i].name, "xwayland") == 0) { + ModuleDefaults[i].toLoad = TRUE; + } + } + } + if (xf86configptr->conf_modules) { /* Walk the disable list and let people know what we've parsed to * not be loaded |