Omission of the login argument in sudo_run_command will make the call to su(1)
fail on FreeBSD, NetBSD, DragonFLy, Darwin and any other UNIX where the su(1)
executable is not a GNU coreutils (derived) su.
Either because the '-c' option before the login argument defines a 'login class'
or because the '-c' option is not defined at all.
su root -c 'the command string to be executed'
will pass '-c' to the spawned shell and work on every platform.
fixes ocaml/opam-depext#51 (however newer MacOS installations tend
to have no root password set)
Port #106 to 2.0 branch
Omission of the login argument in sudo_run_command will make the call to su(1) fail on FreeBSD, NetBSD, DragonFLy, Darwin and any other UNIX where the su(1) executable is not a GNU coreutils (derived) su. Either because the '-c' option before the login argument defines a 'login class' or because the '-c' option is not defined at all.
su root -c 'the command string to be executed'
will pass '-c' to the spawned shell and work on every platform.
fixes ocaml/opam-depext#51 (however newer MacOS installations tend to have no root password set)