build: fix install race condition

It was observed in a Yocto build of openbmc/openbmc:

    chmod: cannot access '/home/jenkins-slave/workspace/ci-openbmc/
    distro/ubuntu/label/docker-builder/target/witherspoon/build/work/
    arm1176jzs-openbmc-linux-gnueabi/pam-ipmi/
    1.0+gitAUTOINC+f3919c432f-r1/image/etc/ipmi_pass': No such file
    or directory

This is caused by a race condition between 'install-exec', which
installs sysconf data, and 'install-data', which has a hook to chmod the
sysconf data.  Switch from 'install-data-hook' to 'install-exec-hook' to
prevent race condition.

Per the Autotools documentation:
    Variables using the standard directory prefixes ‘bin’, ‘sbin’,
    ‘libexec’, ‘sysconf’, ‘localstate’, ‘lib’, or ‘pkglib’ are installed
    by install-exec.

Fixes openbmc/openbmc#3671.

Signed-off-by: Patrick Williams <patrick@stwcx.xyz>
Change-Id: Ib6c85e77e8e10af0038feb7d0a5d35d81c958e98
1 file changed