[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: customize bootloader

On Fri, May 23, 2014 at 2:08 PM, chals <chals@chalsattack.com> wrote:
> On Fri, May 23, 2014 at 7:59 AM, Federico Bruni <fede@inventati.org> wrote:
>> All I need now is replacing @PROJECT@ and @VERSION@.
> The live-build system gives you many options when it comes to
> customizing things to your liking. You can use for example a binary
> hook.
> Your hook will be executed after the syslinux files are in place, so
> it should be trivial to make the "small" changes you want to.

Here I am again replying to myself. I realized that my quoting in the
previous message that I sent to the list was a bit crazy and I didn't
feel quite satisfied with it. This happens when you reply in a
hurry!!!. So I would like to take a chance and try to explain my point
a little bit better. Thanks for listening!

Let me recap:

First, the bootloaders chapter of live-manual as is now, mostly deals
with how to make minor customizations of your bootloader configuration
files. Most people ask things like how to change the default timeout
or how to change the splash image. It is sort of a faq. The most
important information on the chapter is that if you do not want to
bother creating your own theme, you can use one which is ready for
production, located in /usr/share/live/build/bootloaders. You can make
as many modifications as you please to the default theme.

Second, in my opinion, using your own personal syslinux theme gives
you the maximum flexibility. So it should be the preferred option.
Besides, you can do it like a pro if you do it in an scalable way,
packaging it. Correct me if I'm wrong.

Third (your use case),  you would like to use the default theme but
you want to do some additional processing of the splash.svg file.
live-build, as far as I know, does not provide an automatic way of
doing what you want. But you can take advantage of live-build's
increasing flexibility and achieve your aim relatively painlessly.

Pointing you to the binary_syslinux script I think I gave you the
hints to achieve your goal. You can use a similar method. I would use,
like I told you in my previous message, a binary hook.

Once all the syslinux files are in place (and have been processed by
live-build) you can run your binary hook which should be capable of
performing the following steps ( You already succeeded changing the
icon, so I'm skipping that part):

1.- copy the splash.svg file from ../config/bootloaders/isolinux/ to isolinux/

2.- Use sed to make the substitutions you wish
and so forth...

3.- Finally, convert the isolinux/splash.svg to isolinux/splash.png

And be happy with it. It is as easy as it seems :)

Sorry for the long message (again) but I try hard to explain things as
carefully as I can. I do not know if I'm right or wrong. I'm trying to
give you ideas and options for you to experiment with.

Have lots of fun and a really great weekend!


Reply to: