Control: severity -1 important On Mon, 02 Jun 2014, Simon McVittie wrote: > update-binfmts: warning: /usr/share/binfmts/cli: no executable /usr/bin/cli > found, but continuing anyway as you request > update-binfmts: warning: found manually created entry for cli in > /proc/sys/fs/binfmt_misc; leaving it alone
I have been bitten by this on official Kali isos. I'm taking the liberty to upgrade this to important as it breaks other packages... for instance a package depending on jarwrapper expects to have /usr/bin/burpsuite as a jar file to be working. And due to this bug, it's not the case in the live image. https://bugs.kali.org/view.php?id=2466 > Workaround: echo -1 > /proc/sys/fs/binfmt_misc/status before each build. Thanks for this. Note that update-binfmts enables it back but the whole status is lost and thus it avoids this problem. But it's not clean as it doesn't allow parallel build of multiple ISO (which is something I'd like to be able to do). IMO update-binfmts should always record the entry in its database and just let act_enable() do nothing when it detects that it's already enabled in some other way. The attached patch should do this, I'm going to try this on the Kali side. Cheers, -- Raphaël Hertzog ◈ Debian Developer Support Debian LTS: http://www.freexian.com/services/debian-lts.html Learn to master Debian: http://debian-handbook.info/get/
diff --git a/src/update-binfmts.c b/src/update-binfmts.c index e271158..857b214 100644 --- a/src/update-binfmts.c +++ b/src/update-binfmts.c @@ -526,7 +526,7 @@ static int act_disable (const char *name) static int act_install (const char *name, const struct binfmt *binfmt) { - char *admindir_name, *procdir_name; + char *admindir_name; load_format (name, 1); if (kvhash_exists (formats, name)) { @@ -561,27 +561,6 @@ static int act_install (const char *name, const struct binfmt *binfmt) return 0; } } - procdir_name = xasprintf ("%s/%s", procdir, name); - if (exists (procdir_name) && !test) { - /* This is a bit tricky. If we get here, then the kernel knows - * about a format we don't. Either somebody has used binfmt_misc - * directly, or update-binfmts did something wrong. For now we do - * nothing; disabling and re-enabling all binary formats will fix - * this anyway. There may be a --force option in the future to help - * with problems like this. - * - * Disabled for --test, because otherwise it never works; the - * vagaries of binfmt_misc mean that it isn't really possible to - * find out from userspace exactly what's going to happen if people - * have been bypassing update-binfmts. - */ - warning ("found manually created entry for %s in %s; leaving it alone", - name, procdir); - free (procdir_name); - free (admindir_name); - return 1; - } - free (procdir_name); if (test) { printf ("install the following binary format description:\n");