Become a MacRumors Supporter for $50/year with no ads, ability to filter front page stories, and private forums.

19821125

macrumors newbie
Original poster
Aug 10, 2010
2
0
help!!iOS 4.0,makefile error.

Undefined symbols:
".objc_class_name_NSBundle", referenced from:
literal-pointer@__OBJC@__cls_refs@NSBundle in ccv39OXl.o
".objc_class_name_NSAutoreleasePool", referenced from:
literal-pointer@__OBJC@__cls_refs@NSAutoreleasePool in ccv39OXl.o
".objc_class_name_NSFileManager", referenced from:
literal-pointer@__OBJC@__cls_refs@NSFileManager in ccv39OXl.o
ld: symbol(s) not found
collect2: ld returned 1 exit status
make: *** [MobileLoader.dylib] Error 1
 

19821125

macrumors newbie
Original poster
Aug 10, 2010
2
0
I don't see a Makefile. Or even an Makefile error. I see an error in linking. What is your Base SDK set to?

makefile


PLAT = Simulator
Compiler = gcc-4.2
VERSION = 4.0
CC = /Developer/Platforms/iPhone$(PLAT).platform/Developer/usr/bin/$(Compiler)
Sysroot = /Developer/Platforms/iPhone$(PLAT).platform/Developer/SDKs/iPhone$(PLAT)$(VERSION).sdk

CFLAGS = -isysroot $(Sysroot)
CFLAGS += -x objective-c -arch i386 -fmessage-length=0 -pipe -std=c99 -Wno-trigraphs -fpascal-strings -fasm-blocks \
-O0 -Wreturn-type -Wunused-variable -D__IPHONE_OS_VERSION_MIN_REQUIRED=20000 \
-fvisibility=hidden -gdwarf-2

LDFLAGS = -dynamiclib \
-F"$(Sysroot)/System/Library/Frameworks" \
-F"$(Sysroot)/System/Library/PrivateFrameworks" \
-framework CoreFoundation \
-framework CoreGraphics \
-framework Foundation

Target = MobileLoader.dylib

srcs = MobileLoader.mm

all: $(Target)

$(Target): $(srcs)
$(CC) -o $(Target) $(CFLAGS) $(LDFLAGS) $(srcs)


clean:
rm -f $(Target) inst

.PHONY: all
 

robbieduncan

Moderator emeritus
Jul 24, 2002
25,611
893
Harrogate
What, exactly, are you doing? Why do you even have a Makefile? What is MobileLoader.dylib

To me this all looks like jailbrake stuff as when I do my development in XCode I never need to write Makefiles...
 
Register on MacRumors! This sidebar will go away, and you'll see fewer ads.