I've been trying to get cygwin running for several whole days now. I've been reading available documentation and fiddling in many ways with system parameters. I even turned off my "Norton Internet Security" software as best as I could and re-installed and then eventually re-downloaded-and-installed cygwin. I finally got the bash command-line window to stay open when I turned off the Windows 95 compatibility switch I had turned on earlier.
Briefly, as of now, when I execute cygwin.bat I get output "Entering
"C:/cygwin/etc/profile"", as suppose I should, followed by a whole series of
lines "bash: $'\r': command not found" with a few interspersed lines "': not a
valid identifier" and then the two following lines (the second is folded):
bash: /etc/profile: line 91: syntax error near unexpected token `$'in\r''
bash: /etc/profile: line 91: `case "`echo "_$0" | /usr/bin/tr '[:upper:]' '[:low
'r:]' | /usr/bin/sed -e 's/^_//'`" in
and then "Entering "C:/Documents and Settings/USER1/Cyg_home/.bash_profile"",
as I guess I should, then several more lines "bash: $'\r': command not found",
and finally the folded line:
bash: /cygdrive/c/Documents and Settings/USER1/Cyg_home/.bash_profile: line 45:
syntax error: unexpected end of file
<period>, end of sentence. (In all cases above, the obviously "outer" double
quotes (") are not a part of any of the output strings indicated.)
And when I try to copy and paste "cygcheck -s -v -r > cygcheck.out" into the
bash command line, I find that the "e"s are missing. And when I try to edit
the line to insert the "e"s, I find that my "e" key is not functional. Even
when I try to type "exit" to close the window, all I get is "xit". But I'm
able to recall a previous "exit" command to execute and close the window.
I imagine that the messages involving "\r" have something to do with the \r\n
conventions. So I should mention that I use WordPad to edit
bash-initialization files.
I am attaching both a file of the above-mentioned screen output ("bash.. $'r'..
command not found.txt") and the output file "cygcheck.out" which resulted from
running the above-mentioned cygcheck line in a Windows command-line window.
The only modifications I made to the copies of the "default"
bash-initialization files were to insert appropriate echo commands, spaces, and
comment-separator lines at the beginning of the files and to insert also (in
"profile") the five lines:
#===============
echo Location 1 after \# export CVSROOT
#===============
just before the line 91:
# Shell dependent settings
case "`echo "_$0" | /usr/bin/tr '[:upper:]' '[:lower:]' | /usr/bin/sed -e
's/^_//'`" in
It is my intention to eventually modify these bash-initialization files
appropriately to conform as best as possible to my old cygwin installation on
my other computer. But I want to do this in an incremental fashion since it is
so difficult to get highly informative diagnostic info from bash comparable to
that of many C++ compilers, especially regarding syntax errors. And I also
want to allow for new procedures and features that may have been incorporated
in cygwin since my old installation. One of the many things my old
bash-initialization files do is to re-organize the environment variable PATH.
I used them to run makefiles, gcc (old version), Dev-Cpp, and Vide 2.0 (not
necessarily all at the same time).
------
Via reading "profile", "bash.bashrc", ".bash_profile", ".bashrc", and
".inputrc" in the "defaults" tree, it appears likely that at least some of
these bash initialization files are supposed to be automatically set up in /etc
and ~, but I am completely stumped on how that is supposed to be done. In case
I'm misreading something, I guessed that I'm supposed to do the copying
manually, and so I copied "profile" and "bash.bashrc" to /etc (C:\cygwin\etc)
and ".bash_profile", ".bashrc", and ".inputrc" to ~ (C:\Documents and
Settings\USER1\Cyg_home). I also inserted "echo Entering ..." statements at
the beginning of each of these files in order to gain some insight as to which
of these files are now executed and in which order. I am assuming that files
in a given directory of the "defaults" tree are all to be copied to the same
directory, and I am also modeling file locations based on an old, working
installation I have on the other computer.
Does anyone have any ideas on how to solve these problems indicated in the bash
output?
Entering "C:/cygwin/etc/profile" bash: $'\r': command not found bash: $'\r': command not found bash: $'\r': command not found bash: $'\r': command not found bash: $'\r': command not found bash: $'\r': command not found bash: $'\r': command not found bash: $'\r': command not found bash: $'\r': command not found bash: $'\r': command not found ': not a valid identifier bash: $'\r': command not found ': not a valid identifier bash: $'\r': command not found ': not a valid identifier bash: $'\r': command not found ': not a valid identifier bash: $'\r': command not found bash: $'\r': command not found bash: /etc/profile: line 91: syntax error near unexpected token `$'in\r'' bash: /etc/profile: line 91: `case "`echo "_$0" | /usr/bin/tr '[:upper:]' '[:low 'r:]' | /usr/bin/sed -e 's/^_//'`" in Entering "C:/Documents and Settings/USER1/Cyg_home/.bash_profile" bash: $'\r': command not found bash: $'\r': command not found bash: $'\r': command not found bash: $'\r': command not found bash: $'\r': command not found bash: $'\r': command not found bash: /cygdrive/c/Documents and Settings/USER1/Cyg_home/.bash_profile: line 45: syntax error: unexpected end of file bash-3.2$
cygcheck.out
Description: Binary data
-- Problem reports: http://cygwin.com/problems.html FAQ: http://cygwin.com/faq/ Documentation: http://cygwin.com/docs.html Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple

