[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Bug#498138: check for deprecated OCaml -custom linked executable



Stefano Zacchiroli wrote:
> As such, we would like to add a lintian check to warn against OCaml
> custom mode executable. They can easily detected by looking for a magic
> number at the end of the file, as described in the forwarded mail from
> upstream.

Libraries can force custom mode executables. Therefore, I think they
should also be checked.

This check is quite easy using the ocamlobjinfo tool: it prints "Force
custom: YES" when given a faulty .cma.

BTW, on my system:

for u in /usr/lib/ocaml/3.10.2/**/*.cma; do ocamlobjinfo $u|sed "s@^@$u:
@"; done|grep 'Force custom: YES'

returns:

/usr/lib/ocaml/3.10.2/bjack/bjack.cma:   Force custom: YES
/usr/lib/ocaml/3.10.2/ssl/ssl.cma:   Force custom: YES
/usr/lib/ocaml/3.10.2/ssl/ssl_threads.cma:   Force custom: YES


Cheers,

-- 
Stéphane Glondu







Reply to: