You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
With all of the re-configuration to add Cmake functionality, and to refactor the wrapper scripts used on math-mulberry, it became easy and seemed pragmatic to me to make a minor pair of changes to the source. Recall that in issue #20, concerns were raised about why we had to change the working directory from the user's path back to the PMFE build directory to run the wrapper script.
The response to this is basically note that some of the generated PMFE binaries rely on relative paths (local, and with respect to the build time PMFE working directory). As noted by @ceheitsch, the tests only need to be run after each recompilation. This means that that binary run case can be effectively excluded from the wrapper script.
After looking around the sources more, I found some concerns that yet other local, relative references to files are used to load the Turner99 thermodynamic parameters data at runtime. This means that without a change to where the PMFE utilities are looking for those files, it might still be necessary to change the working directory to ensure correct behavior.
My solution is to hardcode the absolute paths to the test sequences files and the local PMFE thermo params directories into a new configure header (include/pmfe_build_config.h.in) that can be referenced at runtime. Since this config header is automatically regenerated every time we recompile, the PMFE source path does not need to be fixed. Moreover, the absolute path references to these dependent files remove the need to change the CWD in the wrapper script to handle the previous relative references to these files.
The changes I made are fairly small and self contained. They can be reviewed in the first commit to the new cmake-build branch as seen here, and then in the references specified as here.
The text was updated successfully, but these errors were encountered:
With all of the re-configuration to add Cmake functionality, and to refactor the wrapper scripts used on
math-mulberry
, it became easy and seemed pragmatic to me to make a minor pair of changes to the source. Recall that in issue #20, concerns were raised about why we had to change the working directory from the user's path back to the PMFE build directory to run the wrapper script.The response to this is basically note that some of the generated PMFE binaries rely on relative paths (local, and with respect to the build time PMFE working directory). As noted by @ceheitsch, the tests only need to be run after each recompilation. This means that that binary run case can be effectively excluded from the wrapper script.
After looking around the sources more, I found some concerns that yet other local, relative references to files are used to load the
Turner99
thermodynamic parameters data at runtime. This means that without a change to where the PMFE utilities are looking for those files, it might still be necessary to change the working directory to ensure correct behavior.My solution is to hardcode the absolute paths to the test sequences files and the local PMFE thermo params directories into a new configure header (
include/pmfe_build_config.h.in
) that can be referenced at runtime. Since this config header is automatically regenerated every time we recompile, the PMFE source path does not need to be fixed. Moreover, the absolute path references to these dependent files remove the need to change the CWD in the wrapper script to handle the previous relative references to these files.The changes I made are fairly small and self contained. They can be reviewed in the first commit to the new
cmake-build
branch as seen here, and then in the references specified as here.The text was updated successfully, but these errors were encountered: