Skip to content
Snippets Groups Projects
  • Adrian Schmutzler's avatar
    buildscript: Remove target binaries from build dir before building · 8edb1689
    Adrian Schmutzler authored
    
    So far, if build fails, but images from last successful build are
    present in OpenWrt build directory (build/bin/targets/...), those
    are copied even after unsuccessful build.
    
    This results in the old images being copied to the bin folder and
    being labelled with the new firmware revision. (!)
    As our error check also only looks at whether images are there,
    the image copying process will look like a success.
    
    This patch deletes old images of the target/subtarget to be built,
    so that the copy-firmware step will find nothing if the build
    stop to early.
    
    Signed-off-by: default avatarAdrian Schmutzler <freifunk@adrianschmutzler.de>
    Reviewed-by: default avatarFabian Bläse <fabian@blaese.de>
    8edb1689