Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[crash-reporter] Replace ssu library dependency with systemsettings. JB#57126 #56

Merged
merged 1 commit into from Mar 28, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
2 changes: 1 addition & 1 deletion rpm/crash-reporter.spec
Expand Up @@ -9,14 +9,14 @@ BuildRequires: qt5-qtdeclarative-devel
BuildRequires: qt5-qtgui-devel
BuildRequires: qt5-qtnetwork-devel
BuildRequires: qt5-qttools-linguist
BuildRequires: ssu-devel
BuildRequires: pkgconfig(dbus-1)
BuildRequires: pkgconfig(libiphb)
BuildRequires: pkgconfig(libudev)
BuildRequires: pkgconfig(libsystemd)
BuildRequires: pkgconfig(mce)
BuildRequires: pkgconfig(qt5-boostable)
BuildRequires: pkgconfig(nemonotifications-qt5)
BuildRequires: pkgconfig(systemsettings)
BuildRequires: pkgconfig(usb-moded-qt5)
BuildRequires: pkgconfig(systemd)
BuildRequires: oneshot
Expand Down
9 changes: 3 additions & 6 deletions src/libs/libs.pro
Expand Up @@ -35,13 +35,12 @@ QT = \

CONFIG += link_pkgconfig
PKGCONFIG += mce \
usb-moded-qt5
usb-moded-qt5 \
nemonotifications-qt5 \
systemsettings

DEFINES += CREPORTER_EXPORTS

CONFIG += link_pkgconfig
PKGCONFIG += nemonotifications-qt5

message(Building architecture: $$system(uname -m))

# Enable Qt Bearer Management API.
Expand Down Expand Up @@ -110,8 +109,6 @@ HEADERS += $$PUBLIC_HEADERS \
settings/creportersettingsbase_p.h \
settings/creportersettingsinit_p.h \

LIBS += -lssu

TARGET = $$qtLibraryTarget(crashreporter)

target.path += $$[QT_INSTALL_LIBS]
Expand Down
6 changes: 3 additions & 3 deletions src/libs/utils/creporterutils.cpp
Expand Up @@ -29,7 +29,7 @@
#include <sys/stat.h>

#ifndef CREPORTER_UNIT_TEST
#include <ssudeviceinfo.h>
#include <deviceinfo.h>
#endif

#include <QDebug>
Expand Down Expand Up @@ -194,7 +194,7 @@ QString CReporterUtils::deviceUid()
reply.waitForFinished();
if (reply.isError()) {
qCWarning(cr) << "DBus unavailable, UUID might be incorrect.";
return SsuDeviceInfo().deviceUid();
return DeviceInfo(true).deviceUid();
} else {
return reply.value();
}
Expand All @@ -206,7 +206,7 @@ QString CReporterUtils::deviceUid()
QString CReporterUtils::deviceModel()
{
#ifndef CREPORTER_UNIT_TEST
return SsuDeviceInfo().deviceModel();
return DeviceInfo(true).model();
#else
return "Device";
#endif
Expand Down