Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Missing extern_parameters.cpp when compiling burn_cell in DEBUG mode #1774

Open
chongchonghe opened this issue Mar 5, 2025 · 3 comments
Open

Comments

@chongchonghe
Copy link

I am trying compile and run the burn_cell unit test in debug mode but got this error:

make: *** No rule to make target `extern_parameters.cpp', needed by `tmp_build_dir/o/3d.gnu.DEBUG.EXE/extern_parameters.o'.  Stop.

steps to reproduce the bug:

  1. run
export AMREX_HOME=/path/to/amrex
cd unit_test/burn_cell
make DEBUG=TRUE
  1. see the error.
@zingale
Copy link
Member

zingale commented Mar 5, 2025

just to be clear -- you replaces /path/to/amrex to the actual path to the amrex/ directory on your system?

@chongchonghe
Copy link
Author

just to be clear -- you replaces /path/to/amrex to the actual path to the amrex/ directory on your system?

Yes, for sure.

After some experiment, I found the following behaviors:

  1. This error did not happen the first time I compile the burn_cell test, but I happens every time I do make clean followed by make. However, when this happens, extern_parameters.cpp actually exists in /tmp_build_dir/microphysics_sources/3d.gnu.EXE/extern_parameters.cpp.
  2. After this error happens, I run another make, and it successfully compiles.
  3. Same for DEBUG=TRUE or DEBUG=FALSE.

I didn't look deep into the cause of this error, but I speculate we could avoid it by using a OUTDIR parameter in make to allow compile into a specific build/ folder.

@zingale
Copy link
Member

zingale commented Mar 6, 2025

are you using cmake? or just make? we already use an build directory, that's what tmp_build_dir does.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants