OpenWrt Forum Archive

Topic: How do I add files to an image?

The content of this topic has been archived on 8 Apr 2018. There are no obvious gaps in this topic, but there may still be some posts missing at the end.

I have external binaries (that have their own built system built) for the OpenWrt running device that I have, is there an easy way to copy these binaries, their config files etc to some directory in the kamikaze built environment to get them bundled in the root filesystem (root.squashfs) so I do not need to wget all of them from my server every time I boot the device?

Just in case it is relevant, my device is ppc40x (kilauea)

Yes. Just put them under the files sud-directory sturcture on your OpenWRT main root directory. For instance, if you want to include /usr/lib/libfile.so.1.2.3 file, you would copy this file to files/usr/lib/libfile.so.1.2.3 under your OpenWRT directory. This way, the compilation process will include the /usr/lib/libfile.so.1.2.3 file to the built firmware.

mazilo wrote:

Yes. Just put them under the files sud-directory sturcture on your OpenWRT main root directory. For instance, if you want to include /usr/lib/libfile.so.1.2.3 file, you would copy this file to files/usr/lib/libfile.so.1.2.3 under your OpenWRT directory..

Umm, where is the OpenWrt "main root" directory. Top level of the build environment? (the one you run 'make' in) or somewhere down in the hierarchy?

kimvais wrote:

Umm, where is the OpenWrt "main root" directory. Top level of the build environment? (the one you run 'make' in) or somewhere down in the hierarchy?

Correct, in the top level where you run make from.

The discussion might have continued from here.