3.1.1. Building and running a sample from a Windows workstation

All of the samples can be built and run from the command line.

To use a terminal to build and run a sample on Microsoft Windows for the Mali OpenGL ES 2.0 Emulator:

  1. Open a Visual Studio command prompt.

  2. Change to the Mali SDK installation directory.

  3. To list the samples, enter:

    build-x86-win32.bat --help
    
  4. Run the batch file to build the samples:

    • To build all of the samples, enter:

      build-x86-win32.bat 
      
    • To build a single sample named sample_name, enter:

      build-x86-win32.bat sample_name 
      
  5. The binary for the sample is created in build\x86\sample_name.

  6. Run the binary to execute the OpenGL ES 2.0 code under emulation on your desktop.

To use a terminal to build a sample on Microsoft Windows to run under Linux on an ARM device:

  1. Open a command prompt.

  2. To list the samples, enter:

    build-arm-linux.bat --help
    
  3. Change to the Mali SDK root directory.

  4. Run the batch file:

    • To build all of the samples, enter:

      build-arm-linux.bat
      
    • To build a single sample named sample_name, enter:

      build-arm-linux.bat sample_name 
      
  5. The binary for the sample is created in build\arm\sample_name.

  6. The sample folder contains the binary file and the assets. Copy the folder to the computer with the ARM processor and run it there.

Copyright © 2011 ARM. All rights reserved.ARM DUI 0607A
Non-ConfidentialID120411