From 088901f119c9ff259b20c31516d58cd788f127c5 Mon Sep 17 00:00:00 2001 From: Lourens Veen Date: Thu, 12 Mar 2026 15:49:05 +0100 Subject: [PATCH 1/2] Fix symlink name in package definition --- src/amuse/rfi/tools/create_dir.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/amuse/rfi/tools/create_dir.py b/src/amuse/rfi/tools/create_dir.py index ee4c5b335d..3e09bce59a 100644 --- a/src/amuse/rfi/tools/create_dir.py +++ b/src/amuse/rfi/tools/create_dir.py @@ -125,7 +125,8 @@ def _make_packages(code_dir: Path, code: str, variables: Dict[str, str]) -> None def make_package(pkg_type: str, suffix: str) -> None: pkg_dir = code_dir / "packages" / f"amuse-{code}{suffix}" pkg_dir.mkdir() - (pkg_dir / code).symlink_to("../..", True) + module = 'amuse_' + code + (pkg_dir / module).symlink_to("../..", True) _instantiate_template( "amuse-code.amuse_deps", From 2d071e195c0e24731ecd8ae4de89a5e6f9d8de55 Mon Sep 17 00:00:00 2001 From: Lourens Veen Date: Thu, 12 Mar 2026 15:58:36 +0100 Subject: [PATCH 2/2] Fix creating code dirs in the AMUSE tree --- src/amuse/rfi/tools/create_dir.py | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/src/amuse/rfi/tools/create_dir.py b/src/amuse/rfi/tools/create_dir.py index 3e09bce59a..50f4e9e702 100644 --- a/src/amuse/rfi/tools/create_dir.py +++ b/src/amuse/rfi/tools/create_dir.py @@ -84,14 +84,13 @@ def _make_support(code_dir: Path, language: str, variables: Dict[str, str]) -> N for tmpl, path in tmpls_paths.items(): _instantiate_template(tmpl, support_dir / path.format(**variables), variables) - # TODO: this needs to be updated when we move the codes out of community/ - shared_base = code_dir / ".." / ".." / ".." / "support" / "shared" + shared_base = code_dir / ".." / ".." / "support" / "shared" shared_dir = support_dir / "shared" if shared_base.exists(): # We're probably inside the AMUSE tree, so we make a symlink like for the other # embedded codes. This avoids having to update many copies of e.g. a broken m4 # macro. - shared_dir.symlink_to(shared_base) + shared_dir.symlink_to(Path("..") / ".." / ".." / "support" / "shared") else: shared_dir.mkdir() for src, dst in _files_support.items():