Skip to content

drivelist.node not found #186

Open
Open

Description

@icoco

Mac MBP M1 compile and package for Linux x86_64

while execute the binary app , report error :

Error: node-loader:
Error: /root/.cache/pkg/06caeb8f704d1a6737597956e137e74f11a8e28f9b9b0eb1a8b734887fb38402/drivelist.node: cannot open shared object file: No such file or directory
at 26747 (/snapshot/app/backend/644.js)

how to solve such issue ?

use the same package.json package for Mac, the binary app can execute successfully .

Activity

  1. robertsLando commented on Oct 24, 2025

    @robertsLando
    Member

    Please show me package.json content and also share pkg command output with --debug flag. Then run the result package with DEBUG_PKG=2 env var and share the run output as well

  2. icoco commented on Oct 24, 2025

    @icoco
    Author

    I just try to package the project 'https://github.com/eclipse-theia/theia-ide'

    "pkg-begin": "-------------------------------------- begin",
      "bin": "applications/browser/lib/backend/main.js", 
      "pkg":{ 
       
        "scripts": [
           "applications/browser/lib/backend/**/*"
        ],
        "assets": [
        
          "applications/browser/lib/frontend/**/*",
           
        ],
        "outputPath": "dist_bin",
        "targets": [
          "node22" 
        ]  
      },
      "pkg-end": " --------------------------------------  end",
    
    

    pkg --debug --targets node22-linux-x64 .

  3. icoco commented on Oct 25, 2025

    @icoco
    Author

    DEBUG_PKG=2 ./myApp,

    ------------------------------- oversized files
      ThingsSpace                             188.0 MB 
        applications                          186.9 MB 
          browser                             186.9 MB 
            lib                               186.9 MB 
              backend                          33.6 MB 
                vendors-node_modules_drivelist_build_Release_drivelist_node-node_modules_stroncium_procfs_lib-9ec906.js   12.2 MB 
                vendors-node_modules_drivelist_build_Release_drivelist_node-node_modules_stroncium_procfs_lib-9ec906.js.map   11.6 MB 
              frontend                        153.3 MB 
                bundle.js                      22.0 MB 
                bundle.js.map                  29.4 MB 
                bundle.js.map.gz                5.3 MB 
                secondary-window.js            20.5 MB 
                secondary-window.js.map        20.0 MB 
                vendors-node_modules_react-tabs_esm_index_js-node_modules_treedoc-viewer_dist_lib_lib_common_-6175a6.js    5.9 MB 
                vendors-node_modules_react-tabs_esm_index_js-node_modules_treedoc-viewer_dist_lib_lib_common_-6175a6.js.map    7.2 MB 
    fs.existsSync [ '/snapshot/ThingsSpace/applications/browser/lib/backend/main.js' ]
    fs.statSync [ '/snapshot/ThingsSpace/applications/browser/lib/backend/main.js' ]
    fs.readSync []
    fs.realpathSync [ '/snapshot/ThingsSpace/applications/browser/lib/backend/main.js' ]
    fs.readFileSync [
      '/snapshot/ThingsSpace/applications/browser/lib/backend/main.js',
      'utf8'
    ]
    fs.readSync []
    
    .....
    
    
    fs.existsSync [
      '/root/.cache/pkg/06caeb8f704d1a6737597956e137e74f11a8e28f9b9b0eb1a8b734887fb38402'
    ]
    fs.existsSync [
      '/root/.cache/pkg/06caeb8f704d1a6737597956e137e74f11a8e28f9b9b0eb1a8b734887fb38402/drivelist.node'
    
    
    

    from log, while fs.readFileSync then should be fs.readSync [], this meaning read success ? or else probably occurs problem ?

    current it report error while executed :
    ....
    Error: node-loader:
    Error: /root/.cache/pkg/06caeb8f704d1a6737597956e137e74f11a8e28f9b9b0eb1a8b734887fb38402/drivelist.node: cannot open shared object file: No such file or directory
    at ../../node_modules/drivelist/build/Release/drivelist.node (/snapshot/ThingsSpace/applications/browser/lib/backend/vendors-node_modules_drivelist_build_Release_drivelist_node-node_modules_stroncium_procfs_lib-9ec906.js)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions