CESR-lab / ucla-roms

GNU General Public License v3.0
5 stars 11 forks source link

New commit won't compile #22

Closed dafyddstephenson closed 5 months ago

dafyddstephenson commented 6 months ago

Hi Jeroen, could you please address the following?

The model will currently not compile with these two problems. Thanks!

dafyddstephenson commented 6 months ago

There is also a problem in bgc_ecosys_vars.F. The previous AVERAGES cpp check has now been replaced with a conditional on wrt_avg_dia, which this module does not have access to.

dafyddstephenson commented 6 months ago

wrt_bgc_diags in bgc.F also still passes the variable avg to create_bgc_dia_file, even though this variable is no longer used in wrt_bgc_diags.

nmolem commented 6 months ago

Apologies for the break. I pushed bug fixes and added a BGC example. At the moment, it doesn't have proper forcing files, but it allows for the check on proper compilation. forcing files hopefully later this week.

dafyddstephenson commented 5 months ago

Hi Jeroen, I realise some of the other cpp checks have disappeared along with AVERAGES in bgc.F. In particular #if defined(MARBL_DIAGS) || defined(BEC2_DIAG) (and #endif /* BEC2_DIAG || MARBL_DIAGS */ ) previously wrapped the contents of the subroutines create_bgc_dia_file , wrt_bgc_diags , calc_avg_dia_bgc , def_bgc_diag. Without these checks (that also wrap related declarations and allocations elsewhere) the compiler errors out. Could you please restore these preprocessor lines for now?

nmolem commented 5 months ago

Apologies Dafydd. Hopefully, more automated testing will solve these things. Please test and let me know. I'll attend to issues asap

dafyddstephenson commented 5 months ago

Hi Jeroen, thanks for the fast turnaround on this. This won't compile for me as the new line public wrt_bgc_diags persists even when the wrt_bgc_diags subroutine does not exist in the case that those keys aren't defined. In my local copy I've just moved the wrt_bgc_diags cpp check to the inside of the SR so it's defined but empty after preprocessing. Everything else works fine after doing that - if you could implement something similar and commit, I think it'll be all clear. Thanks again! Automated testing very nearly done.

nmolem commented 5 months ago

I followed your suggestion. Let me know if this works for you

dafyddstephenson commented 5 months ago

Seems to all be fine now, closing. Thanks again