genimage icon indicating copy to clipboard operation
genimage copied to clipboard

genimage include paths confusion?

Open milkylainen opened this issue 2 years ago • 1 comments

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.

milkylainen avatar Oct 23 '23 13:10 milkylainen

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

Does it work without --includepath?

michaelolbrich avatar Dec 15 '23 14:12 michaelolbrich