Skip Menu |

This queue is for tickets about the Perl-Dist-Strawberry CPAN distribution.

Report information
The Basics
Id: 39663
Status: resolved
Priority: 0/
Queue: Perl-Dist-Strawberry

People
Owner: Nobody in particular
Requestors: nobull67 [...] gmail.com
Cc:
AdminCc:

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



Subject: CPAN/Comfig.pm makepl_arg breaks some modules
The file Perl-Dist-Strawberry-1.04/share/CPAN_Config_5100.pm contains the setting: makepl_arg => q[LIBS=-LC:\\strawberry\\c\\lib INC=-IC:\\strawberry\\c\\include], This is wrong because it causes the LIB setting in a module's Makefile.PL to be overridden thus causing compilation errors. There is no need to pass these setting. The Makefile invokes GCC as simply "gcc" thus assuming that the environment (at least PATH) is configured correctly to find the correct GCC installation. If you are using the GCC.EXE that's found by traversing the PATH environment variable then you should be using the (standard) headers and libraries that are found by traversing the LIB and INCLUDE environment variables. The line in Perl-Dist-Strawberry-1.04/share/CPAN_Config_5100.pm should contain the setting: makepl_arg => q[], Note this bug report is deliberately brief. For more discussion please see http://www.perlmonks.org/?node_id=714150
Subject: Re: [rt.cpan.org #39663] CPAN/Comfig.pm makepl_arg breaks some modules
Date: Mon, 29 Sep 2008 10:04:14 +1000
To: bug-Perl-Dist-Strawberry [...] rt.cpan.org
From: "Adam Kennedy" <adamkennedybackup [...] gmail.com>
A quick note, Strawberry Perl does not set the LIB and INCLUDE environment variables, as these are only used by Microsoft compilers, not by GCC. I'll address this bug in more depth later today, I have a meeting right now. Adam K 2008/9/29 Brian McCauley via RT <bug-Perl-Dist-Strawberry@rt.cpan.org>: Show quoted text
> Sun Sep 28 18:01:51 2008: Request 39663 was acted upon. > Transaction: Ticket created by NOBULL > Queue: Perl-Dist-Strawberry > Subject: CPAN/Comfig.pm makepl_arg breaks some modules > Broken in: 1.04 > Severity: (no value) > Owner: Nobody > Requestors: nobull67@gmail.com > Status: new > Ticket <URL: http://rt.cpan.org/Ticket/Display.html?id=39663 > > > > The file Perl-Dist-Strawberry-1.04/share/CPAN_Config_5100.pm contains > the setting: > > makepl_arg => q[LIBS=-LC:\\strawberry\\c\\lib > INC=-IC:\\strawberry\\c\\include], > > This is wrong because it causes the LIB setting in a module's > Makefile.PL to be overridden thus causing compilation errors. > > There is no need to pass these setting. The Makefile invokes GCC as > simply "gcc" thus assuming that the environment (at least PATH) is > configured correctly to find the correct GCC installation. If you are > using the GCC.EXE that's found by traversing the PATH environment > variable then you should be using the (standard) headers and libraries > that are found by traversing the LIB and INCLUDE environment variables. > > The line in Perl-Dist-Strawberry-1.04/share/CPAN_Config_5100.pm should > contain the setting: > > makepl_arg => q[], > > > Note this bug report is deliberately brief. For more discussion please > see http://www.perlmonks.org/?node_id=714150 >
Subject: Re: [rt.cpan.org #39663] CPAN/Comfig.pm makepl_arg breaks some modules
Date: Mon, 29 Sep 2008 09:12:04 +0100
To: bug-Perl-Dist-Strawberry [...] rt.cpan.org
From: "Brian McCauley" <nobull67 [...] gmail.com>
2008/9/29 Adam Kennedy via RT <bug-Perl-Dist-Strawberry@rt.cpan.org>: Show quoted text
> <URL: http://rt.cpan.org/Ticket/Display.html?id=39663 > > > A quick note, Strawberry Perl does not set the LIB and INCLUDE > environment variables, as these are only used by Microsoft compilers, > not by GCC.
Ah, this means the GCC installation in C:\strawberry\c must implicitly default to "-LC:\strawberry\c\lib -IC:\strawberry\c\include". Guess that makes sense. Wonder where I got the idea that Strawberry set the environment variables? Something certainly did but maybe it was a older version of Strawberry.
Subject: Re: [rt.cpan.org #39663] CPAN/Comfig.pm makepl_arg breaks some modules
Date: Mon, 29 Sep 2008 09:32:06 +0100
To: bug-Perl-Dist-Strawberry [...] rt.cpan.org
From: "Brian McCauley" <nobull67 [...] gmail.com>
2008/9/29 Brian McCauley <nobull67@gmail.com>: Show quoted text
> Wonder where I got the idea that Strawberry set the environment > variables? Something certainly did but maybe it was a older version of > Strawberry.
I've just run strawberry-perl-5.10.0.2.exe on a Win2003 box which didn't already have Stawberry on it and did not have these variables set in the registry. The installation did alter the all user environment variable settings for LIB and INCLUDE. INCLUDE=;C:\strawberry\c\include;C:\strawberry\perl\lib\CORE LIB=;C:\strawberry\c\lib;C:\strawberry\perl\bin
Subject: Re: [rt.cpan.org #39663] CPAN/Comfig.pm makepl_arg breaks some modules
Date: Mon, 29 Sep 2008 18:58:40 +1000
To: bug-Perl-Dist-Strawberry [...] rt.cpan.org
From: "Adam Kennedy" <adamkennedybackup [...] gmail.com>
Strawberry USED to set these environment variables, but that feature was (supposedly) removed. I've got to start building 5.10.0.3 shortly, I'll try to make doubly sure that any regression has been fixed. Regardless, LIB and INCLUDE in the environment don't actually DO anything, as they are a Visual C thing. Adam K 2008/9/29 Brian McCauley via RT <bug-Perl-Dist-Strawberry@rt.cpan.org>: Show quoted text
> Queue: Perl-Dist-Strawberry > Ticket <URL: http://rt.cpan.org/Ticket/Display.html?id=39663 > > > 2008/9/29 Brian McCauley <nobull67@gmail.com>: >
>> Wonder where I got the idea that Strawberry set the environment >> variables? Something certainly did but maybe it was a older version of >> Strawberry.
> > I've just run strawberry-perl-5.10.0.2.exe on a Win2003 box which > didn't already have Stawberry on it and did not have these variables > set in the registry. > > The installation did alter the all user environment variable settings > for LIB and INCLUDE. > > INCLUDE=;C:\strawberry\c\include;C:\strawberry\perl\lib\CORE > LIB=;C:\strawberry\c\lib;C:\strawberry\perl\bin > >
Please also see http://rt.cpan.org/Ticket/Display.html?id=32811 and the related issue in strawberry perl which is http://rt.cpan.org//Ticket/Display.html?id=32789 as I believe this is the same issue. DBD::ODBC (as all DBD modules) has to get the path to the DBI header files and add them to INC in Makefile.PL. If you attempt to do this in Makefile.PL when called via cpan shell in strawberry perl you find it does not work. I believe it does not work because makepl_arg already includes INC and INC on the command line to "perl Makefile.PL" overrides setting (or appending) INC in ExtUtils::MakeMaker. A comment in the perl monks thread NOBULL refers to includes a comment saying it is the Makefile.PL's responsibility to deal with this fact and append it's INC values to ARGV[INC] or perhaps delete ARGV[INC] so that the INC passed to ExtUtils::MakeMaker works but a) I cannot find this in any documentation and b) that is not possible in DBD::* modules without breaking the dependency checking which makes cpan-testers not fail the distribution if DBI does not exist. This is down to the fact that not all CPANs know about configure_requires and build_requires in META.yml yet so you are forced to check for DBI yourself before attempting to use DBI::DBD::dbd_dbi_arch_dir() to get the path and this must be done in ExtUtils::MakeMaker's writeMakefile which is too late to change ARGCV. Martin
Subject: CPAN/Config.pm (not "Comfig.pm") makepl_arg breaks some modules
Using makepl_args to try to pass some heedless "default params" to MakeMaker this way seems broken and wrong to me. I had more to say about it at http://www.perlmonks.org/index.pl?node_id=714335 (failing that, try http://intrepid.perlmonks.org/apropos.pmo/writeups/thread_714150/). Soren Andersen -- Also email somian08 ^AT^ gmail -DOT- com.
RT Issue: Strawberry 5.10

In Sep of 2008, on the 28th, NOBULL created a ticket that read:

The file Perl-Dist-Strawberry-1.04/share/CPAN_Config_5100.pm contains the setting:

makepl_arg => q[LIBS=-LC:\\strawberry\\c\\lib INC=-IC:\\strawberry\\c\\include],

This is wrong because it causes the LIB setting in a module’s Makefile.PL to be overridden thus causing compilation errors.

There is no need to pass these setting. The Makefile invokes GCC as simply “gcc” thus assuming that the environment (at least PATH) is configured correctly to find the correct GCC installation. If you are using the GCC.EXE that’s found by traversing the PATH environment variable then you should be using the (standard) headers and libraries that are found by traversing the LIB and INCLUDE environment variables.

The line in Perl-Dist-Strawberry-1.04/share/CPAN_Config_5100.pm should contain the setting:

makepl_arg => q[],

Note this bug report is deliberately brief. For more discussion please see Strawberry CPAN.pm wrongly overrides INC in Makefile.PL

Since these parameters were apparently moved to $Config{'ldflags'} and $Config{'lddlflags'} well before 5.10.0.6, this bug has been resolved.