qtbase の compile タスクが "expected identifier before numeric constant" エラーで失敗する

エラーメッセージ

../../../../include/QtCore/../../../qtbase-opensource-src-5.2.1/src/corelib/io/qurl.h:139:9: error: expected identifier before numeric constant
         None = 0x0,
         ^

原因

eglfs プラグインの不具合?

解決方法

レシピに次の行を追加する。(eglfs プラグイン不要な場合)

QT_CONFIG_FLAGS_append = "${@base_contains('DISTRO_FEATURES', 'x11', ' -no-eglfs', ' -eglfs', d)}"

new PDO('sqlite:~') 実行時にデータベースファイルが勝手に作られる

原因

PDO SQLite の仕様。

https://stackoverflow.com/questions/40618805/php-pdo-sqlite-connection

自動作成を無効にする方法

そんなものはない。

対策

データベースファイルの有無を確認してから、new PDO() を実行するようにする。

if (file_exists('a.sqlite3')) {
    $pdo = new PDO('sqlite:a.sqlite3');
}

Raspberry Pi に USB シリアルを挿しても ttyUSB0 が作られない

原因

  • "apt upgrade" でカーネルが更新されたのに、再起動していなかったため
    • 稼働中のカーネル(旧)と、アップデートされたモジュール(新)が、適合しなかったと思われる

対処

OS を再起動する。

$ sudo reboot

Linux カーネル 3.20 以降のバージョン番号の付き方

調べてみた。

公式なドキュメントは無い模様。

What are Kernel Version number components (w.x.yy-zzz) called? - Ask Ubuntu より

Then, pretty much arbitrarily, Linus bumped the version to 3.0. And that ended all of that semantic versioning's applicability to Linux versions. And when 3.20 was due, Linus switched to simply incrementing w whenever x got large enough that he ran out of fingers and toes to count it.

それから、ほぼ恣意的に、Linus はバージョンを 3.0 に上げました。 これで、Linux へのセマンティックバージョニングの適用はすべて終わりました。 そして、3.20 が来たとき、Linus はマイナー番号が手足の指の数を超えたら、シンプルにメジャー番号をインクリメントすることに切り替えました。