DEVICE_PACKAGES: differentiate between initramfs and regular images?

With image sizes becoming stringent for rtl838x bootloaders (but not for rtl838x flash sizes) I am wondering if there is a way to make DEVICE_PACKAGES only apply to regular images only, so one could have bare initramfs images that fit the bootloader, and fuller images that allow full functionality?

The idea is at least to serve as a temporary hack, since most rtl838x devices require a ramdisk for initial installation from OEM firmware.

I've looked through include/image.mk, where the magic happens, but I'm not seeing anything obvious or simple to differentiate between both image types.

Background:

Grateful for any ideas.

you either use 2 separate .configs or you configure a new make recipe for a ""slim"" target .

If you use 2 separate configs, you may still need to adjust the defaults as shown in the patch you referenced. Depends on whats included and how slim you need to become to fit

I could compile the SDK along as well to rebuild images in a second pass, but that's not the point. The point is to be able to build all images in one go without stripping bare the actual sysupgrade images.

We're hitting this with 24.10 and with the next stable we'll be in the same boat again, needing further stripping to produce functional ramdisk images.

you can configure a target to build multiple types of images ... the makefile magic is up to you.

You seem to make a lot of assumptions, one being about my presumed lack of familiarity with the buildroot. A bit cocky for someone who's been around for a year, barely. If you know how to tackle my problem, I'd be happy to hear about it, instead of vague hints at a possible solution and 'hack at it yourself'. But I get the feeling you are missing the point of my question.

If you cannot offer it, nor any helpful tips in that direction, stay out of this thread.

I talked to one of the devs on IRC in the meantime who indicated this indeed is not as easy as it might seem at first sight, a bit similar to the per device rootfs packages (DEVICE_EXTRA_PACKAGES).