Enable multiarch (32/64-bit co-installation)
Enable multiarch (32/64-bit co-installation)

It is currently not possible to have 32- and 64-bit builds of beignet
installed on the same system, as the path in intel-beignet.icd
can only be one of the two installations.  This fixes this by giving
this file a different name when beignet is installed in a multiarch
directory:
intel-beignet-i386-linux-gnu.icd -> /usr/lib/i386-linux-gnu/beignet/libCL.so
intel-beignet-x86_64-linux-gnu.icd -> /usr/lib/x86_64-linux-gnu/beignet/libCL.so

Discussion and possible alternative approaches:
http://lists.alioth.debian.org/pipermail/pkg-opencl-devel/Week-of-Mon-20150223/date.html

While preparing this patch I noticed that intel-beignet.icd.in
uses @LIB_INSTALL_DIR@/beignet/ rather than @BEIGNET_INSTALL_DIR@,
which will obviously break if the latter is set directly. Is
that a bug or is this intended to be an internal-only variable?

Signed-off-by: Rebecca Palmer <2decb937e7eca5e941ec22bc308fd452fe4ab2bb@zoho.com>
Reviewed-by: Zhigang Gong <e04a7b9b70b1e4c6318cf117dcd1a9056e14b97a@linux.intel.com>

zhenyw/beignet,zhenyw/beignet,wdv4758h/beignet,freedesktop-unofficial-mirror/beignet,wdv4758h/beignet,wdv4758h/beignet,zhenyw/beignet,wdv4758h/beignet,zhenyw/beignet,wdv4758h/beignet,freedesktop-unofficial-mirror/beignet,zhenyw/beignet,freedesktop-unofficial-mirror/beignet,freedesktop-unofficial-mirror/beignet