jp: fix linking on macOS (#38353)

* jp: fix linking on macOS

* mv to root
This commit is contained in:
Adeeb Shihadeh
2026-07-15 21:39:47 -07:00
committed by GitHub
parent 91b067cca0
commit 61608db786
2 changed files with 16 additions and 0 deletions
+5
View File
@@ -166,6 +166,11 @@ env = Environment(
tools=["default", "cython", "compilation_db", "rednose_filter"],
toolpath=["#site_scons/site_tools", "#rednose_repo/site_scons/site_tools"],
)
# SCons' Darwin linker tool doesn't define the variables used to expand RPATH.
if arch == "Darwin":
env["RPATHPREFIX"] = "-Wl,-rpath,"
env["RPATHSUFFIX"] = ""
env["_RPATH"] = "${_concat(RPATHPREFIX, RPATH, RPATHSUFFIX, __env__)}"
if arch != "larch64":
env['_LIBFLAGS'] = _libflags
@@ -0,0 +1,11 @@
import subprocess
from pathlib import Path
JOTPLUGGLER_DIR = Path(__file__).parent
def test_help():
result = subprocess.run(["./jotpluggler", "-h"], cwd=JOTPLUGGLER_DIR, capture_output=True, text=True)
assert result.returncode == 0, result.stderr
assert "Usage:" in result.stderr