diff --git a/src/Makefile.am b/src/Makefile.am
index 972fb27ca..9130aec92 100644
--- a/src/Makefile.am
+++ b/src/Makefile.am
@@ -144,8 +144,6 @@ libmutter_wayland_la_SOURCES = \
core/screen-private.h \
meta/screen.h \
meta/types.h \
- core/session.c \
- core/session.h \
core/stack.c \
core/stack.h \
core/stack-tracker.c \
@@ -182,6 +180,8 @@ libmutter_wayland_la_SOURCES = \
x11/group-props.h \
x11/group.c \
x11/group.h \
+ x11/session.c \
+ x11/session.h \
x11/window-props.c \
x11/window-props.h \
x11/window-x11.c \
diff --git a/src/core/main.c b/src/core/main.c
index df87ea213..d4a8ac3f8 100644
--- a/src/core/main.c
+++ b/src/core/main.c
@@ -50,7 +50,6 @@
#include "display-private.h"
#include
#include "ui.h"
-#include "session.h"
#include
#include
@@ -78,6 +77,8 @@
#include
#endif
+#include "x11/session.h"
+
#include "wayland/meta-wayland.h"
/*
diff --git a/src/core/window.c b/src/core/window.c
index 36a585738..caef90706 100644
--- a/src/core/window.c
+++ b/src/core/window.c
@@ -38,7 +38,6 @@
#include "keybindings-private.h"
#include "ui.h"
#include "place.h"
-#include "session.h"
#include
#include "resizepopup.h"
#include "constraints.h"
@@ -60,6 +59,7 @@
#include "x11/window-props.h"
#include "x11/xprops.h"
#include "x11/group.h"
+#include "x11/session.h"
#include "wayland/meta-wayland-private.h"
diff --git a/src/core/session.c b/src/x11/session.c
similarity index 100%
rename from src/core/session.c
rename to src/x11/session.c
diff --git a/src/core/session.h b/src/x11/session.h
similarity index 100%
rename from src/core/session.h
rename to src/x11/session.h