473,395 Members | 1,891 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes and contribute your articles to a community of 473,395 developers and data experts.

How to Install and Setup Strawberry Perl

numberwhun
3,509 Expert Mod 2GB
**NOTE: This article is written using the 5.8.8 Alpha2 release of Strawberry Perl.

I am writing this article with much joy and glee. This is due to the fact that Active State no longer has a monopoly on the issue of Perl on the Windows platform

As anyone who code's Perl on the Windows platform knows, the choice that you have (had) for Perl on Windows was Active State. It worked great for your scripting but when it came to installing modules it wasn't always the easiest thing in the world. Granted, the graphical installer was a godsend for those who don't like command line, but what about when you couldn't find the module you needed to use? This was unfortunately due to the fact that Active State does not support every single CPAN module. This literally excludes those who may be working on a project using one of these "forbidden" modules.

In the past few months I have found a few modules that I was wanting/needing to use in a project and they could not be found anywhere in the PPM (Perl Package Manager - this is what Active State Perl uses). If you investigate further, you will find that PPM does not use CPAN directly (as I think it should) but instead uses the Active State PPM repository by default. There are a couple of others out there as well, but they only add a few hundred packages (modules) to the mix.

Well, I did some inquiring to see if anyone knew of a complete repository to use for PPM, but instead was thrown a link to something completely new. Strawberry Perl ! My curiosity peaked and being completely intrigued, I decided to download this new offering and see if it actually worked.

From what I was told, Strawberry Perl used the CPAN interface that most of us are already familiar (or quite intimate with) from the Unix world. That said, for those of you who remember (no matter how vaguely) the CPAN initial setup, the configuration manager looks for the existance and path's of specific utilities in order to be able to do its job.

Well, I made a list of the utilities that it requires and have provided those below for your reference. The following utilities are located at the gnuwin32 website (or use the gnuwin32 listing page ):
  • bzip
  • gzip
  • tar
  • unzip
  • wget
  • less (my favorite pager)

When you download the above utilities, be sure to grab the binary packages. When you unpack the first one, it should go into "c:\Program Files\gnuwin32".
That is the base path that you should then use for extracting the other 5 utilities as they have the same directory structure internally (ie: bin director, etc).

Here are other utilities that you will need (each is a link to its URL):
  • cURL
  • Lynx
  • ncftpget (and ncftp) - Both are installed with the same single download. Be sure and grab the client software (version 3.2.1 as of this blog entry).
  • gpg

It is up to you whether or not you put each utilities path into your system path, but if you don't, you will have to enter the path to where each utility is located manually during the CPAN setup, just as I did. Once you get all of these installed, and also have Strawberry Perl installed, you can then run the CPAN configuration by entering the following command:
perl -MCPAN -e shell
That will kick it off. I simply took all of the defaults, with the exception of the utility paths that were not displayed, I entered them manually.

Once I had completed the software installations and gone through the configuration, I entered the following command from within the CPAN shell environment:

install Bundle::CPAN
This confirmed to me that everything had worked as it installed beautifully. I then installed a few modules that I needed and ran a few scripts that were around from when I had Active State Perl on the machine (yes, it was uninstalled before installing Strawberry Perl. Sorry for not mentioning that earlier).

So far, the only thing that I haven't been able to get working is the CPAN command line interface (ie: typing "perl -MCPAN -e 'install module::name' ". I have not yet gotten CPAN to install modules in that manner, but for me, it is not an issue to jump into the CPAN shell and install from there.

Anywho, I hope that those of you that code Perl on Windows will do your due diligence and go against what used to be a Perl / Windows Monopoly and switch from the limitations of Active State over to the freedom and (IMHO) superiority of Strawberry Perl.
Nov 16 '07 #1
7 55050
KevinADC
4,059 Expert 2GB
Any problems to report so far with Strawberry?

In the README doc it states:

Bundle::CPAN (including Perl modules that largely eliminate the need
for external helper programs like "gzip" and "tar")
Nov 20 '07 #2
Did you try installing Strawberry Perl first?

You shouldn't need to add any additional tools -- it comes packaged with all the pure-Perl equivalents. It also comes with the CPAN configuration file already setup so that running "cpan" at the command line should "just work".

-- dagolden
Jan 7 '08 #3
Others have already mentioned that you only need to install strawberry perl without the other tools first.

Also I just tried:

perl -MCPAN -e "install module::name"

and it worked like a charm.

Notice the use of double quotes (the windows way) instead of single quotes like your attempt.
Jan 8 '08 #4
You shouldn't need any of gnuwin32 tools for Strawberry Perl to work. This may have been the case in the past (I was using some of them to hack-install certain modules in the past), but the new version of Strawberry Perl comes with everything you need.

I'm glad to hear that you've turned to Strawberry Perl! I have a VM running Windows and use Strawberry Perl for Win32 specific stuff.

Also, to install from the prompt, you should just be able to type:
Expand|Select|Wrap|Line Numbers
  1. C:\> cpan module::name
instead of going into the cpan shell.
Jan 8 '08 #5
numberwhun
3,509 Expert Mod 2GB
You shouldn't need any of gnuwin32 tools for Strawberry Perl to work. This may have been the case in the past (I was using some of them to hack-install certain modules in the past), but the new version of Strawberry Perl comes with everything you need.

I'm glad to hear that you've turned to Strawberry Perl! I have a VM running Windows and use Strawberry Perl for Win32 specific stuff.

Also, to install from the prompt, you should just be able to type:
Expand|Select|Wrap|Line Numbers
  1. C:\> cpan module::name
instead of going into the cpan shell.
By new version, I can only assume that you are refering to the 5.10 version of Strawberry Perl. Do let me know if that is what you are referring to.

When I first installed Strawberry Perl, I didn't install anything extra. I went and did the "perl -MCPAN -e "install Bundle::CPAN" and what it came up with is the setup utility that typically runs for CPAN shell when you haven't run it before.

I skipped all of the tools, being curious about whether it would work, but the installation failed when it tried to download and unzip. I think they have definitely changed things since the 5.8.8 version.

I haven't had any issue with the 5.8.8 version so far and am thinking that an upgrade to 5.10 is prudent in the near future. After I do, an update to or a replacement of, this tutorial will definitely be needed.

Regards,

Jeff
Jan 9 '08 #6
By new version, I can only assume that you are refering to the 5.10 version of Strawberry Perl. Do let me know if that is what you are referring to.
Yes, my apologies. I was referring to Strawberry Perl 5.10.0 as the "new version" versus Strawberry Perl 5.8.8 Alpha 2.

My CPAN config has several "blanks" in it where several of the gnuwin32 tools would fit (unzip, gzip, gpg, ....), but it works like it should without those being installed. But, upon starting the CPAN shell, I wasn't stepped through the configuration.

I noticed that your original post was November 16th. The 'final' release of Strawberry Perl 5.10.0 was released on December 23rd. Whenever you feel like it, you might get the final release version and see if it works better for you than before. (and if you're running Vista, there's a note)

Thanks,
Jeremy
Jan 9 '08 #7
numberwhun
3,509 Expert Mod 2GB
Yes, my apologies. I was referring to Strawberry Perl 5.10.0 as the "new version" versus Strawberry Perl 5.8.8 Alpha 2.

My CPAN config has several "blanks" in it where several of the gnuwin32 tools would fit (unzip, gzip, gpg, ....), but it works like it should without those being installed. But, upon starting the CPAN shell, I wasn't stepped through the configuration.

I noticed that your original post was November 16th. The 'final' release of Strawberry Perl 5.10.0 was released on December 23rd. Whenever you feel like it, you might get the final release version and see if it works better for you than before. (and if you're running Vista, there's a note)

Thanks,
Jeremy
Ok, I have gone ahead and made a note at the top of the article regarding the version of Strawberry Perl that this pertains to, for everyone's clarity.
Jan 10 '08 #8

Sign in to post your reply or Sign up for a free account.

Similar topics

2
by: Noah | last post by:
I'm currently writing install/setup scripts in bash and Python for installing our product on UNIX servers. Our products depends on several packages that need to be configured, compiled, and...
0
by: Sean | last post by:
I am working with an OLD copy of Perl 5.004_04 with a "buggy" Socket module (version 1.6) and IO::Socket::Inet version 1.1603. The problem I am having is with Socket timeout issues - they just...
5
by: Excluded_Middle | last post by:
Hi, I am trying to connect to db2 database and want to execute some basic SQL commands like create or select. I am on linux 7 redhat distribution and I have no rights to compile perl or install...
2
by: RedIsGood | last post by:
Howdy I just bought a copy of VB .NET Standard 2003, trying ri install it on my Dell Deminsion 4550. Got plenty of RAM and disk space, been using VB6 on it for a long time, no problems, yet...
1
by: dwasler | last post by:
OS Win XP Pro SP2 I had to uninstall my db2 V8 because of WAS Commerce Server 6.0.2 I created an account with admin rights Now went I try to install db2 V8 via the commerce Whiz installer at...
2
by: =?Utf-8?B?Vi5DaG9ja2FsaW5nYW0u?= | last post by:
IDE : VS .NET 2003, Platform : .NET 2.0, Hi All, I have my project in VS.Net 2003 (VB.Net). The OS is Vista Ultimate. In a form's Button_Click() event i call a dll which calls another dll and...
9
numberwhun
by: numberwhun | last post by:
Ok, I recently installed Strawberry Perl 5.10.0.1 on my work laptop, here at my new job. (mind you by recently, I mean about a month ago). At my last job, I was running Strawberry Perl 5.8.8 and...
223
by: Pilcrow | last post by:
Given that UNIX, including networking, is almost entirely coded in C, how come so many things are almost impossible in ordinary C? Examples: Network and internet access, access to UNIX...
4
by: jrkelley32 | last post by:
I'm using Strawberry Perl to run awstats and encountering an "out of memory" error. Is there a configuration I can change to boost memory? There is plenty available on the machine.
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.