Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

pkg(1) continues after pre-install script fails

18 views
Skip to first unread message

Tijl Coosemans

unread,
Aug 3, 2016, 11:04:28 AM8/3/16
to
The linux_base-* packages require Linux support in the kernel during
installation because they run /compat/linux/sbin/ldconfig. The packages
have a PRE-INSTALL script that checks this and returns an error if the
support isn't there, but pkg(1) ignores such errors and continues to
install the files anyway. Then it runs ldconfig via POST-INSTALL which
fails but errors from this are also ignored and pkg(1) exits normally.
It looks like this:

sysctl: unknown oid 'compat.linux.osrelease'
linuxulator is not (kld)loaded, exiting
pkg-static: PRE-INSTALL script failed
ELF binary type "0" not known.
/bin/sh: /compat/linux/sbin/ldconfig: Exec format error
pkg-static: POST-INSTALL script failed

Shouldn't pkg(1) abort when pre-install fails and return an error when
post-install fails?
_______________________________________________
freebs...@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-ports
To unsubscribe, send any mail to "freebsd-port...@freebsd.org"

Baptiste Daroussin

unread,
Aug 3, 2016, 12:16:05 PM8/3/16
to
On Wed, Aug 03, 2016 at 05:03:01PM +0200, Tijl Coosemans wrote:
> The linux_base-* packages require Linux support in the kernel during
> installation because they run /compat/linux/sbin/ldconfig. The packages
> have a PRE-INSTALL script that checks this and returns an error if the
> support isn't there, but pkg(1) ignores such errors and continues to
> install the files anyway. Then it runs ldconfig via POST-INSTALL which
> fails but errors from this are also ignored and pkg(1) exits normally.
> It looks like this:
>
> sysctl: unknown oid 'compat.linux.osrelease'
> linuxulator is not (kld)loaded, exiting
> pkg-static: PRE-INSTALL script failed
> ELF binary type "0" not known.
> /bin/sh: /compat/linux/sbin/ldconfig: Exec format error
> pkg-static: POST-INSTALL script failed
>
> Shouldn't pkg(1) abort when pre-install fails and return an error when
> post-install fails?

It has been reverted because the number of script failing in the ports tree
is still too high :(

Bapt
signature.asc

Tijl Coosemans

unread,
Aug 3, 2016, 12:58:55 PM8/3/16
to
Can you provide a patch that enables this again and request an exp-run?
0 new messages