plugins/ held two unrelated things: the host that discovers and installs plugins, and the plugins themselves. The host moves to plugins/ with the built-in pacman provider beside it in providers/, where the external providers already live — so plugins/ is now one thing, and the name says which. The external plugin projects only change folder, not layout: providers/ holds aur-provider, flatpak-provider, example-provider and example-addon.
26 lines
1.4 KiB
C++
26 lines
1.4 KiB
C++
// Flatpak provider plugin — an external provider loaded at runtime by
|
|
// PluginManager from the plugins/ directory next to the executable (or in
|
|
// ~/.local/share/PacManager/plugins/). It exports the C ABI contract declared
|
|
// in provider-plugin.h so the host can query metadata, check the backing tool,
|
|
// and instantiate the manager without any compiled-in Flatpak support.
|
|
//
|
|
// Built by default (see the FWS_BUILD_FLATPAK_PLUGIN CMake option): the
|
|
// flatpak-provider-plugin target compiles this file together with
|
|
// flatpak-manager.cpp into libflatpak-provider.so and copies it next to the
|
|
// PacManager binary, so a default build ships with Flatpak support enabled.
|
|
|
|
#include "flatpak-manager.h"
|
|
#include "provider-plugin.h"
|
|
|
|
extern "C" const char* fws_plugin_kind() { return "provider"; }
|
|
extern "C" const char* fws_plugin_id() { return "flatpak"; }
|
|
extern "C" const char* fws_plugin_name() { return "Flatpak"; }
|
|
extern "C" const char* fws_plugin_version() { return "1.0.0"; }
|
|
extern "C" const char* fws_plugin_description() {
|
|
return "Gestionnaire d'applications Flatpak";
|
|
}
|
|
extern "C" const char* fws_plugin_author() { return "BlackAngelTV"; }
|
|
extern "C" IPackageManager* fws_create_provider() { return new FlatpakManager(); }
|
|
// The backing tool is installed by the pacman package "flatpak"; exposing it
|
|
// lets the Plugins page offer to install the missing tool.
|
|
extern "C" const char* fws_plugin_install_hint() { return "flatpak"; } |