Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

xdrgen: Make the xdrgen script location-independent

The @pythondir@ placeholder is meant for build-time substitution,
such as with autoconf. autoconf is not used in the kernel. Let's
replace that mechanism with one that better enables the xdrgen
script to be run from any directory.

Signed-off-by: Chuck Lever <chuck.lever@oracle.com>

+5
+5
tools/net/sunrpc/xdrgen/xdrgen
··· 10 10 __version__ = "0.2" 11 11 12 12 import sys 13 + from pathlib import Path 13 14 import argparse 15 + 16 + _XDRGEN_DIR = Path(__file__).resolve().parent 17 + if str(_XDRGEN_DIR) not in sys.path: 18 + sys.path.insert(0, str(_XDRGEN_DIR)) 14 19 15 20 from subcmds import definitions 16 21 from subcmds import declarations