Commit 2bd37821 authored by Laurent Montel's avatar Laurent Montel 😁

Autogenerate debug file + create categories file

parent 421c7e9f
......@@ -39,6 +39,8 @@ include(KDEInstallDirs)
include(ECMInstallIcons)
include(KDECompilerSettings NO_POLICY_SCOPE)
include(KDECMakeSettings)
include(ECMQtDeclareLoggingCategory)
find_package(KF5KMahjongglib REQUIRED)
find_package(KF5KDEGames 4.9.0 REQUIRED)
......@@ -61,5 +63,6 @@ add_subdirectory(doc)
install(PROGRAMS org.kde.kshisen.desktop DESTINATION ${KDE_INSTALL_APPDIR})
install(FILES org.kde.kshisen.appdata.xml DESTINATION ${KDE_INSTALL_METAINFODIR})
install( FILES kshisen.categories DESTINATION ${KDE_INSTALL_CONFDIR} )
########### Display Summary ###############
feature_summary(WHAT ALL INCLUDE_QUIET_PACKAGES FATAL_ON_MISSING_REQUIRED_PACKAGES)
kshisen kdegames (kshisen) IDENTIFIER [KSHISEN_General]
......@@ -6,6 +6,8 @@ set(kshisen_SRCS
possiblemove.cpp
)
ecm_qt_declare_logging_category(kshisen_SRCS HEADER debug.h IDENTIFIER KSHISEN_General CATEGORY_NAME kshisen)
ki18n_wrap_ui(kshisen_SRCS settings.ui)
kconfig_add_kcfg_files(kshisen_SRCS prefs.kcfgc)
......
/***************************************************************************
* KShisen - A japanese game similar to mahjongg *
* Copyright 2016 Frederik Schwarzer <schwarzer@kde.org> *
* *
* This program is free software; you can redistribute it and/or modify *
* it under the terms of the GNU General Public License as published by *
* the Free Software Foundation; either version 2 of the License, or *
* (at your option) any later version. *
* *
* This program is distributed in the hope that it will be useful, *
* but WITHOUT ANY WARRANTY; without even the implied warranty of *
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
* GNU General Public License for more details. *
* *
* You should have received a copy of the GNU General Public License *
* along with this program. If not, see <http://www.gnu.org/licenses/>. *
***************************************************************************/
#ifndef KSHISEN_DEBUG_H
#define KSHISEN_DEBUG_H
// Qt
#include <QLoggingCategory>
namespace KShisen
{
Q_DECLARE_LOGGING_CATEGORY(KSHISEN_General)
// Use for debugging game mode.
//#define DEBUGGING
}
#endif // KSHISEN_DEBUG_H
......@@ -36,11 +36,6 @@
#include "app.h"
#include "debug.h"
namespace KShisen
{
Q_LOGGING_CATEGORY(KSHISEN_General, "kshisen")
} // namespace KShisen
static constexpr char description[] = I18N_NOOP("A KDE game similar to Mahjongg");
int main(int argc, char ** argv)
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment