X-Recipient: archive-cygwin AT delorie DOT com X-Spam-Check-By: sourceware.org Message-ID: <4024fa2d0801292014o6c4bd8dfm24f38a882633afb3@mail.gmail.com> Date: Wed, 30 Jan 2008 12:14:05 +0800 From: "Taras D" To: cygwin AT cygwin DOT com Subject: Compiling emacs 22.1 from source MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Content-Disposition: inline Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: cygwin-owner AT cygwin DOT com Mail-Followup-To: cygwin AT cygwin DOT com Delivered-To: mailing list cygwin AT cygwin DOT com Hi all, I'm trying to compile emacs 22.1 from source using Cygwin. The install file says: "`cd' to the directory where you unpacked Emacs and invoke the `configure' script: ./configure" I do this, but I get the following errors: ./configure: line 12: $'\r': command not found ./configure: line 23: syntax error near unexpected token `$'in\r'' ./configure: line 23: ` case `(set -o) 2>/dev/null` in ' I searched for these errors on the internet, and found the following (in the Cygwin FAQ): You may get mysterious messages when bash reads your .bashrc or .bash_profile, such as "\r command not found" (or similar). When you get rid of empty lines, the complaints about "\r" disappears, but probably other errors remain. What is going on? The answer may lie in the fact that a text file (also called ASCII file) can come in two formats: in DOS format or in UNIX format. Most editors can automatically detect the formats and work properly in either format. In the DOS format, a new line is represented by two characters: CR (carriage return or ASCII code 13) and LF (line feed or ASCII code 15). In the UNIX format, a new line is represented by only one character, LF. When your .bashrc file is read, bash thinks the extra character is the name of a command, hence the error message. In Cygwin or unix, you can convert a file INFILE in DOS format to a file OUTFILE in Unix format by calling: > tr -d '\15' < INFILE > OUTFILE NOTE: If you now compare the number of characters in INFILE and OUTFILE, you will see that the latter has lost the correct number of characters (i.e., the number of lines in INFILE): > wc INFILE OUTFILE I tried this, but now get the error: configure_dos_format: error: cannot run /bin/sh /emacs_downloaded/emacs-22.1/config.sub What is going wrong? -- Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple Problem reports: http://cygwin.com/problems.html Documentation: http://cygwin.com/docs.html FAQ: http://cygwin.com/faq/