aboutsummaryrefslogtreecommitdiff
path: root/src/kconfig_compiler
diff options
context:
space:
mode:
authorAndreas Cord-Landwehr <cordlandwehr@kde.org>2020-03-22 12:38:38 +0100
committerAndreas Cord-Landwehr <cordlandwehr@kde.org>2020-03-22 12:46:41 +0100
commit43d4f1276b3afe259907add9b458f15252514fa4 (patch)
tree58407e00fd3c70b4ca9a10b645f7c8b3fd1cec49 /src/kconfig_compiler
parent67630e49d69c03eddbb9c291ebc075b342ebfae5 (diff)
downloadkconfig-43d4f1276b3afe259907add9b458f15252514fa4.tar.gz
kconfig-43d4f1276b3afe259907add9b458f15252514fa4.tar.bz2
KConfig: Convert to SPDX license statements
Summary: Convert license headers to SPDX statements and add license files as required by REUSE specification. Reviewers: cgiboudeaux Reviewed By: cgiboudeaux Subscribers: ognarb, cgiboudeaux, kde-frameworks-devel Tags: #frameworks Maniphest Tasks: T11550 Differential Revision: https://phabricator.kde.org/D27601
Diffstat (limited to 'src/kconfig_compiler')
-rw-r--r--src/kconfig_compiler/KConfigCodeGeneratorBase.cpp34
-rw-r--r--src/kconfig_compiler/KConfigCodeGeneratorBase.h32
-rw-r--r--src/kconfig_compiler/KConfigCommonStructs.h38
-rw-r--r--src/kconfig_compiler/KConfigHeaderGenerator.cpp38
-rw-r--r--src/kconfig_compiler/KConfigHeaderGenerator.h30
-rw-r--r--src/kconfig_compiler/KConfigParameters.cpp30
-rw-r--r--src/kconfig_compiler/KConfigParameters.h27
-rw-r--r--src/kconfig_compiler/KConfigSourceGenerator.cpp42
-rw-r--r--src/kconfig_compiler/KConfigSourceGenerator.h28
-rw-r--r--src/kconfig_compiler/KConfigXmlParser.cpp47
-rw-r--r--src/kconfig_compiler/KConfigXmlParser.h29
-rw-r--r--src/kconfig_compiler/kcfg.xsd10
-rw-r--r--src/kconfig_compiler/kconfig_compiler.cpp27
13 files changed, 131 insertions, 281 deletions
diff --git a/src/kconfig_compiler/KConfigCodeGeneratorBase.cpp b/src/kconfig_compiler/KConfigCodeGeneratorBase.cpp
index efe4fb7e..dcbb30c3 100644
--- a/src/kconfig_compiler/KConfigCodeGeneratorBase.cpp
+++ b/src/kconfig_compiler/KConfigCodeGeneratorBase.cpp
@@ -1,26 +1,14 @@
-/* m_this file is part of the KDE libraries
- Copyright (C) 2020 Tomaz Cananbrava (tcanabrava@kde.org)
- Copyright (c) 2003 Cornelius Schumacher <schumacher@kde.org>
- Copyright (c) 2003 Waldo Bastian <bastian@kde.org>
- Copyright (c) 2003 Zack Rusin <zack@kde.org>
- Copyright (c) 2006 Michaël Larouche <michael.larouche@kdemail.net>
- Copyright (c) 2008 Allen Winter <winter@kde.org>
- Copyright (C) 2020 Tomaz Cananbrava (tcanabrava@kde.org)
-
- m_this library is free software; you can redistribute it and/or
- modify it under the terms of the GNU Library General Public
- License as published by the Free Software Foundation; either
- version 2 of the License, or (at your option) any later version.
-
- m_this library 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
- Library General Public License for more details.
-
- You should have received a copy of the GNU Library General Public License
- along with this library; see the file COPYING.LIB. If not, write to
- the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
- Boston, MA 02110-1301, USA.
+/*
+ This file is part of the KDE libraries.
+
+ SPDX-FileCopyrightText: 2003 Cornelius Schumacher <schumacher@kde.org>
+ SPDX-FileCopyrightText: 2003 Waldo Bastian <bastian@kde.org>
+ SPDX-FileCopyrightText: 2003 Zack Rusin <zack@kde.org>
+ SPDX-FileCopyrightText: 2006 Michaël Larouche <michael.larouche@kdemail.net>
+ SPDX-FileCopyrightText: 2008 Allen Winter <winter@kde.org>
+ SPDX-FileCopyrightText: 2020 Tomaz Cananbrava <tcanabrava@kde.org>
+
+ SPDX-License-Identifier: LGPL-2.0-or-later
*/
#include "KConfigCodeGeneratorBase.h"
diff --git a/src/kconfig_compiler/KConfigCodeGeneratorBase.h b/src/kconfig_compiler/KConfigCodeGeneratorBase.h
index 0c815c9b..6059e26f 100644
--- a/src/kconfig_compiler/KConfigCodeGeneratorBase.h
+++ b/src/kconfig_compiler/KConfigCodeGeneratorBase.h
@@ -1,28 +1,14 @@
/*
This file is part of KDE.
- Copyright (C) 2020 Tomaz Cananbrava (tcanabrava@kde.org)
- Copyright (c) 2003 Cornelius Schumacher <schumacher@kde.org>
- Copyright (c) 2003 Waldo Bastian <bastian@kde.org>
- Copyright (c) 2003 Zack Rusin <zack@kde.org>
- Copyright (c) 2006 Michaël Larouche <michael.larouche@kdemail.net>
- Copyright (c) 2008 Allen Winter <winter@kde.org>
- Copyright (C) 2020 Tomaz Cananbrava (tcanabrava@kde.org)
-
- This library is free software; you can redistribute it and/or
- modify it under the terms of the GNU Library General Public
- License as published by the Free Software Foundation; either
- version 2 of the License, or (at your option) any later version.
-
- This library 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
- Library General Public License for more details.
-
- You should have received a copy of the GNU Library General Public License
- along with this library; see the file COPYING.LIB. If not, write to
- the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
- Boston, MA 02110-1301, USA.
+ SPDX-FileCopyrightText: 2003 Cornelius Schumacher <schumacher@kde.org>
+ SPDX-FileCopyrightText: 2003 Waldo Bastian <bastian@kde.org>
+ SPDX-FileCopyrightText: 2003 Zack Rusin <zack@kde.org>
+ SPDX-FileCopyrightText: 2006 Michaël Larouche <michael.larouche@kdemail.net>
+ SPDX-FileCopyrightText: 2008 Allen Winter <winter@kde.org>
+ SPDX-FileCopyrightText: 2020 Tomaz Cananbrava <tcanabrava@kde.org>
+
+ SPDX-License-Identifier: LGPL-2.0-or-later
*/
#ifndef KCONFIGCODEGENERATORBASE_H
@@ -67,7 +53,7 @@ public:
// start a block scope `{` and increase indentation level.
void endScope(ScopeFinalizer finalizer = None);
-
+
// end a block scope `}` and decrease indentation level.
void startScope();
diff --git a/src/kconfig_compiler/KConfigCommonStructs.h b/src/kconfig_compiler/KConfigCommonStructs.h
index fef45a9f..70249d47 100644
--- a/src/kconfig_compiler/KConfigCommonStructs.h
+++ b/src/kconfig_compiler/KConfigCommonStructs.h
@@ -1,26 +1,14 @@
-/* This file is part of the KDE libraries
- Copyright (C) 2020 Tomaz Cananbrava (tcanabrava@kde.org)
- Copyright (c) 2003 Cornelius Schumacher <schumacher@kde.org>
- Copyright (c) 2003 Waldo Bastian <bastian@kde.org>
- Copyright (c) 2003 Zack Rusin <zack@kde.org>
- Copyright (c) 2006 Michaël Larouche <michael.larouche@kdemail.net>
- Copyright (c) 2008 Allen Winter <winter@kde.org>
- Copyright (C) 2020 Tomaz Cananbrava (tcanabrava@kde.org)
-
- This library is free software; you can redistribute it and/or
- modify it under the terms of the GNU Library General Public
- License as published by the Free Software Foundation; either
- version 2 of the License, or (at your option) any later version.
-
- This library 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
- Library General Public License for more details.
-
- You should have received a copy of the GNU Library General Public License
- along with this library; see the file COPYING.LIB. If not, write to
- the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
- Boston, MA 02110-1301, USA.
+/*
+ This file is part of the KDE libraries.
+
+ SPDX-FileCopyrightText: 2003 Cornelius Schumacher <schumacher@kde.org>
+ SPDX-FileCopyrightText: 2003 Waldo Bastian <bastian@kde.org>
+ SPDX-FileCopyrightText: 2003 Zack Rusin <zack@kde.org>
+ SPDX-FileCopyrightText: 2006 Michaël Larouche <michael.larouche@kdemail.net>
+ SPDX-FileCopyrightText: 2008 Allen Winter <winter@kde.org>
+ SPDX-FileCopyrightText: 2020 Tomaz Cananbrava <tcanabrava@kde.org>
+
+ SPDX-License-Identifier: LGPL-2.0-or-later
*/
#ifndef KCONFIGCOMMONSTRUCTS_H
@@ -174,7 +162,7 @@ QString itemDeclaration(const CfgEntry *e, const KConfigParameters &cfg);
QString translatedString(
const KConfigParameters &cfg,
- const QString &string,
+ const QString &string,
const QString &context = QString(),
const QString &param = QString(),
const QString &paramValue = QString());
@@ -197,7 +185,7 @@ QString newInnerItem(
QString userTextsFunctions(
const CfgEntry *e,
const KConfigParameters &cfg,
- QString itemVarStr = QString(),
+ QString itemVarStr = QString(),
const QString &i = QString());
QString paramString(const QString &s, const CfgEntry *e, int i);
diff --git a/src/kconfig_compiler/KConfigHeaderGenerator.cpp b/src/kconfig_compiler/KConfigHeaderGenerator.cpp
index 84f89e26..ec353158 100644
--- a/src/kconfig_compiler/KConfigHeaderGenerator.cpp
+++ b/src/kconfig_compiler/KConfigHeaderGenerator.cpp
@@ -1,26 +1,14 @@
-/* This file is part of the KDE libraries
- Copyright (C) 2020 Tomaz Cananbrava (tcanabrava@kde.org)
- Copyright (c) 2003 Cornelius Schumacher <schumacher@kde.org>
- Copyright (c) 2003 Waldo Bastian <bastian@kde.org>
- Copyright (c) 2003 Zack Rusin <zack@kde.org>
- Copyright (c) 2006 Michaël Larouche <michael.larouche@kdemail.net>
- Copyright (c) 2008 Allen Winter <winter@kde.org>
- Copyright (C) 2020 Tomaz Cananbrava (tcanabrava@kde.org)
-
- This library is free software; you can redistribute it and/or
- modify it under the terms of the GNU Library General Public
- License as published by the Free Software Foundation; either
- version 2 of the License, or (at your option) any later version.
-
- This library 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
- Library General Public License for more details.
-
- You should have received a copy of the GNU Library General Public License
- along with this library; see the file COPYING.LIB. If not, write to
- the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
- Boston, MA 02110-1301, USA.
+/*
+ This file is part of the KDE libraries.
+
+ SPDX-FileCopyrightText: 2003 Cornelius Schumacher <schumacher@kde.org>
+ SPDX-FileCopyrightText: 2003 Waldo Bastian <bastian@kde.org>
+ SPDX-FileCopyrightText: 2003 Zack Rusin <zack@kde.org>
+ SPDX-FileCopyrightText: 2006 Michaël Larouche <michael.larouche@kdemail.net>
+ SPDX-FileCopyrightText: 2008 Allen Winter <winter@kde.org>
+ SPDX-FileCopyrightText: 2020 Tomaz Cananbrava <tcanabrava@kde.org>
+
+ SPDX-License-Identifier: LGPL-2.0-or-later
*/
#include "KConfigHeaderGenerator.h"
@@ -39,7 +27,7 @@ KConfigHeaderGenerator::KConfigHeaderGenerator(
{
}
-void KConfigHeaderGenerator::start()
+void KConfigHeaderGenerator::start()
{
KConfigCodeGeneratorBase::start();
startHeaderGuards();
@@ -156,7 +144,7 @@ void KConfigHeaderGenerator::startHeaderGuards()
stream() << '\n';
}
-void KConfigHeaderGenerator::endHeaderGuards()
+void KConfigHeaderGenerator::endHeaderGuards()
{
stream() << '\n';
stream() << "#endif";
diff --git a/src/kconfig_compiler/KConfigHeaderGenerator.h b/src/kconfig_compiler/KConfigHeaderGenerator.h
index d780b850..b93a47db 100644
--- a/src/kconfig_compiler/KConfigHeaderGenerator.h
+++ b/src/kconfig_compiler/KConfigHeaderGenerator.h
@@ -1,28 +1,14 @@
/*
This file is part of KDE.
- Copyright (C) 2020 Tomaz Cananbrava (tcanabrava@kde.org)
- Copyright (c) 2003 Cornelius Schumacher <schumacher@kde.org>
- Copyright (c) 2003 Waldo Bastian <bastian@kde.org>
- Copyright (c) 2003 Zack Rusin <zack@kde.org>
- Copyright (c) 2006 Michaël Larouche <michael.larouche@kdemail.net>
- Copyright (c) 2008 Allen Winter <winter@kde.org>
- Copyright (C) 2020 Tomaz Cananbrava (tcanabrava@kde.org)
-
- This library is free software; you can redistribute it and/or
- modify it under the terms of the GNU Library General Public
- License as published by the Free Software Foundation; either
- version 2 of the License, or (at your option) any later version.
-
- This library 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
- Library General Public License for more details.
-
- You should have received a copy of the GNU Library General Public License
- along with this library; see the file COPYING.LIB. If not, write to
- the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
- Boston, MA 02110-1301, USA.
+ SPDX-FileCopyrightText: 2003 Cornelius Schumacher <schumacher@kde.org>
+ SPDX-FileCopyrightText: 2003 Waldo Bastian <bastian@kde.org>
+ SPDX-FileCopyrightText: 2003 Zack Rusin <zack@kde.org>
+ SPDX-FileCopyrightText: 2006 Michaël Larouche <michael.larouche@kdemail.net>
+ SPDX-FileCopyrightText: 2008 Allen Winter <winter@kde.org>
+ SPDX-FileCopyrightText: 2020 Tomaz Cananbrava <tcanabrava@kde.org>
+
+ SPDX-License-Identifier: LGPL-2.0-or-later
*/
#ifndef KCONFIGHEADERGENERATOR_H
diff --git a/src/kconfig_compiler/KConfigParameters.cpp b/src/kconfig_compiler/KConfigParameters.cpp
index e715818a..7999475e 100644
--- a/src/kconfig_compiler/KConfigParameters.cpp
+++ b/src/kconfig_compiler/KConfigParameters.cpp
@@ -1,26 +1,14 @@
-/* This file is part of the KDE libraries
- Copyright (C) 2020 Tomaz Cananbrava (tcanabrava@kde.org)
- Copyright (c) 2003 Cornelius Schumacher <schumacher@kde.org>
- Copyright (c) 2003 Waldo Bastian <bastian@kde.org>
- Copyright (c) 2003 Zack Rusin <zack@kde.org>
- Copyright (c) 2006 Michaël Larouche <michael.larouche@kdemail.net>
- Copyright (c) 2008 Allen Winter <winter@kde.org>
- Copyright (C) 2020 Tomaz Cananbrava (tcanabrava@kde.org)
+/*
+ This file is part of the KDE libraries.
- This library is free software; you can redistribute it and/or
- modify it under the terms of the GNU Library General Public
- License as published by the Free Software Foundation; either
- version 2 of the License, or (at your option) any later version.
+ SPDX-FileCopyrightText: 2003 Cornelius Schumacher <schumacher@kde.org>
+ SPDX-FileCopyrightText: 2003 Waldo Bastian <bastian@kde.org>
+ SPDX-FileCopyrightText: 2003 Zack Rusin <zack@kde.org>
+ SPDX-FileCopyrightText: 2006 Michaël Larouche <michael.larouche@kdemail.net>
+ SPDX-FileCopyrightText: 2008 Allen Winter <winter@kde.org>
+ SPDX-FileCopyrightText: 2020 Tomaz Cananbrava <tcanabrava@kde.org>
- This library 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
- Library General Public License for more details.
-
- You should have received a copy of the GNU Library General Public License
- along with this library; see the file COPYING.LIB. If not, write to
- the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
- Boston, MA 02110-1301, USA.
+ SPDX-License-Identifier: LGPL-2.0-or-later
*/
#include "KConfigParameters.h"
diff --git a/src/kconfig_compiler/KConfigParameters.h b/src/kconfig_compiler/KConfigParameters.h
index b114dcc9..1984bb96 100644
--- a/src/kconfig_compiler/KConfigParameters.h
+++ b/src/kconfig_compiler/KConfigParameters.h
@@ -1,27 +1,14 @@
/*
This file is part of KDE.
- Copyright (C) 2020 Tomaz Cananbrava (tcanabrava@kde.org)
- Copyright (c) 2003 Cornelius Schumacher <schumacher@kde.org>
- Copyright (c) 2003 Waldo Bastian <bastian@kde.org>
- Copyright (c) 2003 Zack Rusin <zack@kde.org>
- Copyright (c) 2006 Michaël Larouche <michael.larouche@kdemail.net>
- Copyright (c) 2008 Allen Winter <winter@kde.org>
- Copyright (C) 2020 Tomaz Cananbrava (tcanabrava@kde.org)
- This library is free software; you can redistribute it and/or
- modify it under the terms of the GNU Library General Public
- License as published by the Free Software Foundation; either
- version 2 of the License, or (at your option) any later version.
+ SPDX-FileCopyrightText: 2003 Cornelius Schumacher <schumacher@kde.org>
+ SPDX-FileCopyrightText: 2003 Waldo Bastian <bastian@kde.org>
+ SPDX-FileCopyrightText: 2003 Zack Rusin <zack@kde.org>
+ SPDX-FileCopyrightText: 2006 Michaël Larouche <michael.larouche@kdemail.net>
+ SPDX-FileCopyrightText: 2008 Allen Winter <winter@kde.org>
+ SPDX-FileCopyrightText: 2020 Tomaz Cananbrava <tcanabrava@kde.org>
- This library 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
- Library General Public License for more details.
-
- You should have received a copy of the GNU Library General Public License
- along with this library; see the file COPYING.LIB. If not, write to
- the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
- Boston, MA 02110-1301, USA.
+ SPDX-License-Identifier: LGPL-2.0-or-later
*/
#ifndef KCONFIGXTPARAMETERS_H
diff --git a/src/kconfig_compiler/KConfigSourceGenerator.cpp b/src/kconfig_compiler/KConfigSourceGenerator.cpp
index 3e8a8156..0da8d4df 100644
--- a/src/kconfig_compiler/KConfigSourceGenerator.cpp
+++ b/src/kconfig_compiler/KConfigSourceGenerator.cpp
@@ -1,26 +1,14 @@
-/* This file is part of the KDE libraries
- Copyright (C) 2020 Tomaz Cananbrava (tcanabrava@kde.org)
- Copyright (c) 2003 Cornelius Schumacher <schumacher@kde.org>
- Copyright (c) 2003 Waldo Bastian <bastian@kde.org>
- Copyright (c) 2003 Zack Rusin <zack@kde.org>
- Copyright (c) 2006 Michaël Larouche <michael.larouche@kdemail.net>
- Copyright (c) 2008 Allen Winter <winter@kde.org>
- Copyright (C) 2020 Tomaz Cananbrava (tcanabrava@kde.org)
-
- This library is free software; you can redistribute it and/or
- modify it under the terms of the GNU Library General Public
- License as published by the Free Software Foundation; either
- version 2 of the License, or (at your option) any later version.
-
- This library 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
- Library General Public License for more details.
-
- You should have received a copy of the GNU Library General Public License
- along with this library; see the file COPYING.LIB. If not, write to
- the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
- Boston, MA 02110-1301, USA.
+/*
+ This file is part of the KDE libraries
+
+ SPDX-FileCopyrightText: 2003 Cornelius Schumacher <schumacher@kde.org>
+ SPDX-FileCopyrightText: 2003 Waldo Bastian <bastian@kde.org>
+ SPDX-FileCopyrightText: 2003 Zack Rusin <zack@kde.org>
+ SPDX-FileCopyrightText: 2006 Michaël Larouche <michael.larouche@kdemail.net>
+ SPDX-FileCopyrightText: 2008 Allen Winter <winter@kde.org>
+ SPDX-FileCopyrightText: 2020 Tomaz Cananbrava <tcanabrava@kde.org>
+
+ SPDX-License-Identifier: LGPL-2.0-or-later
*/
#include "KConfigSourceGenerator.h"
@@ -36,7 +24,7 @@ KConfigSourceGenerator::KConfigSourceGenerator(
{
}
-void KConfigSourceGenerator::start()
+void KConfigSourceGenerator::start()
{
KConfigCodeGeneratorBase::start();
stream() << '\n';
@@ -208,7 +196,7 @@ void KConfigSourceGenerator::createPreamble()
if (entry->paramValues.isEmpty()) {
continue;
}
-
+
cppPreamble += QStringLiteral("const char* const ") + cfg().className + QStringLiteral("::") + enumName(entry->param);
cppPreamble += cfg().globalEnums
? QStringLiteral("ToString[] = { \"") + entry->paramValues.join(QStringLiteral("\", \"")) + QStringLiteral("\" };\n")
@@ -284,7 +272,7 @@ void KConfigSourceGenerator::createEnums(const CfgEntry *entry)
return;
}
stream() << " QList<" << cfg().inherits << "::ItemEnum::Choice> values" << entry->name << ";\n";
-
+
for (const auto &choice : qAsConst(entry->choices.choices)) {
stream() << " {\n";
stream() << " " << cfg().inherits << "::ItemEnum::Choice choice;\n";
@@ -668,7 +656,7 @@ void KConfigSourceGenerator::createNonModifyingSignalsHelper()
endScope();
}
-void KConfigSourceGenerator::createSignalFlagsHandler()
+void KConfigSourceGenerator::createSignalFlagsHandler()
{
if (parseResult.signalList.isEmpty()) {
return;
diff --git a/src/kconfig_compiler/KConfigSourceGenerator.h b/src/kconfig_compiler/KConfigSourceGenerator.h
index 1e1ffc97..76897f39 100644
--- a/src/kconfig_compiler/KConfigSourceGenerator.h
+++ b/src/kconfig_compiler/KConfigSourceGenerator.h
@@ -1,28 +1,14 @@
/*
This file is part of KDE.
- Copyright (C) 2020 Tomaz Cananbrava (tcanabrava@kde.org)
- Copyright (c) 2003 Cornelius Schumacher <schumacher@kde.org>
- Copyright (c) 2003 Waldo Bastian <bastian@kde.org>
- Copyright (c) 2003 Zack Rusin <zack@kde.org>
- Copyright (c) 2006 Michaël Larouche <michael.larouche@kdemail.net>
- Copyright (c) 2008 Allen Winter <winter@kde.org>
- Copyright (C) 2020 Tomaz Cananbrava (tcanabrava@kde.org)
+ SPDX-FileCopyrightText: 2003 Cornelius Schumacher <schumacher@kde.org>
+ SPDX-FileCopyrightText: 2003 Waldo Bastian <bastian@kde.org>
+ SPDX-FileCopyrightText: 2003 Zack Rusin <zack@kde.org>
+ SPDX-FileCopyrightText: 2006 Michaël Larouche <michael.larouche@kdemail.net>
+ SPDX-FileCopyrightText: 2008 Allen Winter <winter@kde.org>
+ SPDX-FileCopyrightText: 2020 Tomaz Cananbrava <tcanabrava@kde.org>
- This library is free software; you can redistribute it and/or
- modify it under the terms of the GNU Library General Public
- License as published by the Free Software Foundation; either
- version 2 of the License, or (at your option) any later version.
-
- This library 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
- Library General Public License for more details.
-
- You should have received a copy of the GNU Library General Public License
- along with this library; see the file COPYING.LIB. If not, write to
- the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
- Boston, MA 02110-1301, USA.
+ SPDX-License-Identifier: LGPL-2.0-or-later
*/
#ifndef KCONFIGSOURCEGENERATOR_H
diff --git a/src/kconfig_compiler/KConfigXmlParser.cpp b/src/kconfig_compiler/KConfigXmlParser.cpp
index 045018de..dcbe869f 100644
--- a/src/kconfig_compiler/KConfigXmlParser.cpp
+++ b/src/kconfig_compiler/KConfigXmlParser.cpp
@@ -1,25 +1,14 @@
-/* This file is part of the KDE libraries
- Copyright (c) 2003 Cornelius Schumacher <schumacher@kde.org>
- Copyright (c) 2003 Waldo Bastian <bastian@kde.org>
- Copyright (c) 2003 Zack Rusin <zack@kde.org>
- Copyright (c) 2006 Michaël Larouche <michael.larouche@kdemail.net>
- Copyright (c) 2008 Allen Winter <winter@kde.org>
- Copyright (C) 2020 Tomaz Cananbrava (tcanabrava@kde.org)
-
- This library is free software; you can redistribute it and/or
- modify it under the terms of the GNU Library General Public
- License as published by the Free Software Foundation; either
- version 2 of the License, or (at your option) any later version.
-
- This library 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
- Library General Public License for more details.
-
- You should have received a copy of the GNU Library General Public License
- along with this library; see the file COPYING.LIB. If not, write to
- the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
- Boston, MA 02110-1301, USA.
+/*
+ This file is part of the KDE libraries
+
+ SPDX-FileCopyrightText: 2003 Cornelius Schumacher <schumacher@kde.org>
+ SPDX-FileCopyrightText: 2003 Waldo Bastian <bastian@kde.org>
+ SPDX-FileCopyrightText: 2003 Zack Rusin <zack@kde.org>
+ SPDX-FileCopyrightText: 2006 Michaël Larouche <michael.larouche@kdemail.net>
+ SPDX-FileCopyrightText: 2008 Allen Winter <winter@kde.org>
+ SPDX-FileCopyrightText: 2020 Tomaz Cananbrava <tcanabrava@kde.org>
+
+ SPDX-License-Identifier: LGPL-2.0-or-later
*/
#include "KConfigXmlParser.h"
@@ -133,12 +122,12 @@ void KConfigXmlParser::readParameterFromEntry(CfgEntry &readEntry, const QDomEle
{
readEntry.param = e.attribute(QStringLiteral("name"));
readEntry.paramType = e.attribute(QStringLiteral("type"));
-
+
if (readEntry.param.isEmpty()) {
std::cerr << "Parameter must have a name: " << qPrintable(dumpNode(e)) << std::endl;
exit (1);
}
-
+
if (readEntry.paramType.isEmpty()) {
std::cerr << "Parameter must have a type: " << qPrintable(dumpNode(e)) << std::endl;
exit(1);
@@ -220,7 +209,7 @@ void KConfigXmlParser::readChoicesFromEntry(CfgEntry &readEntry, const QDomEleme
}
chlist.append(choice);
}
-
+
QString name = e.attribute(QStringLiteral("name"));
QString prefix = e.attribute(QStringLiteral("prefix"));
@@ -406,7 +395,7 @@ CfgEntry *KConfigXmlParser::parseEntry(const QString &group, const QDomElement &
preProcessDefault(readEntry.defaultValue, readEntry.name, readEntry.type, readEntry.choices, readEntry.code, cfg);
}
- // TODO: Try to Just return the CfgEntry we populated instead of
+ // TODO: Try to Just return the CfgEntry we populated instead of
// creating another one to fill the code.
CfgEntry *result = new CfgEntry();
result->group = readEntry.group;
@@ -446,7 +435,7 @@ KConfigXmlParser::KConfigXmlParser(const KConfigParameters &cfg, const QString &
{
mValidNameRegexp.setPattern(QRegularExpression::anchoredPattern(QStringLiteral("[a-zA-Z_][a-zA-Z0-9_]*")));
}
-
+
void KConfigXmlParser::start()
{
QFile input(mInputFileName);
@@ -459,7 +448,7 @@ void KConfigXmlParser::start()
std::cerr << "Parse error in " << qPrintable(mInputFileName) << ", line " << errorRow << ", col " << errorCol << ": " << qPrintable(errorMsg) << std::endl;
exit (1);
}
-
+
QDomElement cfgElement = doc.documentElement();
if (cfgElement.isNull()) {
std::cerr << "No document in kcfg file" << std::endl;
@@ -557,6 +546,6 @@ void KConfigXmlParser::readSignalTag(const QDomElement &e)
theSignal.label = e2.text();
}
}
-
+
mParseResult.signalList.append(theSignal);
}
diff --git a/src/kconfig_compiler/KConfigXmlParser.h b/src/kconfig_compiler/KConfigXmlParser.h
index 5dbd2745..fa46e4b9 100644
--- a/src/kconfig_compiler/KConfigXmlParser.h
+++ b/src/kconfig_compiler/KConfigXmlParser.h
@@ -1,25 +1,14 @@
-/* This file is part of the KDE libraries
- Copyright (c) 2003 Cornelius Schumacher <schumacher@kde.org>
- Copyright (c) 2003 Waldo Bastian <bastian@kde.org>
- Copyright (c) 2003 Zack Rusin <zack@kde.org>
- Copyright (c) 2006 Michaël Larouche <michael.larouche@kdemail.net>
- Copyright (c) 2008 Allen Winter <winter@kde.org>
- Copyright (C) 2020 Tomaz Cananbrava (tcanabrava@kde.org)
+/*
+ This file is part of the KDE libraries
- This library is free software; you can redistribute it and/or
- modify it under the terms of the GNU Library General Public
- License as published by the Free Software Foundation; either
- version 2 of the License, or (at your option) any later version.
+ SPDX-FileCopyrightText: 2003 Cornelius Schumacher <schumacher@kde.org>
+ SPDX-FileCopyrightText: 2003 Waldo Bastian <bastian@kde.org>
+ SPDX-FileCopyrightText: 2003 Zack Rusin <zack@kde.org>
+ SPDX-FileCopyrightText: 2006 Michaël Larouche <michael.larouche@kdemail.net>
+ SPDX-FileCopyrightText: 2008 Allen Winter <winter@kde.org>
+ SPDX-FileCopyrightText: 2020 Tomaz Cananbrava <tcanabrava@kde.org>
- This library 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
- Library General Public License for more details.
-
- You should have received a copy of the GNU Library General Public License
- along with this library; see the file COPYING.LIB. If not, write to
- the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
- Boston, MA 02110-1301, USA.
+ SPDX-License-Identifier: LGPL-2.0-or-later
*/
#ifndef KCONFIGXMLPARSER_H
diff --git a/src/kconfig_compiler/kcfg.xsd b/src/kconfig_compiler/kcfg.xsd
index 11196d45..f28a70d7 100644
--- a/src/kconfig_compiler/kcfg.xsd
+++ b/src/kconfig_compiler/kcfg.xsd
@@ -11,11 +11,11 @@
<xsd:annotation>
<xsd:documentation>
- Copyright (c) 2003 Cornelius Schumacher &lt;schumacher@kde.org&gt;
- Copyright (c) 2003 Waldo Bastian &lt;bastian@kde.org&gt;
- Copyright (c) 2003 Zack Rusin &lt;zack@kde.org&gt;
- Copyright (c) 2004 Frans Englich &lt;frans.englich@telia.com&gt;
- Copyright (c) 2006 Michaël Larouche &lt;michael.larouche@kdemail.net&gt;
+ SPDX-FileCopyrightText: 2003 Cornelius Schumacher &lt;schumacher@kde.org&gt;
+ SPDX-FileCopyrightText: 2003 Waldo Bastian &lt;bastian@kde.org&gt;
+ SPDX-FileCopyrightText: 2003 Zack Rusin &lt;zack@kde.org&gt;
+ SPDX-FileCopyrightText: 2004 Frans Englich &lt;frans.englich@telia.com&gt;
+ SPDX-FileCopyrightText: 2006 Michaël Larouche &lt;michael.larouche@kdemail.net&gt;
Permission to use, copy, modify and distribute this DTD
and its accompanying documentation for any purpose and without fee
diff --git a/src/kconfig_compiler/kconfig_compiler.cpp b/src/kconfig_compiler/kconfig_compiler.cpp
index f4349420..605dd2b5 100644
--- a/src/kconfig_compiler/kconfig_compiler.cpp
+++ b/src/kconfig_compiler/kconfig_compiler.cpp
@@ -1,26 +1,13 @@
/*
This file is part of KDE.
- Copyright (c) 2003 Cornelius Schumacher <schumacher@kde.org>
- Copyright (c) 2003 Waldo Bastian <bastian@kde.org>
- Copyright (c) 2003 Zack Rusin <zack@kde.org>
- Copyright (c) 2006 Michaël Larouche <michael.larouche@kdemail.net>
- Copyright (c) 2008 Allen Winter <winter@kde.org>
-
- This library is free software; you can redistribute it and/or
- modify it under the terms of the GNU Library General Public
- License as published by the Free Software Foundation; either
- version 2 of the License, or (at your option) any later version.
-
- This library 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
- Library General Public License for more details.
-
- You should have received a copy of the GNU Library General Public License
- along with this library; see the file COPYING.LIB. If not, write to
- the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
- Boston, MA 02110-1301, USA.
+ SPDX-FileCopyrightText: 2003 Cornelius Schumacher <schumacher@kde.org>
+ SPDX-FileCopyrightText: 2003 Waldo Bastian <bastian@kde.org>
+ SPDX-FileCopyrightText: 2003 Zack Rusin <zack@kde.org>
+ SPDX-FileCopyrightText: 2006 Michaël Larouche <michael.larouche@kdemail.net>
+ SPDX-FileCopyrightText: 2008 Allen Winter <winter@kde.org>
+
+ SPDX-License-Identifier: LGPL-2.0-or-later
*/
// Compiling this file with this flag is just crazy