Questions tagged [duplicate-symbol]
99 questions
1
vote
3 answers
Why do C++ member functions defined in a class not produce duplicate symbols, whereas they do in C?
C Example
bb.c:
#include "bb.h"
#include
void bb() {
printf("aa()...\n");
aa();
}
main.c:
#include "aa.h"
#include "bb.h"
int main(int argc, const char** argv) {
aa();
bb();
return 0;
}
aa.h:
#ifndef aa_h
#define…

magnus
- 4,031
- 7
- 26
- 48
1
vote
1 answer
About linker command failed with exit code 1
I defined namespace "MAPDATA" in a header file(MapData.h) that I have created,and I defined a variable in
"MAPDATA".
MapData.h
namespace MAPDATA{
cocos2d::CCSize MapSizeData;
cocos2d::CCSize TileSizeData;
int MaxTileXData;
int…

user3321541
- 221
- 1
- 16
1
vote
1 answer
the issue with exit code 1 (use -v to see invocation)
I'm having a problem about xcode. Please help me check this issue
This is my log from xcode
Ld /Users/admin/Library/Developer/Xcode/DerivedData/Management-dbumnvnvxcjatwgwzoxobimmdmvo/Build/Products/Debug-iphonesimulator/Management.app/Management…

iOS dev
- 35
- 1
- 6
1
vote
0 answers
Duplicate symbol in admob static library
In my application i am using libGoogleAdMobAds.a and libGDataTouchStaticLib.a for ads and video sharing on YouTube but it shows the duplicate symbols for architecture i386 for libGDataTouchStaticLib.a(SBJSON.o)
How can i avoid this error in my app?

BADRI
- 643
- 8
- 26
1
vote
1 answer
XCode: Duplicate Symbol
I have a C function heightParameter that is a simple tool that I use in a couple of my UIViewControllers. I am declaring this only in my main implementation of each UIViewController subclass (in the .m) above my other functions, so that I didn't…

RileyE
- 10,874
- 13
- 63
- 106
0
votes
1 answer
I am expecting to get duplicate symbol linker error but I don't get it, why?
As far as I know if I define a function in a header file and include that header file in multiple source files(translation units), and link them together I should get duplicate symbol linker error. However I don't get that error having the following…

Erik Nouroyan
- 35
- 6
0
votes
1 answer
iOS : duplicate symbols for architecture arm64 after pod install
I am getting error when added a new pod. My initial pod file was
#platform :ios, '9.0'
target 'xxxxxx' do
# Comment the next line if you don't want to use dynamic frameworks
use_frameworks!
# Pods for TPV Plus
pod 'IQKeyboardManagerSwift'
…

RP89
- 101
- 3
- 13
0
votes
0 answers
Symbols already defined with C++ templates used by static and shared libraries
I have the following problem in my project that contains several modules (I am sorry but I could not find a simpler example) :
Module1 defines a full template class ILocatable
Module2 defines a class Component
Module3 defines a class…

ConanLord
- 73
- 5
0
votes
0 answers
Where to start troubleshooting with "duplicate symbol"?
I'm learning C++ on Mac and trying to follow along with the SFML Game Development by Example book.
Any obvious places to start looking for problems when I get:
duplicate symbol __Z2dpi in:
…

johnnywz00
- 1
- 2
0
votes
2 answers
Duplicate Symbols Error - Am I doing my includes right?
I am working on a project with several modules and I'm getting a lot of duplicate symbols errors. I've tried to create a stripped-down version of my project to diagnose the error.
I have the code and dependency structure below. Every .hpp and .tpp…

Paradox
- 1,935
- 1
- 18
- 31
0
votes
2 answers
Duplicate symbols, GTMOAuth2 and Facebook SDK for IOS both using SBJSON
I have an app in which I have implemented facebook login. I copied the sources from the facebook sdk directly into my project. Now I need to add google login. This time I have added GTMOAuth2 as a static library. (I also have the source for this too…

gyozo kudor
- 6,284
- 10
- 53
- 80
0
votes
1 answer
Build Error: ld: Duplicate Symbol _canVirate
Below is my build log. I've tried all the usual error-fixing solutions: Deleting build folder, cleaning, restarting Xcode, etc.
Ld
build/Debug-iphonesimulator/SquirrelGame.app/SquirrelGame
normal i386 cd
/Users/Student/Desktop/SquirrelGame
…
user764362
0
votes
1 answer
Including header library in a new project shows duplicate 'constexpr' error
I have two separate projects. The first project uses the range-v3 header only library and I want to use the range library in my new project too, but including the library shows the duplicate constexpr error. I don't have any duplicate error in my…

M.Mac
- 699
- 3
- 14
0
votes
1 answer
ionic | duplicate symbols error when having cordova-plugin-firebase and cordova-plugin-firebase-analytics installed
I have cordova-plugin-firebase(1.1.3) and cordova-plugin-firebase-analytics(1.0.0) installed in my ionic project. But when I build, I get duplicate symbols error in Xcode like below:
ld:110 duplicate symbols for archetecture arm64
clang: error:…

dan.oy
- 41
- 1
- 4
0
votes
1 answer
UITesting with Multiple XCTestCase Class
I am writing UITest cases for my Project. So I want to have multiple files either subclassed to XCTestCase or subclassed to my Other Test Classes. Whenever I create a such File, I am getting the following error.
duplicate symbol…

Rahul Singh
- 1,219
- 3
- 13
- 36