Results 1 to 10 of 10

Your favorite Apple, iPhone, iPad, iOS, Jailbreak, and Cydia site.


Thread: error with make

  1. #1
    Default error with make
    im just starting out with obj c and mac programing and need alittle help

    i have heavenly and the toolchain installed and i downloaded the helloworld_src when i run make i get this error

    $make
    /usr/local/arm-apple-darwin/bin/gcc -v -c hello.m -o hello.o
    /usr/local/arm-apple-darwin/bin/gcc: /usr/local/arm-apple-darwin/bin/gcc: cannot execute binary file
    make: *** [hello.o] Error 126

    anyone know why im geting this?

    here is more info

    $ gcc -v
    Using built-in specs.
    Target: powerpc-apple-darwin8
    Configured with: /private/var/tmp/gcc/gcc-5367.obj~1/src/configure --disable-checking -enable-werror --prefix=/usr --mandir=/share/man --enable-languages=c,objc,c++,obj-c++ --program-transform-name=/^[cg][^.-]*$/s/$/-4.0/ --with-gxx-include-dir=/include/c++/4.0.0 --with-slibdir=/usr/lib --build=powerpc-apple-darwin8 --host=powerpc-apple-darwin8 --target=powerpc-apple-darwin8
    Thread model: posix
    gcc version 4.0.1 (Apple Computer, Inc. build 5367)


    $ uname -a
    Darwin pear-pcs-power-mac-g3-pci-graphics.local 8.0.0 Darwin Kernel Version 8.0.0: Sat Mar 26 14:15:22 PST 2005; rootnu-792.obj~1/RELEASE_PPC Power Macintosh powerpc

    Thank you

  2. #2
    Official MMI Troll with an Attitude Digitol's Avatar
    Join Date
    May 2007
    Posts
    131
    Thanks
    4
    Thanked 21 Times in 14 Posts

    Try this: rm -f *.o Hello or rm -f *.o then build using make. Also

    Make sure you have the .030 compiler. If still no-go, make sure you have the .30 toolchain

    -Digitol-
    Last edited by Digitol; 09-21-2007 at 08:32 PM.

  3. #3
    makefile

    CC=/usr/local/arm-apple-darwin/bin/gcc -v
    CXX=/usr/local/arm-apple-darwin/bin/g++

    LD=$(CC)
    LDFLAGS = -Wl,-syslibroot,$(HEAVENLY) \
    -framework CoreFoundation \
    -framework Foundation \
    -framework UIKit \
    -framework LayerKit \
    -framework CoreGraphics \
    -framework GraphicsServices \
    -framework CoreSurface \
    -lobjc -larmfp

    all: Hello

    Hello: hello.o HelloApplication.o
    $(LD) $(LDFLAGS) -o $@ $^

    %.o: %.m
    $(CC) -c $(CFLAGS) $(CPPFLAGS) $< -o $@

    clean:
    rm -f *.o Hello


    it already has the rm -f *.o Hello in there and i used the iPhoneToolchainv05.dmg to install it is that .030 compiler and .30 toolchain?

    Thank you

  4. #4
    Official MMI Troll with an Attitude Digitol's Avatar
    Join Date
    May 2007
    Posts
    131
    Thanks
    4
    Thanked 21 Times in 14 Posts

    the .dmg toolchain is no good. must compile it on your own for ppc compat.

  5. #5
    Simple things....did you modify the hello world source files? If you did check that you have matching {}. But I have read things that need to be done to get the compiler to work on a PPC. I am using intel Mac without issues.

  6. #6
    Quote Originally Posted by Digitol View Post
    the .dmg toolchain is no good. must compile it on your own for ppc compat.
    Yup.. what ^^^^ he said. All the precompiled 'stuff' is for Intel Mac's. You've got two choices;

    1. Buy an Intel Mac
    2. Get your hands very dirty and compile all your stuff yourself

    Of course there might be option 3, if you can find another PPC iPhone developer
    White 3G

  7. #7
    when I try to compile LLVM I get this error

    $ make ENABLE_OPTIMIZED=1
    llvm[1]: Compiling Alarm.cpp for Release build
    llvm[1]: Compiling Disassembler.cpp for Release build
    llvm[1]: Compiling DynamicLibrary.cpp for Release build
    llvm[1]: Compiling IncludeFile.cpp for Release build
    llvm[1]: Compiling MappedFile.cpp for Release build
    llvm[1]: Compiling Memory.cpp for Release build
    llvm[1]: Compiling Mutex.cpp for Release build
    llvm[1]: Compiling Path.cpp for Release build
    llvm[1]: Compiling Process.cpp for Release build
    llvm[1]: Compiling Program.cpp for Release build
    llvm[1]: Compiling Signals.cpp for Release build
    In file included from /Users/Pear_PC/llvm-svn/include/llvm/ADT/STLExtras.h:23,
    from Unix/Signals.inc:16,
    from Signals.cpp:30:
    /Users/Pear_PC/llvm-svn/include/llvm/ADT/iterator:55:4: error: #error "Need to have standard iterator to define bidirectional iterator!"
    /Users/Pear_PC/llvm-svn/include/llvm/ADT/iterator:71:4: error: #error "Need to have standard iterator to define forward iterator!"
    make[1]: *** [/Users/Pear_PC/llvm-svn/lib/System/Release/Signals.o] Error 1
    make: *** [all] Error 1


    and when I google this error all I get is the file that the error is in not whats causeing it to error.

    This is the file on llvm.org
    http://llvm.org/svn/llvm-project/llv...DT/iterator.in

    Im a perl programer so im new to this compileing thing

    any help
    Thank you much

  8. #8
    Official MMI Troll with an Attitude Digitol's Avatar
    Join Date
    May 2007
    Posts
    131
    Thanks
    4
    Thanked 21 Times in 14 Posts

    Make sure you have the latest devtools(v.2.4.x?) and not the beta. 2.5.x? I think. Also can try macports to install llvm. sudo port install llvm. If by some fantastic chance my work schedule loosens up I can provide a PPC toolchain installer .pkg.
    -Digitol-

  9. #9
    im installing macports right now hope it works and installer would be great. Im a perl programer so im not used to this compileing deal

    Thank for your help

  10. #10
    ok i installed xcode 2.4.1 and installed llvm with macports and i still get the iterator error with macports there any other options?

    Thank you

Posting Permissions
  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •