diff --git a/.github/workflows/Format-and-Test.yml b/.github/workflows/Format-and-Test.yml index b19675b9..9afe2ad1 100644 --- a/.github/workflows/Format-and-Test.yml +++ b/.github/workflows/Format-and-Test.yml @@ -65,7 +65,7 @@ jobs: run: | brew update brew install gcc open-mpi - ln -s $(brew --prefix)/bin/gfortran-15 $(brew --prefix)/bin/gfortran + # ln -s $(brew --prefix)/bin/gfortran-15 $(brew --prefix)/bin/gfortran - name: Clone GITM repository uses: actions/checkout@v4 - name: Run tests on MacOS (compile, clean, run one test, no output checking) diff --git a/Config.pl b/Config.pl index b1c98e8d..ba5217e0 100755 --- a/Config.pl +++ b/Config.pl @@ -99,6 +99,16 @@ my $command = "touch ext/Electrodynamics/src/Makefile.DEPEND"; print "creating DEPEND file in electrodynamics:\n\t $command\n"; my $exit_status = `$command`; + + # Write Makefile.local for ext/* libraries so they can find GITM's build + # config: Makefile.dirs for paths, Makefile.conf for compiler rules + my $GitMDir = `pwd`; chomp $GitMDir; + open(my $fh, ">", "ext/Electrodynamics/build/Makefile.local") + or die "Cannot write ext/Electrodynamics/build/Makefile.local: $!"; + print $fh "DIRSFILE := $GitMDir/Makefile.def\n"; + print $fh "BUILDDIR := $GitMDir\n"; + close($fh); + print "Created ext/Electrodynamics/build/Makefile.local\n"; } &modify_utilities if $NoFlush; diff --git a/Makefile b/Makefile index 9874c349..029597bc 100644 --- a/Makefile +++ b/Makefile @@ -43,7 +43,7 @@ VERSION: GITM: @cd ${SHAREDIR}; echo "Entering ${SHAREDIR}"; make --no-print-directory LIB @cd $(ABDIR); echo "Entering ${ABDIR}" ; make --no-print-directory LIB - @cd $(EIEDIR)/src; echo "Entering ${EIEDIR}/src"; make --no-print-directory DIRSFILE=${DIRSFILE} SHARELIB + @cd $(EIEDIR)/src; echo "Entering ${EIEDIR}/src"; make --no-print-directory SHARELIB @cd ${EUADIR}; echo "Entering ${EUADIR}"; make --no-print-directory LIB @cd $(IODIR); echo "Entering ${IODIR}"; make --no-print-directory LIB @cd $(GLDIR); echo "Entering ${GLDIR}"; make --no-print-directory LIB diff --git a/srcMake/Makefile.def b/srcMake/Makefile.def index 2ebd41d0..a3fce882 100644 --- a/srcMake/Makefile.def +++ b/srcMake/Makefile.def @@ -4,9 +4,6 @@ localdefault: help # default target DIR = ${UADIR} -DIRSFILE = ${UADIR}/Makefile.def -BUILDDIR = ${UADIR} - SCRIPTDIR = ${UADIR}/share/Scripts LIBDIR = ${UADIR}/src RUNDIR = ${UADIR}/run