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

Test musica #225

Merged
merged 15 commits into from
Aug 16, 2023
Merged
Show file tree
Hide file tree
Changes from 3 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
35 changes: 34 additions & 1 deletion Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,39 @@ RUN cd pnetcdf-1.12.3 && \
make -j 8 install && \
ldconfig

ENV FC=gfortran

###################################################
## Build and install json-fortran
###################################################
RUN curl -LO https://github.com/jacobwilliams/json-fortran/archive/8.2.0.tar.gz \
&& tar -zxvf 8.2.0.tar.gz \
&& cd json-fortran-8.2.0 \
&& mkdir build \
&& cd build \
&& cmake -D SKIP_DOC_GEN:BOOL=TRUE .. \
&& make install -j 8

# add a symlink
RUN ln -s /usr/local/jsonfortran-gnu-8.2.0/lib/libjsonfortran.a /usr/local/lib/libjsonfortran.a

###################################################
## Build and install MUSICA
###################################################

RUN git clone https://github.com/NCAR/musica.git
RUN mkdir /musica/build \
&& cd /musica/build \
&& export JSON_FORTRAN_HOME="/usr/local/jsonfortran-gnu-8.2.0" \
&& cmake \
-D ENABLE_TESTS=OFF \
-D ENABLE_TUVX=OFF \
.. \
&& make install -j 8

# add a symlink
RUN ln -s /usr/local/musica-0.3.0/lib64/libmusica.a /usr/local/lib/libmusica.a

###################################################
## Build CAM-SIMA
###################################################
Expand Down Expand Up @@ -81,7 +114,7 @@ WORKDIR $CASE_NAME

RUN ./case.setup

RUN ./xmlchange CAM_CONFIG_OPTS="--dyn none --physics-suites held_suarez_1994"
RUN ./xmlchange CAM_CONFIG_OPTS="--dyn none --physics-suites musica"
RUN ./xmlchange ROF_NCPL=48
RUN ./xmlchange STOP_OPTION=nsteps
RUN ./xmlchange STOP_N=5
Expand Down
2 changes: 1 addition & 1 deletion Externals.cfg
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ externals = Externals.cfg
required = True

[cmeps]
tag = cmeps0.14.24
tag = cmeps0.14.34
protocol = git
repo_url = https://github.com/ESCOMP/CMEPS.git
local_path = components/cmeps
Expand Down
4 changes: 2 additions & 2 deletions Externals_CAM.cfg
Original file line number Diff line number Diff line change
Expand Up @@ -22,8 +22,8 @@ required = False
[ncar-physics]
local_path = src/physics/ncar_ccpp
protocol = git
repo_url = https://github.com/NCAR/atmospheric_physics
tag = atmos_phys0_00_018
repo_url = https://github.com/K20shores/atmospheric_physics
branch = musica_ccpp
K20shores marked this conversation as resolved.
Show resolved Hide resolved
required = True

[silhs]
Expand Down
12 changes: 12 additions & 0 deletions cime_config/config_component.xml
Original file line number Diff line number Diff line change
Expand Up @@ -301,6 +301,18 @@
<desc>User mods to apply to specific compset matches. </desc>
</entry>

<entry id="CAM_LINKED_LIBS">
<type>char</type>
<valid_values></valid_values>
<default_value>-lmusica -ljsonfortran</default_value>
<group>build_component_cam</group>
<file>env_build.xml</file>
<desc>
CAMSIMA linked libraries. The libraries are built by CAMSIMA's buildlib script and should be included
during linking of the model executable.
</desc>
</entry>

<help>
=========================================
CAM naming conventions
Expand Down
Loading