1

それは非常に簡単です: 私の js は gnome-shell 拡張機能の一部であり、いくつかのインポート行が含まれています:

[...]
const Gettext = imports.gettext;
const MessageTray = imports.ui.messageTray;
imports.searchPath.push("/opt/tempmon/lib"); // append custom search path
const Helper = imports.tempmon; // import helper module
[...implementation...]

共有ライブラリをseed-module.hで正常にコンパイルし、/opt/tempmon/lib/libseed_tempmon.soの下に配置しました

Looking Glass (lg) ディスプレイ:

gjs/seed (混乱しています) は、「JS-Module tempmon in search path」を見つけることができませんでした。

モジュールを JS 環境に含めるには、どのようなアクションが必要ですか?

4

0 に答える 0