From b5083bf7fc6b3bdc97889d99bbbabc60638d7df3 Mon Sep 17 00:00:00 2001 From: Joseph D Hughes Date: Mon, 10 Jun 2024 18:53:50 -0500 Subject: [PATCH] * cleanup --- autotest/test_build.py | 9 ++------- autotest/test_cli_cmds.py | 2 -- autotest/test_gridgen.py | 2 -- autotest/test_mf6_existing_meson.py | 2 -- 4 files changed, 2 insertions(+), 13 deletions(-) diff --git a/autotest/test_build.py b/autotest/test_build.py index 13d67a3..1e02c2e 100644 --- a/autotest/test_build.py +++ b/autotest/test_build.py @@ -70,8 +70,6 @@ def test_build(function_tmpdir, target: str) -> None: pm.target = target pm.inplace = True fc = os.environ.get("FC", "gfortran") - # if system() == "Darwin" and fc == "gfortran": - # pm.syslibs = "-Wl,-ld_classic" assert ( pymake.build_apps( target, @@ -88,9 +86,9 @@ def test_build(function_tmpdir, target: str) -> None: @pytest.mark.parametrize("target", targets_meson) def test_meson_build(function_tmpdir, target: str) -> None: kwargs = {} + cc = os.environ.get("CC", "gcc") fc = os.environ.get("FC", "gfortran") - if system() == "Darwin" and fc == "gfortran": - kwargs["LDFLAGS"] = "-Wl,-ld_classic" + pymake.linker_update_environment(cc=cc, fc=fc) with set_dir(function_tmpdir), set_env(**kwargs): assert ( pymake.build_apps( @@ -115,9 +113,6 @@ def test_makefile_build(function_tmpdir, target: str) -> None: pm.inplace = True pm.dryrun = True pm.makeclean = False - fc = os.environ.get("FC", "gfortran") - # if system() == "Darwin" and fc == "gfortran": - # pm.syslibs = "-Wl,-ld_classic" with set_dir(function_tmpdir): pm.download_target(target) diff --git a/autotest/test_cli_cmds.py b/autotest/test_cli_cmds.py index fe916c9..f31e0a3 100644 --- a/autotest/test_cli_cmds.py +++ b/autotest/test_cli_cmds.py @@ -116,8 +116,6 @@ def test_mfpymake(function_tmpdir, meson: bool) -> None: fc = os.environ.get("FC") cmd.append(fc) - # if system() == "Darwin" and fc == "gfortran": - # set_env(**{"LDFLAGS": "-Wl,-ld_classic"}) linker_update_environment(fc=fc) if meson: diff --git a/autotest/test_gridgen.py b/autotest/test_gridgen.py index 007431f..1c69312 100644 --- a/autotest/test_gridgen.py +++ b/autotest/test_gridgen.py @@ -32,8 +32,6 @@ def pm(module_tmpdir, target) -> pymake.Pymake: pm.appdir = str(module_tmpdir) pm.cc = environ.get("CXX", "g++") pm.fc = None - # if system() == "Darwin" and pm.cc == "g++": - # pm.syslibs = "-Wl,-ld_classic" pm.inplace = True pm.makeclean = True yield pm diff --git a/autotest/test_mf6_existing_meson.py b/autotest/test_mf6_existing_meson.py index 0971b3e..26cd762 100644 --- a/autotest/test_mf6_existing_meson.py +++ b/autotest/test_mf6_existing_meson.py @@ -38,8 +38,6 @@ def pm(workspace, targets) -> pymake.Pymake: pm.target = str(targets[0]) pm.appdir = str(workspace / "bin") pm.fc = os.environ.get("FC", "gfortran") - # if system() == "Darwin" and pm.fc == "gfortran": - # pm.syslibs = "-Wl,-ld_classic" pm.meson = True pm.makeclean = True pm.mesondir = str(workspace)