fix: comprehensive boot warnings and exceptions — fixable silenced, unfixable diagnosed

Build system (5 gaps hardened):
- COOKBOOK_OFFLINE defaults to true (fork-mode)
- normalize_patch handles diff -ruN format
- New 'repo validate-patches' command (25/25 relibc patches)
- 14 patched Qt/Wayland/display recipes added to protected list
- relibc archive regenerated with current patch chain

Boot fixes (fixable):
- Full ISO EFI partition: 16 MiB → 1 MiB (matches mini, BIOS hardcoded 2 MiB offset)
- D-Bus system bus: absolute /usr/bin/dbus-daemon path (was skipped)
- redbear-sessiond: absolute /usr/bin/redbear-sessiond path (was skipped)
- daemon framework: silenced spurious INIT_NOTIFY warnings for oneshot_async services (P0-daemon-silence-init-notify.patch)
- udev-shim: demoted INIT_NOTIFY warning to INFO (expected for oneshot_async)
- relibc: comprehensive named semaphores (sem_open/close/unlink) replacing upstream todo!() stubs
- greeterd: Wayland socket timeout 15s → 30s (compositor DRM wait)
- greeter-ui: built and linked (header guard unification, sem_compat stubs removed)
- mc: un-ignored in both configs, fixed glib/libiconv/pcre2 transitive deps
- greeter config: removed stale keymapd dependency from display/greeter services
- prefix toolchain: relibc headers synced, _RELIBC_STDLIB_H guard unified

Unfixable (diagnosed, upstream):
- i2c-hidd: abort on no-I2C-hardware (QEMU) — process::exit → relibc abort
- kded6/greeter-ui: page fault 0x8 — Qt library null deref
- Thread panics fd != -1 — Rust std library on Redox
- DHCP timeout / eth0 MAC — QEMU user-mode networking
- hwrngd/thermald — no hardware RNG/thermal in VM
- live preload allocation — BIOS memory fragmentation, continues on demand
This commit is contained in:
2026-05-05 20:20:37 +01:00
parent a5f97b6632
commit f31522130f
81834 changed files with 11051982 additions and 108 deletions
@@ -0,0 +1,5 @@
# Copyright (C) 2022 The Qt Company Ltd.
# SPDX-License-Identifier: BSD-3-Clause
add_subdirectory(qsqlquery)
add_subdirectory(qsqlrecord)
@@ -0,0 +1,16 @@
# Copyright (C) 2022 The Qt Company Ltd.
# SPDX-License-Identifier: BSD-3-Clause
#####################################################################
## tst_bench_qsqlquery Binary:
#####################################################################
qt_internal_add_benchmark(tst_bench_qsqlquery
SOURCES
main.cpp
LIBRARIES
Qt::CorePrivate
Qt::Sql
Qt::SqlPrivate
Qt::Test
)
@@ -0,0 +1,118 @@
// Copyright (C) 2016 The Qt Company Ltd.
// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only
#include <QTest>
#include <QtSql/QtSql>
#include "../../../../auto/sql/kernel/qsqldatabase/tst_databases.h"
class tst_QSqlQuery : public QObject
{
Q_OBJECT
public:
using QObject::QObject;
public slots:
void initTestCase();
void cleanupTestCase();
void init();
void cleanup();
private slots:
void benchmark_data() { generic_data(); }
void benchmark();
void benchmarkSelectPrepared_data() { generic_data(); }
void benchmarkSelectPrepared();
private:
// returns all database connections
void generic_data(const QString &engine = QString());
tst_Databases dbs;
};
QTEST_MAIN(tst_QSqlQuery)
void tst_QSqlQuery::initTestCase()
{
dbs.open();
}
void tst_QSqlQuery::cleanupTestCase()
{
dbs.close();
}
void tst_QSqlQuery::init()
{
}
void tst_QSqlQuery::cleanup()
{
}
void tst_QSqlQuery::generic_data(const QString &engine)
{
if (dbs.fillTestTable(engine) == 0) {
if (engine.isEmpty())
QSKIP( "No database drivers are available in this Qt configuration");
else
QSKIP( (QString("No database drivers of type %1 are available in this Qt configuration").arg(engine)).toLocal8Bit());
}
}
void tst_QSqlQuery::benchmark()
{
QFETCH(QString, dbName);
QSqlDatabase db = QSqlDatabase::database(dbName);
CHECK_DATABASE(db);
QSqlQuery q(db);
TableScope ts(db, "benchmark", __FILE__);
QVERIFY_SQL(q, exec("CREATE TABLE " + ts.tableName() + "(\n"
"MainKey INT NOT NULL,\n"
"OtherTextCol VARCHAR(45) NOT NULL,\n"
"PRIMARY KEY(MainKey))"));
int i=1;
QBENCHMARK {
const QString num = QString::number(i);
QVERIFY_SQL(q, exec("INSERT INTO " + ts.tableName() + " VALUES(" + num + ", 'Value" + num + "')"));
i++;
}
}
void tst_QSqlQuery::benchmarkSelectPrepared()
{
QFETCH(QString, dbName);
QSqlDatabase db = QSqlDatabase::database(dbName);
CHECK_DATABASE(db);
QSqlQuery q(db);
TableScope ts(db, "benchmark", __FILE__);
QVERIFY_SQL(q, exec("CREATE TABLE " + ts.tableName() + "(id INT NOT NULL)"));
const int NUM_ROWS = 1000;
int expectedSum = 0;
QString fillQuery = "INSERT INTO " + ts.tableName() + " VALUES (0)";
for (int i = 1; i < NUM_ROWS; ++i) {
fillQuery += ", (" + QString::number(i) + QLatin1Char(')');
expectedSum += i;
}
QVERIFY_SQL(q, exec(fillQuery));
QVERIFY_SQL(q, prepare("SELECT id FROM " + ts.tableName()));
QBENCHMARK {
QVERIFY_SQL(q, exec());
int sum = 0;
while (q.next())
sum += q.value(0).toInt();
QCOMPARE(sum, expectedSum);
}
}
#include "main.moc"
@@ -0,0 +1,16 @@
# Copyright (C) 2022 The Qt Company Ltd.
# SPDX-License-Identifier: BSD-3-Clause
#####################################################################
## tst_bench_qsqlrecord Binary:
#####################################################################
qt_internal_add_benchmark(tst_bench_qsqlrecord
SOURCES
tst_bench_qsqlrecord.cpp
LIBRARIES
Qt::CorePrivate
Qt::Sql
Qt::SqlPrivate
Qt::Test
)
@@ -0,0 +1,110 @@
// Copyright (C) 2021 The Qt Company Ltd.
// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only
#include <QTest>
#include <QtSql/QtSql>
#include "../../../../auto/sql/kernel/qsqldatabase/tst_databases.h"
class tst_QSqlRecord : public QObject
{
Q_OBJECT
public slots:
void initTestCase();
void cleanupTestCase();
void cleanup();
private slots:
void benchmarkRecord_data() { generic_data(); }
void benchmarkRecord();
void benchFieldName_data() { generic_data("QPSQL"); }
void benchFieldName();
void benchFieldIndex_data() { generic_data("QPSQL"); }
void benchFieldIndex();
private:
void generic_data(const QString &engine = QString());
tst_Databases dbs;
};
QTEST_MAIN(tst_QSqlRecord)
void tst_QSqlRecord::initTestCase()
{
dbs.open();
}
void tst_QSqlRecord::cleanupTestCase()
{
dbs.close();
}
void tst_QSqlRecord::cleanup()
{
}
void tst_QSqlRecord::generic_data(const QString &engine)
{
if (dbs.fillTestTable(engine) == 0) {
if (engine.isEmpty())
QSKIP("No database drivers are available in this Qt configuration");
else
QSKIP(QString("No database drivers of type %1 are available in this Qt configuration").arg(engine).toLocal8Bit());
}
}
void tst_QSqlRecord::benchmarkRecord()
{
QFETCH(QString, dbName);
QSqlDatabase db = QSqlDatabase::database(dbName);
CHECK_DATABASE(db);
TableScope ts(db, "record", __FILE__);
{
QSqlQuery qry(db);
QVERIFY_SQL(qry, exec("create table " + ts.tableName() +
" (id int NOT NULL, t_varchar varchar(20), "
"t_char char(20), primary key(id))"));
// Limit to 500: at 600, the set-up takes nearly 5 minutes
for (int i = 0; i < 500; i++)
QVERIFY_SQL(qry, exec(QString("INSERT INTO " + ts.tableName() +
" VALUES (%1, 'VarChar%1', 'Char%1')").arg(i)));
QVERIFY_SQL(qry, exec(QString("SELECT * from ") + ts.tableName()));
QBENCHMARK {
while (qry.next())
qry.record();
QVERIFY(qry.seek(0));
}
}
}
void tst_QSqlRecord::benchFieldName()
{
QFETCH(QString, dbName);
QSqlDatabase db = QSqlDatabase::database(dbName);
QCOMPARE(tst_Databases::getDatabaseType(db), QSqlDriver::PostgreSQL);
QSqlQuery qry(db);
QVERIFY_SQL(qry, exec("SELECT GENERATE_SERIES(1,5000) AS r"));
QBENCHMARK {
while (qry.next())
qry.value("r");
QVERIFY(qry.seek(0));
}
}
void tst_QSqlRecord::benchFieldIndex()
{
QFETCH(QString, dbName);
QSqlDatabase db = QSqlDatabase::database(dbName);
QCOMPARE(tst_Databases::getDatabaseType(db), QSqlDriver::PostgreSQL);
QSqlQuery qry(db);
QVERIFY_SQL(qry, exec("SELECT GENERATE_SERIES(1,5000) AS r"));
QBENCHMARK {
while (qry.next())
qry.value(0);
QVERIFY(qry.seek(0));
}
}
#include "tst_bench_qsqlrecord.moc"