Use libelf to find the location of the settings struct
Give better hints to the compiler on this logic
Reading should use MAP_PRIVATE
Reduce duplicated logic
Give a hint that we are sequentially reading memory

At least on FreeBSD this lowered page faults from 92 to 84
Don't remove the main binary when making a copy
Update bdlib for AtomicFile
Don't try munmap(NULL)
Use bd::AtomicFile to avoid cross-device renaming from Tempfile

This also removes the need for making a copy of the file. The copy was
never setup be restored anyhow.
Write userfile with AtomicFile
Import libelf 0.8.13
Build bundled libelf and link statically if needed
Document libelf change
Fix detection of errors when compiling
Merge branch 'maint'

* maint:
  Fix detection of errors when compiling
Merge branch 'binary-libelf' into next

* binary-libelf:
  Document libelf change
  Build bundled libelf and link statically if needed
  Import libelf 0.8.13
  Write userfile with AtomicFile
  Use bd::AtomicFile to avoid cross-device renaming from Tempfile
  Don't try munmap(NULL)
  Update bdlib for AtomicFile
  Don't remove the main binary when making a copy
  Give a hint that we are sequentially reading memory
  Reduce duplicated logic
  Reading should use MAP_PRIVATE
  Give better hints to the compiler on this logic
  Use libelf to find the location of the settings struct

Conflicts:
	doc/UPDATES
	lib/bdlib
	src/userrec.c
Remove AIX/MINIX support
Merge branch 'maint'

* maint:
  Remove AIX/MINIX support

Conflicts:
	configure
Add missing libelf.m4
Merge branch 'binary-libelf' into next

* binary-libelf:
  Add missing libelf.m4