pkgsrc-Users archive

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

bmake on OpenBSD (unsupported malloc option "A")



Hi,

I'm running OpenBSD-current and use pkgsrc for some things.

I am noticing that bmake keeps reporting

    malloc() warning: unknown char in MALLOC_OPTIONS

This is because the job.c file in the bmake distribution defines

    const char *malloc_options="A";

which on NetBSD means

A   All warnings (except for the warning about unknown flags being set)
    become fatal.  The process will call abort(3) in these cases.

This malloc option is not available on OpenBSD.

In my local version of bmake, I have changed this to instead use "S"
(which is not equivalent):

S   Enable all options suitable for security auditing.

This is, I believe (after reading the sources), equivalent of using "CGJ":

C   “Canaries”.  Add canaries at the end of allocations in order to
    detect heap overflows.  The canary's content is checked when free(3)
    is called.  If it has been corrupted, the process is aborted.

G   “Guard”.  Enable guard pages.  Each page size or larger allocation
    is followed by a guard page that will cause a segmentation fault
    upon any access.

J   “More junking”.  Increase the junk level by one if it is smaller than 2.

I'd just thought I'd mention this if anyone else is annoyed by the
warning message on OpenBSD for each invocation of the tool.

Cheers,
Kusalananda


Home | Main Index | Thread Index | Old Index