pwndbg is a Python module for gdb. The built-in interpreter is used and
pwndbg offers additional routines. Packaging this is tricky because that
interpreter needs to be used. Using `python3.withPackages` won't work.
By setting `NIX_PYTHONPATH`, the interpreter should pick up pwndbg and
its dependencies.
If `NIX_PYTHONPATH` does not function we can fall back to `PYTHONPATH`.
An example of when that won't work is if pwndbg runs a script of itself
in a subshell. `NIX_PYTHONPATH` would be unset, but `PYTHONPATH` not.
There is a bug in this feature: It allows extra arguments to leak in
from the environment. For example:
$ export extraFlagsArray=date
$ man ls
Note that you get the man page for date rather than for ls. This happens
because 'man' happens to use a wrapper (to add groff to its PATH).
An attempt to fix this was made in 5ae18574fc in PR #19328 for
issue #2537, but 1. That change didn't actually fix the problem because
it addressed makeWrapper's environment during the build process, not the
constructed wrapper script's environment after installation, and 2. That
change was apparently accidentally lost when merged with 7ff6eec5fd.
Rather than trying to fix the bug again, we remove the extraFlagsArray
feature, since it has never been used in the public repo in the ten
years it has been available.
wrapAclocal continues to use its own, separate flavor of extraFlagsArray
in a more limited context. The analogous bug there was fixed in
4d7d10da6b in 2011.
This is a partial revert of #58715. Bumping the default caused problems
described in #69213. I tested that the vscode corruption happened even
with the 0.10 pre-release, so I'm keeping patchelfUnstable on 0.10
(patchelfUnstable shouldn't cause a large rebuild anyway)
ycmd gives 'no completer support' because of missing 'gopls'.
Add this as a conditional dependency.
Refactor the 'mkdir -p' step to be conditional per-dependency,
and placed just before the link step.
This is mostly for legibility but also pedantic correctness:
do not create a directory unless it will be used.
Signed-off-by: Sirio Balmelli <sirio@b-ad.ch>
Copy _all_ of 'third_party'.
Cherry-picking the contents of this dir is a fragile approach as
they change in later commits (breaking this build).
This approach continues to work on the current build,
and will not break with later versions of the project.
Signed-off-by: Sirio Balmelli <sirio@b-ad.ch>