Skip to content

Should we create em wrapper scripts for other llvm tools (such as llvm-dwp and llvm-nm)? #14533

@sbc100

Description

@sbc100

This is maybe an emsdk issues since other users of emscripten probably have such tools in their PATH already.

It certainly seems like users would want access to other llvm tools such as llvm-nm, llvm-dwp, etc, but emsdk does not add the llvm tools to the PATH by default.

We could have simple no-op wrappers in the emscripten directory called em-nm em-dwp? Or we could just ensure the llvm tools are in the PATH? We do have a couple of existing no-op wrappers emar and emranlib, but historically they were requires since we had slightly different behaviour to upstream. They are still around but mostly for legacy reasons.

Reasons to use wrappers scripts:

  1. Avoids putting tip-of-tree llvm tools in users path (avoids shadowing system tools)
  2. Ensures the correctly-configured version of llvm tool is used, no just the one in the PATH.
  3. Consistency with emcc and emar

Reasons to avoid wrapper scripts:

  1. Extra overhead per call. Runs a shell and a python process.
  2. They don't actually add any actual functionality
  3. Could lead to confusion if folks think these are actually different to upstream tools in some way (More than one way to do that same thing).

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