First SDL application on the playbook, builds, but does not create a binary file.

/*This source code copyrighted by Lazy Foo' Productions (2004-2012)
and may not be redestributed without written permission.*/

//Include SDL functions and datatypes
#include "SDL.h"

int main( int argc, char* args[] )
{
    //The images
    SDL_Surface* hello = NULL;
    SDL_Surface* screen = NULL;

    //Start SDL
    SDL_Init( SDL_INIT_EVERYTHING );

    //Set up screen
    screen = SDL_SetVideoMode( 640, 480, 32, SDL_SWSURFACE );

    //Load image
    hello = SDL_LoadBMP( "hello.bmp" );

    //Apply image to screen
    SDL_BlitSurface( hello, NULL, screen, NULL );

    //Update Screen
    SDL_Flip( screen );

    //Pause
    SDL_Delay( 2000 );

    //Free the loaded image
    SDL_FreeSurface( hello );

    //Quit SDL
    SDL_Quit();

    return 0;
}

This generates without error, but does not generate a binary file to get started. Only a .o

Any suggestions?

EDIT: I am also including TCO with her. It's trip over. Did I miss something in my code for TCO runs correctly?

C:\Users\Acer\Desktop\TouchControlOverlay\Device-Debug/libTouchControlOverlay.so: undefined reference to `png_create_read_struct'
C:\Users\Acer\Desktop\TouchControlOverlay\Device-Debug/libTouchControlOverlay.so: undefined reference to `xmlStrncasecmp'
C:\Users\Acer\Desktop\TouchControlOverlay\Device-Debug/libTouchControlOverlay.so: undefined reference to `xmlDocGetRootElement'
C:\Users\Acer\Desktop\TouchControlOverlay\Device-Debug/libTouchControlOverlay.so: undefined reference to `png_init_io'
C:\Users\Acer\Desktop\TouchControlOverlay\Device-Debug/libTouchControlOverlay.so: undefined reference to `png_get_image_height'
C:\Users\Acer\Desktop\TouchControlOverlay\Device-Debug/libTouchControlOverlay.so: undefined reference to `png_get_image_width'
C:\Users\Acer\Desktop\TouchControlOverlay\Device-Debug/libTouchControlOverlay.so: undefined reference to `png_create_info_struct'
C:\Users\Acer\Desktop\TouchControlOverlay\Device-Debug/libTouchControlOverlay.so: undefined reference to `png_set_tRNS_to_alpha'
C:\Users\Acer\Desktop\TouchControlOverlay\Device-Debug/libTouchControlOverlay.so: undefined reference to `png_set_longjmp_fn'
C:\Users\Acer\Desktop\TouchControlOverlay\Device-Debug/libTouchControlOverlay.so: undefined reference to `png_read_image'
C:\Users\Acer\Desktop\TouchControlOverlay\Device-Debug/libTouchControlOverlay.so: undefined reference to `png_set_palette_to_rgb'
C:\Users\Acer\Desktop\TouchControlOverlay\Device-Debug/libTouchControlOverlay.so: undefined reference to `xmlReadFile'
C:\Users\Acer\Desktop\TouchControlOverlay\Device-Debug/libTouchControlOverlay.so: undefined reference to `xmlFreeDoc'
C:\Users\Acer\Desktop\TouchControlOverlay\Device-Debug/libTouchControlOverlay.so: undefined reference to `png_read_info'
C:\Users\Acer\Desktop\TouchControlOverlay\Device-Debug/libTouchControlOverlay.so: undefined reference to `png_set_bgr'
C:\Users\Acer\Desktop\TouchControlOverlay\Device-Debug/libTouchControlOverlay.so: undefined reference to `xmlCleanupParser'
C:\Users\Acer\Desktop\TouchControlOverlay\Device-Debug/libTouchControlOverlay.so: undefined reference to `png_destroy_read_struct'

EDIT: missed me png and xml2

It seems to be missing the library 'png' on the link phase. Can you confirm for me that the link against it?

Go into the settings of your project, build C/c++, select tab "settings of the tool. You will see the folders 'QCC Linker, libraries' on the list. You must have "png" it.

Another way to check is when you compile look at the last line (the link phase, starting with "qcc o", you should see a '-lpng ' modifier.)

Tags: BlackBerry Developers

Similar Questions

Maybe you are looking for