Customizing the generic plugin

LuaFAR 3

Customizing the generic plugin


The easiest way to build a LuaFAR plugin DLL is via luaplug.mak makefile (MinGW is required). This makefile can be used either directly or included in another makefile. It accepts the following parameters:

  • TARGET – name of the resulting DLL, e.g.: “TARGET = helloworld.dll”.

  • FAR_EXPORTS – list of functions that should be exported by the plugin (in uppercase, whitespace-separated, final letter W removed), e.g.:
    FAR_EXPORTS = OPEN PROCESSEDITORINPUT”.
    The following functions are always exported, so there’s no need to include them in the list: GetGlobalInfoW, SetStartupInfoW, GetPluginInfoW, ExitFARW and ProcessSynchroEventW.

  • FARDIR – the root directory of Far Manager source tree, e.g. “FARDIR = C:\farmanager”.

  • MYCFLAGS – list of additional compilation flags

  • MYLDFLAGS – list of additional linking-stage flags