我需要在两个文件之间共享一个const值;所以我决定使用const变量,而不是保留一个神奇的数字。所以我在我的appDelegate.m中创建了一个global变量constintviewTag=100;然后以externconstintviewTag;访问它,但我收到以下链接器错误:Undefinedsymbolsforarchitecturei386:"viewTag",referencedfrom:-[xxxViewControllerlaunchxxx]inlibxxx_iPad.a(xxxViewController.o)ld:symbol(s)notfoundforarch