in two words, I need a compiler for *.ino files and the bootloader on the Board, separate from the Arduino IDE. And I would like it to be a lightweight solution.
That seems very clear - why didn't you say so up front.
If you compile an Arduino program using verbose mode you will see the full list of commands that are used in the compile process. Any other program could exceute the same commands.
I presume the bootloader is just a hex file that gets uploaded to the Arduino.
I suspect it would be reasonably straightforward to create your own system to compile and upload code for a single type of Arduino. But I also suspect that there would be a huge workload in making your system capable of dealing with the wide range of boards that the Arduino IDE can work with.
The Arduino IDE is written in Java and I suspect a large part of the IDE download is a copy of the JVM.
Are you aware that you can call the IDE from the command line? I write my Arduino code using the Geany editor and it calls a short Python program to compile and upload the code using the IDE from the command line.