Correct way to compile latest stable LE8.2.5?

  • I was wondering if this indeed is the correct way to compile the last/latest libreelec 8.2.5, this is what I did:

    ------------------------------------------------------

    Ubuntu (16.x) preparations

    ------------------------------------------------------

    Code
    sudo apt update && sudo apt upgrade
    
    sudo apt install gcc make git unzip wget xz-utils
    
    sudo dpkg-reconfigure dash

    ------------------------------------------------------

    Had some Perl errors earlier on, so...

    ------------------------------------------------------

    Code
    sudo apt-get install libxml-parser-perl
    
    sudo perl -e shell -MCPAN
    install XML::Parser
    exit

    ------------------------------------------------------

    Github cloning (and reverse to 8.2.5)

    ------------------------------------------------------

    Code
    cd ~
    
    git clone https://github.com/LibreELEC/LibreELEC.tv.git -b libreelec-8.2 LibreELEC.tv.8.2.5
    
    cd ~/LibreELEC.tv.8.2.5
    
    git checkout 8.2.5
    git reset --hard 0beeae9

    Branch librelec-8.2:

    Latest Commit =0beeae9

    Merge Pull Request #2648

    ------------------------------------------------------

    Compile LE825

    ------------------------------------------------------

    Code
    PROJECT=RPi2 ARCH=arm tools/download-tool
    
    PROJECT=RPi2 ARCH=arm IMAGE_SUFFIX=v825 make image

    .

    This does seem to work and function, I was just wondering if I got it the right way, I mean like the correct branch/checkout for the absolute latest/current (stable) libreelec 8.2.5 version.

    Kind regards

    Edited 2 times, last by apoc (May 23, 2018 at 3:04 PM).

    • Official Post

    The "git reset --hard" isn't necessary because you already checked-out the repo at a specific tag, and IMAGE_SUFFIX=v825 isn't required as the 8.2.5 version is part of the release image filename. Also be aware that the repo-tool script will download the sources for all packages in the build system; whereas if you allow them to be downloaded at build-time you only download sources for the packages used in the image you create. Apart from that (and one typo, which I corrected) all looks fine.

    If you plan to build/rebuild things I'd recommend moving the 'sources' folder somewhere outside the main git folder and then creating a symlink to it. This allows you to nuke the git folders and re-clone (or share sources between multiple git folders) without having to re-download or duplicate all the sources. If you're a git novice it's kind of inevitable that at some point things get screwed up and the easiest way forwards is to nuke/clone again, and downloading sources adds time to the build process. NB: It takes a while to get the hang of git and everyone makes mistakes at first (nobody ever stops learning).

  • What typo do/did you mean?

    Apart from that (and one typo, which I corrected)

    But no harm is done right?

    Besides the fact that some extra download time was/is added for downloading unnecessary packages before the actual compiler will begin I guess?

    Also be aware that the repo-tool script will download the sources for all packages in the build system; whereas if you allow them to be downloaded at build-time you only download sources for the packages used in the image you create

    • Official Post

    It was an extra "cd" on the end of a command. It looked like a simple copy/paste error so I edited the post. If you'd gotten the commands wrong you wouldn't have built an image :)

    There's no harm from running repo-tool but it's not necessary and you're using disk space for packages you won't use, e.g. if you build RPi2 you'll also end up grabbing the kernel sources for 3x Amlogic kernels, 1x Rockchip kernel, and all the hardware specific packages for those build targets. I'd guesstimate it's an extra ~1GB of data.