Skip Menu |

This queue is for tickets about the SDL_perl CPAN distribution.

Report information
The Basics
Id: 19155
Status: resolved
Priority: 0/
Queue: SDL_perl

People
Owner: Nobody in particular
Requestors: mcummings [...] gentoo.org
Cc:
AdminCc:

Bug Information
Severity: Important
Broken in: 2.1.3
Fixed in: (no value)



Subject: SDL installs to wrong dirs in arch/auto
When installing under perl-5.8.8, with Module::Build 0.28, we're seeing the files from src (the shared object files) getting installed into arch/auto/src/SDL instead of arch/auto/SDL. I've dup'd this on a few boxes running 0.28 of Module::Build - but don't have access to any running 0.22 to be able to confirm 100% that this is a problem using the newer version of Module::Build. Everything builds fine, it just goes to the wrong places. Can you confirm (either way) that this is a problem with the M::B parsing? example: /usr/lib/perl5/vendor_perl/5.8.8/i686-linux/auto/src /usr/lib/perl5/vendor_perl/5.8.8/i686-linux/auto/src/SDL_perl /usr/lib/perl5/vendor_perl/5.8.8/i686-linux/auto/src/SDL_perl/SDL_perl.bs /usr/lib/perl5/vendor_perl/5.8.8/i686-linux/auto/src/SDL_perl/SDL_perl.so /usr/lib/perl5/vendor_perl/5.8.8/i686-linux/auto/src/SDL /usr/lib/perl5/vendor_perl/5.8.8/i686-linux/auto/src/SDL/SFont /usr/lib/perl5/vendor_perl/5.8.8/i686-linux/auto/src/SDL/SFont/SFont.bs /usr/lib/perl5/vendor_perl/5.8.8/i686-linux/auto/src/SDL/SFont/SFont.so /usr/lib/perl5/vendor_perl/5.8.8/i686-linux/auto/src/SDL/OpenGL /usr/lib/perl5/vendor_perl/5.8.8/i686-linux/auto/src/SDL/OpenGL/OpenGL.bs /usr/lib/perl5/vendor_perl/5.8.8/i686-linux/auto/src/SDL/OpenGL/OpenGL.so Obligatory perl -V output: Summary of my perl5 (revision 5 version 8 subversion 8) configuration: Platform: osname=linux, osvers=2.6.11-gentoo-r9, archname=i686-linux uname='linux sys947 2.6.11-gentoo-r9 #5 thu sep 22 05:09:50 edt 2005 i686 intel(r) pentium(r) 4 cpu 3.00ghz genuineintel gnulinux ' config_args='-des -Darchname=i686-linux -Dcccdlflags=-fPIC -Dccdlflags=-rdynamic -Dcc=i686-pc-linux-gnu-gcc -Dprefix=/usr -Dvendorprefix=/usr -Dsiteprefix=/usr -Dlocincpth= -Doptimize=-O2 -march=pentium4 -fomit-frame-pointer -Duselargefiles -Dd_semctl_semun -Dscriptdir=/usr/bin -Dman1dir=/usr/share/man/man1 -Dman3dir=/usr/share/man/man3 -Dinstallman1dir=/usr/share/man/man1 -Dinstallman3dir=/usr/share/man/man3 -Dman1ext=1 -Dman3ext=3pm -Dinc_version_list=5.8.0 5.8.0/i686-linux 5.8.2 5.8.2/i686-linux 5.8.4 5.8.4/i686-linux 5.8.5 5.8.5/i686-linux 5.8.6 5.8.6/i686-linux 5.8.7 5.8.7/i686-linux -Dcf_by=Gentoo -Ud_csh -Di_ndbm -Di_gdbm -Di_db' hint=recommended, useposix=true, d_sigaction=define usethreads=undef use5005threads=undef useithreads=undef usemultiplicity=undef useperlio=define d_sfio=undef uselargefiles=define usesocks=undef use64bitint=undef use64bitall=undef uselongdouble=undef usemymalloc=n, bincompat5005=undef Compiler: cc='i686-pc-linux-gnu-gcc', ccflags ='-fno-strict-aliasing -pipe -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64', optimize='-O2 -march=pentium4 -fomit-frame-pointer', cppflags='-fno-strict-aliasing -pipe' ccversion='', gccversion='3.3.5 (Gentoo Linux 3.3.5-r1, ssp-3.3.2-3, pie-8.7.7.1)', gccosandvers='' intsize=4, longsize=4, ptrsize=4, doublesize=8, byteorder=1234 d_longlong=define, longlongsize=8, d_longdbl=define, longdblsize=12 ivtype='long', ivsize=4, nvtype='double', nvsize=8, Off_t='off_t', lseeksize=8 alignbytes=4, prototype=define Linker and Libraries: ld='i686-pc-linux-gnu-gcc', ldflags =' -L/usr/local/lib' libpth=/usr/local/lib /lib /usr/lib libs=-lpthread -lnsl -lndbm -lgdbm -ldb -ldl -lm -lcrypt -lutil -lc perllibs=-lpthread -lnsl -ldl -lm -lcrypt -lutil -lc libc=/lib/libc-2.3.4.so, so=so, useshrplib=false, libperl=libperl.a gnulibc_version='2.3.4' Dynamic Linking: dlsrc=dl_dlopen.xs, dlext=so, d_dlsymun=undef, ccdlflags='-rdynamic' cccdlflags='-fPIC', lddlflags='-shared -L/usr/local/lib' Characteristics of this binary (from libperl): Compile-time options: PERL_MALLOC_WRAP USE_LARGE_FILES USE_PERLIO Built under linux Compiled at Mar 29 2006 09:06:18 @INC: /etc/perl /usr/lib/perl5/vendor_perl/5.8.8/i686-linux /usr/lib/perl5/vendor_perl/5.8.8 /usr/lib/perl5/vendor_perl/5.8.5 /usr/lib/perl5/vendor_perl/5.8.6 /usr/lib/perl5/vendor_perl/5.8.6/i686-linux /usr/lib/perl5/vendor_perl/5.8.7 /usr/lib/perl5/vendor_perl/5.8.7/i686-linux /usr/lib/perl5/vendor_perl /usr/lib/perl5/site_perl/5.8.8/i686-linux /usr/lib/perl5/site_perl/5.8.8 /usr/lib/perl5/site_perl/5.8.4 /usr/lib/perl5/site_perl/5.8.4/i686-linux /usr/lib/perl5/site_perl/5.8.6 /usr/lib/perl5/site_perl/5.8.6/i686-linux /usr/lib/perl5/site_perl/5.8.7 /usr/lib/perl5/site_perl/5.8.7/i686-linux /usr/lib/perl5/site_perl /usr/lib/perl5/5.8.8/i686-linux /usr/lib/perl5/5.8.8 /usr/local/lib/site_perl
From: mcummings [...] gentoo.org
I've confirmed that this problem goes away with older M::B's - 0.2601 puts everything in the right place. Not sure if at this point that makes this a SDL or a M::B problem...
RT-Send-CC: module-build-bugs [...] rt.cpan.org
I have the same problem, with M::B 0.28 on Debian/GNU Linux x86 unstable. After moving everything from <perldir>/auto/src into <perldir>/auto, everything works as expected. I think this is a M::B bug, so I'll open a ticket in that queue.
Could the solution be just to change Build.PL lines like this: to => 'src/SDL/OpenGL.xs', to this: to => 'SDL/OpenGL.xs', I haven't actually tried it out, because I don't have all the prereqs for SDL on my system, but I think it's worth a shot. -Ken
From: mcummings [...] gentoo.org
On Sun May 21 13:47:06 2006, KWILLIAMS wrote: Show quoted text
> Could the solution be just to change Build.PL lines like this: > > to => 'src/SDL/OpenGL.xs', > > to this: > > to => 'SDL/OpenGL.xs',
almost :) Attached is a working patch - haven't tested against M::B-0.2801 to see if its still needed (though I'm guessing since Ken's weighed in, it probably is)
--- src/OpenGL.xs.orig 2006-05-24 16:33:05.000000000 -0400 +++ src/OpenGL.xs 2006-05-24 16:33:40.000000000 -0400 @@ -23,7 +23,7 @@ #define GL_ALL_CLIENT_ATTRIB_BITS 0xFFFFFFF #endif /* GL_ALL_CLIENT_BITS */ -#include "../defines.h" +#include "../src/defines.h" SV* sdl_perl_nurbs_error_hook; void --- src/SDL.xs.orig 2006-05-24 16:33:10.000000000 -0400 +++ src/SDL.xs 2006-05-24 16:33:59.000000000 -0400 @@ -69,7 +69,7 @@ static int sdl_perl_use_smpeg_audio = 0; #define HAVE_TLS_CONTEXT #endif -#include "defines.h" +#include "../src/defines.h" Uint32 sdl_perl_timer_callback ( Uint32 interval, void* param ) --- src/SFont.xs.orig 2006-05-24 16:33:17.000000000 -0400 +++ src/SFont.xs 2006-05-24 16:36:40.000000000 -0400 @@ -23,8 +23,8 @@ #define HAVE_TLS_CONTEXT #endif -#include "../defines.h" -#include "../SFont.h" +#include "../src/defines.h" +#include "../src/SFont.h" #ifdef HAVE_SDL_IMAGE #include <SDL_image.h> --- Build.PL.orig 2006-05-24 17:10:37.000000000 -0400 +++ Build.PL 2006-05-24 17:09:25.000000000 -0400 @@ -35,7 +35,7 @@ my %subsystems = SDL => { file => { from => 'src/SDL.xs', - to => 'src/SDL_perl.xs', + to => 'SDL/SDL_perl.xs', }, libraries => [qw( SDL SDL_image SDL_mixer SDL_net SDL_ttf SDL_gfx png jpeg smpeg )], @@ -43,14 +43,14 @@ my %subsystems = OpenGL => { file => { from => 'src/OpenGL.xs', - to => 'src/SDL/OpenGL.xs', + to => 'SDL/OpenGL.xs', }, libraries => [qw( SDL GL GLU )], }, SFont => { file => { from => 'src/SFont.xs', - to => 'src/SDL/SFont.xs', + to => 'SDL/SFont.xs', }, libraries => [qw( SDL SDL_image )], },
From: Ferret (james.noble [...] worc.ox.ac.uk)
Keep in mind I don't know much about perl. Sorry. I've tried this patch with M::B-0.28, it creates: auto/SDL/SDL_perl/SDL_perl.so auto/SDL/OpenGL/OpenGL.so auto/SDL/SFont/SFont.so I'm not sure about the first of these files, since with older M::B-0.26.11 it was put in: auto/SDL_perl/SDL_perl.so And the file /usr/lib/perl5/vendor_perl/5.8.8/i686-linux/SDL.pm on my system seems to expect it there: use SDL_perl; I fiddled the patch so that it says: to => './SDL_perl.xs', And then the file gets put where a 'use SDL_perl;' can find it. (also changed the defines.h line to work, of course) (without the ,/ the build tries to create /SDL_perl.c, a seperate M::B bug by the looks of it -- someone please check this for me, as I simply don't know enough perl) I'm not sure if this is correct, though, maybe SDL.pm should say 'use SDL::SDL_perl.pm;'? It would help to know exactly where these .so files *should* go!
From: mcummings [...] gentoo.org
On Thu May 25 16:52:34 2006, guest wrote: Show quoted text
> And the file /usr/lib/perl5/vendor_perl/5.8.8/i686-linux/SDL.pm on my > system seems to expect it there: > > use SDL_perl; >
You're absolutely right - my mistake :( Will post a fresher patch for future generations in a little bit :)
From: mcummings [...] gentoo.org
On Thu May 25 18:57:44 2006, guest wrote: Show quoted text
> You're absolutely right - my mistake :( Will post a fresher patch for > future generations in a little bit :)
Here we go. And this time, fully tested with the tests under <TARBALL-SRC>/test :)
diff -Naurp SDL_Perl-2.1.3/Build.PL SDL_Perl-2.1.3-new/Build.PL --- SDL_Perl-2.1.3/Build.PL 2005-10-05 05:25:49.000000000 -0400 +++ SDL_Perl-2.1.3-new/Build.PL 2006-05-25 19:00:23.000000000 -0400 @@ -35,7 +35,7 @@ my %subsystems = SDL => { file => { from => 'src/SDL.xs', - to => 'src/SDL_perl.xs', + to => './SDL_perl.xs', }, libraries => [qw( SDL SDL_image SDL_mixer SDL_net SDL_ttf SDL_gfx png jpeg smpeg )], @@ -43,14 +43,14 @@ my %subsystems = OpenGL => { file => { from => 'src/OpenGL.xs', - to => 'src/SDL/OpenGL.xs', + to => 'SDL/OpenGL.xs', }, libraries => [qw( SDL GL GLU )], }, SFont => { file => { from => 'src/SFont.xs', - to => 'src/SDL/SFont.xs', + to => 'SDL/SFont.xs', }, libraries => [qw( SDL SDL_image )], }, diff -Naurp SDL_Perl-2.1.3/src/OpenGL.xs SDL_Perl-2.1.3-new/src/OpenGL.xs --- SDL_Perl-2.1.3/src/OpenGL.xs 2005-10-05 05:25:49.000000000 -0400 +++ SDL_Perl-2.1.3-new/src/OpenGL.xs 2006-05-25 18:59:04.000000000 -0400 @@ -23,7 +23,7 @@ #define GL_ALL_CLIENT_ATTRIB_BITS 0xFFFFFFF #endif /* GL_ALL_CLIENT_BITS */ -#include "../defines.h" +#include "../src/defines.h" SV* sdl_perl_nurbs_error_hook; void diff -Naurp SDL_Perl-2.1.3/src/SDL.xs SDL_Perl-2.1.3-new/src/SDL.xs --- SDL_Perl-2.1.3/src/SDL.xs 2005-10-05 05:25:49.000000000 -0400 +++ SDL_Perl-2.1.3-new/src/SDL.xs 2006-05-25 19:04:00.000000000 -0400 @@ -69,7 +69,7 @@ static int sdl_perl_use_smpeg_audio = 0; #define HAVE_TLS_CONTEXT #endif -#include "defines.h" +#include "src/defines.h" Uint32 sdl_perl_timer_callback ( Uint32 interval, void* param ) diff -Naurp SDL_Perl-2.1.3/src/SFont.xs SDL_Perl-2.1.3-new/src/SFont.xs --- SDL_Perl-2.1.3/src/SFont.xs 2005-10-05 05:25:49.000000000 -0400 +++ SDL_Perl-2.1.3-new/src/SFont.xs 2006-05-25 18:59:04.000000000 -0400 @@ -23,8 +23,8 @@ #define HAVE_TLS_CONTEXT #endif -#include "../defines.h" -#include "../SFont.h" +#include "../src/defines.h" +#include "../src/SFont.h" #ifdef HAVE_SDL_IMAGE #include <SDL_image.h>
On Thu May 25 19:07:09 2006, guest wrote: Show quoted text
> On Thu May 25 18:57:44 2006, guest wrote:
> > You're absolutely right - my mistake :( Will post a fresher patch for > > future generations in a little bit :)
> > Here we go. And this time, fully tested with the tests under > <TARBALL-SRC>/test :)
I'll apply to the subversion repository. Dave
v2.2.0