18 lomiri-download-manager,
32 stdenv.mkDerivation (finalAttrs: {
33 pname = "lomiri-content-hub";
36 src = fetchFromGitLab {
38 repo = "development/core/lomiri-content-hub";
39 rev = finalAttrs.version;
40 hash = "sha256-eA5oCoAZB7fWyWm0Sy6wXh0EW+h76bdfJ2dotr7gUC0=";
51 substituteInPlace import/*/Content/CMakeLists.txt \
52 --replace-fail "\''${CMAKE_INSTALL_LIBDIR}/qt5/qml" "\''${CMAKE_INSTALL_PREFIX}/${qtbase.qtQmlPrefix}"
54 # Look for peer files in running system
55 substituteInPlace src/com/lomiri/content/service/registry-updater.cpp \
56 --replace-fail '/usr' '/run/current-system/sw'
58 # Don't override default theme search path (which honours XDG_DATA_DIRS) with a FHS assumption
59 substituteInPlace import/Lomiri/Content/contenthubplugin.cpp \
60 --replace-fail 'QIcon::setThemeSearchPaths(QStringList() << ("/usr/share/icons/"));' ""
69 qtdeclarative # qmlplugindump
83 lomiri-download-manager
97 checkInputs = [ gtest ];
99 dontWrapQtApps = true;
102 (lib.cmakeBool "GSETTINGS_COMPILE" true)
103 (lib.cmakeBool "GSETTINGS_LOCALINSTALL" true)
104 (lib.cmakeBool "ENABLE_TESTS" finalAttrs.finalPackage.doCheck)
105 (lib.cmakeBool "ENABLE_DOC" true)
106 (lib.cmakeBool "ENABLE_UBUNTU_COMPAT" true) # in case something still depends on it
112 list: suffix: lib.strings.concatMapStringsSep ":" (drv: "${lib.getBin drv}/${suffix}") list;
115 # Executes qmlplugindump
116 export QT_PLUGIN_PATH=${listToQtVar [ qtbase ] qtbase.qtPluginPrefix}
117 export QML2_IMPORT_PATH=${
127 doCheck = stdenv.buildPlatform.canExecute stdenv.hostPlatform;
129 # Starts & talks to D-Bus services, breaks under parallelism
130 enableParallelChecking = false;
133 for exampleExe in content-hub-test-{importer,exporter,sharer}; do
134 moveToOutput bin/$exampleExe $examples
135 moveToOutput share/applications/$exampleExe.desktop $examples
137 moveToOutput share/icons $examples
138 moveToOutput share/lomiri-content-hub/peers $examples
142 for exampleBin in $examples/bin/*; do
148 tests.pkg-config = testers.testMetaPkgConfig finalAttrs.finalPackage;
149 updateScript = gitUpdater { };
153 description = "Content sharing/picking service for the Lomiri desktop";
155 lomiri-content-hub is a mediation service to let applications share content between them,
156 even if they are not running at the same time.
158 homepage = "https://gitlab.com/ubports/development/core/lomiri-content-hub";
159 changelog = "https://gitlab.com/ubports/development/core/lomiri-content-hub/-/blob/${finalAttrs.version}/ChangeLog";
160 license = with lib.licenses; [
164 mainProgram = "lomiri-content-hub-service";
165 maintainers = lib.teams.lomiri.members;
166 platforms = lib.platforms.linux;
168 "liblomiri-content-hub"
169 "liblomiri-content-hub-glib"