title: Running CMake on Amazon Linux
body: <p>I am trying to build OpenJpeg on an AWS Amazon Linux EC2 instance. I installed cmake and gcc and had no issues during installation. When I try to cmake openjpeg I get the following error:</p>
  
  <pre><code>-- Check if the system is big endian
  -- Searching 16 bit integer
  CMake Error at /usr/share/cmake/Modules/TestBigEndian.cmake:44 (message):
    no suitable type found
  Call Stack (most recent call first):
    CMakeLists.txt:164 (TEST_BIG_ENDIAN)
  
  
  -- Configuring incomplete, errors occurred!
  </code></pre>
  
  <p>Checking the error logs it seems CMake is unable to determine the size of integers, shorts and longs. The full error log can be found in <a href="https://gist.github.com/redserpent7/596dc1f74fde92fe7a595f219bf68e8c#file-cmakeerror-log" rel="noreferrer">this gist</a></p>
  
  <p>How can I work this out and make CMake work?</p>