Project

General

Profile

Bug #3302

source tarball modified flag does not get updated in an existing build tree

Added by Szilárd Páll 7 months ago. Updated 5 months ago.

Status:
Closed
Priority:
Normal
Assignee:
Category:
mdrun
Target version:
Affected version - extra info:
Affected version:
Difficulty:
uncategorized
Close

Description

Reproduces with:

$ bin/gmx --version | grep -i "GROMACS version" -A1; echo -e "\n" >> ../src/gromacs/mdlib/sim_util.cpp; make gmx; bin/gmx --version | grep -i "GROMACS version" -A1; cmake ../ && make gmx; bin/gmx --version | grep -i "GROMACS version" -A1;
GROMACS version:    2020
Verified release checksum is c8f31ed8bc66001c3c8d6e5ddb61aab8bb1d400b5f5dba93c53473fa79c1a50a
[  0%] Built target mdrun_objlib
[  0%] Built target scanner
[  1%] Built target fftwBuild
[  4%] Built target thread_mpi
[  5%] Built target tng_io_obj
[  5%] Built target tng_io_zlib
[  5%] Built target lmfit_objlib
[ 27%] Built target linearalgebra
[ 28%] Built target modularsimulator
[ 28%] Built target vmddlopen
Scanning dependencies of target libgromacs
[ 28%] Building CXX object src/gromacs/CMakeFiles/libgromacs.dir/mdlib/sim_util.cpp.o
[ 28%] Linking CXX shared library ../../lib/libgromacs.so
[ 98%] Built target libgromacs
[ 98%] Built target view_objlib
[ 98%] Linking CXX executable ../../bin/gmx
[100%] Built target gmx
GROMACS version:    2020
Verified release checksum is c8f31ed8bc66001c3c8d6e5ddb61aab8bb1d400b5f5dba93c53473fa79c1a50a
-- The source code for this GROMACS installation is different from the officially released version.
-- The GROMACS-managed build of FFTW 3 will configure with the following optimizations: --enable-sse2;--enable-avx;--enable-avx2
-- Configuring done
-- Generating done
-- Build files have been written to: /home/pszilard/projects/gromacs/gromacs-2020/build_gcc8
[  0%] Built target mdrun_objlib
[  0%] Built target scanner
[  1%] Built target fftwBuild
[  4%] Built target thread_mpi
[  5%] Built target tng_io_obj
[  5%] Built target tng_io_zlib
[  5%] Built target lmfit_objlib
[ 27%] Built target linearalgebra
[ 28%] Built target modularsimulator
[ 28%] Built target vmddlopen
[ 28%] Generating baseversion-gen.cpp
Scanning dependencies of target libgromacs
[ 28%] Building CXX object src/gromacs/CMakeFiles/libgromacs.dir/utility/baseversion-gen.cpp.o
[ 28%] Linking CXX shared library ../../lib/libgromacs.so
[ 98%] Built target libgromacs
[ 98%] Built target view_objlib
[ 98%] Linking CXX executable ../../bin/gmx
[100%] Built target gmx
GROMACS version:    2020-MODIFIED
This program has been built from source code that has been altered and does not match the code released as part of the official GROMACS version 2020-MODIFIED. If you did not intend to use an altered GROMACS version, make sure to download an intact source distribution and compile that before proceeding.
If you have modified the source code, you are strongly encouraged to set your custom version suffix (using -DGMX_VERSION_STRING_OF_FORK) which will can help later with scientific reproducibility but also when reporting bugs.

Note that without manually running cmake, the modification is not flagged.

Associated revisions

Revision cb488214 (diff)
Added by Paul Bauer 5 months ago

Always hash files when building from release tarball

The CMake logic to check if the source files in a release tarball have
not been modified has not been robust enough in cases where people first
run cmake to generate the build directory and then later change files in
the source tree.

The build has now been changed to be more in line with the development
builds, where checking for modifications is happening in all cases.

Fixes #3302

Change-Id: Id54c529bfbe51191ed5262d8da05897b2f53c057

History

#1 Updated by Paul Bauer 7 months ago

  • Status changed from New to Accepted
  • Assignee set to Paul Bauer

Confirmed for me as well, I'll see that I change the part that checks the build

#2 Updated by Paul Bauer 7 months ago

  • Target version set to 2020.1

#3 Updated by Paul Bauer 7 months ago

reading more through gmxVersionInfo.cmake I see that the issue is that we are not anticipating changes in the build dir after configure time when building from the tarball.
Also, the parts of the file generating the information for the version info file are not run as part of a target, so we can't build a dependency on them.

This means the CMake in the file needs to be changed to also have the generation of the version info file as a target.

#4 Updated by Paul Bauer 7 months ago

  • Status changed from Accepted to Fix uploaded

#5 Updated by Paul Bauer 5 months ago

  • Status changed from Fix uploaded to Resolved

#6 Updated by Paul Bauer 5 months ago

  • Status changed from Resolved to Closed

Also available in: Atom PDF