#29768closeddefect (duplicate)
Reported by: | Owned by: | vincent@… | |
---|---|---|---|
Priority: | Normal | Milestone: | |
Component: | ports | Version: | 1.9.2 |
Keywords: | Cc: | ||
Port: | playerstage-stage |
Undefined symbols for architecture i386: with 200+ apple mach-o linker (Id) errors I have just purchased Unity iOS 3.4.2f2 and am running it on an Apple Macbook running 10.6.8 Snow Leopard. I am using XCode 4.2 on the same computer. Sep 08, 2009 Question: Q: 'Undefined symbols for architecture' when building Universal Binaries The build I'm doing works fine when specifying either i386 or x8664 or ppc.by itself., however whenever I try to combine the archs to make a UB, I get problems building libraries. Dismiss Join GitHub today. GitHub is home to over 50 million developers working together to host and review code, manage projects, and build software together. https://hotnew292.weebly.com/informant-5-for-macos.html. Undefined symbols for architecture i386: 'TIME', referenced from: +UIColorRandom randomColor in UIColor-Random.o ld: symbol(s) not found for architecture i386 collect2: ld returned 1 exit status From what I have learned from googling, I think it may have something to do with my.pch file which is as follows:.
Undefined Symbols For Architecture I386 Macos X
Description
Attachments (3)
- main.log (98.4 KB) - added by basbaum@…9 years ago.
- cleaned log
- playerstage-cmake.diff (1.0 KB) - added by ryandesign (Ryan Schmidt)9 years ago.
- proposed patch
- main2.log (162.4 KB) - added by basbaum@…9 years ago.
- after cmake being reinstall
Download all attachments as: .zip
Change History (14)
comment:1follow-up: 2 Changed 9 years ago by ryandesign (Ryan Schmidt)
Cc: | ryandesign@… added |
---|---|
Keywords: | PlayerStageFails removed |
Owner: | changed from macports-tickets@… to vincent@… |
Port: | playerstage-stage added |
Summary: | Player/Stage fails to build 'undefined symbols for architecture i386' → playerstage-stage: Undefined symbols for architecture i386 |
comment:2 in reply to: 1 ; follow-up: 3 Changed 9 years ago by ryandesign (Ryan Schmidt)
comment:3 in reply to: 2 ; follow-up: 5 Changed 9 years ago by basbaum@…
comment:4 Changed 9 years ago by basbaum@…
comment:5 in reply to: 3 ; follow-up: 6 Changed 9 years ago by ryandesign (Ryan Schmidt)
Changed 9 years ago by basbaum@…
Changed 9 years ago by ryandesign (Ryan Schmidt)
comment:6 in reply to: 5 ; follow-up: 10 Changed 9 years ago by ryandesign (Ryan Schmidt)
comment:7 Changed 9 years ago by ryandesign (Ryan Schmidt)
comment:8 Changed 9 years ago by basbaum@…
Changed 9 years ago by basbaum@…
comment:9 in reply to: description Changed 9 years ago by basbaum@…
comment:10 in reply to: 6 Changed 9 years ago by ryandesign (Ryan Schmidt)
comment:11 Changed 9 years ago by jmroot (Joshua Root)
Note: See TracTickets for help on using tickets.
I teach a computer architecture course. I am trying to provide working Intel examples in both Mac OS and Microsoft Visual Studio environments. I am using Xcode 7.2, build 7C68. I am receiving the following message in the link step:
Undefined symbols for architecture
I have tried varying the build architecture between x86_64 and i386, as well as the default, with no effect. The main program and assembler function are trivial - I just need a working base. Here is the main program:
#include <iostream>
int AsmSub(int);
int main(int argc, const char * argv[]) {
![Architecture Architecture](/uploads/1/3/3/9/133911580/213844389.png)
int someVariable ; /
someVariable = -1;
std::cout << 'Calling AsmSubn';
someVariable = AsmSub(someVariable);
Undefined Symbols For Architecture I386 Macos Pdf
std::cout << 'Back From AsmSub, value:' << someVariable << 'n';
return 0;
}
Here is the assembler function being called, which just returns (I am assuming that EAX will contain both the single parameter and the result, but that is unrelated to this problem):
.global AsmSub
Quicktime player for mac osx yosemite. .text
.align 16
AsmSub:
ret
.data
.end
Here are the link step error messages:
Undefined symbols for architecture x86_64:
'AsmSub(int)', referenced from:
_main in main.o
ld: symbol(s) not found for architecture x86_64
clang: error: linker command failed with exit code 1 (use -v to see invocation)
I am certain that this is probably a trivial oversight on my part, but I have not found anything like a useful answer with several searches. Any help will be truly appreciated. I have already used Google and Stack Overflow - hoping someone can run this on their own machine and see if it fails for them as well.
Hank Murphy