• Looks like provision.sh first checks for existance of compiler (line 175)

    This returns true for any arm-none-eabi-gcc, even very old versions

    So it never reaches line 183/184

    Is my assumption correct, or is there some misunderstanding on my side

  • Yes, if you have an arm-none-eabi-gcc installed then it'll use that, regardless of the version.

    For most people they won't have the compiler installed, or if they installed it, it's because they have a compiler they're happy with, so it hasn't been an issue thus far.

  • For some weeks now, it is best solution to use gcc-arm-none-eabi-8-2018-q4-major
    I've done some testing based on actual provision.sh and looks like

    1. If we already have an older version of gcc-arm-none-eabi installed, provision.sh will never install v8
    2. if v8 is installed manually using command from provision.sh, older version is used, v8 is ignored
    3. after changing sequence in export to export PATH=/home/nodejs/http88/Espruino/gcc-ar­m-none-eabi-8-2018-q4-major/bin:$PATH v8 is used

    Since I'm not an expert in this area, could please someone check

  • That all sounds right to me I think?

    provision.sh just checks that there's a gcc-arm-none-eabi on the path, not which version it is.

    Since provision.sh is expecting that GCC won't be installed, it adds it to the end of the path by default - so if it was previously installed and you ran the old code manually then the old one would have ended up being used.

  • Would you see any possible problems, to install V8 always and changing sequence, so that v8 is always searched first ?

  • Yes, I think there would be problems - people may well want to use their own compiler, especially if v9 gets released and we're still on v8.

    I don't think changing the path order would be a big problem though.

    Maybe a FORCE=1 option could be added, to force the compilers/etc to always be installed even if there was one already on the path?

    However since this would appear to be for your tool, it might make sense to just modify your tool such that the existing gcc-arm-none-eabi was removed from your path before running provision.sh?

  • Removing is not a good solution for me.
    I'm one of the guys mentioned by you, having their own idea from time to time.
    And since my server is not dedicated for my tool, ...

    Looke like I'll need something like an "provision.sh-changed-event" and do the job manually.
    I'm pretty sure, this will not happen very often.
    May be https://app.github-file-watcher.com/ is a solution

  • Surely just removing the tool from the path for that one session is absolutely fine - it's not like it's global.

    For instance adding the command:

    export PATH=`echo $PATH | sed -e "s/:[^:]*arm[^:]*:/:/"`

    to your script would remove any path entry containing the text arm, just for that terminal session, and not across your whole system

    (you probably want to run echo $PATH first to check that's the correct entry to remove though)

  • Post a reply
    • Bold
    • Italics
    • Link
    • Image
    • List
    • Quote
    • code
    • Preview

Does provision check correct version for ARM boards ?

Posted by Avatar for JumJum @JumJum