Native node module could not be found in asar


I use native node module which depends on another library. The module and the library are located inside the subfolder of the application:

    |- package.json
    |- index.html
    |- main.js
    |- modules
        |- mymodule.node
        |- somelib.dll

When I pack the app by electron-packager without --asar switch then the app works. But if I use --asar switch and run the app then I get such error

Uncaught Error: The specified module could not be found.

where the D7C1.tmp is copied binary file of mymodule.node. Seems the native module cannot find the library which is dependent on. How to solve it?


The solution is --asar-unpack:


but strange I cannot specify also the directory inside the pattern. The option below does not match any file from my file structure :confused: