Skip to content

Commit a5ee669

Browse files
committed
fixed errors
1 parent 172fc03 commit a5ee669

File tree

1 file changed

+10
-6
lines changed

1 file changed

+10
-6
lines changed

.github/workflows/test-tinker.yml

Lines changed: 10 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -151,14 +151,18 @@ jobs:
151151
# We force OBJS to be appended to the dependency list
152152
sed -i 's/libtinker.a: ${OBJS}/libtinker.a: ${OBJS} potent.o action.o energi.o boxes.o/g' Makefile
153153
154-
# CRITICAL FIX: The default libtinker.a rule uses a hardcoded object list that is missing files.
155-
# Rather than trying to patch the complex rule, we rename it to disable it, and append a correct one.
156-
157-
# 1. Rename the old target to disable it
154+
# CRITICAL FIX: Explicitly compile the missing objects to ensure they exist.
155+
# The makefile rules might be missing or not triggering correctly for these specific files.
156+
echo "Compiling missing objects manually..."
157+
gfortran -c -O2 -fdefault-integer-8 -fdefault-real-8 -mcmodel=large potent.f || echo "Failed to compile potent.f"
158+
gfortran -c -O2 -fdefault-integer-8 -fdefault-real-8 -mcmodel=large action.f || echo "Failed to compile action.f"
159+
gfortran -c -O2 -fdefault-integer-8 -fdefault-real-8 -mcmodel=large energi.f || echo "Failed to compile energi.f"
160+
gfortran -c -O2 -fdefault-integer-8 -fdefault-real-8 -mcmodel=large boxes.f || echo "Failed to compile boxes.f"
161+
162+
# Now rename the old broken target
158163
sed -i 's/^libtinker.a:/OLD_libtinker.a:/g' Makefile
159164
160-
# 2. Append the new, correct target rule
161-
# We explicitly list the missing objects here as well to be safe
165+
# Append the new target rule, explicitly listing the objects we just compiled
162166
echo "" >> Makefile
163167
echo "libtinker.a: \${OBJS} potent.o action.o energi.o boxes.o" >> Makefile
164168
echo -e "\tar \${LIBFLAGS} libtinker.a \${OBJS} potent.o action.o energi.o boxes.o" >> Makefile

0 commit comments

Comments
 (0)