Revert "Fix build on big endian system"

This reverts commit 87152adc39ea8e15f1b67df4d80e55f03c718fd8.
Fix build on big endian system

Fixes #11136

(cherry picked from commit 1b56fcc29ab868b2f06ec7e0f8d02c01581daae5)