Re: [AMBER] Amber Install on Mojave (ld: library not found for -lmc) Fix

From: Andrew Schaub <aschaub.uci.edu>
Date: Mon, 8 Oct 2018 12:33:00 -0400

Ok, I think I found a quick fix (I'm doing make install now, and it hasn't
broke yet) for MacOS 10.14 (Mojave) w/ XCode 10.0. From this recent thread:
https://forums.developer.apple.com/thread/106114

I explicitly add the location of those files to my path so the compiler
knows where to look.

export
PATH=$PATH:/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS.sdk/usr/include/

Though this looks like a temporary fix, from someone's reply in a
stackexchange post:

"libstdc++ was deprecated 5 years ago. Apple's more recent platforms (tvOS
and watchOS) don't support it.Support was removed from the iOS 12.0
Simulator runtime, but it remains in the iOS 12.0 (device) runtime for
binary compatibility with shipping apps. You should update your project to
use libc++ rather than libstdc++ by setting the CLANG_CXX_LIBRARY build
setting ("C++ Standard Library") to libc++. If you have any static
libraries that depend on libstdc++.tbd, you can workaround it for now by
copying the file from the SDKs in Xcode 9.4 (and libstdc++.*.dylib in the
iOS simulator runtime), but that is not a long term solution. You should
contact the provider of those libraries and request versions built using
libc++. " Source:
https://stackoverflow.com/questions/50694822/xcode-10-ios-12-does-not-contain-libstdc6-0-9

Hope this helps answer some questions for you as well.

Best Regards,

Andrew

On Mon, Oct 8, 2018 at 10:55 AM Gustaf Olsson <gustaf.olsson.lnu.se> wrote:

> This is the same error that I am receiving using Hombrew GNU compilers, it
> does not make a difference if -macAccelerate is included or omitted
>
> Best regards
> // Gustaf
>
> On 8 Oct 2018, at 15:09, Andrew Schaub <aschaub.uci.edu<mailto:
> aschaub.uci.edu>> wrote:
>
> Ok, I was able to get the serial version working on MacOS Mojave. It failed
> when I tried to do mpi. It might have something to do with the /usr/include
> I have AMBER on my workstation and other laptop. I'm just playing around
> with trying to get it work on a new laptop.
>
> $ ./configure -mpi -macAccelerate gnu
> $ make install
>
> It failed during the parmed installation:
>
> building 'parmed.amber._rdparm' extension
> creating build/temp.macosx-10.7-x86_64-2.7
> creating build/temp.macosx-10.7-x86_64-2.7/src
> clang -fno-strict-aliasing -I/opt/amber18/miniconda/include -arch x86_64
> -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes
> -I/opt/amber18/AmberTools/src/parmed/src
> -I/opt/amber18/miniconda/include/python2.7 -c src/_rdparm.cpp -o
> build/temp.macosx-10.7-x86_64-2.7/src/_rdparm.o
> warning: include path for stdlibc++ headers not found; pass '-std=libc++'
> on the command line to use the libc++ standard library instead
> [-Wstdlibcxx-not-found]
> In file included from src/_rdparm.cpp:17:
> /opt/amber18/AmberTools/src/parmed/src/readparm.h:5:10: fatal error:
> 'locale' file not found
> #include <locale>
> ^~~~~~~~
> 1 warning and 1 error generated.
> error: command 'clang' failed with exit status 1
> make[2]: *** [parmed] Error 1
> make[1]: *** [parallel] Error 2
> make: *** [install] Error 2
>
> Best Regards,
>
> Andrew
>
> On Sun, Oct 7, 2018 at 8:02 PM Andrew Schaub <aschaub.uci.edu<mailto:
> aschaub.uci.edu>> wrote:
>
> Good Evening,
>
> I just thought I would mention this on the listserv in case anyone else
> has similar issues. When trying to install on Mojave, I was getting the
> following error message:
>
> ld: library not found for -lmc
>
> It turns out it the compiler was looking for the /usr/include folder
> which no longer exists with the most recent version of XCode Developer
> Tools and Mojave. In order to get the installation to work, just install
> the include folder from the following link instructions:
>
> https://developer.apple.com/documentation/xcode_release_notes/xcode_10_release_notes
>
> There is a .pkg file (
>
> https://developer.apple.com/documentation/xcode_release_notes/xcode_10_release_notes
> )
> which will install the include folder into the /usr/ folder like previous
> versions of MacOS and XCode.
>
> Afterwards I was able to get AMBER to work, using gcc5
> ./configure -macAccelerate gnu
>
> Best Regards,
>
> Andrew
>
>
>
> --
> Andrew Schaub
> 949-877-9380<tel:949-877-9380> (cell)
> aschaub.uci.edu<mailto:aschaub.uci.edu> <
> http://www.linkedin.com/pub/andrew-schaub/9a/907/382/>
> _______________________________________________
> AMBER mailing list
> AMBER.ambermd.org<mailto:AMBER.ambermd.org>
> http://lists.ambermd.org/mailman/listinfo/amber
>
> _______________________________________________
> AMBER mailing list
> AMBER.ambermd.org
> http://lists.ambermd.org/mailman/listinfo/amber
>


-- 
Andrew Schaub
949-877-9380 (cell)
aschaub.uci.edu  <http://www.linkedin.com/pub/andrew-schaub/9a/907/382/>
_______________________________________________
AMBER mailing list
AMBER.ambermd.org
http://lists.ambermd.org/mailman/listinfo/amber
Received on Mon Oct 08 2018 - 10:00:02 PDT
Custom Search