arm-apple-darwin-ld: Undefined Symbols: UITableView

Discussion in 'iOS Development' started by pankaj33t, Feb 21, 2009.

  1. pankaj33t

    pankaj33t New Member

    Joined:
    Feb 20, 2009
    Messages:
    7
    Likes Received:
    0
    I am new to the iPhone/ipod programming.
    was able to successfully setup the open toolchain & compile the Hello-World example - was too excited to see this working on my iPod touch.

    Issue faced now:
    Next when I tried to write real application using View Controller / Navigation Bar it gave me the following errors.

    /usr/local/bin/arm-apple-darwin-ld: Undefined symbols:
    .objc_class_name_UIColor
    .objc_class_name_UITableView
    .objc_class_name_UITableViewController
    _objc_setProperty
    .objc_class_name_UIBarButtonItem
    .objc_class_name_UIFont
    .objc_class_name_UINavigationController
    .objc_class_name_UIScreen
    .objc_class_name_UIButton
    collect2: ld returned 1 exit status
    make: *** [mToken] Error 1

    Am I missing some framework or library. Please Help.

    using iPod touch firmware 1.1.4

    Thanks.
  2. Steaps

    Steaps New Member

    Joined:
    Oct 24, 2007
    Messages:
    5,074
    Likes Received:
    41
    Device:
    iPod touch
    Have you included UIKit?
    Also, i don't know anything really about the toolchain, but i'm pretty sure you need it.
  3. pankaj33t

    pankaj33t New Member

    Joined:
    Feb 20, 2009
    Messages:
    7
    Likes Received:
    0
    yes, UIKit is included.
    Here is the makefile I am using:

    CC=arm-apple-darwin-g++
    LD=$(CC)
    LDFLAGS=-lobjc -lxml2 -framework CoreFoundation -framework Foundation -framework UIKit -framework LayerKit -framework CoreGraphics -framework GraphicsServices -framework CoreSurface -bind_at_load -multiply_defined suppress

    MTOKENINC = -I /usr/local/arm-apple-darwin/include/libxml2


    all: mToken

    mToken: main.o xmlmanager.o SHA1.o HMAC_SHA1.o otlib.o DisplayViewController.o DataEntryViewController.o myAppDelegate.o RootViewController.o
    $(LD) $(LDFLAGS) -v -o $@ $^

    %.o: %.m
    $(CC) -c $(CFLAGS) $(CPPFLAGS) $(MTOKENINC) -DMAC_OS_X_VERSION_MAX_ALLOWED=1050 $< -o $@

    %.o: %.mm
    $(CC) -c $(CFLAGS) $(CPPFLAGS) $(MTOKENINC) -DMAC_OS_X_VERSION_MAX_ALLOWED=1050 $< -o $@

    clean:
    rm -f *.o myApp
  4. gojohnnyboi

    gojohnnyboi Well-Known Member

    Joined:
    Jan 25, 2008
    Messages:
    3,339
    Likes Received:
    55
    haha! no wonder. you're compiler is built for the 1.1.x firmwares. you probably used the cygwin binary installer or something yes?

    no, you'll have to rebuild the toolchain configured for arm-apple-darwin9

    you have arm-apple-darwin.

    http://saurik.com/id/4

    you have the 1.1.x frameworks too, which don't have those items in them.





    EDIT: oh, you're compiling for 1.1.4 purposely. well, the classes you're trying to use are still only in the 2.0 frameworks, so you can't use them. sorry
  5. lauNchD

    lauNchD Well-Known Member

    Joined:
    Jan 27, 2008
    Messages:
    1,844
    Likes Received:
    261
    Device:
    iPhone 5 (Black)
    I would STRONGLY suggest you update to one of the newer firmwares (like 2.2 or 2.2.1). UIColor does not exist in 1.1.4, you have to use GSColorRef, which is much more complicated. UITableView is called UITable and does not have the reuse function, navigation controllers don't exist, no Interface builder (maybe you're on Windows anyway), so you have to do all that "manually!"
    Why would you want to develop for 1.1.4 anyway? It's almost a year old now!
  6. pankaj33t

    pankaj33t New Member

    Joined:
    Feb 20, 2009
    Messages:
    7
    Likes Received:
    0
    Thanks Guys, let me do this. Is there a installer / package / script which could setup toolchain for firmware 2.0 + on Linux / Windows.
  7. omokas

    omokas Member

    Joined:
    Feb 5, 2009
    Messages:
    712
    Likes Received:
    5
    Device:
    iPhone 4 (White)
    Sorry man i don't use mac os x to compile apps , i only use windows ...
  8. gojohnnyboi

    gojohnnyboi Well-Known Member

    Joined:
    Jan 25, 2008
    Messages:
    3,339
    Likes Received:
    55
    http://saurik.com/id/4

    that will work for any os, but it's best on linux or os x
  9. Chicken

    Chicken Retired Moderator

    Joined:
    Feb 17, 2008
    Messages:
    2,494
    Likes Received:
    7
    Device:
    iPhone 5S
    that is the way to go http://www.saurik.com/id/4 unfortunately their is no binary toolchain installer yet Saurik is working on it but I think he is having trouble with the NDA
  10. gojohnnyboi

    gojohnnyboi Well-Known Member

    Joined:
    Jan 25, 2008
    Messages:
    3,339
    Likes Received:
    55
    no. installers are out. the toolchain installer isn't illegal to my understanding, it's the headers.

Share This Page