Skip to content
Snippets Groups Projects
  • David Bauer's avatar
    6b22b742
    build: fix duplicate building of host-tools · 6b22b742
    David Bauer authored
    Upstream introduced two different methods for determining the state of a
    package within the OpenWrt buildsystem. While both are based around the
    md5 hash-function, one taks filename & mtime into account while the
    other one uses the actual md5 hash of the file-content.
    
    Ever wondered why Gluon suddenly took considerably longer to build?
    The messy part is how the build-system chooses which method to use. This
    is based around the AUTOREMOVE configuration. Gluon sets this variable
    conditionally when built with GLUON_AUTOREMOVE set to 1.
    
    Enter the Gluon build-system. It first compiles Lua, without the
    AUTOREMOVE configuration passed to OpenWrt. This compiles the packages
    with the old hash-method based around filename & mtime. Afterwards, it
    builds with AUTOREMOVE enabled, changing the hash-function and
    rebuilding all host-packages.
    
    Fix this by setting AUTOREMOVE for both build-processes according to the
    setting of GLUON_AUTOREMOVE.
    
    Link: https://github.com/openwrt/openwrt/commit/53a08e37437972ba0a8fbf953a93a70a6b784ef4
    
    
    
    Signed-off-by: default avatarDavid Bauer <mail@david-bauer.net>
    6b22b742
    History
    build: fix duplicate building of host-tools
    David Bauer authored
    Upstream introduced two different methods for determining the state of a
    package within the OpenWrt buildsystem. While both are based around the
    md5 hash-function, one taks filename & mtime into account while the
    other one uses the actual md5 hash of the file-content.
    
    Ever wondered why Gluon suddenly took considerably longer to build?
    The messy part is how the build-system chooses which method to use. This
    is based around the AUTOREMOVE configuration. Gluon sets this variable
    conditionally when built with GLUON_AUTOREMOVE set to 1.
    
    Enter the Gluon build-system. It first compiles Lua, without the
    AUTOREMOVE configuration passed to OpenWrt. This compiles the packages
    with the old hash-method based around filename & mtime. Afterwards, it
    builds with AUTOREMOVE enabled, changing the hash-function and
    rebuilding all host-packages.
    
    Fix this by setting AUTOREMOVE for both build-processes according to the
    setting of GLUON_AUTOREMOVE.
    
    Link: https://github.com/openwrt/openwrt/commit/53a08e37437972ba0a8fbf953a93a70a6b784ef4
    
    
    
    Signed-off-by: default avatarDavid Bauer <mail@david-bauer.net>