Define "platform" variable
add debug code for buildpackage
Switch to grains["osrelease"]|int to check osmajorrelease

The minion deployed to the build VMs seems to be an older version, where
a bug recently fixed in the osmajorrelease grain has not been fixed.
This makes sense as we don't want the build VM to be at the mercy of
code in the branch being tested.

This commit coerces the value of grains["osrelease"] to an integer in
order to determine the major release.