Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

clang error #12

Open
BrianaGross opened this issue Mar 26, 2020 · 7 comments
Open

clang error #12

BrianaGross opened this issue Mar 26, 2020 · 7 comments

Comments

@BrianaGross
Copy link

Hi all,

Has anyone successfully installed this on Mac OS Mojave? After running the make command, I received the following error: clang: error: unsupported option '-fopenmp'. I see that this is a known issue for Mojave, but I'm afraid I'm unable to translate the suggested solutions to this program. I wondered if anyone had a record of how they overcame this and used graphmap2 recently.

Thank you,
Briana

@jmaricb
Copy link
Member

jmaricb commented Mar 26, 2020

Hi @BrianaGross ,

unfortunately Graphmap2 will not compile on Mac OS X Clang complier.

There is an option to compile it on mac by downloading GNU C++ compiler with Homebrew.

You can download Homebrew here https://brew.sh/

Then run the command 'brew install gcc' which will install C++ compiler alongside Clang compiler.
The compiler will be installed in directory like this: /usr/local/bin/g++-9
You can type 'which g++-9' to find the installation directory.

Finally, replace the 19. line in the Makefile file 'GCC ?= g++' with '/usr/local/bin/g++-9' (or wherever your compiler was installed).

The program should compile now.
Unfortunately, I don't know better way to build Graphmap2 on Mac.

Let me know if you can't reproduce this installation.

@BrianaGross
Copy link
Author

Thanks so much for your quick response! Much appreciated.

I followed your helpful instructions (including checking the location of my gcc install), and when I ran make I got the error Makefile:19: *** missing separator. Stop.

Should there be anything on line 19 other than /usr/local/bin/g++-9 followed by a hard return?

Thank you!

@jmaricb
Copy link
Member

jmaricb commented Mar 26, 2020

I am sorry, I made a typo. It should be replaced with

GCC ?= /usr/local/bin/g++-9' (or whatever the location of the installation is)

@BrianaGross
Copy link
Author

Thanks! I corrected the line and the install seemed to proceed, but eventually ended with the error:

ld: warning: direct access in function 'operator new[](unsigned long, std::nothrow_t const&) [clone .cold]' from file '/usr/local/Cellar/gcc/9.3.0/lib/gcc/9/gcc/x86_64-apple-darwin18/9.3.0/../../../libstdc++.a(new_opvnt.o)' to global weak symbol 'operator new[](unsigned long, std::nothrow_t const&)' from file '/usr/local/Cellar/gcc/9.3.0/lib/gcc/9/gcc/x86_64-apple-darwin18/9.3.0/../../../libstdc++.a(new_opvnt.o)' means the weak symbol cannot be overridden at runtime. This was likely caused by different translation units being compiled with different visibility settings.

I haven't really been able to figure out what this one means... I have a feeling I am getting into some things that are maybe just inherent to my OS now, so I don't know if you can answer this question. Thanks for your help so far!

@jmaricb
Copy link
Member

jmaricb commented Mar 26, 2020

Have you followed these exact steps:

git clone https://github.com/lbcb-sci/graphmap2
cd graphmap2
make modules
make

Did you run make modules before running make ?

@jmaricb
Copy link
Member

jmaricb commented Mar 26, 2020

If you are I can try to take a look because I don't know right now. I am also compiling on Mac and it is successful for me by following the steps I have described. If I find something I will let you know.

@BrianaGross
Copy link
Author

Yes, I followed all those steps - I even re-downloaded and tried again. It must be something specific to my set-up. I will try to figure it out. It was very nice of you to show me the C++ compiler work-around! Thanks so much.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants