Re: lib/auto/IO/Compress/Compress.a: No such file or directory

2020-01-28 Thread Jeffrey Walton
On Tue, Jan 28, 2020 at 1:02 PM Jeffrey Walton  wrote:
>
> On Tue, Jan 28, 2020 at 4:06 AM Jeffrey Walton  wrote:
> >
> > Hi Everyone,
> >
> > I'm catching this error when building Perl from sources. Both Perl
> > 5.10.1 and Perl 5.30.1 experience it. I am seeing it on both Fedora 1
> > and Cent OS 5.
> >
> > cc -o perl  -L/home/jwalton/bootstrap/lib  perlmain.o
> > lib/auto/attrs/attrs.a lib/auto/B/B.a
> > lib/auto/Compress/Raw/Bzip2/Bzip2.a lib/auto/Compress/Raw/Zlib/Zlib.a
> > lib/auto/Cwd/Cwd.a lib/auto/Data/Dumper/Dumper.a
> > lib/auto/Devel/DProf/DProf.a lib/auto/Devel/Peek/Peek.a
> > lib/auto/Devel/PPPort/PPPort.a lib/auto/Digest/MD5/MD5.a
> > lib/auto/Digest/SHA/SHA.a lib/auto/Encode/Encode.a
> > lib/auto/Fcntl/Fcntl.a lib/auto/File/Glob/Glob.a
> > lib/auto/Filter/Util/Call/Call.a lib/auto/Hash/Util/Util.a
> > lib/auto/Hash/Util/FieldHash/FieldHash.a
> > lib/auto/I18N/Langinfo/Langinfo.a lib/auto/IO/IO.a
> > lib/auto/IO/Compress/Compress.a lib/auto/IPC/SysV/SysV.a
> > lib/auto/List/Util/Util.a lib/auto/Math/BigInt/FastCalc/FastCalc.a
> > lib/auto/MIME/Base64/Base64.a lib/auto/mro/mro.a
> > lib/auto/Opcode/Opcode.a lib/auto/PerlIO/encoding/encoding.a
> > lib/auto/PerlIO/scalar/scalar.a lib/auto/PerlIO/via/via.a
> > lib/auto/POSIX/POSIX.a lib/auto/re/re.a lib/auto/SDBM_File/SDBM_File.a
> > lib/auto/Socket/Socket.a lib/auto/Storable/Storable.a
> > lib/auto/Sys/Hostname/Hostname.a lib/auto/Sys/Syslog/Syslog.a
> > lib/auto/Text/Soundex/Soundex.a lib/auto/threads/threads.a
> > lib/auto/threads/shared/shared.a lib/auto/Time/HiRes/HiRes.a
> > lib/auto/Time/Piece/Piece.a lib/auto/Unicode/Normalize/Normalize.a
> > lib/auto/Encode/Byte/Byte.a lib/auto/Encode/CN/CN.a
> > lib/auto/Encode/EBCDIC/EBCDIC.a lib/auto/Encode/JP/JP.a
> > lib/auto/Encode/KR/KR.a lib/auto/Encode/Symbol/Symbol.a
> > lib/auto/Encode/TW/TW.a lib/auto/Encode/Unicode/Unicode.a libperl.a
> > `cat ext.libs` /home/jwalton/bootstrap/lib/libdb.a -lm
> > /usr/lib/libcrypt.a
> > cc: lib/auto/IO/Compress/Compress.a: No such file or directory
> >
> > Here is the full build: https://pastebin.com/Pu0cYi25
>
> How does the build system find lib/auto/IO/Compress/Compress.a at
> lines 2071, 4257, 5416; but fails to find it at 6124?
>
> Is Perl deleting an archive it needs? If so, then how do I stop it
> from deleting files it needs?.

 ./Configure -des -Dcompression=disable

suffers the same problem.

I'm pretty sure this build system is broken.

-- 
To unsubscribe, e-mail: beginners-unsubscr...@perl.org
For additional commands, e-mail: beginners-h...@perl.org
http://learn.perl.org/




Re: lib/auto/IO/Compress/Compress.a: No such file or directory

2020-01-28 Thread Jeffrey Walton
On Tue, Jan 28, 2020 at 4:06 AM Jeffrey Walton  wrote:
>
> Hi Everyone,
>
> I'm catching this error when building Perl from sources. Both Perl
> 5.10.1 and Perl 5.30.1 experience it. I am seeing it on both Fedora 1
> and Cent OS 5.
>
> cc -o perl  -L/home/jwalton/bootstrap/lib  perlmain.o
> lib/auto/attrs/attrs.a lib/auto/B/B.a
> lib/auto/Compress/Raw/Bzip2/Bzip2.a lib/auto/Compress/Raw/Zlib/Zlib.a
> lib/auto/Cwd/Cwd.a lib/auto/Data/Dumper/Dumper.a
> lib/auto/Devel/DProf/DProf.a lib/auto/Devel/Peek/Peek.a
> lib/auto/Devel/PPPort/PPPort.a lib/auto/Digest/MD5/MD5.a
> lib/auto/Digest/SHA/SHA.a lib/auto/Encode/Encode.a
> lib/auto/Fcntl/Fcntl.a lib/auto/File/Glob/Glob.a
> lib/auto/Filter/Util/Call/Call.a lib/auto/Hash/Util/Util.a
> lib/auto/Hash/Util/FieldHash/FieldHash.a
> lib/auto/I18N/Langinfo/Langinfo.a lib/auto/IO/IO.a
> lib/auto/IO/Compress/Compress.a lib/auto/IPC/SysV/SysV.a
> lib/auto/List/Util/Util.a lib/auto/Math/BigInt/FastCalc/FastCalc.a
> lib/auto/MIME/Base64/Base64.a lib/auto/mro/mro.a
> lib/auto/Opcode/Opcode.a lib/auto/PerlIO/encoding/encoding.a
> lib/auto/PerlIO/scalar/scalar.a lib/auto/PerlIO/via/via.a
> lib/auto/POSIX/POSIX.a lib/auto/re/re.a lib/auto/SDBM_File/SDBM_File.a
> lib/auto/Socket/Socket.a lib/auto/Storable/Storable.a
> lib/auto/Sys/Hostname/Hostname.a lib/auto/Sys/Syslog/Syslog.a
> lib/auto/Text/Soundex/Soundex.a lib/auto/threads/threads.a
> lib/auto/threads/shared/shared.a lib/auto/Time/HiRes/HiRes.a
> lib/auto/Time/Piece/Piece.a lib/auto/Unicode/Normalize/Normalize.a
> lib/auto/Encode/Byte/Byte.a lib/auto/Encode/CN/CN.a
> lib/auto/Encode/EBCDIC/EBCDIC.a lib/auto/Encode/JP/JP.a
> lib/auto/Encode/KR/KR.a lib/auto/Encode/Symbol/Symbol.a
> lib/auto/Encode/TW/TW.a lib/auto/Encode/Unicode/Unicode.a libperl.a
> `cat ext.libs` /home/jwalton/bootstrap/lib/libdb.a -lm
> /usr/lib/libcrypt.a
> cc: lib/auto/IO/Compress/Compress.a: No such file or directory
>
> Here is the full build: https://pastebin.com/Pu0cYi25

How does the build system find lib/auto/IO/Compress/Compress.a at
lines 2071, 4257, 5416; but fails to find it at 6124?

Is Perl deleting an archive it needs? If so, then how do I stop it
from deleting files it needs?

-- 
To unsubscribe, e-mail: beginners-unsubscr...@perl.org
For additional commands, e-mail: beginners-h...@perl.org
http://learn.perl.org/




lib/auto/IO/Compress/Compress.a: No such file or directory

2020-01-28 Thread Jeffrey Walton
Hi Everyone,

I'm catching this error when building Perl from sources. Both Perl
5.10.1 and Perl 5.30.1 experience it. I am seeing it on both Fedora 1
and Cent OS 5.

cc -o perl  -L/home/jwalton/bootstrap/lib  perlmain.o
lib/auto/attrs/attrs.a lib/auto/B/B.a
lib/auto/Compress/Raw/Bzip2/Bzip2.a lib/auto/Compress/Raw/Zlib/Zlib.a
lib/auto/Cwd/Cwd.a lib/auto/Data/Dumper/Dumper.a
lib/auto/Devel/DProf/DProf.a lib/auto/Devel/Peek/Peek.a
lib/auto/Devel/PPPort/PPPort.a lib/auto/Digest/MD5/MD5.a
lib/auto/Digest/SHA/SHA.a lib/auto/Encode/Encode.a
lib/auto/Fcntl/Fcntl.a lib/auto/File/Glob/Glob.a
lib/auto/Filter/Util/Call/Call.a lib/auto/Hash/Util/Util.a
lib/auto/Hash/Util/FieldHash/FieldHash.a
lib/auto/I18N/Langinfo/Langinfo.a lib/auto/IO/IO.a
lib/auto/IO/Compress/Compress.a lib/auto/IPC/SysV/SysV.a
lib/auto/List/Util/Util.a lib/auto/Math/BigInt/FastCalc/FastCalc.a
lib/auto/MIME/Base64/Base64.a lib/auto/mro/mro.a
lib/auto/Opcode/Opcode.a lib/auto/PerlIO/encoding/encoding.a
lib/auto/PerlIO/scalar/scalar.a lib/auto/PerlIO/via/via.a
lib/auto/POSIX/POSIX.a lib/auto/re/re.a lib/auto/SDBM_File/SDBM_File.a
lib/auto/Socket/Socket.a lib/auto/Storable/Storable.a
lib/auto/Sys/Hostname/Hostname.a lib/auto/Sys/Syslog/Syslog.a
lib/auto/Text/Soundex/Soundex.a lib/auto/threads/threads.a
lib/auto/threads/shared/shared.a lib/auto/Time/HiRes/HiRes.a
lib/auto/Time/Piece/Piece.a lib/auto/Unicode/Normalize/Normalize.a
lib/auto/Encode/Byte/Byte.a lib/auto/Encode/CN/CN.a
lib/auto/Encode/EBCDIC/EBCDIC.a lib/auto/Encode/JP/JP.a
lib/auto/Encode/KR/KR.a lib/auto/Encode/Symbol/Symbol.a
lib/auto/Encode/TW/TW.a lib/auto/Encode/Unicode/Unicode.a libperl.a
`cat ext.libs` /home/jwalton/bootstrap/lib/libdb.a -lm
/usr/lib/libcrypt.a
cc: lib/auto/IO/Compress/Compress.a: No such file or directory

Here is the full build: https://pastebin.com/Pu0cYi25

Here is the Configure line. PREFIX is $HOME/bootstrap.

if ! ./Configure -des -Dprefix="$PREFIX" -Dextras="Test::More Text::Template" \
 -Dlocincpth="$PREFIX/include" -Dloclibpth="$PREFIX/lib"
-Dlibs="$PREFIX/lib/libdb.a -lm"
then
echo "Failed to configure Perl"
exit 1
fi
...

I saw something online about Perl's IO compression being optional, but
I could not find the switch to disable it.

Does anyone know how to work around this?

Thanks in advance.

-- 
To unsubscribe, e-mail: beginners-unsubscr...@perl.org
For additional commands, e-mail: beginners-h...@perl.org
http://learn.perl.org/




Re: it told me that Can't open perl script " hello.p1" No such file or directory

2011-05-23 Thread Thomas Lingmann

Hi,

you saved your script as 'perl.p1' but you run it as 'hello.p1'.

hth

* Gang Cheng  [23.05.2011 09:30]:
> hi,
> 
>   I instaled my perl under the e:\r_software\perl.
>  I wrote a hello world programme as below
> 
> #! /usr/bin/perl
> print “Hello,word!\n”;
> 
> and save it under e:\ as perl.p1
> 
> but when I run it with the window commend line as
> 
> 
> E:\ perl hello.p1     it told me that Can't open perl script "
> hello.p1"  No such file or directory!!
> 
> how can I solve it  thank you!!!

--
To unsubscribe, e-mail: beginners-unsubscr...@perl.org
For additional commands, e-mail: beginners-h...@perl.org
http://learn.perl.org/




Re: it told me that Can't open perl script " hello.p1" No such file or directory

2011-05-23 Thread Kenneth Wolcott
On Mon, May 23, 2011 at 00:20, Gang Cheng  wrote:
> hi,
>
>  I instaled my perl under the e:\r_software\perl.
>  I wrote a hello world programme as below
>
> #! /usr/bin/perl
> print “Hello,word!\n”;
>
> and save it under e:\ as perl.p1
>
> but when I run it with the window commend line as
>
>
> E:\ perl hello.p1         it told me that Can't open perl script "
> hello.p1"  No such file or directory!!
>
> how can I solve it  thank you!!!
>

"p1" is different than "pl".  "pl" is the usual suffix chosen for perl
programs.  Try "perl hello.pl" after renaming your script to be
"hello.pl".  On UNIX/Linux systems you might get an error about the
script not being executable, but that should not happen on Windoze.
Perhaps Perl is not in your path?  Try "\r_software\perl\bin\perl
hel;lo.pl" if that is where the Perl binary is.  Is this Strawberry
Perl?

Hope this helps,
Ken Wolcott

--
To unsubscribe, e-mail: beginners-unsubscr...@perl.org
For additional commands, e-mail: beginners-h...@perl.org
http://learn.perl.org/




Re: it told me that Can't open perl script " hello.p1" No such file or directory

2011-05-23 Thread Alexey Mishustin
5/23/2011, "Gang Cheng"  вы писали:

>hi,
>
>  I instaled my perl under the e:\r_software\perl.
> I wrote a hello world programme as below
>
>#! /usr/bin/perl
>print “Hello,word!\n”;
>
>and save it under e:\ as perl.p1
>
>but when I run it with the window commend line as
>
>
>E:\ perl hello.p1 it told me that Can't open perl script "
>hello.p1"  No such file or directory!!
>
>how can I solve it  thank you!!!

Maybe hello.pl, not hello.p1?

'pl' (abbreviated from 'Perl') is the common extension of perl
scripts.

--
Regards,
Alex

--
To unsubscribe, e-mail: beginners-unsubscr...@perl.org
For additional commands, e-mail: beginners-h...@perl.org
http://learn.perl.org/




it told me that Can't open perl script " hello.p1" No such file or directory

2011-05-23 Thread Gang Cheng
hi,

  I instaled my perl under the e:\r_software\perl.
 I wrote a hello world programme as below

#! /usr/bin/perl
print “Hello,word!\n”;

and save it under e:\ as perl.p1

but when I run it with the window commend line as


E:\ perl hello.p1 it told me that Can't open perl script "
hello.p1"  No such file or directory!!

how can I solve it  thank you!!!


Re: make command throws error "Perl script no found" C:/Program No such file or directory

2009-01-08 Thread Owen
> On Jan 6, 5:32 pm, rc...@pcug.org.au (Owen) wrote:
>> > Hi,
>>
>> > I have perl5.10.0 installed under C:/ and using bash prompt to run
>> a
>> >makecommand.
>>
>> How are you doing that?
>>
>>
>>
>> > When I issue themakecommandit throws error
>>
>> > "Perl Script not found" C:/Program no such file or directory
>>
>> Where is the script that you are trying to run?
>>
>>
>>
>> > Perl is not installed in Program files it under c:
>>
>> It is not worried about perl, it is worried about the script
>>
>>
>>
>> > Also I do understand it could be a spacing problem due to which it
>> is
>> > not able to get Program Files.
>> > But Iam sure what it is trying to find in program files.
>>
>> > I have C:/Perl/bin/perl5.10.0 added to my PATH variable.
>>
>> > How do I sort out this issue.
>> > Or does program files contain some other requirement needed by the
>> >makefile.
>> > Please let me know.
>>
>> What is themakefile? Note that 'make' is not a perlcommand.
>>
>> Owen
>
> Hi,
>
> Iam running a windows machine and using cgywin.I need to run a
> couple of bash commands in windows environment as it is the
> requirement of the installation kit.
> Basic requirements that is needed for instaaltion are
> cgywin
> VC++
> Perl
>
> Installed those and when I need to run a make command in one
> particular directory of the kit it throws me this error.




I do not think it is possible to help you.

There is not enough information on what you are doing

Is there a forum for the program you are trying to install?

Look for the perl script and try and locate where it is. Go to that
directory and then run the make command

Owen







-- 
To unsubscribe, e-mail: beginners-unsubscr...@perl.org
For additional commands, e-mail: beginners-h...@perl.org
http://learn.perl.org/




Re: make command throws error "Perl script no found" C:/Program No such file or directory

2009-01-08 Thread viji19812001
On Jan 6, 5:32 pm, rc...@pcug.org.au (Owen) wrote:
> > Hi,
>
> > I have perl5.10.0 installed under C:/ and using bash prompt to run a
> >makecommand.
>
> How are you doing that?
>
>
>
> > When I issue themakecommandit throws error
>
> > "Perl Script not found" C:/Program no such file or directory
>
> Where is the script that you are trying to run?
>
>
>
> > Perl is not installed in Program files it under c:
>
> It is not worried about perl, it is worried about the script
>
>
>
> > Also I do understand it could be a spacing problem due to which it is
> > not able to get Program Files.
> > But Iam sure what it is trying to find in program files.
>
> > I have C:/Perl/bin/perl5.10.0 added to my PATH variable.
>
> > How do I sort out this issue.
> > Or does program files contain some other requirement needed by the
> >makefile.
> > Please let me know.
>
> What is themakefile? Note that 'make' is not a perlcommand.
>
> Owen

Hi,

Iam running a windows machine and using cgywin.I need to run a
couple of bash commands in windows environment as it is the
requirement of the installation kit.
Basic requirements that is needed for instaaltion are
cgywin
VC++
Perl

Installed those and when I need to run a make command in one
particular directory of the kit it throws me this error.
Please suggest


--
To unsubscribe, e-mail: beginners-unsubscr...@perl.org
For additional commands, e-mail: beginners-h...@perl.org
http://learn.perl.org/




Re: make command throws error "Perl script no found" C:/Program No such file or directory

2009-01-07 Thread Rob Dixon
viji19812...@gmail.com wrote:
> 
> I have perl5.10.0 installed under C:/ and using bash prompt to run a
> make command.
> 
> When I issue the make command it throws error
> 
> "Perl Script not found" C:/Program no such file or directory
> 
> Perl is not installed in Program files it under c:
> 
> Also I do understand it could be a spacing problem due to which it is
> not able to get Program Files.
> But Iam sure what it is trying to find in program files.
> 
> I have C:/Perl/bin/perl5.10.0 added to my PATH variable.
> 
> How do I sort out this issue.
> Or does program files contain some other requirement needed by the
> make file.
> Please let me know.

You have a confusion of ideas between Unix and Windows and it will be very
difficult to help you without seeing first-hand what you have done. If you have
booted to Windows then you are not running a bash shell unless you also have
Cygwin or something similar installed. On the other hand, if you have booted to
Linux then the Windows paths are irrelevant.

Rob

-- 
To unsubscribe, e-mail: beginners-unsubscr...@perl.org
For additional commands, e-mail: beginners-h...@perl.org
http://learn.perl.org/




Re: make command throws error "Perl script no found" C:/Program No such file or directory

2009-01-07 Thread viji19812001
On Jan 6, 5:32 pm, rc...@pcug.org.au (Owen) wrote:
> > Hi,
>
> > I have perl5.10.0 installed under C:/ and using bash prompt to run a
> >makecommand.
>
> How are you doing that?
>
> Installed perl online. And Under C:/cygwin/bash.exe takes me to bash 
> prompt.there i issue a make command which is needed for an installation 
> that Iam doing
>
> > When I issue themakecommandit throws error
>
> > "Perl Script not found" C:/Program no such file or directory
>
> Where is the script that you are trying to run?
>
Iam installing an opentv kit...hence its make command that iam running
under c:/optv.where the kit is installed.
>
>
> > Perl is not installed in Program files it under c:
>
> It is not worried about perl, it is worried about the script
>
>
>
> > Also I do understand it could be a spacing problem due to which it is
> > not able to get Program Files.
> > But Iam sure what it is trying to find in program files.
>
> > I have C:/Perl/bin/perl5.10.0 added to my PATH variable.
>
> > How do I sort out this issue.
> > Or does program files contain some other requirement needed by the
> >makefile.
> > Please let me know.
>
> What is themakefile? Note that 'make' is not a perlcommand.
>
True ,make is a unix command which iam executing in bash prompt but it
shows some dependency while executing the make command.
Please let me know what needs to be done.
> Owen


--
To unsubscribe, e-mail: beginners-unsubscr...@perl.org
For additional commands, e-mail: beginners-h...@perl.org
http://learn.perl.org/




Re: make command throws error "Perl script no found" C:/Program No such file or directory

2009-01-06 Thread Owen
> Hi,
>
> I have perl5.10.0 installed under C:/ and using bash prompt to run a
> make command.

How are you doing that?

>
> When I issue the make command it throws error
>
> "Perl Script not found" C:/Program no such file or directory

Where is the script that you are trying to run?

>
> Perl is not installed in Program files it under c:

It is not worried about perl, it is worried about the script

>
> Also I do understand it could be a spacing problem due to which it is
> not able to get Program Files.
> But Iam sure what it is trying to find in program files.
>
> I have C:/Perl/bin/perl5.10.0 added to my PATH variable.
>
> How do I sort out this issue.
> Or does program files contain some other requirement needed by the
> make file.
> Please let me know.



What is the make file? Note that 'make' is not a perl command.



Owen


-- 
To unsubscribe, e-mail: beginners-unsubscr...@perl.org
For additional commands, e-mail: beginners-h...@perl.org
http://learn.perl.org/




make command throws error "Perl script no found" C:/Program No such file or directory

2009-01-06 Thread viji19812001
Hi,

I have perl5.10.0 installed under C:/ and using bash prompt to run a
make command.

When I issue the make command it throws error

"Perl Script not found" C:/Program no such file or directory

Perl is not installed in Program files it under c:

Also I do understand it could be a spacing problem due to which it is
not able to get Program Files.
But Iam sure what it is trying to find in program files.

I have C:/Perl/bin/perl5.10.0 added to my PATH variable.

How do I sort out this issue.
Or does program files contain some other requirement needed by the
make file.
Please let me know.

Regards,
vijaya.


-- 
To unsubscribe, e-mail: beginners-unsubscr...@perl.org
For additional commands, e-mail: beginners-h...@perl.org
http://learn.perl.org/




Re: No such file or directory

2008-05-30 Thread Mimi Cafe
Still cannot see why Perl complains that  Could not open file for reading.
File or directory does exist.
I have modified my script and now using Getopt::Long module instead of the
@ARGV variable. Can someone take a look?

The script is now run with command line options like this:
myscript --master --compare file_name --compare another_file

Here is a section of the script

use strict;
use warnings;
#use diagnostics;
use Getopt::Long;

use constant DEFAULT_REPORTDIR => ".\\compare_report";

my $master_list = "";
my @compare_lists = "";
my $help = "";

Getopt::Long::Configure ("ignorecase");

GetOptions(
 "master=s" => \$master_list,
 "compare:s" => [EMAIL PROTECTED],
 "help|?!" => \$help,
);

usage() if $help;
@compare_lists = split(' ',join(' ',@compare_lists));
foreach (@compare_lists){
 die "File $_ does not exist or it's empty. Please check the file try
again.\n" unless -s $_;
}


#foreach (@compare_lists){print "$_\n";} # This prints the CLI arguments
correctly.
#

my $outputdir = DEFAULT_REPORTDIR;
unless (-d $outputdir){
 mkdir ($outputdir) or die "could not create dir for $outputdir: $!\n";
}

# Read the master list and populate our array.
open (MASTERFILE, "<", $master_list) or die "Could not open $master_list for
reading: $!\n";
my @master_clients = ;
close MASTERFILE;
##
#print "master list starts below:\n";
#foreach (@master_clients){print "$_\n";}exit;
##
my (%inputclient,$list);

# Read the other files and compare the content to the master client list.
foreach $list (@compare_lists){
 # Output file name set of element curerently processed.
 # Open file to read from.
 open(INPUTFH, "<", $list) or die "Could not open $list for reading:
$!\n"; # Could
not open file for reading. File or directory does exist.
 while (){
   chomp;
   $inputclient{"s_"} = $_;
 }
 close INPUTFH;

 #$outputfile = "NOT_IN" . "$outputfile";
 my $outputfile = $list;
 my (@missing_clients, %outputclient);

 open (OUTPUTFILE, ">", $outputfile) || die "Could not open $outputfile:
$!\n";
 foreach my $aditem (@master_clients){
  push (@missing_clients, $aditem) unless exists $inputclient{"$aditem"};
 }



On 29/05/2008, Mimi Cafe <[EMAIL PROTECTED]> wrote:
>
>
>  I am on Windows so it should not be case-sensitive. The script and all
>> required files in one folder. I pass 3 arguments to the script (script.pl
>> file1 file2 file3)and I can open the first file stored in $ARGV[0] as seen
>> below:
>>
>> my $ad_clients = shift @ARGV;
>>
>> open (ADFILE, "<", $ad_clients) or die "Could not open $ad_clients for
>> reading: $! \n"; # This works fine!
>> my @ad_clients = ;
>> close ADFILE;
>>
>> my %inputclient;
>>
>> foreach my $supplied (@ARGV){
>> open (INPUTFILE, "<", $supplied) or die "Could not open $supplied for
>> reading: $!\n # This does not works! Error: No such file or directory
>>
> Mimi
>
>>
>>
>>
>>
>> On 29/05/2008, Ken Foskey <[EMAIL PROTECTED]> wrote:
>>>
>>>  On Thu, 2008-05-29 at 11:45 +0100, Mimi Cafe wrote:
>>>
>>> my script is in the same directory as my files, but it cannot find the file
>>> ABC.txt in open() below.
>>>
>>> foreach my $supplied (@ARGV){
>>>  # Output file name set of element currently processed.
>>>
>>>  # Open file to read from.
>>>  open (INPUTFILE, "<", "$supplied") or die "Could not open $supplied: $!\n";
>>> # Error: No such file or directory.
>>> }
>>>
>>> Any help
>>>
>>> Mimi
>>>
>>>
>>>
>>> for starters you might want to look at the <> operator:
>>>
>>> while( <> ) {
>>> }
>>>
>>> Will read each file on the command line in sequence, saves you thinking
>>> about it.
>>>
>>> If it is Unix it is case sensitive,  is this your problem?
>>>
>>> Are you actually in the directory?   `bin/myscript.pl bin/ABC.txt`
>>>
>>>
>>>
>>
>>
>


Re: No such file or directory

2008-05-29 Thread Mimi Cafe
> I am on Windows so it should not be case-sensitive. The script and all
> required files in one folder. I pass 3 arguments to the script (script.pl
> file1 file2 file3)and I can open the first file stored in $ARGV[0] as seen
> below:
>
> my $ad_clients = shift @ARGV;
>
> open (ADFILE, "<", $ad_clients) or die "Could not open $ad_clients for
> reading: $! \n"; # This works fine!
> my @ad_clients = ;
> close ADFILE;
>
> my %inputclient;
>
> foreach my $supplied (@ARGV){
> open (INPUTFILE, "<", $supplied) or die "Could not open $supplied for
> reading: $!\n # This does not works! Error: No such file or directory
>
Mimi

>
>
>
>
> On 29/05/2008, Ken Foskey <[EMAIL PROTECTED]> wrote:
>>
>>  On Thu, 2008-05-29 at 11:45 +0100, Mimi Cafe wrote:
>>
>> my script is in the same directory as my files, but it cannot find the file
>> ABC.txt in open() below.
>>
>> foreach my $supplied (@ARGV){
>>  # Output file name set of element currently processed.
>>
>>  # Open file to read from.
>>  open (INPUTFILE, "<", "$supplied") or die "Could not open $supplied: $!\n";
>> # Error: No such file or directory.
>> }
>>
>> Any help
>>
>> Mimi
>>
>>
>>
>> for starters you might want to look at the <> operator:
>>
>> while( <> ) {
>> }
>>
>> Will read each file on the command line in sequence, saves you thinking
>> about it.
>>
>> If it is Unix it is case sensitive,  is this your problem?
>>
>> Are you actually in the directory?   `bin/myscript.pl bin/ABC.txt`
>>
>>
>>
>
>


Re: No such file or directory

2008-05-29 Thread Mimi Cafe
I am on Windows so it should not be case-sensitive. The script and all
required files in one folder. I pass 2 arguments to the script and can I can
open open the file in the $ARGV[0].

my $ad_clients = shift @ARGV;

open (ADFILE, "<", $ad_clients) or die "Could not open $ad_clients for
reading: $! \n"; # This works fine!
my @ad_clients = ;
close ADFILE;

my %inputclient;

foreach my $supplied (@ARGV){
open (INPUTFILE, "<", $supplied) or die "Could not open $supplied for
reading: $!\n # This does not works! Error: No such file or directory
Mimi




On 29/05/2008, Ken Foskey <[EMAIL PROTECTED]> wrote:
>
>  On Thu, 2008-05-29 at 11:45 +0100, Mimi Cafe wrote:
>
> my script is in the same directory as my files, but it cannot find the file
> ABC.txt in open() below.
>
> foreach my $supplied (@ARGV){
>  # Output file name set of element currently processed.
>
>  # Open file to read from.
>  open (INPUTFILE, "<", "$supplied") or die "Could not open $supplied: $!\n";
> # Error: No such file or directory.
> }
>
> Any help
>
> Mimi
>
>
>
> for starters you might want to look at the <> operator:
>
> while( <> ) {
> }
>
> Will read each file on the command line in sequence, saves you thinking
> about it.
>
> If it is Unix it is case sensitive,  is this your problem?
>
> Are you actually in the directory?   `bin/myscript.pl bin/ABC.txt`
>
>
>


Re: No such file or directory

2008-05-29 Thread Ken Foskey
On Thu, 2008-05-29 at 11:45 +0100, Mimi Cafe wrote:

> my script is in the same directory as my files, but it cannot find the file
> ABC.txt in open() below.
> 
> foreach my $supplied (@ARGV){
>  # Output file name set of element currently processed.
> 
>  # Open file to read from.
>  open (INPUTFILE, "<", "$supplied") or die "Could not open $supplied: $!\n";
> # Error: No such file or directory.
> }
> 
> Any help
> 
> Mimi



for starters you might want to look at the <> operator:

while( <> ) {
}

Will read each file on the command line in sequence, saves you thinking
about it.

If it is Unix it is case sensitive,  is this your problem?

Are you actually in the directory?   `bin/myscript.pl bin/ABC.txt`



Re: No such file or directory

2008-05-29 Thread Jeff Peng
On Thu, May 29, 2008 at 6:45 PM, Mimi Cafe <[EMAIL PROTECTED]> wrote:
> my script is in the same directory as my files, but it cannot find the file
> ABC.txt in open() below.
>
> foreach my $supplied (@ARGV){
>  # Output file name set of element currently processed.
>
>  # Open file to read from.
>  open (INPUTFILE, "<", "$supplied") or die "Could not open $supplied: $!\n";
> # Error: No such file or directory.
> }

How do you pass the files to the script?
Using opendir to do it is better I may suggest.


-- 
Jeff Peng - [EMAIL PROTECTED]
Professional Squid supports in China
http://www.ChinaSquid.com/

-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
http://learn.perl.org/




No such file or directory

2008-05-29 Thread Mimi Cafe
my script is in the same directory as my files, but it cannot find the file
ABC.txt in open() below.

foreach my $supplied (@ARGV){
 # Output file name set of element currently processed.

 # Open file to read from.
 open (INPUTFILE, "<", "$supplied") or die "Could not open $supplied: $!\n";
# Error: No such file or directory.
}

Any help

Mimi


Re: No such file or directory

2008-05-21 Thread anthony brooke



- Original Message 
From: Jeff Peng <[EMAIL PROTECTED]>
To: Perl Beginners 
Sent: Wednesday, May 21, 2008 15:53:00
Subject: Re: No such file or directory

> open(RULES, 'rule.pl')

please use full path if you don't know where you are exactly.

On Wed, May 21, 2008 at 3:45 PM, anthony brooke <[EMAIL PROTECTED]> wrote:


-- 
Jeff Peng - [EMAIL PROTECTED]
Professional Squid supports in China
http://www.ChinaSquid.com/

-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
http://learn.perl.org/


The problem is I am using mod_perl, wherever I am it always show "/" as the 
current working directory. I got to post the problem to 

Send instant messages to your online friends http://uk.messenger.yahoo.com 

Re: No such file or directory

2008-05-21 Thread Jeff Peng
> open(RULES, 'rule.pl')

please use full path if you don't know where you are exactly.

On Wed, May 21, 2008 at 3:45 PM, anthony brooke <[EMAIL PROTECTED]> wrote:


-- 
Jeff Peng - [EMAIL PROTECTED]
Professional Squid supports in China
http://www.ChinaSquid.com/

-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
http://learn.perl.org/




Re: No such file or directory

2008-05-21 Thread anthony brooke





anthony brooke wrote:
> Hello, I know that this is a very common problem, but I am very sure that  
> the file exist in that directory, also its permission is -rwxrwxrwx , why 
> does it give such an error ? What are the other potential problems that cause 
> this ? Thanks
>
> Send instant messages to your online friends http://uk.messenger.yahoo.com 
>  
Anthony
It would help  if you could post a sample of you script and give the 
actuall error.


Also I am using mod_perl, is it because of that make my cwd become the top 
directory "/" ? Thanks

Send instant messages to your online friends http://uk.messenger.yahoo.com 

Re: No such file or directory

2008-05-21 Thread anthony brooke





anthony brooke wrote:
> Hello, I know that this is a very common problem, but I am very sure that  
> the file exist in that directory, also its permission is -rwxrwxrwx , why 
> does it give such an error ? What are the other potential problems that cause 
> this ? Thanks
>
> Send instant messages to your online friends http://uk.messenger.yahoo.com 
>  
Anthony
It would help  if you could post a sample of you script and give the 
actuall error.


open(RULES, 'rule.pl') || die "Could not open rule file 'rule.pl'. Error 
$!";
Could not open rule file 'rule.pl'. Error No such file or directory at 
/var/www/modperl//ParserGenerator.pm line 368.

Btw, why do I have double forward slash on that shown module ?

When I put these code in /var/www/modperl//ParserGenerator.pm
use Cwd;
die ">>".getcwd."<<";

[Wed May 21 15:17:46 2008] [error] >>/<< at 
/var/www/modperl//ParserGenerator.pm line 44.\n

I think I am confuse now.

Send instant messages to your online friends http://uk.messenger.yahoo.com 

Re: No such file or directory

2008-05-20 Thread Roman

anthony brooke wrote:

Hello, I know that this is a very common problem, but I am very sure that  the 
file exist in that directory, also its permission is -rwxrwxrwx , why does it 
give such an error ? What are the other potential problems that cause this ? 
Thanks

Send instant messages to your online friends http://uk.messenger.yahoo.com 
  

Anthony
It would help  if you could post a sample of you script and give the 
actuall error.


--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
http://learn.perl.org/




No such file or directory

2008-05-20 Thread anthony brooke
Hello, I know that this is a very common problem, but I am very sure that  the 
file exist in that directory, also its permission is -rwxrwxrwx , why does it 
give such an error ? What are the other potential problems that cause this ? 
Thanks

Send instant messages to your online friends http://uk.messenger.yahoo.com 

Re: AW: *.jpg: No such file or directory

2003-04-01 Thread Scott R. Godin
James Hughes wrote:

> 
> Just a thought, but try to change to your directory first
> 
> my $dir = '/home/me/images/';
> my @jpegs = `ls *.jpg`;
> chdir ($dir) || die "Cannot chdir to $dir: $!";;
> foreach (@jpegs) {
> print"$_";# dont forget that a newline is still at the end of
> each element in the array...
> }

err, make that

my $dir = '/home/me/images';
chdir $dir or die "Cannot chdir to $dir: $!";
my @jpegs = glob "*.jpg"; #use perl rather than shell wherever possible

print join("\n", @jpegs) if scalar(@jpegs);

Always chdir to the dir you need FIRST, before actually trying to get a list 
of files IN it. ;) 


-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



AW: *.jpg: No such file or directory

2003-03-31 Thread Hughes, James

Just a thought, but try to change to your directory first

my $dir = '/home/me/images/';
my @jpegs = `ls *.jpg`;
chdir ($dir) || die "Cannot chdir to $dir: $!";;
foreach (@jpegs) {
print"$_";  # dont forget that a newline is still at the end of
each element in the array...
}




-Ursprüngliche Nachricht-
Von: mel awaisi [mailto:[EMAIL PROTECTED]
Gesendet: Mittwoch, 12. März 2003 03:43
An: [EMAIL PROTECTED]; [EMAIL PROTECTED]
Betreff: ls: *.jpg: No such file or directory 


Hi

My error is as the subject says, i have a script that i am 
trying in it to 
locate where a directory with images are.

the part in the script that the error i think is arising from is

my $dir = '/home/me/images/';
my @jpegs = `ls *.jpg`;
foreach (@jpegs) {
print"$_";  # dont forget that a newline is still 
at the end of each 
element in the array...
}

----
ls: *.jpg: No such file or directory
---

Regards,

Mel

_
Chat online in real time with MSN Messenger http://messenger.msn.co.uk


-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: AW: ls: *.jpg: No such file or directory

2003-03-12 Thread Scott R. Godin
On Wed, 12 Mar 2003, Liedtke Stephan ICM MP IT BLM GA KLF wrote:

Obviously people have gotten so used to top-posting and reading things 
BACKWARDS (and NOT reading the stuff that comes afterwards, like 
the REST OF KNOWN HUMANITY) that... 

> 
> Try my @jpegs = `ls /*.jpg`;
> 
>   SIEMENS AG
>   Information and Communication mobile
>   ICM MP IT BLM GA KLf
>   *:+49 (0) 2842-95-4979
>   Südstr. 9 *:   +49 (0) 2842-95-5991
>   D-47475 Kamp-Lintfort   *: [EMAIL PROTECTED]
> 
> 
> 
> -Ursprüngliche Nachricht-
> Von: Scott R. Godin [mailto:[EMAIL PROTECTED] 
> Gesendet: Mittwoch, 12. März 2003 11:25
> An: [EMAIL PROTECTED]; [EMAIL PROTECTED]
> Betreff: Re: ls: *.jpg: No such file or directory 
> 
> 
> Mel Awaisi wrote:
> 
> > Hi
> > 
> > My error is as the subject says, i have a script that i am trying in 
> > it to locate where a directory with images are.
> > 
> > the part in the script that the error i think is arising from is
> > 
> > my $dir = '/home/me/images/';
> > my @jpegs = `ls *.jpg`;
> > foreach (@jpegs) {
> > print"$_";    # dont forget that a newline is still at the end of each
> > element in the array...
> > }
> > 
> > 
> > ls: *.jpg: No such file or directory
> > ---
> > 

...they COMPLETELY miss the fact that I RESPONDED to THE ABOVE, with THE 
BELOW: 

> 
> chdir '/home/me/images/' or die "Unable to chdir to /home/me/images: $!"; my
> @jpegs = glob "*.jpg";
> 
> print "$_\n" for @jpegs;
> 

Q.E.D.


This is why top-posting is bad, people.

Deal with it. Just say no to top-posting.



-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



RE: *.jpg: No such file or directory

2003-03-12 Thread Dan Muey

> Hi
Howdy!
Definitely not a DBI question, prepare to pummeled by them ;p

> 
> My error is as the subject says, i have a script that i am 
> trying in it to 
> locate where a directory with images are.

As I'm sure you'll hear a lot of ::
1) That is not an error. There are not any jpg files in the directory that the script 
is in apparently.
2) You need to either chdir or put the directory name in the ls cammand
3) Since you are getting a reply from the ls program there's probably no need to 
specify the entire path to the program.
But that's something to think about whenever doing backtick executions.

@jpegs = `ls /home/me/images/*.jpg`;
foreach ...
4) if all you want to do is print them one per line just do ::
print `;s /home/me/images/*.jpg`;


DMuey

> 
> the part in the script that the error i think is arising from is
> 
> my $dir = '/home/me/images/';
> my @jpegs = `ls *.jpg`;
> foreach (@jpegs) {
>   print"$_";  # dont forget that a newline is still 
> at the end of each 
> element in the array...
> }
> 
> 
> ls: *.jpg: No such file or directory
> ---
> 
> Regards,
> 
> Mel
> 
> _
> Chat online in real time with MSN Messenger http://messenger.msn.co.uk
> 
> 
> -- 
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> 
> 

--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: ls: *.jpg: No such file or directory

2003-03-12 Thread Scott R. Godin
Mel Awaisi wrote:

> Hi
> 
> My error is as the subject says, i have a script that i am trying in it to
> locate where a directory with images are.
> 
> the part in the script that the error i think is arising from is
> 
> my $dir = '/home/me/images/';
> my @jpegs = `ls *.jpg`;
> foreach (@jpegs) {
> print"$_";# dont forget that a newline is still at the end of each
> element in the array...
> }
> 
> 
> ls: *.jpg: No such file or directory
> ---
> 

chdir '/home/me/images/' or die "Unable to chdir to /home/me/images: $!";
my @jpegs = glob "*.jpg";

print "$_\n" for @jpegs;


-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



RE: *.jpg: No such file or directory

2003-03-12 Thread Paul Boutros
This doesn't seem to be a database question, and so doesn't really belong
on the DBI mailing list.  I've removed it from the follow-up list.
Paul

On Tue, 11 Mar 2003, Corey D. Herbel wrote:

> two thoughts
> 
> I'd imagine the path to the command 'ls' is unknown.  Try the full command
> path for the command.
> e.g. '/bin/ls'
> 
> Prossibly a better way to write the code...
> my $imagedir="/home/me/images";
> chdir($imagedir) or die "Can't cd to $imagedir; $!\n";
> my @jpegs = <*.jpg>;
> foreach (@jpegs)  {
>   
> }
> 
> -Original Message-
> From: mel awaisi [mailto:[EMAIL PROTECTED]
> Sent: Tuesday, March 11, 2003 8:43 PM
> To: [EMAIL PROTECTED]; [EMAIL PROTECTED]
> Subject: ls: *.jpg: No such file or directory
> 
> 
> Hi
> 
> My error is as the subject says, i have a script that i am trying in it to
> locate where a directory with images are.
> 
> the part in the script that the error i think is arising from is
> 
> my $dir = '/home/me/images/';
> my @jpegs = `ls *.jpg`;
> foreach (@jpegs) {
>   print"$_";  # dont forget that a newline is still at the end of each
> element in the array...
> }
> 
> 
> ls: *.jpg: No such file or directory
> ---
> 
> Regards,
> 
> Mel
> 
> _
> Chat online in real time with MSN Messenger http://messenger.msn.co.uk
> 


-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



RE: *.jpg: No such file or directory

2003-03-12 Thread Corey D. Herbel
two thoughts

I'd imagine the path to the command 'ls' is unknown.  Try the full command
path for the command.
e.g. '/bin/ls'

Prossibly a better way to write the code...
my $imagedir="/home/me/images";
chdir($imagedir) or die "Can't cd to $imagedir; $!\n";
my @jpegs = <*.jpg>;
foreach (@jpegs)  {

}

-Original Message-
From: mel awaisi [mailto:[EMAIL PROTECTED]
Sent: Tuesday, March 11, 2003 8:43 PM
To: [EMAIL PROTECTED]; [EMAIL PROTECTED]
Subject: ls: *.jpg: No such file or directory


Hi

My error is as the subject says, i have a script that i am trying in it to
locate where a directory with images are.

the part in the script that the error i think is arising from is

my $dir = '/home/me/images/';
my @jpegs = `ls *.jpg`;
foreach (@jpegs) {
print"$_";  # dont forget that a newline is still at the end of each
element in the array...
}


ls: *.jpg: No such file or directory
---

Regards,

Mel

_
Chat online in real time with MSN Messenger http://messenger.msn.co.uk


-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: ls: *.jpg: No such file or directory

2003-03-11 Thread Steve Grazzini
In perl.beginners Mel Awaisi <[EMAIL PROTECTED]> wrote:
> 
> the part in the script that the error i think is arising 
> from is
> 
> my $dir = '/home/me/images/';
> my @jpegs = `ls *.jpg`;
> foreach (@jpegs) {
>   print"$_";  # dont forget that a newline is 
>   # still at the end of each 
>   # element in the array...
> }
> 
> 
> ls: *.jpg: No such file or directory
> ---

I'm not sure what your question is... but since you've
declared $dir and not actually used it, maybe you want
to try one of these:

  #
  # add the directory to the glob
  #
  my @jpegs = qx{ ls $dir/*.jpg };

  #
  # or better yet, use Perl's glob
  #
  my @jpegs = glob "$dir/*.jpg";

You could also chdir() to the images directory first.

[ f'ups set ]

HTH
-- 
Steve

-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



ls: *.jpg: No such file or directory

2003-03-11 Thread mel awaisi
Hi

My error is as the subject says, i have a script that i am trying in it to 
locate where a directory with images are.

the part in the script that the error i think is arising from is

my $dir = '/home/me/images/';
my @jpegs = `ls *.jpg`;
foreach (@jpegs) {
	print"$_"; 	# dont forget that a newline is still at the end of each 
element in the array...
}

----
ls: *.jpg: No such file or directory
---
Regards,

Mel

_
Chat online in real time with MSN Messenger http://messenger.msn.co.uk
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


RE: "No Such File or Directory"

2002-10-15 Thread Nikola Janceski

That's not ok.

use File::Path;
mkpath();

if you want that functionality.

> -Original Message-
> From: James Edward Gray II [mailto:[EMAIL PROTECTED]]
> Sent: Tuesday, October 15, 2002 2:14 PM
> To: [EMAIL PROTECTED]
> Subject: "No Such File or Directory"
> 
> 
> Okay, here's a different on, mkdir() is giving me a "No Such File or 
> Directory" error.  I am passing it a string of two directories I want 
> created, one inside the other, but the way I read the entry in 
> Programming Perl, this is okay.  Am I missing something?
> 
> James
> 
> 
> -- 
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> 



The views and opinions expressed in this email message are the sender's
own, and do not necessarily represent the views and opinions of Summit
Systems Inc.


-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]




"No Such File or Directory"

2002-10-15 Thread James Edward Gray II

Okay, here's a different on, mkdir() is giving me a "No Such File or 
Directory" error.  I am passing it a string of two directories I want 
created, one inside the other, but the way I read the entry in 
Programming Perl, this is okay.  Am I missing something?

James


-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]




Re: No such file or directory exists

2001-10-24 Thread Peter Scott

At 10:12 AM 10/24/2001 -0500, [EMAIL PROTECTED] wrote:
>elementary? oooh, that hurts =)

Hey, everyone does it (or something like it), that's the only reason to 
call it elementary - because we manage to keep making the same mistakes and 
forgetting to check the obvious.  You want to know how many times I've 
hunted down the bug that turned out to be typing #!/usr/bin/prel?  Or 
leaving the semicolon out after use strict?  A few days ago I thought I was 
so hot for reporting how perl cored when I accidentally typed perl -duse 
strict.  Until Jarrko pointed out that this was using the -u flag.  Doh.

The help desk people who start by asking the user whether the machine is 
plugged in don't seem so deserving of scorn as they are usually portrayed...

>but you are right, I should have been using -w

Oh, you'd still have a problem on 5.004 (an even more perplexing error 
message).  But at least then we'd be able to tell that you'd enabled 
warnings :-)
Peter Scott
[EMAIL PROTECTED]
http://www.perldebugged.com


-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]




Re: No such file or directory exists

2001-10-24 Thread Greg . Froese

elementary? oooh, that hurts =)
but you are right, I should have been using -w




Peter Scott <[EMAIL PROTECTED]>
10/24/2001 10:03 AM

 
To: [EMAIL PROTECTED], [EMAIL PROTECTED]
cc: 
Subject:    Re: No such file or directory exists


At 09:01 AM 10/24/2001 -0500, [EMAIL PROTECTED] wrote:
>I'm working with my perl scripts in Linux and Windows.  my scripts were
>running fine when I ran them as "perl myscript.pl"
>
>but when I tried to execute the perl script using only its name
>(./myscript.pl) then I would get the message "No such file exists"
>I searched and searched until I found that there were ^M chars at the end
>of each line of my source.  These could not be seen with the text editor 
I
>was using, but could be seen using "cat -v myscript.pl"
>
>I also found a one line perl command that removes all of these 
characters,
>and then my script worked fine to run as "./myscript.pl".
>I don't have that command on this machine, but if anybody is having the
>same trouble, I could email them later with the command.
>
>What is the cause of these chars? Is it using a Windows editor to code
>these scripts, and then running them in Linux?

Bingo.  And I'll bet you're being naughty and not using the -w flag 
(unless 
you're being modern and using 'use warnings', in which case I take it back 

and then some).  Because the ^M at the end of the #! line is being taken 
as 
part of the invocation, and in order for you to get that error message, it 

would have to be taken as part of the path to perl, which means that you 
don't have any options following it.

>I'm curious to know the cause of this because I spent a good part of 2
>hours getting that problem sorted out.

Often the silliest things do have this effect.  That's why I mentioned 
this 
one (which can cause other errors) and other 'elementary' errors in my 
book.
Peter Scott
[EMAIL PROTECTED]
http://www.perldebugged.com






Re: No such file or directory exists

2001-10-24 Thread Peter Scott

At 09:01 AM 10/24/2001 -0500, [EMAIL PROTECTED] wrote:
>I'm working with my perl scripts in Linux and Windows.  my scripts were
>running fine when I ran them as "perl myscript.pl"
>
>but when I tried to execute the perl script using only its name
>(./myscript.pl) then I would get the message "No such file exists"
>I searched and searched until I found that there were ^M chars at the end
>of each line of my source.  These could not be seen with the text editor I
>was using, but could be seen using "cat -v myscript.pl"
>
>I also found a one line perl command that removes all of these characters,
>and then my script worked fine to run as "./myscript.pl".
>I don't have that command on this machine, but if anybody is having the
>same trouble, I could email them later with the command.
>
>What is the cause of these chars? Is it using a Windows editor to code
>these scripts, and then running them in Linux?

Bingo.  And I'll bet you're being naughty and not using the -w flag (unless 
you're being modern and using 'use warnings', in which case I take it back 
and then some).  Because the ^M at the end of the #! line is being taken as 
part of the invocation, and in order for you to get that error message, it 
would have to be taken as part of the path to perl, which means that you 
don't have any options following it.

>I'm curious to know the cause of this because I spent a good part of 2
>hours getting that problem sorted out.

Often the silliest things do have this effect.  That's why I mentioned this 
one (which can cause other errors) and other 'elementary' errors in my book.
Peter Scott
[EMAIL PROTECTED]
http://www.perldebugged.com


-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]




Re: No such file or directory exists

2001-10-24 Thread Etienne Marcotte

I run my scripts on both linux and windows and never got this problem..

Always edited with notepad or wordpad.

I run them from the command line or by choosing "open with -> perl" directly
on the file with my win2k.

I really don't know what was causing the problem... but IMO the "no such file
exists" means that it's not found.. if it was the ^M that would mean the file
was found, and then an error would maybe occur when reading it..

Etienne

[EMAIL PROTECTED] wrote:

> That was not the problem.  The problem was the ^M at the end of each line
>
> walter valenti <[EMAIL PROTECTED]>
> Sent by: [EMAIL PROTECTED]
> 10/24/2001 09:11 AM
>
>
> To: [EMAIL PROTECTED]
> cc: [EMAIL PROTECTED], [EMAIL PROTECTED]
> Subject:Re: No such file or directory exists
>
> Hi,
> look the first line of the script: contains the location of perl's
> interpreter
> Most common are:
> #!/usr/bin/perl
>
> #!/usr/local/bin/perl
>
> Walter
>
> > I'm working with my perl scripts in Linux and Windows.  my scripts were
> > running fine when I ran them as "perl myscript.pl"
> >
> > but when I tried to execute the perl script using only its name
> > (./myscript.pl) then I would get the message "No such file exists"
> > I searched and searched until I found that there were ^M chars at the
> end
> > of each line of my source.  These could not be seen with the text editor
> I
> > was using, but could be seen using "cat -v myscript.pl"
> >
> > I also found a one line perl command that removes all of these
> characters,
> > and then my script worked fine to run as "./myscript.pl".
> > I don't have that command on this machine, but if anybody is having the
> > same trouble, I could email them later with the command.
> >
> > What is the cause of these chars? Is it using a Windows editor to code
> > these scripts, and then running them in Linux?
> > I'm curious to know the cause of this because I spent a good part of 2
> > hours getting that problem sorted out.
> >
> > Thanks,
> > Greg
>
> _
> Do You Yahoo!?
> Get your free @yahoo.com address at http://mail.yahoo.com

 S/MIME Cryptographic Signature