Fwd: Bug#981584: scons: MD5-timestamp decider does no longer follow symlinks

Bill Deegan <[email protected]>
Newsgroups gmane.comp.programming.tools.scons.user
Message-ID <CAEyG4CHfLQsCbJAvXFvHMOizKdmfr-2twydhbnu9XMtW0SOofg@mail.gmail.com>
Forwarded from Debian bug report.

---------- Forwarded message ---------
From: Robert Luberda <[email protected]>
Date: Mon, Feb 1, 2021 at 10:39 AM
Subject: Bug#981584: scons: MD5-timestamp decider does no longer follow
symlinks
To: Debian Bug Tracking System <[email protected]>


Package: scons
Version: 4.0.1+dfsg-2
Severity: normal
Tags: upstream

Hi,

I'm attaching a simple test project that:
- contains hello2.c file that is symbolic link to hello.c file;
- and sets 'MD5-timestamp' as the decider function.

Previously (what I'm proving at the bottom of this mail) scons used
to build hello2 when hello.c was changed. In the current version of
scons only hello gets rebuilt.

# Initial compilation with scons 4:
  robert@vox:/tmp/proj$ scons --debug=explain
  scons: Reading SConscript files ...
  scons: done reading SConscript files.
  scons: Building targets ...
  scons: building `hello.o' because it doesn't exist
  gcc -o hello.o -c hello.c
  scons: building `hello' because it doesn't exist
  gcc -o hello hello.o
  scons: building `hello2.o' because it doesn't exist
  gcc -o hello2.o -c hello2.c
  scons: building `hello2' because it doesn't exist
  gcc -o hello2 hello2.o
  scons: done building targets.

# The following command changes both hello.c and hello2.c...
  robert@vox:/tmp/proj$ sed -i -e 's/word/WoRd/i' hello.c

# ... but hello2.c is not rebuilt:
  robert@vox:/tmp/proj$ scons --debug=explain
  scons: Reading SConscript files ...
  scons: done reading SConscript files.
  scons: Building targets ...
  scons: rebuilding `hello.o' because:
             `hello.c' changed
             `/usr/bin/gcc' changed
  gcc -o hello.o -c hello.c
  scons: rebuilding `hello' because:
             `hello.o' changed
             `/usr/bin/gcc' changed
  gcc -o hello hello.o
  scons: done building targets.

  robert@vox:/tmp/proj$ scons -v
  SCons by Steven Knight et al.:
        SCons: v4.0.1.c289977f8b34786ab6c334311e232886da7e8df1, 2020-07-17
01:50:03, by bdbaddog on ProDog2020
        SCons path: ['/usr/lib/python3/dist-packages/SCons']
  Copyright (c) 2001 - 2020 The SCons Foundation



After downgrading scons to 3.1.2+dfsg-0.1, it works as I would expect:

# Initial compilation with scons 3:
  robert@vox:/tmp/proj$ scons --debug=explain
  scons: Reading SConscript files ...
  scons: done reading SConscript files.
  scons: Building targets ...
  scons: building `hello.o' because it doesn't exist
  gcc -o hello.o -c hello.c
  scons: building `hello' because it doesn't exist
  gcc -o hello hello.o
  scons: building `hello2.o' because it doesn't exist
  gcc -o hello2.o -c hello2.c
  scons: building `hello2' because it doesn't exist
  gcc -o hello2 hello2.o
  scons: done building targets.

# Still both files are changed by the following command:
  robert@vox:/tmp/proj$ sed -i -e 's/word/WORd/i' hello.c
# ... and both are rebuilt:
  robert@vox:/tmp/proj$ scons --debug=explain
  scons: Reading SConscript files ...
  scons: done reading SConscript files.
  scons: Building targets ...
  scons: rebuilding `hello.o' because:
             `hello.c' changed
             `/usr/bin/gcc' changed
  gcc -o hello.o -c hello.c
  scons: rebuilding `hello' because:
             `hello.o' changed
             `/usr/bin/gcc' changed
  gcc -o hello hello.o
  scons: rebuilding `hello2.o' because:
             `hello2.c' changed
             `/usr/bin/gcc' changed
  gcc -o hello2.o -c hello2.c
  scons: rebuilding `hello2' because:
             `hello2.o' changed
             `/usr/bin/gcc' changed
  gcc -o hello2 hello2.o
  scons: done building targets.

  robert@vox:/tmp/proj$  scons -v
  SCons by Steven Knight et al.:
        script: v3.1.2.bee7caf9defd6e108fc2998a2520ddb36a967691, 2019-12-17
02:07:09, by bdeegan on octodog
        engine: v3.1.2.bee7caf9defd6e108fc2998a2520ddb36a967691, 2019-12-17
02:07:09, by bdeegan on octodog
        engine path: ['/usr/lib/scons/SCons']
  Copyright (c) 2001 - 2019 The SCons Foundation


Regards,
robert


-- System Information:
Debian Release: bullseye/sid
  APT prefers unstable-debug
  APT policy: (990, 'unstable-debug'), (990, 'unstable'), (990, 'testing'),
(990, 'stable'), (500, 'stable-updates'), (500, 'unstable'), (500, 'stable')
Architecture: amd64 (x86_64)
Foreign Architectures: i386


Versions of packages scons depends on:
ii  python3                3.9.1-1
ii  python3-pkg-resources  51.3.3-1

scons recommends no packages.

scons suggests no packages.

-- no debconf information

_______________________________________________
Scons-users mailing list
[email protected]
https://pairlist4.pair.net/mailman/listinfo/scons-users
scons-test-project.tar.gz (application/gzip, 368 B) - not displayed
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.