pengutronix / genimage

tool to generate multiple filesystem and flash images from a tree
GNU General Public License v2.0
298 stars 107 forks source link

genimage include paths confusion? #228

Open milkylainen opened 9 months ago

milkylainen commented 9 months ago

I have a genimage configuration, consisting of only basenames for image directives. So I was expecting to add search paths to images via the includepath option. But the actual configuration file was specified as an absolute path in the call to genimage: (Please excuse some redacting of text for privacy reasons. I think the point gets through anyway.)

$ strace genimage --config /home/user/work/image.raw.cfg --includepath /home/user/work/images:/srv/tftp --outputpath /home/user/work/images

brk(0x55ed2f1f3000) = 0x55ed2f1f3000 stat("/home/user/work/images//home/user/work/image.raw.cfg", 0x7ffd3ac19060) = -1 ENOENT (No such file or directory) stat("/srv/tftp//home/user/work/image.raw.cfg", 0x7ffd3ac19130) = -1 ENOENT (No such file or directory) stat(".//home/user/work/image.raw.cfg", 0x7ffd3ac19200) = -1 ENOENT (No such file or directory) write(2, "ERROR: could not open config fil"..., 91ERROR: could not open config file '/home/user/work/image.raw.cfg' ) = 91 exit_group(1) = ? So it's a bit confusing, including the error message. The file is definitely there in the absolute path. Either all paths should be offset (but I don't think the manual explicitly says so for configs), or I would have expected an absolute path to be used, at least for config.
michaelolbrich commented 7 months ago

In genimage we just pass the filename to libconfuse. I think it's this issue: libconfuse/libconfuse#154.

Does it work without --includepath?