Muskovitz has asked for the wisdom of the Perl Monks concerning the following question:

Hi Monks,

I installed PERL SDL Correctly but when i try to write simple scripts for start off i get this following error. I am using Linux.
SDL_gfx_primitives support has not been compiled at /usr/local/lib/per +l/5.14.2/SDLx/Surface.pm line 245. SDLx::Surface::draw_line(SDLx::App=SCALAR(0x8d455f8), ARRAY(0x8d45 +60c), ARRAY(0x8d45698), ARRAY(0x8d45710)) called at Documents/dev.pl +line 9
& the code:
#!/usr/bin/perl use strict; use warnings; use SDL; use SDLx::App; my $app=SDLx::App->new(width=>400,height=>400); $app->draw_line([200, 20],[20,200],[255, 255, 0, 255]); $app->update; sleep(5);
But when i try to run this on windows it worked.

Replies are listed 'Best First'.
Re: Can't draw in PERL SDL
by Corion (Patriarch) on Sep 15, 2015 at 11:12 UTC
    SDL_gfx_primitives support has not been compiled

    So, when you install SDL again, make sure to compile SDL_gfx_primitives support.

      I install PERL SDL using CPAN

        I install PERL SDL using CPAN

        When you install libSDL not SDL.pm, like the thing that Alien::SDL installs