Open vidavidorra opened 8 years ago
I have done a base test on the time needed for downloading and installing the IDE and compiler, of which the results can be found in the table below.
Description | Size [MB] (optional) | Time [s] |
---|---|---|
Downloading IDE | 548 | 47 |
Unpacking IDE | 0 | |
Installing IDE | 61 | |
Downloading compiler | 59 | 3.5 |
Installing compiler | 37 | |
Total | 149.51 |
These times are based on this build.
Info
When building on the Travis CI server the
travis-install-dependencies.sh
script is called. This downloads and installs the MPLAB X IDE and compiler, where the IDE is around 550 MB and takes about a minute to install (strongly depending on the workload of the servers).It would be nice to make shorten the time needed to download and install this IDE. To clarify, from the downloaded IDE only Java, the
prjMakefilesGenerator.sh
script and the config file are used. This is about 200 MB and it would be quicker to install just the files that are needed for the build.Generate make files script
In this make file script the following variables are used.
here
/opt/microchip/mplabx/v3.15/mplab_ide/bin
mplabx_dir
/opt/microchip/mplabx/v3.15/mplab_ide
netbeans_dir
/opt/microchip/mplabx/v3.15/mplab_ide
development_netbeans_dir
/opt/microchip/mplabx/v3.15/mplab_ide/mplabide-nb-platform/nbbuild/netbeans
gen_jar
opt/microchip/mplabx/v3.15/mplab_ide/lib/PrjMakefilesGenerator.jar
os
Linux
jdkhome
/opt/microchip/mplabx/v3.15/sys/java/jre1.8.0_60
jvm
/opt/microchip/mplabx/v3.15/sys/java/jre1.8.0_60/bin/java
So at least the following files/folders would be needed to run this script.
mplab_ide.conf
/opt/microchip/mplabx/v3.15/mplab_ide/etc/mplab_ide.conf
jdkhome
variable/opt/microchip/mplabx/v3.15/sys/java/jre1.8.0_60
jvm
/opt/microchip/mplabx/v3.15/sys/java/jre1.8.0_60/bin/java
Which would result in a size of around 200 MB.
Possible solution
In order to reduce the time needed for downloading and installing this IDE a custom package for the IDE would need to be made. This package needs to contain at least the files and folders listed in the table above Along with the files of that script obviously. This would result in the following files and folders.
It those files and folders could be placed in a
.tar.gz
archive which would only need to be extracted it could result in reducing the time needed for the build with about 80 seconds, which would be about 40 % (based on a build time of 3 minutes).Steps
prjMakefilesGenerator.sh
script still works;.tar.gz
archive containing the files and folders listed above;.tar.gz
archive on the new clean Linux VM and extract it;prjMakefilesGenerator.sh
script works;prjMakefilesGenerator.sh
script if needed and test again;.tar.gz
archive on a Travis CI build and measure the time needed for downloading and extracting the archive to see if the time is improved;.tar.gz
archive and create instructions on how to use it.