cmake: Enable CMP0042 @rpath usage for MacOSX
cmake: CMP0042 is set conditionally, default to 2.8 behaviour
Fix channel count when exporting RGB images

Fixes #12091, #11569.
Merge pull request #1175 from melissalinkert/rgb-export

Fix channel count when exporting RGB images in ImageJ
Merge pull request #1170 from rleigh-dundee/macosx-rpath-cmake3

cmake: Enable CMP0042 @rpath usage for MacOSX