Added platform dependency chacks for GL calls