Thursday, January 3, 2008

iPhone ToolChain build in EEE pc

My new EEE PC goes to technical support today due to internet sharing connection failed problem.

Today I download the iPhoneToolChain binary (intel) and install it in my ppc mac
(beware, it will overwrite your linker /usr/bin/ld)
and I have to reinstall the xcode in order to solve the problem as my ppc cannot run intel binary obviously.

the MakeFile should be changed to
CC=/usr/local/arm-apple-darwin/bin/gcc
CXX=/usr/local/arm-apple-darwin/bin/g++
CFLAGS=-fsigned-char
LDFLAGS=-Wl,-syslibroot,/usr/local/arm-apple-darwin/heavenly
-lobjc -ObjC
-framework CoreFoundation
-framework Foundation
-framework UIKit
-framework LayerKit
-framework CoreGraphics
-framework GraphicsServices
-framework Celestial
-framework MusicLibrary


This version of ToolChain seems to have a more complete header files than self build one

My objective is to put the binary file to my new EEE PC Linux for later iPhone development work.

If you need the iphone header file for 1.1.2, get it here
http://ericasadun.com/ftp/Misc/

For example, I modified the Makefile for iCountDown as below

APP=iCountDown

CC=arm-apple-darwin-gcc
LD=$(CC)

CFLAGS=-I/usr/local/arm-apple-darwin/include/ -fsigned-char

LDFLAGS=-lobjc \
-framework CoreFoundation \
-framework Foundation \
-framework UIKit \
-framework LayerKit \
-framework CoreGraphics \
-framework WebCore \
-framework GraphicsServices

all: ${APP}.app/${APP}

${APP}.app/${APP}: main.o iCountDown.o CDList.o SetupView.o CustomTable.o CustomTableCell.o ToggleDisplayView.o
$(LD) $(LDFLAGS) -v -o $@ $^

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

nice:
rm -f *.o

clean:
rm -f *.o ${APP}.app/${APP}


No comments: