on xenial help sign in
Add barebones FullLightDM plugin
3c9cce6Josh Arenson
debian/control+2−1
@@ -11,7 +11,7 @@ Build-Depends: cmake,
11# version. To allow cross-compiling to work, we also must
11# version. To allow cross-compiling to work, we also must
12# append :native to g++-4.9 so we don't try to run armhf g++
12# append :native to g++-4.9 so we don't try to run armhf g++
13# on an x86 CPU for eaxmple, when cross-compiling.
13# on an x86 CPU for eaxmple, when cross-compiling.
14− g++-4.9:native,
14+# g++-4.9:native,
15 graphviz,
15 graphviz,
16 gsettings-ubuntu-schemas (>= 0.0.2+14.10.20140815),
16 gsettings-ubuntu-schemas (>= 0.0.2+14.10.20140815),
17 libconnectivity-qt1-dev,
17 libconnectivity-qt1-dev,
@@ -21,6 +21,7 @@ Build-Depends: cmake,
21 libglib2.0-dev,
21 libglib2.0-dev,
22 libgsettings-qt-dev,
22 libgsettings-qt-dev,
23 libhardware-dev,
23 libhardware-dev,
24+ liblightdm-qt5-3-dev,
24 libpam0g-dev,
25 libpam0g-dev,
25 libpay2-dev,
26 libpay2-dev,
26 libpulse-dev,
27 libpulse-dev,
debian/unity8-private.install+1
@@ -2,6 +2,7 @@ usr/lib/*/libunity8-private.*
2usr/lib/*/unity8/libUbuntuGestures*
2usr/lib/*/unity8/libUbuntuGestures*
3usr/lib/*/unity8/qml/AccountsService
3usr/lib/*/unity8/qml/AccountsService
4usr/lib/*/unity8/qml/Dash
4usr/lib/*/unity8/qml/Dash
5+usr/lib/*/unity8/qml/FullLightDM
5usr/lib/*/unity8/qml/Greeter
6usr/lib/*/unity8/qml/Greeter
6usr/lib/*/unity8/qml/IntegratedLightDM
7usr/lib/*/unity8/qml/IntegratedLightDM
7usr/lib/*/unity8/qml/Lights
8usr/lib/*/unity8/qml/Lights
plugins/CMakeLists.txt+1
@@ -12,6 +12,7 @@ macro(add_unity8_plugin PLUGIN VERSION PATH)
12endmacro()
12endmacro()
13
13
14add_subdirectory(AccountsService)
14add_subdirectory(AccountsService)
15+add_subdirectory(FullLightDM)
15add_subdirectory(Greeter)
16add_subdirectory(Greeter)
16add_subdirectory(IntegratedLightDM)
17add_subdirectory(IntegratedLightDM)
17add_subdirectory(Lights)
18add_subdirectory(Lights)
plugins/FullLightDM/CMakeLists.txtnew file+31
@@ -0,0 +1,31 @@
1+pkg_check_modules(LIBUSERMETRICSOUTPUT REQUIRED libusermetricsoutput-1)
2+pkg_check_modules(LIBLIGHTDM REQUIRED liblightdm-qt5-3)
3+
4+include_directories(
5+ ${CMAKE_CURRENT_SOURCE_DIR}
6+ ${CMAKE_CURRENT_BINARY_DIR}
7+ ${CMAKE_SOURCE_DIR}/plugins/Utils
8+ ${CMAKE_SOURCE_DIR}/tests/mocks/IntegratedLightDM
9+ ${LIBLIGHTDM_INCLUDE_DIRS}
10+ ${libunity8-private_SOURCE_DIR}
11+ ${LIBUSERMETRICSOUTPUT_INCLUDE_DIRS}
12+)
13+
14+set(QMLPLUGIN_SRC
15+ plugin.cpp
16+ )
17+
18+add_library(FullLightDM-qml MODULE
19+ ${QMLPLUGIN_SRC}
20+ )
21+
22+target_link_libraries(FullLightDM-qml
23+ unity8-private
24+ lightdm-qt5-3
25+ ${LIBLIGHTDM_LDFLAGS}
26+ ${LIBUSERMETRICSOUTPUT_LDFLAGS}
27+ )
28+
29+qt5_use_modules(FullLightDM-qml DBus Gui Qml)
30+
31+add_unity8_plugin(FullLightDM 0.1 FullLightDM TARGETS FullLightDM-qml)
plugins/FullLightDM/plugin.cppnew file+26
@@ -0,0 +1,26 @@
1+/*
2+ * Copyright (C) 2015 Canonical, Ltd.
3+ *
4+ * This program is free software; you can redistribute it and/or modify
5+ * it under the terms of the GNU General Public License as published by
6+ * the Free Software Foundation; version 3.
7+ *
8+ * This program is distributed in the hope that it will be useful,
9+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
10+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
11+ * GNU General Public License for more details.
12+ *
13+ * You should have received a copy of the GNU General Public License
14+ * along with this program. If not, see <http://www.gnu.org/licenses/>.
15+ *
16+ */
17+
18+#include "plugin.h"
19+
20+#include <QtQml/qqml.h>
21+
22+void FullLightDMPlugin::registerTypes(const char *uri)
23+{
24+
25+ Q_ASSERT(uri == QLatin1String("FullLightDM"));
26+}
plugins/FullLightDM/plugin.hnew file+33
@@ -0,0 +1,33 @@
1+/*
2+ * Copyright (C) 2015 Canonical, Ltd.
3+ *
4+ * This program is free software; you can redistribute it and/or modify
5+ * it under the terms of the GNU General Public License as published by
6+ * the Free Software Foundation; version 3.
7+ *
8+ * This program is distributed in the hope that it will be useful,
9+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
10+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
11+ * GNU General Public License for more details.
12+ *
13+ * You should have received a copy of the GNU General Public License
14+ * along with this program. If not, see <http://www.gnu.org/licenses/>.
15+ *
16+ */
17+
18+#ifndef FULL_LIGHTDM_PLUGIN_H
19+#define FULL_LIGHTDM_PLUGIN_H
20+
21+#include <QtQml/QQmlEngine>
22+#include <QtQml/QQmlExtensionPlugin>
23+
24+class FullLightDMPlugin : public QQmlExtensionPlugin
25+{
26+ Q_OBJECT
27+ Q_PLUGIN_METADATA(IID "org.qt-project.Qt.QQmlExtensionInterface")
28+
29+public:
30+ void registerTypes(const char *uri) override;
31+};
32+
33+#endif /* FULL_LIGHTDM_PLUGIN_H */
plugins/FullLightDM/qmldirnew file+3
@@ -0,0 +1,3 @@
1+module FulLightDM
2+plugin FullLightDM-qml
3+typeinfo FullLightDM.qmltypes
plugins/IntegratedLightDM/CMakeLists.txt−5
@@ -1,6 +1,4 @@
1pkg_check_modules(LIBUSERMETRICSOUTPUT REQUIRED libusermetricsoutput-1)
1pkg_check_modules(LIBUSERMETRICSOUTPUT REQUIRED libusermetricsoutput-1)
2−# TODO: Once we split out a separate greeter process, uncomment these lines
3−#pkg_check_modules(LIBLIGHTDM REQUIRED liblightdm-qt5-2)
4
2
5add_subdirectory(liblightdm)
3add_subdirectory(liblightdm)
6
4
@@ -9,7 +7,6 @@ include_directories(
9 ${CMAKE_CURRENT_BINARY_DIR}
7 ${CMAKE_CURRENT_BINARY_DIR}
10 ${CMAKE_SOURCE_DIR}/plugins/Utils
8 ${CMAKE_SOURCE_DIR}/plugins/Utils
11 ${CMAKE_SOURCE_DIR}/tests/mocks/IntegratedLightDM
9 ${CMAKE_SOURCE_DIR}/tests/mocks/IntegratedLightDM
12− #${LIBLIGHTDM_INCLUDE_DIRS}
13 ${libunity8-private_SOURCE_DIR}
10 ${libunity8-private_SOURCE_DIR}
14 ${LIBUSERMETRICSOUTPUT_INCLUDE_DIRS}
11 ${LIBUSERMETRICSOUTPUT_INCLUDE_DIRS}
15)
12)
@@ -30,8 +27,6 @@ add_library(IntegratedLightDM-qml MODULE
30target_link_libraries(IntegratedLightDM-qml
27target_link_libraries(IntegratedLightDM-qml
31 integratedLightDM
28 integratedLightDM
32 unity8-private
29 unity8-private
33−# TODO: Once we split out a separate greeter process, uncomment these lines
34−# ${LIBLIGHTDM_LDFLAGS}
35 ${LIBUSERMETRICSOUTPUT_LDFLAGS}
30 ${LIBUSERMETRICSOUTPUT_LDFLAGS}
36 )
31 )
37
32