Re: [AMBER] problem building AmberTools/sleap on AIX

From: Wei Zhang <zgjzweig.gmail.com>
Date: Fri, 16 Jan 2009 15:19:42 -0600

Hi Shan-ho,

     I guess the easiest way it to skip the whole nablib directory,
current it is not used by sleap yet.

     To do this, you have to modify gleap/mortsrc/Makefile,

    (1) in the first section:

     OBJECTS = \
            .......... \
            nablib/xxx.o ...\
            nablib/xxx.o

      remove the those object file in nablist

    (2) in the second section:

      all:
           .....
           cd nablib; make
           .....

      remove the line "cd nablib; make"

    Can you try this and let me know the result?

     Sincerely,

     Wei








On Jan 16, 2009, at 2:58 PM, Shan-ho Tsai wrote:

>
> Hi all,
>
> I'm still struggling to get sleap to build on AIX.
> As my last posting in this thread indicates, I've
> tried to compile all mortsrc/nablib code (both C
> and C++ code) with g++. However, I got an error
> when compiling memutil.c (incorrect C++ syntax
> in nab.h). Is there a way I can modify nab.h
> (line 219) to make it compatible with g++ ?
>
> I've also tried using the IBM xlC compiler, but
> got an error compiling one of the C++ programs.
> As this is not listed as a supported compiler for
> AmberTools, I didn't pursue this path further.
>
> Any other suggestions?
>
> Thanks in advance,
> Shan-Ho
>
>
> On Mon, 12 Jan 2009, Shan-ho Tsai wrote:
>
>>
>> Hi Wei,
>> Thank you very much for your response. I made the change
>> in src/gleap/mortsrc/nablib/Makefile that you suggested
>> and recompiled. I am getting an error compiling memutil.c.
>> The error message is:
>>
>> g++ -c -Dflex -DMORT -O3 -DBINTRAJ -o memutil.o memutil.c
>> In file included from memutil.c:4:
>> nab.h:219: error: expected ',' or '...' before '&' token
>> nab.h:219: error: ISO C++ forbids declaration of 'molecule_t'
>> with no type
>> gmake[2]: *** [memutil.o] Error 1
>>
>> ---------------------------------------------
>> Line 219 in nab.h is
>>
>> double molsurf(const molecule_t&, double, bool verbose=false );
>>
>> I got this error using either g++ 3.3.2 or 4.1.2.
>>
>> Thank you!
>> Shan-Ho
>>
>> On Fri, 9 Jan 2009, Wei Zhang wrote:
>>
>>> Hi,
>>>
>>> It looks like due to C++ name mangling, maybe because we use gcc
>>> to compile c source
>>> code, but use g++ to compile c++ code and link them together.
>>>
>>> Can you try the following:
>>>
>>> find file amber10/src/gleap/mortsrc/nablib/Makefile. Change line
>>> 3 to 4 from:
>>> .c.o:
>>> $(CC) -c -Dflex -DMORT $(OCFLAGS) -o $. $<
>>>
>>> to
>>> .c.o:
>>> $(CXX) -c -Dflex -DMORT $(OCFLAGS) -o $. $<
>>>
>>> then recompile. This will make sure c code will also compiled by c+
>>> + compiler.
>>>
>>> Sincerely,
>>>
>>> Wei
>>>
>
> _______________________________________________
> AMBER mailing list
> AMBER.ambermd.org
> http://lists.ambermd.org/mailman/listinfo/amber


_______________________________________________
AMBER mailing list
AMBER.ambermd.org
http://lists.ambermd.org/mailman/listinfo/amber
Received on Sun Jan 18 2009 - 01:22:16 PST
Custom Search