Re: [AMBER] Difficulty compiling amber12/ambertools13

From: Jason Swails <jason.swails.gmail.com>
Date: Mon, 17 Jun 2013 13:42:02 -0400

On Mon, Jun 17, 2013 at 12:10 PM, Daniel Roe <daniel.r.roe.gmail.com> wrote:

> Hi,
>
> This is actually an issue with dos line endings in the patch file
> confusing 'patch' under cygwin. If you remove the dos line endings
> from the patch, updating should occur successfully:
>

I'll expand on this a little bit for those curious. The problem arose
initially due to a saved test file that had dos line endings --
particularly the MMPBSA.py saved CSV files (energies.csv.save), which were
created via the Python CSV module. The person that created these files
(me), did so on a Mac, which, by default, uses carriage returns instead of
Unix newlines in its standard text editors.

Since most editors are friendly to these files, this never presented any
noticeable problems before. Cue Cygwin.

Because it operates on DOS, where everything is carriage-return newlines,
it helpfully discards these newlines in the saved test files for MMPBSA.py
(since they are saved in a Cygwin-owned directory, as I understand).
 However, the patch file indicates that these carriage-return endings
should be present for these files, and so the patching process dies when it
can't match the context of the changes.

We can't simply dos2unix the patch file in general, since it will then fail
on true Unix systems (where such implicit \r\n -> \n conversion is not
done). The solution implemented in the fix that was just released is to
detect this condition on Cygwin and convert the newlines when appropriate.


You can fix update_amber to work on cygwin with the following command:

cd $AMBERHOME && ./update_amber --apply
http://ambermd.org/bugfixes/AmberTools/13.0/cygwin_fix

After you do this, you should be able to simply follow the instructions
online to get Amber installed. (The above command will not cause any
problems on Linux and Mac computers, but it's only necessary on Windows)

Thanks for the report,
Jason

-- 
Jason M. Swails
Quantum Theory Project,
University of Florida
Ph.D. Candidate
352-392-4032
_______________________________________________
AMBER mailing list
AMBER.ambermd.org
http://lists.ambermd.org/mailman/listinfo/amber
Received on Mon Jun 17 2013 - 11:00:02 PDT
Custom Search