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

Duplicate Symbols when including red libMumbleKit.a #39

Open
fbartolom opened this issue May 20, 2015 · 1 comment
Open

Duplicate Symbols when including red libMumbleKit.a #39

fbartolom opened this issue May 20, 2015 · 1 comment

Comments

@fbartolom
Copy link

I am still trying to include MumbleKit into a new project. Now I managed to compile the whole without errors, but, at the end of the process, all .a libraries, both for MumbleKit and the 3dparty dependencies remain red as if not existing. Notwithstanding, when I include this 'red' library into the binaries to link, I gat a host of duplicate symbols on the library proper of the kind:

duplicate symbol _CRYPTO_get_new_lockid in:
/Users/fbartolom/Library/Developer/Xcode/DerivedData/inArrivoHD-ebjdiuuwdpdvchgmpsyqkpvvvyhw/Build/Products/Debug-iphonesimulator/libMumbleKit.a(cryptlib.o)
/Users/fbartolom/openssl-ios/lib/libcrypto_iOS.a(cryptlib.o)
duplicate symbol _CRYPTO_num_locks in:
/Users/fbartolom/Library/Developer/Xcode/DerivedData/inArrivoHD-ebjdiuuwdpdvchgmpsyqkpvvvyhw/Build/Products/Debug-iphonesimulator/libMumbleKit.a(cryptlib.o)
/Users/fbartolom/openssl-ios/lib/libcrypto_iOS.a(cryptlib.o)
duplicate symbol _CRYPTO_get_new_dynlockid in:
/Users/fbartolom/Library/Developer/Xcode/DerivedData/inArrivoHD-ebjdiuuwdpdvchgmpsyqkpvvvyhw/Build/Products/Debug-iphonesimulator/libMumbleKit.a(cryptlib.o)
/Users/fbartolom/openssl-ios/lib/libcrypto_iOS.a(cryptlib.o)
duplicate symbol _CRYPTO_lock in:
/Users/fbartolom/Library/Developer/Xcode/DerivedData/inArrivoHD-ebjdiuuwdpdvchgmpsyqkpvvvyhw/Build/Products/Debug-iphonesimulator/libMumbleKit.a(cryptlib.o)
/Users/fbartolom/openssl-ios/lib/libcrypto_iOS.a(cryptlib.o)
duplicate symbol _CRYPTO_destroy_dynlockid in:
/Users/fbartolom/Library/Developer/Xcode/DerivedData/inArrivoHD-ebjdiuuwdpdvchgmpsyqkpvvvyhw/Build/Products/Debug-iphonesimulator/libMumbleKit.a(cryptlib.o)

What should I do to come out of this problem?

@mkrautz
Copy link
Contributor

mkrautz commented May 20, 2015

Same problem I commented on previously:

You link against OpenSSL (libcrypto_iOS.a, perhaps also libssl_iOS.a), while MumbleKit also does.

If these are the same version, you should be able to keep using the headers you have used previously, and simply use the MumbleKit version. Note however that the OpenSSL shipped with MumbleKit is quite old by now, so that's probably not a good idea.

One way to solve this problem would be to remove the OpenSSL static library (.a) from the libMumbleKit target. That way, a libMumbleKit.a should still be produced, but will not include any OpenSSL symbols. The OpenSSL symbols would then be provided by your OpenSSL libraries, instead.

Note that this will only work if the OpenSSL versions match, or are of the same minor series. Since MumbleKit expects OpenSSL 1.0.0, this requires that your OpenSSL is also 1.0.0.

Hope it helps.

P.S. the library is red because it has not been built yet. once built, it should display normally.

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