Re: mod_perl/freebsd
At 12:17 PM 7/22/2003 -0400, Andy Harrison wrote: -BEGIN PGP SIGNED MESSAGE- ~ On 22-Jul-2003, Andrew Hurst wrote message "Re: mod_perl/freebsd" ~ > Usage: >/usr/local/bin/use.perl port -> /usr/bin/perl is the perl5 port >/usr/local/bin/use.perl system -> /usr/bin/perl is the system perl Could you tell me what this changes, exactly? I need to make certain that /usr/bin/perl stays at its current version (5.005_03). Does this simply update /etc/make.conf? I looked for a man page, but don't see it. Its a regular perl script, just open it up in your favorite text editor and read it. As far as I know (without reading over the source carefully) it just changes a few symlinks and changes a line in make.conf so that when you rebuild the world it will use the new perl. -Andrew ~~ Andy Harrison Great Works Internet System Operations (full headers for details) -BEGIN PGP SIGNATURE- Version: PGP 6.5.8 iQCVAwUBPx1jklPEkLgodAWVAQHu8wQAphPErffZC7yTpwGjYy48l1P6wPk+hzHe 6W9cPggLzNWY6tDPGf7kBXWSxeLAjG0YhrL03QmQXTJY805J/qTUwUdyUYCcXs4z S8sNajWWT79KIoPl3NvLvRoFHI/yZwyhGmlH57P4NznRheC0JjO+HKu9jWKV9iEI V1dW/Dls9ws= =LpYU -END PGP SIGNATURE-
Re: mod_perl/freebsd
At 10:09 AM 7/22/2003 -0400, Andy Harrison wrote: -BEGIN PGP SIGNED MESSAGE- I'd like to install mod_perl from ports on freebsd, but it complains: Error: you don't have the right version of perl in /usr/bin. This is correct, I want to install it against the version of perl in /usr/local/bin *not* against the version in /usr/bin. Anyone know what to do? Sounds like you didn't run 'use.perl ports' after installing the version from the ports. [EMAIL PROTECTED] hurstdog$ use.perl Usage: /usr/local/bin/use.perl port -> /usr/bin/perl is the perl5 port /usr/local/bin/use.perl system -> /usr/bin/perl is the system perl [EMAIL PROTECTED] hurstdog$ Thats on 4.7-RELEASE. It could have changed with the latest releases, I haven't checked. But I think that should solve your problem. -Andrew ~~ Andy Harrison Great Works Internet System Operations (full headers for details) -BEGIN PGP SIGNATURE- Version: PGP 6.5.8 iQCUAwUBPx1FNFPEkLgodAWVAQFR7wP4u6m6l6qGwN8XK29riuyZiMCx72k88H/c pqvIZFHIhl8MMIlj1Rsh7bjfMitgSAQT6psFvWCnNjJJAkLL5P+p6GSxGhLsATJC 9BgTfdaPycpk/s2O/Lo00lCVVkv/YkmeGcJc/cebmTills93NRIs+k2C2x5orfk3 b9O7o4Ydvg== =SUXE -END PGP SIGNATURE-
Re: Values of an array..
At 01:22 PM 7/21/2003 -0800, Dennis Stout wrote: > >"Dennis Stout" wrote ... > > my %user_list = get_users($where); > > > > foreach (keys %user_list) { > > my $user = $_; > > foreach (@{$user_list{$user}{DOMAIN}}) { > > $user_list{$user}{DOMAINS} .= > >"$user_list{$user}{DOMAIN}[$_],"; > > } > > chop($user_list{$user}{DOMAINS}); > >... > > >$user_list{$user}{DOMAINS} .= "$user_list{$user}{DOMAIN}[$_],"; > > That line is the culprit. $_ contains each domain name as a text > string. Which evaluates to 0 when used as an integer, which then gives the > first entry in the array. Thus you get the first entry in the array as > many times as you have entries in the array. Try changing that to a > regular (indexed) for loop and that should fix it. Good eye, I was too busy thinking of hashes and things. I hate array's. Should just be $user_list{$user}{DOMAINS} .= "$_,"; huh? Yep. After I sent the last email I realized that suggesting an indexed for loop was more effort than just deleting part of the string already there, like you just suggested. Thanks No problem. -Andrew Dennis
Re: Values of an array..
"Dennis Stout" wrote ... my %user_list = get_users($where); foreach (keys %user_list) { my $user = $_; foreach (@{$user_list{$user}{DOMAIN}}) { $user_list{$user}{DOMAINS} .= "$user_list{$user}{DOMAIN}[$_],"; } chop($user_list{$user}{DOMAINS}); ... $user_list{$user}{DOMAINS} .= "$user_list{$user}{DOMAIN}[$_],"; That line is the culprit. $_ contains each domain name as a text string. Which evaluates to 0 when used as an integer, which then gives the first entry in the array. Thus you get the first entry in the array as many times as you have entries in the array. Try changing that to a regular (indexed) for loop and that should fix it. Hope that helps. -Andrew
Re: mod_perl's ease of installation and the list (was: Re: Problems installing libapreq)
On Thu, Aug 16, 2001 at 09:25:19PM -0700, Ask Bjoern Hansen wrote: > On Thu, 16 Aug 2001, Nick Tonkin wrote: > > > ( In the absence of any better ideas at this time, I'm gonna nuke > > /usr/local/lib/perl5 completely and see what happens if I start over > > again. ) > > On FreeBSD, better do a new installation of perl somewhere else > (/home/perl, /usr/local/perl/, ... whatever) and do all the mod_perl > stuff with that (just use "/home/perl/bin/perl Makefile.PL" and > "/home/perl/bin/perl -MCPAN -e shell" and so on later). In my experience, its better to stick with the FreeBSD installed perl. I used to upgrade to perl 5.6.1 whenever cpan wanted to, but it created too many problems, for one, it seems that FreeBSD installed libperl.so, etc to /usr/lib. When I reinstalled perl, it would put them in /user/local/lib. I would also have a libperl.a in both of those directories. Furthurmore, after installing mod_perl (I think it was mod_perl that put this there) I would have one in /usr/local/lib/perl5/5.6.1/i386-freebsd/CORE/libperl.a Having these 3 versions really screwed things over, so when I tried to install mod_perl, mod_php, and mod_ssl (latest versions) it would fail with a Dynaloader.o undefined reference error. After re-making world, all works fine, and I'm not upgrading perl on this until freebsd wants to again :) So in my opinion its much better to not even mess with upgrading perl on FreeBSD, too many problems. Though there might be a good way to do it that I'm not aware of. -Andrew Hurst > > > - ask > > -- > ask bjoern hansen, http://ask.netcetera.dk/ !try; do(); > more than a billion impressions per week, http://valueclick.com PGP signature