1
votes

I have been teaching myself Perl after being introduced to the language during a programming module during my Bioinformatics Masters studies at the University of Liverpool, UK.

I have decided that for fun in my spare time I would practise my new skills building basic games and so have downloaded the SDL::Manual Writing Games in Perl pdf.

I have followed the instructions for installing SDL:

1.3 Installing SDL Perl

We assume the presence of a recent version of the Perl language (at least Perl 5.10) and supporting packages. We also assume that you can install packages from the CPAN, including SDL Perl itself.

1.3.1 Windows

Alien::SDL will install binaries for 32bit and 64bit so there is no need to compile anything.

I am using a windows machine.

In the command prompt I type "cpan Alien::SDL"

I have also tried :

1.3.4 CPAN install

Before installing SDL Perl, ensure that you have the most recent versions of the modulesnecessary to build SDL:

 $ sudo cpan CPAN
 $ sudo cpan YAML Module::Build

After these two steps CPAN will be able to install SDL:

 $ sudo cpan SDL

When I try to run the first example script:

use strict;
use warnings;
use SDL;
use SDLx::App;

my $app = SDLx::App->new();

sleep( 2 );

I get this error:

Can't locate SDL.pm in @INC (you may need to install the SDL module) (@INC contains: C:/Perl/site/lib C:/Perl/lib .) at test.pl line 5. BEGIN failed--compilation aborted at test.pl line 5.

I have searched for solutions online but have not found anything that works. I have tried installing strawberry perl and following the steps above with no success.

Thanks in advance for your help.


EDIT in response to comments:

I am running ActiveState Perl downloaded from www.activestate.com/activeperl/downloads

perl 5, version 24, subversion 1 (v5.24.1) built for MSWin32-x86-multi-thread-64int Binary build 2402 [401627]

After determining the location where cpan installed the module SDL by running cpan -D SDL it turned out the module has not yet installed.

Tried again to install the SDL module on Windows runnning "cpan SDL" in the command prompt but recieved this message at the end of the prompt:

Configuring F/FR/FROGGS/SDL-2.546.tar.gz with Build.PL
*************************** !!!WARNING!!!       ********************************
This Release breaks back compatibility support with versions 2.4x and     below
     **************************************************************************
Using 'My::Builder::Windows' class ...
fileparse(): need a valid pathname at C:/Perl/lib/ExtUtils/CBuilder    /Base.pm line 48.
Warning: No success on command[C:\Perl\bin\perl.exe Build.PL     --installdirs=site]
  FROGGS/SDL-2.546.tar.gz
  C:\Perl\bin\perl.exe Build.PL --installdirs=site -- NOT OK

Edit No2 in Response to Answer from @Borodin

I used "cpan" to enter the program and get the cpan> prompt. Then tried:

cpan> install SDL

The failed install log is as below:

cpan> install SDL
Reading 'C:\Perl\cpan\Metadata'
  Database was generated on Sun, 05 Mar 2017 16:17:03 GMT
Running install for module 'SDL'
Checksum for C:\Perl\cpan\sources\authors\id\F\FR\FROGGS\SDL-2.546.tar.gz ok
Scanning cache C:\Perl/cpan/build for sizes
.......---------------------------------------------------------------------    DONE
DEL(1/45): C:\Perl\cpan\build\Alien-SDL-1.446-Ry63hQ
DEL(2/45): C:\Perl\cpan\build\tmp-8260
DEL(3/45): C:\Perl\cpan\build\File-ShareDir-1.102-ZEDEAk
DEL(4/45): C:\Perl\cpan\build\Alien-SDL-1.446-uYw0HW.yml
DEL(5/45): C:\Perl\cpan\build\Alien-SDL-1.446-uYw0HW
DEL(6/45): C:\Perl\cpan\build\tmp-9900
DEL(7/45): C:\Perl\cpan\build\File-ShareDir-1.102-D3CWex
DEL(8/45): C:\Perl\cpan\build\Alien-SDL-1.446-8w1iMC
DEL(9/45): C:\Perl\cpan\build\File-ShareDir-Install-0.11-eZrfcU
DEL(10/45): C:\Perl\cpan\build\File-ShareDir-Install-0.11-eZrfcU.yml
DEL(11/45): C:\Perl\cpan\build\Class-Inspector-1.31-q85DoY
DEL(12/45): C:\Perl\cpan\build\Class-Inspector-1.31-q85DoY.yml
DEL(13/45): C:\Perl\cpan\build\File-ShareDir-1.102-0NJhW3
DEL(14/45): C:\Perl\cpan\build\File-ShareDir-1.102-0NJhW3.yml
DEL(15/45): C:\Perl\cpan\build\Alien-SDL-1.446-8w1iMC.yml
DEL(16/45): C:\Perl\cpan\build\SDL-2.546-uInIpE
DEL(17/45): C:\Perl\cpan\build\SDL-2.546-uInIpE.yml
DEL(18/45): C:\Perl\cpan\build\Alien-SDL-1.446-mjDNhS
DEL(19/45): C:\Perl\cpan\build\Alien-SDL-1.446-mjDNhS.yml
DEL(20/45): C:\Perl\cpan\build\Alien-SDL-1.446-bMFs_e
DEL(21/45): C:\Perl\cpan\build\Alien-SDL-1.446-bMFs_e.yml
DEL(22/45): C:\Perl\cpan\build\CPAN-2.16-dKjoJS
DEL(23/45): C:\Perl\cpan\build\CPAN-2.16-dKjoJS.yml
DEL(24/45): C:\Perl\cpan\build\SDL-2.546-PQW9_Y
DEL(25/45): C:\Perl\cpan\build\Alien-SDL-1.446-rcxZIw
DEL(26/45): C:\Perl\cpan\build\Alien-SDL-1.446-rcxZIw.yml
DEL(27/45): C:\Perl\cpan\build\SDL-2.546-PQW9_Y.yml
DEL(28/45): C:\Perl\cpan\build\SDL-2.546-1bjrml
DEL(29/45): C:\Perl\cpan\build\Alien-SDL-1.446-RHakeY
DEL(30/45): C:\Perl\cpan\build\Alien-SDL-1.446-RHakeY.yml
DEL(31/45): C:\Perl\cpan\build\SDL-2.546-1bjrml.yml
DEL(32/45): C:\Perl\cpan\build\Alien-SDL-1.446-c8W7Wx
DEL(33/45): C:\Perl\cpan\build\Alien-SDL-1.446-c8W7Wx.yml
DEL(34/45): C:\Perl\cpan\build\SDL-2.546-F3Cec8.yml
DEL(35/45): C:\Perl\cpan\build\SDL-2.546-F3Cec8
DEL(36/45): C:\Perl\cpan\build\tmp-3500
DEL(37/45): C:\Perl\cpan\build\Alien-SDL-1.446-4WCocG
DEL(38/45): C:\Perl\cpan\build\Alien-SDL-1.446-lm9Pyz
DEL(39/45): C:\Perl\cpan\build\Alien-SDL-1.446-lm9Pyz.yml
DEL(40/45): C:\Perl\cpan\build\Test-Deep-1.126-EbwC2Z
DEL(41/45): C:\Perl\cpan\build\Test-Deep-1.126-EbwC2Z.yml
DEL(42/45): C:\Perl\cpan\build\Test-Warn-0.32-NqNVqB
DEL(43/45): C:\Perl\cpan\build\Test-Warn-0.32-NqNVqB.yml
DEL(44/45): C:\Perl\cpan\build\Test-Most-0.35-MKUUN1
DEL(45/45): C:\Perl\cpan\build\Test-Most-0.35-MKUUN1.yml
SDL-2.546
SDL-2.546/INSTALL
SDL-2.546/META.yml
SDL-2.546/TODO
SDL-2.546/OFL.txt
SDL-2.546/typemap
SDL-2.546/META.json
SDL-2.546/CHANGELOG
SDL-2.546/MANIFEST
SDL-2.546/COPYING
SDL-2.546/OFL-FAQ.txt
SDL-2.546/Build.PL
SDL-2.546/lib
SDL-2.546/lib/SDL_perl.pm
SDL-2.546/lib/SDL.pm
SDL-2.546/lib/SDLx
SDL-2.546/lib/SDLx/Music.pm
SDL-2.546/lib/SDLx/Controller.pm
SDL-2.546/lib/SDLx/Validate.pm
SDL-2.546/lib/SDLx/Sprite.pm
SDL-2.546/lib/SDLx/SFont.pm
SDL-2.546/lib/SDLx/Layer.pm
SDL-2.546/lib/SDLx/Text.pm
SDL-2.546/lib/SDLx/Sound.pm
SDL-2.546/lib/SDLx/Surface.pm
SDL-2.546/lib/SDLx/App.pm
SDL-2.546/lib/SDLx/Rect.pm
SDL-2.546/lib/SDLx/TTF.pm
SDL-2.546/lib/SDLx/FPS.pm
SDL-2.546/lib/SDLx/LayerManager.pm
SDL-2.546/lib/SDLx/Sprite
SDL-2.546/lib/SDLx/Sprite/Animated.pm
SDL-2.546/lib/SDLx/Surface
SDL-2.546/lib/SDLx/Surface/TiedMatrixRow.pm
SDL-2.546/lib/SDLx/Surface/TiedMatrix.pm
SDL-2.546/lib/SDLx/Music
SDL-2.546/lib/SDLx/Music/Data.pm
SDL-2.546/lib/SDLx/Music/Default.pm
SDL-2.546/lib/SDLx/Controller
SDL-2.546/lib/SDLx/Controller/State.pm
SDL-2.546/lib/SDLx/Controller/Interface.pm
SDL-2.546/lib/SDLx/Controller/Timer.pm
SDL-2.546/lib/Module
SDL-2.546/lib/Module/Build
SDL-2.546/lib/Module/Build/SDL.pm
SDL-2.546/lib/SDL 
SDL-2.546/lib/SDL/Event.pm
SDL-2.546/lib/SDL/Cursor.pm
SDL-2.546/lib/SDL/PixelFormat.pm
SDL-2.546/lib/SDL/Net.pm
SDL-2.546/lib/SDL/AudioCVT.pm
SDL-2.546/lib/SDL/Palette.pm
SDL-2.546/lib/SDL/Audio.pm
SDL-2.546/lib/SDL/Tutorial.pm
SDL-2.546/lib/SDL/Events.pm
SDL-2.546/lib/SDL/VideoInfo.pm
SDL-2.546/lib/SDL/Overlay.pm
SDL-2.546/lib/SDL/CDTrack.pm
SDL-2.546/lib/SDL/RWOps.pm
SDL-2.546/lib/SDL/AudioSpec.pm
SDL-2.546/lib/SDL/GFX.pm
SDL-2.546/lib/SDL/Constants.pm
SDL-2.546/lib/SDL/Time.pm
SDL-2.546/lib/SDL/MultiThread.pm
SDL-2.546/lib/SDL/Mixer.pm
SDL-2.546/lib/SDL/TTFont.pm
SDL-2.546/lib/SDL/SMPEG.pm
SDL-2.546/lib/SDL/Config.pm
SDL-2.546/lib/SDL/Mouse.pm
SDL-2.546/lib/SDL/Joystick.pm
SDL-2.546/lib/SDL/Image.pm
SDL-2.546/lib/SDL/Surface.pm
SDL-2.546/lib/SDL/Pango.pm
SDL-2.546/lib/SDL/Rect.pm
SDL-2.546/lib/SDL/TTF.pm
SDL-2.546/lib/SDL/Video.pm
SDL-2.546/lib/SDL/Color.pm
SDL-2.546/lib/SDL/CD.pm
SDL-2.546/lib/SDL/CDROM.pm
SDL-2.546/lib/SDL/Version.pm
SDL-2.546/lib/SDL/GFX
SDL-2.546/lib/SDL/GFX/Framerate.pm
SDL-2.546/lib/SDL/GFX/ImageFilter.pm
SDL-2.546/lib/SDL/GFX/FPSManager.pm
SDL-2.546/lib/SDL/GFX/BlitFunc.pm
SDL-2.546/lib/SDL/GFX/Rotozoom.pm
SDL-2.546/lib/SDL/GFX/Primitives.pm
SDL-2.546/lib/SDL/SMPEG
SDL-2.546/lib/SDL/SMPEG/Info.pm
SDL-2.546/lib/SDL/TTF
SDL-2.546/lib/SDL/TTF/Font.pm
SDL-2.546/lib/SDL/Pango
SDL-2.546/lib/SDL/Pango/Context.pm
SDL-2.546/lib/SDL/Tutorial
SDL-2.546/lib/SDL/Tutorial/Animation.pm
SDL-2.546/lib/SDL/Tutorial/LunarLander.pm
SDL-2.546/lib/SDL/Mixer
SDL-2.546/lib/SDL/Mixer/Music.pm
SDL-2.546/lib/SDL/Mixer/MixMusic.pm
SDL-2.546/lib/SDL/Mixer/Samples.pm
SDL-2.546/lib/SDL/Mixer/Channels.pm
SDL-2.546/lib/SDL/Mixer/Groups.pm
SDL-2.546/lib/SDL/Mixer/Effects.pm
SDL-2.546/lib/SDL/Mixer/MixChunk.pm
SDL-2.546/lib/SDL/Net
SDL-2.546/lib/SDL/Net/IPaddress.pm
SDL-2.546/lib/SDL/Net/TCP.pm
SDL-2.546/lib/SDL/Net/UDP.pm
SDL-2.546/lib/SDL/Internal
SDL-2.546/lib/SDL/Internal/Loader.pm
SDL-2.546/lib/pods
SDL-2.546/lib/pods/SDL.pod
SDL-2.546/lib/pods/SDLx
SDL-2.546/lib/pods/SDLx/Text.pod
SDL-2.546/lib/pods/SDLx/Surface.pod
SDL-2.546/lib/pods/SDLx/Sound.pod
SDL-2.546/lib/pods/SDLx/SFont.pod
SDL-2.546/lib/pods/SDLx/Rect.pod
SDL-2.546/lib/pods/SDLx/Music.pod
SDL-2.546/lib/pods/SDLx/App.pod
SDL-2.546/lib/pods/SDLx/Sprite.pod
SDL-2.546/lib/pods/SDLx/Controller.pod
SDL-2.546/lib/pods/SDLx/Layer.pod
SDL-2.546/lib/pods/SDLx/LayerManager.pod
SDL-2.546/lib/pods/SDLx/Sprite
SDL-2.546/lib/pods/SDLx/Sprite/Animated.pod
SDL-2.546/lib/pods/SDLx/Controller
SDL-2.546/lib/pods/SDLx/Controller/State.pod
SDL-2.546/lib/pods/SDLx/Controller/Interface.pod
SDL-2.546/lib/pods/SDL
SDL-2.546/lib/pods/SDL/Video.pod
SDL-2.546/lib/pods/SDL/RWOps.pod
SDL-2.546/lib/pods/SDL/Surface.pod
SDL-2.546/lib/pods/SDL/Overlay.pod
SDL-2.546/lib/pods/SDL/Rect.pod
SDL-2.546/lib/pods/SDL/Event.pod
SDL-2.546/lib/pods/SDL/Mixer.pod
SDL-2.546/lib/pods/SDL/Events.pod
SDL-2.546/lib/pods/SDL/CD.pod
SDL-2.546/lib/pods/SDL/Color.pod
SDL-2.546/lib/pods/SDL/AudioSpec.pod
SDL-2.546/lib/pods/SDL/CDROM.pod
SDL-2.546/lib/pods/SDL/Credits.pod
SDL-2.546/lib/pods/SDL/Time.pod
SDL-2.546/lib/pods/SDL/Joystick.pod 
SDL-2.546/lib/pods/SDL/Version.pod
SDL-2.546/lib/pods/SDL/CDTrack.pod
SDL-2.546/lib/pods/SDL/Palette.pod
SDL-2.546/lib/pods/SDL/Audio.pod
SDL-2.546/lib/pods/SDL/Pango.pod
SDL-2.546/lib/pods/SDL/Platform.pod
SDL-2.546/lib/pods/SDL/Image.pod
SDL-2.546/lib/pods/SDL/MPEG.pod
SDL-2.546/lib/pods/SDL/Cursor.pod
SDL-2.546/lib/pods/SDL/Mouse.pod
SDL-2.546/lib/pods/SDL/Tutorial.pod
SDL-2.546/lib/pods/SDL/PixelFormat.pod
SDL-2.546/lib/pods/SDL/MultiThread.pod
SDL-2.546/lib/pods/SDL/AudioCVT.pod
SDL-2.546/lib/pods/SDL/Deprecated.pod
SDL-2.546/lib/pods/SDL/Cookbook.pod
SDL-2.546/lib/pods/SDL/TTF.pod
SDL-2.546/lib/pods/SDL/SMPEG.pod
SDL-2.546/lib/pods/SDL/VideoInfo.pod
SDL-2.546/lib/pods/SDL/GFX
SDL-2.546/lib/pods/SDL/GFX/ImageFilter.pod
SDL-2.546/lib/pods/SDL/GFX/BlitFunc.pod
SDL-2.546/lib/pods/SDL/GFX/Rotozoom.pod
SDL-2.546/lib/pods/SDL/GFX/FPSManager.pod
SDL-2.546/lib/pods/SDL/GFX/Primitives.pod
SDL-2.546/lib/pods/SDL/GFX/Framerate.pod
SDL-2.546/lib/pods/SDL/TTF
SDL-2.546/lib/pods/SDL/TTF/Font.pod
SDL-2.546/lib/pods/SDL/Pango 
SDL-2.546/lib/pods/SDL/Pango/Context.pod
SDL-2.546/lib/pods/SDL/Tutorial
SDL-2.546/lib/pods/SDL/Tutorial/Animation.pod
SDL-2.546/lib/pods/SDL/Tutorial/LunarLander.pod
SDL-2.546/lib/pods/SDL/Mixer
SDL-2.546/lib/pods/SDL/Mixer/Samples.pod
SDL-2.546/lib/pods/SDL/Mixer/MixMusic.pod
SDL-2.546/lib/pods/SDL/Mixer/Effects.pod
SDL-2.546/lib/pods/SDL/Mixer/Music.pod
SDL-2.546/lib/pods/SDL/Mixer/Groups.pod
SDL-2.546/lib/pods/SDL/Mixer/MixChunk.pod
SDL-2.546/lib/pods/SDL/Mixer/Channels.pod
SDL-2.546/lib/pods/SDL/Cookbook
SDL-2.546/lib/pods/SDL/Cookbook/PDL.pod
SDL-2.546/lib/pods/SDL/Cookbook/OpenGL.pod
SDL-2.546/MacOSX
SDL-2.546/MacOSX/Makefile.test
SDL-2.546/MacOSX/Info.plist
SDL-2.546/MacOSX/main.c
SDL-2.546/MacOSX/SDLPerl.icns
SDL-2.546/share
SDL-2.546/share/GenBasR.ttf
SDL-2.546/scripts
SDL-2.546/scripts/gl_const.pl
SDL-2.546/scripts/auto_constants.pl
SDL-2.546/scripts/const.pl
SDL-2.546/scripts/SDLpp.pl
SDL-2.546/scripts/MultiThreadPOC.pl  
SDL-2.546/scripts/sdl_const.pl
SDL-2.546/scripts/sdl_module_maker.pl
SDL-2.546/test
SDL-2.546/test/data
SDL-2.546/test/data/README
SDL-2.546/test/data/chest.png
SDL-2.546/test/data/electrohar.ttf
SDL-2.546/test/data/font.bmp
SDL-2.546/test/data/logo.png
SDL-2.546/test/data/font.png
SDL-2.546/test/data/highlight.png
SDL-2.546/test/data/5x7.fnt
SDL-2.546/test/data/icon.bmp
SDL-2.546/test/data/hero.bmp
SDL-2.546/test/data/LargeFont.bmp
SDL-2.546/test/data/picture.jpg
SDL-2.546/test/data/menu.png
SDL-2.546/test/data/sample.wav
SDL-2.546/test/data/24P_Arial_NeonYellow.png
SDL-2.546/test/data/wood_dark.png
SDL-2.546/test/data/silence.wav
SDL-2.546/test/data/hero.png 
SDL-2.546/test/data/24P_Copperplate_Blue.png
SDL-2.546/test/data/pattern_red_white_2x2.bmp
SDL-2.546/test/data/test-mpeg.mpg
SDL-2.546/test/data/picture.tif
SDL-2.546/test/data/wood_light.png
SDL-2.546/test/data/tribe_i.wav
SDL-2.546/test/data/picture.bmp
SDL-2.546/test/data/button_light.png
SDL-2.546/test/data/button_dark.png
SDL-2.546/inc
SDL-2.546/inc/My
SDL-2.546/inc/My/Builder.pm
SDL-2.546/inc/My/Builder
SDL-2.546/inc/My/Builder/Unix.pm
SDL-2.546/inc/My/Builder/Windows.pm
SDL-2.546/inc/My/Builder/Darwin.pm
SDL-2.546/src
SDL-2.546/src/SMPEG.xs
SDL-2.546/src/SDL.xs
SDL-2.546/src/Image.xs 
SDL-2.546/src/helper.h
SDL-2.546/src/defines.h
SDL-2.546/src/ppport.h
SDL-2.546/src/GFX
SDL-2.546/src/GFX/README
SDL-2.546/src/GFX/Primitives.xs
SDL-2.546/src/GFX/Framerate.xs
SDL-2.546/src/GFX/BlitFunc.xs
SDL-2.546/src/GFX/GFX.xs
SDL-2.546/src/GFX/Rotozoom.xs
SDL-2.546/src/GFX/FPSManager.xs
SDL-2.546/src/GFX/CHANGELOG
SDL-2.546/src/GFX/ImageFilter.xs
SDL-2.546/src/SMPEG
SDL-2.546/src/SMPEG/Info.xs
SDL-2.546/src/TTF
SDL-2.546/src/TTF/README
SDL-2.546/src/TTF/TTF.xs
SDL-2.546/src/TTF/objects
SDL-2.546/src/TTF/objects/Font.xs
SDL-2.546/src/Pango
SDL-2.546/src/Pango/Pango.xs
SDL-2.546/src/Pango/objects
SDL-2.546/src/Pango/objects/Context.xs
SDL-2.546/src/SDLx
SDL-2.546/src/SDLx/Timer.h
SDL-2.546/src/SDLx/Layer.h
SDL-2.546/src/SDLx/SFont.xs
SDL-2.546/src/SDLx/Validate.h
SDL-2.546/src/SDLx/LayerManager.h
SDL-2.546/src/SDLx/Validate.xs
SDL-2.546/src/SDLx/SFont.h
SDL-2.546/src/SDLx/LayerManager.xs
SDL-2.546/src/SDLx/Layer.xs
SDL-2.546/src/SDLx/Surface.xs
SDL-2.546/src/SDLx/Timer.xs 
SDL-2.546/src/SDLx/Controller 
SDL-2.546/src/SDLx/Controller/Interface.h
SDL-2.546/src/SDLx/Controller/Interface.xs
SDL-2.546/src/SDLx/Controller/State.xs
SDL-2.546/src/Mixer
SDL-2.546/src/Mixer/README
SDL-2.546/src/Mixer/Music.xs
SDL-2.546/src/Mixer/Groups.xs
SDL-2.546/src/Mixer/Effects.xs
SDL-2.546/src/Mixer/Channels.xs
SDL-2.546/src/Mixer/Samples.xs
SDL-2.546/src/Mixer/Mixer.xs
SDL-2.546/src/Mixer/objects
SDL-2.546/src/Mixer/objects/MixChunk.xs
SDL-2.546/src/Mixer/objects/MixMusic.xs
SDL-2.546/src/support
SDL-2.546/src/support/darwin_support.h
SDL-2.546/src/support/win32.c
SDL-2.546/src/support/darwin_support.m
SDL-2.546/src/Core
SDL-2.546/src/Core/MultiThread.xs
SDL-2.546/src/Core/CDROM.xs
SDL-2.546/src/Core/Video.xs
SDL-2.546/src/Core/Joystick.xs
SDL-2.546/src/Core/Audio.xs
SDL-2.546/src/Core/Mouse.xs
SDL-2.546/src/Core/Time.xs
SDL-2.546/src/Core/Events.xs
SDL-2.546/src/Core/objects
SDL-2.546/src/Core/objects/VideoInfo.xs
SDL-2.546/src/Core/objects/AudioCVT.xs
SDL-2.546/src/Core/objects/CDTrack.xs
SDL-2.546/src/Core/objects/CD.xs
SDL-2.546/src/Core/objects/AudioSpec.xs
SDL-2.546/src/Core/objects/Event.xs
SDL-2.546/src/Core/objects/RWOps.xs
SDL-2.546/src/Core/objects/typemap
SDL-2.546/src/Core/objects/Version.xs
SDL-2.546/src/Core/objects/Overlay.xs
SDL-2.546/src/Core/objects/Color.xs
SDL-2.546/src/Core/objects/Rect.xs
SDL-2.546/src/Core/objects/Palette.xs
SDL-2.546/src/Core/objects/Surface.xs
SDL-2.546/src/Core/objects/keysym.xs
SDL-2.546/src/Core/objects/Cursor.xs
SDL-2.546/src/Core/objects/PixelFormat.xs
SDL-2.546/examples
SDL-2.546/examples/GFX
SDL-2.546/examples/GFX/script_roto.pl
SDL-2.546/examples/cookbook
SDL-2.546/examples/cookbook/pogl_sdl_texture.pl
SDL-2.546/examples/cookbook/1.pl
SDL-2.546/examples/cookbook/openglapp.pl
SDL-2.546/examples/cookbook/pdl.pl
SDL-2.546/examples/SDLx 
SDL-2.546/examples/SDLx/SDLx_text_zoom.pl
SDL-2.546/examples/SDLx/SDLx_controller_two_squares.pl
SDL-2.546/examples/SDLx/SDLx_LayerManager_Chess.pl
SDL-2.546/examples/SDLx/SDLx_text.pl
SDL-2.546/examples/SDLx/SDLx_text_wordwrap.pl
SDL-2.546/examples/SDLx/app.pl
SDL-2.546/examples/SDLx/SDLx_C_Interface.pl
SDL-2.546/examples/SDLx/SDLx_sprite.pl
SDL-2.546/examples/SDLx/SDLx_text_styles.pl
SDL-2.546/examples/SDLx/SDLx_Sound.pl
SDL-2.546/examples/SDLx/SDLx_text_shadow.pl
SDL-2.546/examples/SDLx/pong.pl
SDL-2.546/examples/SDLx/music.pl
SDL-2.546/examples/SDLx/SDLx_sprite_animated.pl
SDL-2.546/examples/pixel_operations
SDL-2.546/examples/pixel_operations/starry.pl
SDL-2.546/examples/pixel_operations/tie_matrix.pl
SDL-2.546/examples/pixel_operations/fast_pixel_write.pl
SDL-2.546/examples/pixel_operations/sols
SDL-2.546/examples/pixel_operations/sols/ch02.pl
SDL-2.546/t
SDL-2.546/t/sdlx_sprite.t
SDL-2.546/t/sdlx_app.t
SDL-2.546/t/mixer_mixchunk.t
SDL-2.546/t/gfx_primitives2.t
SDL-2.546/t/core_video.t
SDL-2.546/t/core_cd.t
SDL-2.546/t/core_multi.t
SDL-2.546/t/core_video_convert_surface.t
SDL-2.546/t/sdlx_text.t
SDL-2.546/t/core_rect.t
SDL-2.546/t/image.t
SDL-2.546/t/core_error.t
SDL-2.546/t/pango.t
SDL-2.546/t/core_rwops.t
SDL-2.546/t/gfx_framerate.t
SDL-2.546/t/extendingrect.t
SDL-2.546/t/core_palette.t
SDL-2.546/t/core_audiospec.t
SDL-2.546/t/core_timer.t
SDL-2.546/t/ttf.t
SDL-2.546/t/gfx_imagefilter.t
SDL-2.546/t/00-load.t
SDL-2.546/t/image_xpm_array.t
SDL-2.546/t/core_joystick.t 
SDL-2.546/t/sdlx_sprite_animated.t
SDL-2.546/t/sdlx_controller.t
SDL-2.546/t/core_audio.t
SDL-2.546/t/gfx_rotozoom.t
SDL-2.546/t/gfx_fpsmanager.t
SDL-2.546/t/colorpm.t
SDL-2.546/t/mixer_channels.t
SDL-2.546/t/sdlx_sfont.t
SDL-2.546/t/core_surface.t
SDL-2.546/t/sdlx_fps.t
SDL-2.546/t/sdlx_music.t
SDL-2.546/t/mixer_music.t
SDL-2.546/t/sdlx_controller_interface.t
SDL-2.546/t/core_version.t
SDL-2.546/t/mixer.t
SDL-2.546/t/mixer_mixmusic.t
SDL-2.546/t/sdlx_validate.t
SDL-2.546/t/sdlx_layermanager.t
SDL-2.546/t/mixer_effects.t
SDL-2.546/t/mixer_samples.t
SDL-2.546/t/core_overlay.t
SDL-2.546/t/sdlx_surface.t
SDL-2.546/t/core_mouse.t
SDL-2.546/t/ttf_font.t
SDL-2.546/t/gfx_primitives.t
SDL-2.546/t/gfx.t
SDL-2.546/t/sdlx_rect.t
SDL-2.546/t/sdlgamerect.t
SDL-2.546/t/sdlx_sound.t
SDL-2.546/t/core.t
SDL-2.546/t/smpeg.t
SDL-2.546/t/config.t
SDL-2.546/t/core_events.t
SDL-2.546/t/mixer_groups.t
SDL-2.546/t/core_video_gamma.t
SDL-2.546/t/lib
SDL-2.546/t/lib/SDL
SDL-2.546/t/lib/SDL/TestTool.pm
Configuring F/FR/FROGGS/SDL-2.546.tar.gz with Build.PL
*************************** !!!WARNING!!!   ********************************
This Release breaks back compatibility support with versions 2.4x and below
**************************************************************************
Using 'My::Builder::Windows' class ...
fileparse(): need a valid pathname at C:/Perl/lib/ExtUtils/CBuilder/Base.pm line 48.
Warning: No success on command[C:\Perl\bin\perl.exe Build.PL    --installdirs=site]
  FROGGS/SDL-2.546.tar.gz
  C:\Perl\bin\perl.exe Build.PL --installdirs=site -- NOT OK
2
So you're on Windows, but those examples are for Linux. What exactly have you installed, how did you do that, and which version of Perl are you running? - simbabque
As a first step, try determine the location where cpan installed the module SDL by running cpan -D SDL. - Håkon Hægland
I am running perl 5, version 24, subversion 1 (v5.24.1). In the command prompt i just ran "cpan CPAN" followed by "cpan YAML Module::Build" and then tried installing SDL running "cpan SDL" This was all after trying to install the module using "cpan Alien::SDL" - Chris_Roberts
@HåkonHægland - When I ran "cpan -D SDL" I got this message: Loading internal null logger. Install Log::Log4perl for logging messages CPAN: Term::ANSIColor loaded ok (v4.06) CPAN: Storable loaded ok (v2.56_01) Reading 'C:\Perl\cpan\Metadata' Database was generated on Sat, 04 Mar 2017 15:41:02 GMT SDL (no description) F/FR/FROGGS/SDL-2.546.tar.gz (no installation file) Installed: not installed CPAN: 2.546 Not up to date Tobias Leich (FROGGS) [email protected] - Chris_Roberts
@HåkonHægland. I am using windows so I dont think I can use "sudo". C:\Users\Chris\Desktop>sudo cpan SDL 'sudo' is not recognized as an internal or external command, operable program or batch file. I tried running cmd as administrator and running "cpan SDL" but still with no success. - Chris_Roberts

2 Answers

1
votes

SDL installs just fine for me on ActivePerl

Regarding Alien::SDL, that is the SDL binaries which the main SDL module requires. It also needs a bunch of other stuff, but cpan should install all of that for you

I recommend that you use the cpan to enter the program and get the cpan> prompt. Then try

cpan> install SDL

It should test and install any modules that you need and finally SDL itself

If it fails, then please add the failed install log to your question

0
votes

Recommend installing in Ubuntu, SDL installs without trouble there. If you don't want to switch, try Ubuntu on a USB stick: https://www.ubuntu.com/download/desktop/create-a-usb-stick-on-windows