Results 1 to 4 of 4

Thread: Why does not this code run? Program stalled at start up . Using ClanLib 2.3.6

  1. #1

    Default Why does not this code run? Program stalled at start up . Using ClanLib 2.3.6

    English is not my mother-tone , so the grammar may look weird.
    I am new to ClanLib.
    I am writing a small game using ClanLib2.

    I used ClanLib 2.3.4 a few days ago and the code ran normally except for a different behavior between Debug and Release modes. So I upgraded to ClanLib 2.3.6. Unfortunately , the situation gets worse. When I launch the program , it gets full-screen , then stalled . I interrupt the process with gdb and find it stopped at "CL_InputDevice::sig_mouse_move". Nothing is printed to the terminal , does that means there is nothing wrong with ClanLib(or it thoughts nothing wrong)?

    I attached the project. It's managed using qmake.
    My kernel version is 2.6.35, architecture is i386.
    Please tell me if you need more information.
    Attached Files Attached Files

  2. #2
    ClanLib Developer
    Join Date
    May 2007
    Posts
    1,787

    Default

    I will not be able to compile it for 2 weeks, maybe someone else can. Usually running it under microsoft windows with visual studio will identify if it is the programs fault.

    You can try this to help identify the problem: Use clanGL1 or clanSWRender as the render target (instead of clanGL). If that helps, upgrade the video card driver, if possible.

    We have tested ClanLib for linux using Debian/Ubuntu and Fedora linux with Nvidia and ATI cards.

    Do the ClanLib examples work?

  3. #3

    Default

    The examples don't work either. Well , I just tried three of them:Basic2D,Fullscreen and Collision.

    With OpenGL and OpenGL1 : Basic2D , Collision and my own code show a window that is stucked (only a window frame with something from the underlying window).Look at the attachment "ClanLib.png".
    With OpenGL and OpenGL1: Fullscreen just crashes with segment error.

    With SWRender: None of them compile: /usr/lib/gcc/i386-redflag-linux/4.5.0/../../../libclan23SWRender.so: undefined reference to `__sync_val_compare_and_swap_4'

    If my gcc version too old ? I'm using 4.5.0.
    My video card is GeForce 9500 GT , the driver is NVIDIA-Linux-x86-285.05.09.run.



    Quote Originally Posted by rombust View Post
    I will not be able to compile it for 2 weeks, maybe someone else can. Usually running it under microsoft windows with visual studio will identify if it is the programs fault.

    You can try this to help identify the problem: Use clanGL1 or clanSWRender as the render target (instead of clanGL). If that helps, upgrade the video card driver, if possible.

    We have tested ClanLib for linux using Debian/Ubuntu and Fedora linux with Nvidia and ATI cards.

    Do the ClanLib examples work?
    Attached Thumbnails Attached Thumbnails Click image for larger version. 

Name:	ClanLib.png 
Views:	25 
Size:	417.0 KB 
ID:	758  

  4. #4
    ClanLib Developer
    Join Date
    May 2007
    Posts
    1,787

    Default

    For clanSWRender (32 bit builds) you need to also use the "-msse2" compiler option.

    We used to set the option in pkgconfig automatically, but this caused problems for people who do not have SSE2 - Or have mixed sse2 and non sse2 code

    So if you add "-msse2" when running gcc at the linking stage, it should compile.

    I am not sure why clanGL1 and clanGL are not working with your setup at the moment.

Similar Threads

  1. How to optimize ClanLib program?
    By leixiong in forum Official ClanLib SDK Forums
    Replies: 6
    Last Post: 10-12-2011, 11:36 AM
  2. How to make release and debug program with ClanLib?
    By leixiong in forum Official ClanLib SDK Forums
    Replies: 3
    Last Post: 10-12-2011, 10:59 AM
  3. ClanLib whole program optimization for Win32
    By rombust in forum Official ClanLib SDK Forums
    Replies: 1
    Last Post: 08-04-2011, 10:34 PM
  4. 2 questions when start using Clanlib GUI moudule
    By westpointer in forum Official ClanLib SDK Forums
    Replies: 2
    Last Post: 05-26-2010, 12:44 PM
  5. Submit Code to Clanlib
    By ART_Adventures in forum Official ClanLib SDK Forums
    Replies: 3
    Last Post: 09-26-2006, 10:25 PM

Bookmarks

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •