Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP

Loading…

Creating ActivePerl PPM package for Alien::SDL #177

Open
kthakore opened this Issue · 18 comments

3 participants

@kthakore
Owner

No description provided.

@kthakore kthakore was assigned
@FROGGS FROGGS was assigned
@asb-capfan

Hi there!

I just tried to install Alien::SDL using ActiveState Perl 5.12.3 x32 and the cpan shell. There is a set of compiled files listed, but the installation fails. Ahould it work or isn't it simply not possible to install it via cpan shell?
There is also an error because of the use of a HOME variable, that is not defined.

Here is the log:

Set up gcc environment - 4.4.3
Gonna use 'My::Builder::Windows' class ...
Set up gcc environment - 4.4.3

Welcome to Alien::SDL module installation
-----------------------------------------

Gonna check config script...
(scriptname=sdl-config)
Gonna check availability of prebuilt binaries ...
(os=MSWin32 cc=C:/STRAWB~1/c/bin/gcc.exe archname=MSWin32-x86-multi-thread)

You have the following options:
[1] Binaries Win/32bit SDL-1.2.14 (extended, 20100704) RECOMMENDED
        (gfx, image, mixer, net, smpeg, ttf, sound, svg, rtf, Pango)
[2] Binaries Win/32bit SDL-1.2.14 (extended, 20111205)
        (gfx, image, mixer, net, smpeg, ttf, sound, svg, rtf, Pango)
[3] Quit installation

What way do you wanna go? [1 ]
1
Using binaries Win/32bit SDL-1.2.14 (extended, 20100704) RECOMMENDED
        (gfx, image, mixer, net, smpeg, ttf, sound, svg, rtf, Pango)
Creating new 'MYMETA.yml' with configuration results
Creating new 'Build' script for 'Alien-SDL' version '1.430'
Set up gcc environment - 4.4.3
Set up gcc environment - 4.4.3
Set up gcc environment - 4.4.3
Build option used:
        Binaries Win/32bit SDL-1.2.14 (extended, 20100704) RECOMMENDED
        (gfx, image, mixer, net, smpeg, ttf, sound, svg, rtf, Pango)
Building Alien-SDL
Use of uninitialized value $ENV{"HOME"} in concatenation (.) or string at C:/Per
l/lib/CPAN/Config.pm line 6.
Fetching 'http://strawberryperl.com/package/kmx/sdl/Win32_SDL-1.2.14-extended-bi
n_20100704.zip'...
Checking checksum for 'download\Win32_SDL-1.2.14-extended-bin_20100704.zip'...
Extracting download\Win32_SDL-1.2.14-extended-bin_20100704.zip...
./Build: blib\lib\Alien\SDL.pm: cannot resolve L<Alien> in paragraph 26.
  FROGGS/Alien-SDL-1.430.tar.gz
  C:\Perl\bin\perl.exe ./Build -- OK
Running Build test
Set up gcc environment - 4.4.3
Set up gcc environment - 4.4.3
Set up gcc environment - 4.4.3
t\001_load.t ................ 1/1 # Testing Alien::SDL 1.43, Perl 5.012003, C:\P
erl\bin\perl.exe
# Build type: use_prebuilt_binaries
# Detected sdl-config script: n.a.
# Build option used:
#       Binaries Win/32bit SDL-1.2.14 (extended, 20100704) RECOMMENDED
#       (gfx, image, mixer, net, smpeg, ttf, sound, svg, rtf, Pango)
# URL:
#       http://strawberryperl.com/package/kmx/sdl/Win32_SDL-1.2.14-extended-bin_
20100704.zip
#       http://froggs.de/libsdl/Win32_SDL-1.2.14-extended-bin_20100704.zip
# SHA1: 98409ddeb649024a9cc1ab8ccb2ca7e8fe804fd8
t\001_load.t ................ ok
t\002_config.t .............. 1/5 # Prefix='C:\Perl\cpan\build\Alien-SDL-1.430-i
pjEY6\blib\lib\auto\share\dist\Alien-SDL\1.430_a1ddf79e\bin\..\'
t\002_config.t .............. ok
t\003_check_header.t ........ # Testing basic headers SDL.h + SDL_version.h
[Alien::SDL] Testing header(s): SDL.h NOK: (In file included from c:\strawb~1\c\
bin\../lib/gcc/x86_64-w64-mingw32/4.4.3/../../../../x86_64-w64-mingw32/include/w
indows.h:13,
                 from C:\Users\root\AppData\Local\Temp\DnM2hcvtfn.c:3:
c:\strawb~1\c\bin\../lib/gcc/x86_64-w64-mingw32/4.4.3/../../../../x86_64-w64-min
gw32/include/_mingw.h:382:2: error: #error You cannot use 32-bit time_t (_USE_32
BIT_TIME_T) with _WIN64)
t\003_check_header.t ........ 1/2
#   Failed test 'Testing availability of 'SDL.h''
#   at t\003_check_header.t line 7.
#          got: '0'
#     expected: '1'
[Alien::SDL] Testing header(s): SDL.h, SDL_version.h NOK: (In file included from
 c:\strawb~1\c\bin\../lib/gcc/x86_64-w64-mingw32/4.4.3/../../../../x86_64-w64-mi
ngw32/include/windows.h:13,
                 from C:\Users\root\AppData\Local\Temp\xKAggaVMci.c:3:
c:\strawb~1\c\bin\../lib/gcc/x86_64-w64-mingw32/4.4.3/../../../../x86_64-w64-min
gw32/include/_mingw.h:382:2: error: #error You cannot use 32-bit time_t (_USE_32
BIT_TIME_T) with _WIN64)

#   Failed test 'Testing availability of 'SDL.h, SDL_version.h''
#   at t\003_check_header.t line 8.
#          got: '0'
#     expected: '1'
# Looks like you failed 2 tests of 2.
t\003_check_header.t ........ Dubious, test returned 2 (wstat 512, 0x200)
Failed 2/2 subtests
t\004_get_header_version.t .. 1/1 # Core version: 1.2.14
t\004_get_header_version.t .. ok

Test Summary Report
-------------------
t\003_check_header.t      (Wstat: 512 Tests: 2 Failed: 2)
  Failed tests:  1-2
  Non-zero exit status: 2
Files=4, Tests=9,  2 wallclock secs ( 0.02 usr +  0.05 sys =  0.06 CPU)
Result: FAIL
Failed 1/4 test programs. 2/9 subtests failed.
  FROGGS/Alien-SDL-1.430.tar.gz
  C:\Perl\bin\perl.exe ./Build test -- NOT OK
//hint// to see the cpan-testers results for installing this module, try:
  reports FROGGS/Alien-SDL-1.430.tar.gz
Running Build install
  make test had returned bad status, won't install without force


cpan>

HTH,
Alex

@FROGGS
Owner

Hi, to me it looks like you have a strawberry perl at C:\strawberry and and ActivePerl at C:\Perl.
These two are messing up each other.
It looks like you are running ActivePerls perl with the gcc (and header files) from strawberry.

Can you rename the C:\strawberry folder to something else and try again to install via ActivePerls cpan client?

@asb-capfan

Ok, I reinstalled perl propperly. I now use a virtual machine with Windows XP (32-bit) in Order to check ActiveState installations.

However, there is still no package listed in ppm. Here you can find the build logs: http://code.activestate.com/ppm/Alien-SDL/

I installes manually via the CPAN console. This works fine, when using the 32-bit variant (because for ActiveState Perl x86 there is a MinGW-package you can install to get a compiler).
NB: installation of SDL had to be forced, because of the failing tests mentioned in this bug report: #220

@FROGGS
Owner

Never seen these AS build-logs... I'll have a look next days.

@asb-capfan

Cool thank you.

@FROGGS
Owner

Compiling via ActivePerl works now, pushing in a minute...

But seems like they only build ppm's for non-dev releases, so this will have to wait a few days.

@asb-capfan

Sounds good :)

@FROGGS
Owner

K, cant wait... I released Alien::SDL 1.432 right now.
So I dont have to do anything about poking someone at ActivePerl's to get the ppm's built?

@asb-capfan

AFAIK there is no need to poke someone at AS in order to get your package built. They simply mirror CPAN and use some sort of buildbot - that's what I guess because of the errors in this build log I linked to.

@FROGGS
Owner

Works perfectly fine for me...

C:\>cpan FROGGS/Alien-SDL-1.432.tar.gz
Set up gcc environment - 3.4.5 (mingw-vista special r3)
CPAN: Storable loaded ok (v2.22)
Going to read 'C:\activeperl\cpan\Metadata'
  Database was generated on Wed, 30 May 2012 11:07:03 GMT
Running make for F/FR/FROGGS/Alien-SDL-1.432.tar.gz
CPAN: LWP::UserAgent loaded ok (v6.02)
CPAN: Time::HiRes loaded ok (v1.9721)
Fetching with LWP:
http://ppm.activestate.com/CPAN/authors/id/F/FR/FROGGS/Alien-SDL-1.432.tar.gz
CPAN: YAML::XS loaded ok (v0.35)
CPAN: Digest::SHA loaded ok (v5.62)
Fetching with LWP:
http://ppm.activestate.com/CPAN/authors/id/F/FR/FROGGS/CHECKSUMS
CPAN: Compress::Zlib loaded ok (v2.033)
Checksum for C:\activeperl\cpan\sources\authors\id\F\FR\FROGGS\Alien-SDL-1.432.tar.gz ok
CPAN: Archive::Tar loaded ok (v1.76)
CPAN: File::Temp loaded ok (v0.22)
CPAN: Parse::CPAN::Meta loaded ok (v1.4401)
CPAN: Module::CoreList loaded ok (v2.50)

  CPAN.pm: Going to build F/FR/FROGGS/Alien-SDL-1.432.tar.gz

CPAN: CPAN::Reporter loaded ok (v1.1902)
Set up gcc environment - 3.4.5 (mingw-vista special r3)
Welcome to Alien::SDL module installation
-----------------------------------------
checking operating system... MSWin32
checking compiler... C:/ACTIVE~1/site/bin/gcc.exe
checking build system type... MSWin32-x86-multi-thread
checking platform specific module... using 'My::Builder::Windows'
Set up gcc environment - 3.4.5 (mingw-vista special r3)
checking SDL_INST_DIR env var... no
checking for config script... no
checking for prebuilt binaries... yes, 2 option(s)
checking for pthread... no
checking for SDL... no
checking for z... no
checking for jpeg... no
checking for tiff... no
checking for png... no
checking for SDL_image... no
checking for ogg... no
checking for vorbis... no
checking for SDL_mixer... no
checking for SDL_ttf... no
checking for SDL_gfx... no
checking for pangoft2... no
checking for pango... no
checking for gobject... no
checking for gmodule... no
checking for glib... no
checking for fontconfig... no
checking for freetype... no
checking for expat... no
checking for SDL_Pango... no

You have the following options:
[1] Binaries Win/32bit SDL-1.2.14 (extended, 20100704) RECOMMENDED
        (gfx, image, mixer, net, smpeg, ttf, sound, svg, rtf, Pango)
[2] Binaries Win/32bit SDL-1.2.14 (extended, 20111205)
        (gfx, image, mixer, net, smpeg, ttf, sound, svg, rtf, Pango)
[3] Quit installation

What way do you wanna go? [1 ]
1
Using binaries Win/32bit SDL-1.2.14 (extended, 20100704) RECOMMENDED
        (gfx, image, mixer, net, smpeg, ttf, sound, svg, rtf, Pango)
Created MYMETA.yml and MYMETA.json
Creating new 'Build' script for 'Alien-SDL' version '1.432'
(C:\activeperl\bin\perl.exe Build.PL --installdirs=site exited with 0)
CPAN::Reporter: Build.PL result is 'pass', No errors.
Set up gcc environment - 3.4.5 (mingw-vista special r3)
Set up gcc environment - 3.4.5 (mingw-vista special r3)
Set up gcc environment - 3.4.5 (mingw-vista special r3)
Build option used:
        Binaries Win/32bit SDL-1.2.14 (extended, 20100704) RECOMMENDED
        (gfx, image, mixer, net, smpeg, ttf, sound, svg, rtf, Pango)
Building Alien-SDL
Fetching 'http://strawberryperl.com/package/kmx/sdl/Win32_SDL-1.2.14-extended-bin_20100704.zip'...
Checking checksum for 'download\Win32_SDL-1.2.14-extended-bin_20100704.zip'...
Extracting download\Win32_SDL-1.2.14-extended-bin_20100704.zip...
(C:\activeperl\bin\perl.exe ./Build exited with 0)
CPAN::Reporter: Build result is 'pass', No errors.
  FROGGS/Alien-SDL-1.432.tar.gz
  C:\activeperl\bin\perl.exe ./Build -- OK
Running Build test
Set up gcc environment - 3.4.5 (mingw-vista special r3)
Set up gcc environment - 3.4.5 (mingw-vista special r3)
Set up gcc environment - 3.4.5 (mingw-vista special r3)
# Testing Alien::SDL 1.432, Perl 5.012004, C:\ACTIVE~1\bin\perl.exe
# Build type: use_prebuilt_binaries
# Detected sdl-config script: n.a.
# Build option used:
#       Binaries Win/32bit SDL-1.2.14 (extended, 20100704) RECOMMENDED
#       (gfx, image, mixer, net, smpeg, ttf, sound, svg, rtf, Pango)
# URL:
#       http://strawberryperl.com/package/kmx/sdl/Win32_SDL-1.2.14-extended-bin_20100704.zip
#       http://froggs.de/libsdl/Win32_SDL-1.2.14-extended-bin_20100704.zip
# SHA1: 98409ddeb649024a9cc1ab8ccb2ca7e8fe804fd8
t\001_load.t ................ ok
# Prefix='C:\activeperl\cpan\build\Alien-SDL-1.432-rYGkcM\blib\lib\auto\share\dist\Alien-SDL\1.432_a1ddf79e\bin\..\'
t\002_config.t .............. ok
# Testing basic headers SDL.h + SDL_version.h
[Alien::SDL] Testing header(s): SDL.h
[Alien::SDL] Testing header(s): SDL.h, SDL_version.h
t\003_check_header.t ........ ok
# Core version: 1.2.14
t\004_get_header_version.t .. ok
All tests successful.
Files=4, Tests=9, 10 wallclock secs ( 0.06 usr +  0.53 sys =  0.59 CPU)
Result: PASS
(C:\activeperl\bin\perl.exe ./Build test exited with 0)
CPAN::Reporter: Test result is 'pass', All tests successful.
CPAN::Reporter: preparing a CPAN Testers report for Alien-SDL-1.432
Set up gcc environment - 3.4.5 (mingw-vista special r3)
CPAN::Reporter: sending test report with 'pass' via Metabase
  FROGGS/Alien-SDL-1.432.tar.gz
  C:\activeperl\bin\perl.exe ./Build test -- OK
Running Build install
Set up gcc environment - 3.4.5 (mingw-vista special r3)
Set up gcc environment - 3.4.5 (mingw-vista special r3)
Set up gcc environment - 3.4.5 (mingw-vista special r3)
@FROGGS
Owner

I guess Alien::SDL->check_header( ''SDL.h ) tries to use cl, which isnt there...

@FROGGS
Owner

K, I have some updates...

First, ActivePerl's ppm-build-server uses cl (MSVC), so we have to change a lot. I discovered that we have to be C89 compliant, means we can not mix declaration and code in our XS (SDL). Then comes the next problem: Our binary packages of prebuilt libsdl-libs are built with gcc. We need to rebuild the whole bunch using MSVC to get the *.lib files.

I changed already hundreds of lines of code for the first part, but need way more time for the second.

User who want to use it with Active perl can still install the mingw-package (ppm install mingw32 or so) and then will be able to install and use Alien::SDL and SDL.

@FROGGS
Owner

BTW: the core stuff is working (with a downloaded SDL.lib from libsdl.org). For now it has to be in PATH, but I will fix that.
So ATM we could provide binaries but you dont have SDL_image or SDL_mixer or others.

@FROGGS
Owner

update: compiled libSDL, libSDL_gfx and libSDL_image using MSVC2010, looks good so far except SDL::Audio. When you turn on SDL_RELEASE_TESTING SDL::Audio hangs.

@FROGGS
Owner

Just SDL_Pango and SDL_ttf left, everthing else works.

@kthakore
Owner
@asb-capfan

This is really cool! Thank you very much!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.