Bug 98166

Summary: [vulkan, radv] make install regenerates radv_timestamp.h and rebuilds radv_device.lo
Product: Mesa Reporter: Vedran Miletić <vedran>
Component: Drivers/Vulkan/radeonAssignee: mesa-dev
Status: RESOLVED FIXED QA Contact: mesa-dev
Severity: normal    
Priority: medium    
Version: git   
Hardware: Other   
OS: All   
Whiteboard:
i915 platform: i915 features:

Description Vedran Miletić 2016-10-08 19:25:40 UTC
Making install in amd/vulkan
make[3]: Entering directory '/home/vedranm/workspace/mesa/src/amd/vulkan'
Updating radv_timestamp.h
  GEN      radv_timestamp.h
make  install-am
make[4]: Entering directory '/home/vedranm/workspace/mesa/src/amd/vulkan'
Updating radv_timestamp.h
  GEN      radv_timestamp.h
  CC       radv_device.lo
  CCLD     libvulkan_common.la
  CXXLD    libvulkan_radeon.la
  GEN      .install-mesa-links
make[5]: Entering directory '/home/vedranm/workspace/mesa/src/amd/vulkan'
Updating radv_timestamp.h
  GEN      radv_timestamp.h
  CC       radv_device.lo
  CCLD     libvulkan_common.la
  CXXLD    libvulkan_radeon.la
 /usr/bin/mkdir -p '/usr/local/lib64'
 /bin/sh ../../../libtool   --mode=install /usr/bin/install -c   libvulkan_radeon.la '/usr/local/lib64'
libtool: install: /usr/bin/install -c .libs/libvulkan_radeon.so /usr/local/lib64/libvulkan_radeon.so
libtool: install: /usr/bin/install -c .libs/libvulkan_radeon.lai /usr/local/lib64/libvulkan_radeon.la
libtool: finish: PATH="/sbin:/bin:/usr/sbin:/usr/bin:/sbin" ldconfig -n /usr/local/lib64
----------------------------------------------------------------------
Libraries have been installed in:
   /usr/local/lib64

Would be much if it was regenerated/rebuilt only on make and not on make install.
Comment 1 Emil Velikov 2016-10-10 12:53:18 UTC
(In reply to Vedran Miletić from comment #0)
> Would be much if it was regenerated/rebuilt only on make and not on make
> install.

much better ? Indeed it would.

Sadly given the constrains I cannot think of anything nicer I'm afraid. The gist is that the file must be updated on incremental builds and we cannot ensure that not files are changed/rebuild between build and install stage. For the experiments and a lot more context check the git history, and mailing list, for anv_timestamp.h.

One 'workaround' is to use SOURCE_DATE_EPOCH as described here [1].
[1] https://reproducible-builds.org/specs/source-date-epoch/
Comment 2 Emil Velikov 2016-11-24 21:08:43 UTC
Should not longer be the case with

commit d94383970f2cad9f474760b18fd277efeda4c612
Author: Bas Nieuwenhuizen <bas@basnieuwenhuizen.nl>
Date:   Tue Nov 22 00:19:30 2016 +0100

    radv: Use library mtime for cache UUID.

Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.