fix(shell): wrong target

A mistake, since the target name changed, the target name in shell
should also change

Log: fix recoveryshell
This commit is contained in:
chenhongtao 2022-09-02 15:56:30 +08:00 committed by deepin-bot[bot]
parent e221e232fc
commit 068a6d9688
14 changed files with 3 additions and 474 deletions

View File

@ -1 +0,0 @@
DTK_VERSION=

View File

@ -1,48 +0,0 @@
######################################################################
# Automatically generated by qmake (3.1) Thu Aug 19 09:48:31 2021
######################################################################
TEMPLATE = app
TARGET = thread_util
INCLUDEPATH += .
QT+= core widgets testlib
CONFIG += c++11
# The following define makes your compiler warn you if you use any
# feature of Qt which has been marked as deprecated (the exact warnings
# depend on your compiler). Please consult the documentation of the
# deprecated API in order to know how to port your code away from it.
DEFINES += QT_DEPRECATED_WARNINGS
CONFIG(debug, debug|release) {
LIBS += -lgtest -lgmock
QMAKE_CXXFLAGS += -g -Wall -fprofile-arcs -ftest-coverage -fsanitize=address -fsanitize-recover=address -O2
QMAKE_LFLAGS += -g -Wall -fprofile-arcs -ftest-coverage -fsanitize=address -fsanitize-recover=address -O2
QMAKE_CXX += -g -fprofile-arcs -ftest-coverage -fsanitize=address -fsanitize-recover=address -O2
}
LIBS += -pthread
QMAKE_CXXFLAGS += -pthread
#QMAKE_CXXFLAGS_RELEASE += -fvisibility=hidden
#DEFINES += LIBDTKCORE_LIBRARY
# You can also make your code fail to compile if you use deprecated APIs.
# In order to do so, uncomment the following line.
# You can also select to disable deprecated APIs only up to a certain version of Qt.
#DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0x060000 # disables all the APIs deprecated before Qt 6.0.0
INCLUDEPATH += $$PWD/../../src
INCLUDEPATH += $$PWD/../../src/base
INCLUDEPATH += $$PWD/../../src/util
# Input
HEADERS += \
$${PWD}/../../src/dtkcore_global.h \
$${PWD}/../../src/util/dasync.h \
$${PWD}/../../src/util/dthreadutils.h
SOURCES += \
$${PWD}/../../src/util/dthreadutils.cpp \
main.cpp

View File

@ -1,4 +0,0 @@
TEMPLATE = subdirs
SUBDIRS += expintf-example
SUBDIRS += dasync-example

View File

@ -1,16 +0,0 @@
TEMPLATE = app
QT += dbus
SOURCES += \
$$PWD/main.cpp
win32:CONFIG(release, debug|release): LIBS += -L$$OUT_PWD/../../src/release -ldtkcore
else:win32:CONFIG(debug, debug|release): LIBS += -L$$OUT_PWD/../../src/debug -ldtkcore
else:unix: LIBS += -L$$OUT_PWD/../../src -ldtkcore
INCLUDEPATH += $$PWD/../../src
INCLUDEPATH += $$PWD/../../src/base
CONFIG(debug, debug|release) {
unix:QMAKE_RPATHDIR += $$OUT_PWD/../../src
}

View File

@ -1,55 +0,0 @@
include($$PWD/private/private.pri)
INCLUDEPATH += $$PWD/../base
INSTALL_PREFIX=$$QT_INSTALL_PREFIX
isEmpty(INSTALL_PREFIX): INSTALL_PREFIX=$$[QT_INSTALL_PREFIX]
DEFINES += PREFIX=\\\"$$INSTALL_PREFIX\\\"
HEADERS += \
$$PWD/dbasefilewatcher.h \
$$PWD/dcapmanager.h \
$$PWD/dfilesystemwatcher.h \
$$PWD/dfilewatcher.h \
$$PWD/dfilewatchermanager.h \
$$PWD/dpathbuf.h \
$$PWD/dstandardpaths.h \
$$PWD/dtrashmanager.h \
$$PWD/dcapfile.h \
SOURCES += \
$$PWD/dbasefilewatcher.cpp \
$$PWD/dcapmanager.cpp \
$$PWD/dfilewatcher.cpp \
$$PWD/dfilewatchermanager.cpp \
$$PWD/dstandardpaths.cpp \
$$PWD/dpathbuf.cpp \
$$PWD/dcapfsfileengine.cpp \
$$PWD/dcapfile.cpp \
linux {
SOURCES += \
$$PWD/dfilesystemwatcher_linux.cpp \
$$PWD/dtrashmanager_linux.cpp
} else:win* {
SOURCES += \
$$PWD/dfilesystemwatcher_win.cpp \
$$PWD/dtrashmanager_dummy.cpp
} else {
SOURCES += \
$$PWD/dfilesystemwatcher_dummy.cpp \
$$PWD/dtrashmanager_dummy.cpp
}
includes.files += $$PWD/*.h
includes.files += \
$$PWD/DFileWatcher \
$$PWD/DBaseFileWatcher \
$$PWD/DCapManager \
$$PWD/DCapFile \
$$PWD/DCapDir \
$$PWD/DFileSystemWatcher \
$$PWD/DFileWatcherManager \
$$PWD/DPathBuf \
$$PWD/DStandardPaths \
$$PWD/DTrashManager \

View File

@ -1,104 +0,0 @@
QT -= gui
QT += dbus
QT += xml
CONFIG += link_pkgconfig
TARGET = dtkcore
# 龙芯架构上没有默认添加PT_GNU_STACK-section,所以此处手动指定一下
contains(QMAKE_HOST.arch, mips.*): QMAKE_LFLAGS_SHLIB += "-Wl,-z,noexecstack"
QMAKE_CXXFLAGS_RELEASE += -fvisibility=hidden
INCLUDEPATH += $$PWD
HEADERS += $$PWD/dtkcore_global.h \
dconfig.h \
dsgapplication.h \
dsysinfo.h \
dsecurestring.h \
ddesktopentry.h
SOURCES += \
dconfig.cpp \
dsgapplication.cpp \
dsysinfo.cpp \
dsecurestring.cpp \
ddesktopentry.cpp \
dtkcore_global.cpp
linux: {
!isEmpty(D_DSG_APP_DATA_FALLBACK): DEFINES += D_DSG_APP_DATA_FALLBACK=\\\"$$D_DSG_APP_DATA_FALLBACK\\\"
HEADERS += \
$$PWD/dconfigfile.h
SOURCES += \
$$PWD/dconfigfile.cpp
# generic dbus interfaces
isEmpty(DTK_DISABLE_DBUS_CONFIG) {
QT += dbus
config.files = $$PWD/dbus/org.desktopspec.ConfigManager.xml
config.header_flags += -c DSGConfig -N
config.source_flags += -c DSGConfig -N
manager.files = $$PWD/dbus/org.desktopspec.ConfigManager.Manager.xml
manager.header_flags += -c DSGConfigManager -N
manager.source_flags += -c DSGConfigManager -N
DBUS_INTERFACES += config manager
} else {
DEFINES += D_DISABLE_DBUS_CONFIG
}
} else {
DEFINES += D_DISABLE_DCONFIG
}
include($$PWD/base/base.pri)
include($$PWD/util/util.pri)
include($$PWD/log/log.pri)
include($$PWD/filesystem/filesystem.pri)
include($$PWD/settings/settings.pri)
include($$PWD/dci/dci.pri)
includes.files += \
$$PWD/*.h \
$$PWD/dtkcore_config.h \
$$PWD/DtkCores \
$$PWD/DSysInfo \
$$PWD/DSecureString \
$$PWD/DDesktopEntry \
$$PWD/DConfigFile \
$$PWD/DConfig \
$$PWD/DSGApplication
# ----------------------------------------------
# install config
DTK_MODULE_NAME = $$TARGET
load(dtk_build)
LIBS += -ldl
INSTALLS += includes target
isEmpty(DTK_STATIC_LIB){
DEFINES += LIBDTKCORE_LIBRARY
} else {
DEFINES += DTK_STATIC_LIB
}
#cmake
load(dtk_cmake)
#qt module
load(dtk_module)
!isEmpty(DTK_MULTI_VERSION) {
# 支持上游一包多依赖
load(dtk_multiversion)
# 5.5 5.6可通过重复调用此函数,来增加对更多版本的支持
dtkBuildMultiVersion(5.5)
# INSTALL变量增加多版本下的配置文件
load(dtk_install_multiversion)
}

View File

@ -131,7 +131,7 @@ else()
${base_SRCS}
${dci_SRCS}
${filesystem_SRCS}
${log_SRCS}
${log_SRCS}
${settings_SRC}
${utils_SRC}
${glob_SRC}

View File

@ -1,27 +0,0 @@
QT += testlib
QT -= gui
TARGET = tst_ddesktopentrytest
TEMPLATE = app
CONFIG += c++11
CONFIG -= app_bundle
!isEmpty(DTK_STATIC_LIB){
DEFINES += DTK_STATIC_LIB
}
load(dtk_testcase)
win32:CONFIG(release, debug|release): LIBS += -L$$OUT_PWD/../../src/release/ -ldtkcore -lgtest
else:win32:CONFIG(debug, debug|release): LIBS += -L$$OUT_PWD/../../src/debug/ -ldtkcore -lgtest
else:unix: LIBS += -L$$OUT_PWD/../../src/ -ldtkcore -lgtest
INCLUDEPATH += $$PWD/../../src
DEPENDPATH += $$PWD/../../src
unix:QMAKE_RPATHDIR += $$OUT_PWD/../../src
QMAKE_LFLAGS += -Wl,--export-dynamic
SOURCES += \
$$PWD/../../src/ddesktopentry.cpp \
ut_ddesktopentrytest.cpp

View File

@ -1,25 +0,0 @@
QT += testlib concurrent
QT -= gui
TEMPLATE = app
CONFIG += c++11
!isEmpty(DTK_STATIC_LIB){
DEFINES += DTK_STATIC_LIB
}
load(dtk_testcase)
win32:CONFIG(release, debug|release): LIBS += -L$$OUT_PWD/../../src/release/ -ldtkcore
else:win32:CONFIG(debug, debug|release): LIBS += -L$$OUT_PWD/../../src/debug/ -ldtkcore
else:unix: LIBS += -L$$OUT_PWD/../../src/ -ldtkcore
INCLUDEPATH += $$PWD/../../src
DEPENDPATH += $$PWD/../../src
QMAKE_RPATHDIR += $$OUT_PWD/../../src
QMAKE_LFLAGS += -Wl,--export-dynamic
SOURCES += \
$$PWD/../../src/util/dthreadutils.cpp \
ut_dthreadutils.cpp

View File

@ -1,54 +0,0 @@
QT += testlib dbus
QT -= gui
TEMPLATE = app
CONFIG += c++11
!isEmpty(DTK_STATIC_LIB){
DEFINES += DTK_STATIC_LIB
}
# 使用 tmp 目录下的 os-version
DEFINES += OS_VERSION_TEST_FILE=\\\"/tmp/etc/os-version\\\"
load(dtk_testcase)
SOURCES += \
$$PWD/../../src/util/dtimeunitformatter.cpp \
$$PWD/../../src/util/ddisksizeformatter.cpp \
$$PWD/../../src/log/LogManager.cpp \
$$PWD/../../src/filesystem/dpathbuf.cpp \
$$PWD/../../src/util/ddbussender.cpp \
$$PWD/../../src/settings/dsettings.cpp \
$$PWD/../../src/settings/dsettingsgroup.cpp \
$$PWD/../../src/settings/dsettingsoption.cpp \
$$PWD/../../src/dsysinfo.cpp \
main.cpp \
ut_dutil.cpp \
ut_singleton.cpp
HEADERS += \
$$PWD/../../src/util/dtimeunitformatter.h \
$$PWD/../../src/util/ddisksizeformatter.h \
$$PWD/../../src/log/LogManager.h \
$$PWD/../../src/filesystem/dpathbuf.h \
$$PWD/../../src/util/ddbussender.h \
$$PWD/../../src/settings/dsettings.h \
$$PWD/../../src/settings/dsettingsgroup.h \
$$PWD/../../src/settings/dsettingsoption.h \
$$PWD/../../src/dsysinfo.h \
$$PWD/../../src/base/dsingleton.h \
ut_dutil.h \
ut_singleton.h
win32:CONFIG(release, debug|release): LIBS += -L$$OUT_PWD/../../src/release/ -ldtkcore -lgtest
else:win32:CONFIG(debug, debug|release): LIBS += -L$$OUT_PWD/../../src/debug/ -ldtkcore -lgtest
else:unix: LIBS += -L$$OUT_PWD/../../src/ -ldtkcore -lgtest
INCLUDEPATH += \
$$PWD/../../src \
$$PWD/../../src/log
DEPENDPATH += $$PWD/../../src
QMAKE_RPATHDIR += $$PWD/../../src
RESOURCES += \
data.qrc

View File

@ -1,31 +0,0 @@
QT += testlib
QT -= gui
TEMPLATE = app
CONFIG += c++11
# TODO: vtabhook release test failed
QMAKE_CXXFLAGS_RELEASE -= -O2
!isEmpty(DTK_STATIC_LIB){
DEFINES += DTK_STATIC_LIB
}
load(dtk_testcase)
win32:CONFIG(release, debug|release): LIBS += -L$$OUT_PWD/../../src/release/ -ldtkcore -lgtest
else:win32:CONFIG(debug, debug|release): LIBS += -L$$OUT_PWD/../../src/debug/ -ldtkcore -lgtest
else:unix: LIBS += -L$$OUT_PWD/../../src/ -ldtkcore -lgtest -ldl
INCLUDEPATH += $$PWD/../../src
DEPENDPATH += $$PWD/../../src
QMAKE_RPATHDIR += $$OUT_PWD/../../src
QMAKE_LFLAGS += -Wl,--export-dynamic
HEADERS += \
$$PWD/../../src/util/dvtablehook.h
SOURCES += \
$$PWD/../../src/util/dvtablehook.cpp \
ut_dvtablehook.cpp

View File

@ -4,19 +4,6 @@
#
# SPDX-License-Identifier: LGPL-3.0-or-later
BUILD_DIR=`pwd`/../build/tests/
HTML_DIR=${BUILD_DIR}/html
XML_DIR=${BUILD_DIR}/report
#EXTRACT_ARGS="src"
export ASAN_OPTIONS=halt_on_error=0
TESTARGS="--gtest_output=xml:${XML_DIR}/report_dtkcore.xml" make check -j$(nproc)
#!/bin/bash
# SPDX-FileCopyrightText: 2022 UnionTech Software Technology Co., Ltd.
#
# SPDX-License-Identifier: LGPL-3.0-or-later
BUILD_DIR=`pwd`/../build/tests/
HTML_DIR=${BUILD_DIR}/html
XML_DIR=${BUILD_DIR}/report
@ -28,11 +15,11 @@ cd ..
cmake -Bbuild -DCMAKE_BUILD_TYPE=Debug
cmake --build build --target test -j$(nproc)
cmake --build build --target ut-DtkCore -j$(nproc)
cd $BUILD_DIR
./ut-DtkCore
./ut-DtkCore --gtest_output=xml:${XML_DIR}/report_dtkcore.xml
lcov -d ./ -c -o coverage_all.info
#lcov --extract coverage_all.info $EXTRACT_ARGS --output-file coverage.info

View File

@ -1,89 +0,0 @@
TEMPLATE = app
QT += core dbus xml testlib concurrent
CONFIG += thread c++11 link_pkgconfig
CONFIG -= app_bundle
QMAKE_LFLAGS += -Wl,--export-dynamic
CONFIG(debug, debug|release) {
LIBS += -lgtest -lgmock
QMAKE_CXXFLAGS += -g -Wall -fprofile-arcs -ftest-coverage -fsanitize=address -fsanitize-recover=address -O2
QMAKE_LFLAGS += -g -Wall -fprofile-arcs -ftest-coverage -fsanitize=address -fsanitize-recover=address -O2
QMAKE_CXX += -g -fprofile-arcs -ftest-coverage -fsanitize=address -fsanitize-recover=address -O2
}
load(dtk_testcase)
# 指定moc文件生成目录和src一样
MOC_DIR=$$OUT_PWD/../src
# 使用 tmp 目录下的 os-version
DEFINES += OS_VERSION_TEST_FILE=\\\"/tmp/etc/os-version\\\"
DEPENDPATH += $$PWD/../src
unix: {
QMAKE_RPATHDIR += $$OUT_PWD/../src
LIBS += -lgtest
# for dlsym
LIBS += -ldl
# TODO: vtabhook release test failed
QMAKE_CXXFLAGS_RELEASE -= -O2
}
INCLUDEPATH += \
$$PWD/../src \
$$PWD/../src/base \
$$PWD/../src/base/private \
$$PWD/../src/filesystem \
$$PWD/../src/log \
$$PWD/../src/settings \
$$PWD/../src/util \
$$PWD/../src/dci
include($$PWD/../src/base/base.pri)
include($$PWD/../src/filesystem/filesystem.pri)
include($$PWD/../src/log/log.pri)
include($$PWD/../src/settings/settings.pri)
include($$PWD/../src/util/util.pri)
include($$PWD/../src/dci/dci.pri)
HEADERS += $$PWD/ut_*.h \
$$PWD/../src/dtkcore_global.h \
$$PWD/../src/dsysinfo.h \
$$PWD/../src/dsecurestring.h \
$$PWD/../src/ddesktopentry.h \
$$PWD/../src/dconfig.h \
$$PWD/../src/dsgapplication.h
SOURCES += $$PWD/*.cpp \
$$PWD/../src/dsysinfo.cpp \
$$PWD/../src/dsecurestring.cpp \
$$PWD/../src/ddesktopentry.cpp \
$$PWD/../src/dconfig.cpp \
$$PWD/../src/dsgapplication.cpp
linux: {
!isEmpty(D_DSG_APP_DATA_FALLBACK): DEFINES += D_DSG_APP_DATA_FALLBACK=\\\"$$D_DSG_APP_DATA_FALLBACK\\\"
HEADERS += \
$$PWD/../src/dconfigfile.h
SOURCES += \
$$PWD/../src/dconfigfile.cpp
QT += dbus
config.files = $$PWD/../src/dbus/org.desktopspec.ConfigManager.xml
config.header_flags += -c DSGConfig -N
config.source_flags += -c DSGConfig -N
manager.files = $$PWD/../src/dbus/org.desktopspec.ConfigManager.Manager.xml
manager.header_flags += -c DSGConfigManager -N
manager.source_flags += -c DSGConfigManager -N
DBUS_INTERFACES += config manager
}
RESOURCES += data.qrc

View File

@ -1,4 +0,0 @@
TEMPLATE = subdirs
!mac:!win*: SUBDIRS += settings deepin-os-release qdbusxml2cpp
SUBDIRS += dci