rawko3 / iphone-dev

Automatically exported from code.google.com/p/iphone-dev
0 stars 0 forks source link

Toolchain will not compile code after what seems to be an successful toolchain compilation #139

Open GoogleCodeExporter opened 8 years ago

GoogleCodeExporter commented 8 years ago
What steps will reproduce the problem?
1. Sucessfully compiled the toolchain on Ubuntu 7.10
2. Ran makefile:

CC = /usr/local/bin/arm-apple-darwin-gcc
LD = $(CC)
LDFLAGS =   -lobjc \
        -framework CoreFoundation \
        -framework Foundation \
        -framework UIKit \
        -framework CoreGraphics \
        -framework CoreTelephony \
        -framework CoreAudio\
        -framework Celestial
CFLAGS=

vrecorder: main.o 
    $(LD) $(LDFLAGS) main.o -o vrecorder

main.o: main.m main.h
    $(CC) -c main.m

3.

What is the expected output? What do you see instead?

It should have been a compiled w/o any warnings or errors. On my other
system also running Ubuntu 7.10 and the toolchain (compiled a month ago)
the source code for my app compiled without any errors. On the box I
installed the toolchain on today I got:

make
/usr/local/bin/arm-apple-darwin-gcc -c main.m
In file included from
/usr/local/lib/gcc/arm-apple-darwin/4.0.1/../../../../arm-apple-darwin/include/C
arbonCore/ConditionalMacros.h:42,
                 from
/usr/local/lib/gcc/arm-apple-darwin/4.0.1/../../../../arm-apple-darwin/include/C
arbonCore/MacTypes.h:20,
                 from
/usr/local/lib/gcc/arm-apple-darwin/4.0.1/../../../../arm-apple-darwin/include/C
oreFoundation/CFBase.h:38,
                 from
/usr/local/lib/gcc/arm-apple-darwin/4.0.1/../../../../arm-apple-darwin/include/C
oreFoundation/CoreFoundation.h:38,
                 from main.h:1,
                 from main.m:1:
/usr/local/lib/gcc/arm-apple-darwin/4.0.1/../../../../arm-apple-darwin/include/T
argetConditionals.h:123:10:
error: #error unrecognized GNU C compiler
In file included from
/usr/local/lib/gcc/arm-apple-darwin/4.0.1/../../../../arm-apple-darwin/include/C
arbonCore/DriverServices.h:32,
                 from
/usr/local/lib/gcc/arm-apple-darwin/4.0.1/../../../../arm-apple-darwin/include/C
arbonCore/CarbonCore.h:125,
                 from
/usr/local/lib/gcc/arm-apple-darwin/4.0.1/../../../../arm-apple-darwin/include/C
oreServices/CoreServices.h:21,
                 from
/usr/local/lib/gcc/arm-apple-darwin/4.0.1/../../../../arm-apple-darwin/include/C
oreGraphics/CGEvent.h:17,
                 from
/usr/local/lib/gcc/arm-apple-darwin/4.0.1/../../../../arm-apple-darwin/include/C
oreGraphics/CoreGraphics.h:24,
                 from
/usr/local/lib/gcc/arm-apple-darwin/4.0.1/../../../../arm-apple-darwin/include/U
IKit/UIKit.h:3,
                 from main.h:2,
                 from main.m:1:
/usr/local/lib/gcc/arm-apple-darwin/4.0.1/../../../../arm-apple-darwin/include/C
arbonCore/MachineExceptions.h:286:
error: syntax error before ‘*’ token
/usr/local/lib/gcc/arm-apple-darwin/4.0.1/../../../../arm-apple-darwin/include/C
arbonCore/MachineExceptions.h:320:
error: syntax error before ‘*’ token
In file included from
/usr/local/lib/gcc/arm-apple-darwin/4.0.1/../../../../arm-apple-darwin/include/C
arbonCore/CarbonCore.h:161,
                 from
/usr/local/lib/gcc/arm-apple-darwin/4.0.1/../../../../arm-apple-darwin/include/C
oreServices/CoreServices.h:21,
                 from
/usr/local/lib/gcc/arm-apple-darwin/4.0.1/../../../../arm-apple-darwin/include/C
oreGraphics/CGEvent.h:17,
                 from
/usr/local/lib/gcc/arm-apple-darwin/4.0.1/../../../../arm-apple-darwin/include/C
oreGraphics/CoreGraphics.h:24,
                 from
/usr/local/lib/gcc/arm-apple-darwin/4.0.1/../../../../arm-apple-darwin/include/U
IKit/UIKit.h:3,
                 from main.h:2,
                 from main.m:1:
/usr/local/lib/gcc/arm-apple-darwin/4.0.1/../../../../arm-apple-darwin/include/C
arbonCore/fp.h:93:2:
error: #error unsupported CPU
In file included from
/usr/local/lib/gcc/arm-apple-darwin/4.0.1/../../../../arm-apple-darwin/include/C
arbonCore/CarbonCore.h:161,
                 from
/usr/local/lib/gcc/arm-apple-darwin/4.0.1/../../../../arm-apple-darwin/include/C
oreServices/CoreServices.h:21,
                 from
/usr/local/lib/gcc/arm-apple-darwin/4.0.1/../../../../arm-apple-darwin/include/C
oreGraphics/CGEvent.h:17,
                 from
/usr/local/lib/gcc/arm-apple-darwin/4.0.1/../../../../arm-apple-darwin/include/C
oreGraphics/CoreGraphics.h:24,
                 from
/usr/local/lib/gcc/arm-apple-darwin/4.0.1/../../../../arm-apple-darwin/include/U
IKit/UIKit.h:3,
                 from main.h:2,
                 from main.m:1:
/usr/local/lib/gcc/arm-apple-darwin/4.0.1/../../../../arm-apple-darwin/include/C
arbonCore/fp.h:471:
error: conflicting types for ‘scalb’
/usr/local/lib/gcc/arm-apple-darwin/4.0.1/../../../../arm-apple-darwin/include/C
arbonCore/fp.h:885:
error: conflicting types for ‘__fpclassifyd’
/usr/local/lib/gcc/arm-apple-darwin/4.0.1/../../../../arm-apple-darwin/include/a
rchitecture/arm/math.h:138:
error: previous declaration of ‘__fpclassifyd’ was here
/usr/local/lib/gcc/arm-apple-darwin/4.0.1/../../../../arm-apple-darwin/include/C
arbonCore/fp.h:896:
error: conflicting types for ‘__fpclassifyf’
/usr/local/lib/gcc/arm-apple-darwin/4.0.1/../../../../arm-apple-darwin/include/a
rchitecture/arm/math.h:137:
error: previous declaration of ‘__fpclassifyf’ was here
/usr/local/lib/gcc/arm-apple-darwin/4.0.1/../../../../arm-apple-darwin/include/C
arbonCore/fp.h:908:
error: conflicting types for ‘__fpclassify’
/usr/local/lib/gcc/arm-apple-darwin/4.0.1/../../../../arm-apple-darwin/include/a
rchitecture/arm/math.h:139:
error: previous declaration of ‘__fpclassify’ was here
/usr/local/lib/gcc/arm-apple-darwin/4.0.1/../../../../arm-apple-darwin/include/C
arbonCore/fp.h:1338:
error: ‘SIGDIGLEN’ undeclared here (not in a function)
In file included from
/usr/local/lib/gcc/arm-apple-darwin/4.0.1/../../../../arm-apple-darwin/include/O
SServices/OSServices.h:45,
                 from
/usr/local/lib/gcc/arm-apple-darwin/4.0.1/../../../../arm-apple-darwin/include/C
oreServices/CoreServices.h:25,
                 from
/usr/local/lib/gcc/arm-apple-darwin/4.0.1/../../../../arm-apple-darwin/include/C
oreGraphics/CGEvent.h:17,
                 from
/usr/local/lib/gcc/arm-apple-darwin/4.0.1/../../../../arm-apple-darwin/include/C
oreGraphics/CoreGraphics.h:24,
                 from
/usr/local/lib/gcc/arm-apple-darwin/4.0.1/../../../../arm-apple-darwin/include/U
IKit/UIKit.h:3,
                 from main.h:2,
                 from main.m:1:
/usr/local/lib/gcc/arm-apple-darwin/4.0.1/../../../../arm-apple-darwin/include/O
SServices/OpenTransport.h:359:
error: syntax error before numeric constant
In file included from
/usr/local/lib/gcc/arm-apple-darwin/4.0.1/../../../../arm-apple-darwin/include/O
SServices/OSServices.h:47,
                 from
/usr/local/lib/gcc/arm-apple-darwin/4.0.1/../../../../arm-apple-darwin/include/C
oreServices/CoreServices.h:25,
                 from
/usr/local/lib/gcc/arm-apple-darwin/4.0.1/../../../../arm-apple-darwin/include/C
oreGraphics/CGEvent.h:17,
                 from
/usr/local/lib/gcc/arm-apple-darwin/4.0.1/../../../../arm-apple-darwin/include/C
oreGraphics/CoreGraphics.h:24,
                 from
/usr/local/lib/gcc/arm-apple-darwin/4.0.1/../../../../arm-apple-darwin/include/U
IKit/UIKit.h:3,
                 from main.h:2,
                 from main.m:1:
/usr/local/lib/gcc/arm-apple-darwin/4.0.1/../../../../arm-apple-darwin/include/O
SServices/OpenTransportProtocol.h:121:
error: conflicting types for ‘uid_t’
/usr/local/lib/gcc/arm-apple-darwin/4.0.1/../../../../arm-apple-darwin/include/s
ys/types.h:167:
error: previous declaration of ‘uid_t’ was here
/usr/local/lib/gcc/arm-apple-darwin/4.0.1/../../../../arm-apple-darwin/include/O
SServices/OpenTransportProtocol.h:122:
error: conflicting types for ‘gid_t’
/usr/local/lib/gcc/arm-apple-darwin/4.0.1/../../../../arm-apple-darwin/include/s
ys/types.h:114:
error: previous declaration of ‘gid_t’ was here
/usr/local/lib/gcc/arm-apple-darwin/4.0.1/../../../../arm-apple-darwin/include/O
SServices/OpenTransportProtocol.h:124:
error: conflicting types for ‘dev_t’
/usr/local/lib/gcc/arm-apple-darwin/4.0.1/../../../../arm-apple-darwin/include/s
ys/types.h:97:
error: previous declaration of ‘dev_t’ was here
make: *** [main.o] Error 1

Original issue reported on code.google.com by dou...@gmail.com on 18 May 2008 at 7:49

GoogleCodeExporter commented 8 years ago
Suggested trying using common easily available source: If I compile using the 
example
 helloworld application from www.idevdocs.com/tutorial.php?t=9 :

make
/usr/local/bin/arm-apple-darwin-gcc -v -c   hello.m -o hello.o
Using built-in specs.
Target: arm-apple-darwin
Configured with: ../../llvm-gcc-4.0-iphone/configure
--enable-llvm=/home/doug/iphone/llvm-svn --enable-languages=c,c++,objc,obj-c++
--target=arm-apple-darwin --enable-sjlj-exceptions --with-heavenly=
--with-as=/usr/local/bin/arm-apple-darwin-as
--with-ld=/usr/local/bin/arm-apple-darwin-ld --enable-wchar_t=no : 
(reconfigured)
../../llvm-gcc-4.0-iphone/configure --enable-llvm=/home/doug/iphone/llvm-svn
--enable-languages=c,c++,objc,obj-c++ --target=arm-apple-darwin
--enable-sjlj-exceptions --with-heavenly=/usr/local/share/iphone-filesystem
--with-as=/usr/local/bin/arm-apple-darwin-as
--with-ld=/usr/local/bin/arm-apple-darwin-ld --enable-wchar_t=no
Thread model: posix
gcc version 4.0.1 (Apple Computer, Inc. build 5449)(LLVM build
2.0-svn-iphone-dev-0.3-svn)
 /usr/local/libexec/gcc/arm-apple-darwin/4.0.1/cc1obj -quiet -v -D__DYNAMIC__ hello.m
-fPIC -mmacosx-version-min=10.4 -mfpu=vfp -mcpu=arm1176jzf-s -quiet -dumpbase 
hello.m
-auxbase-strip hello.o -version -o /tmp/ccfC2kja.s
ignoring nonexistent directory
"/usr/local/lib/gcc/arm-apple-darwin/4.0.1/../../../../arm-apple-darwin/sys-incl
ude"
ignoring nonexistent directory "/System/Library/Frameworks"
ignoring nonexistent directory "/Library/Frameworks"
#include "..." search starts here:
#include <...> search starts here:
 /usr/local/lib/gcc/arm-apple-darwin/4.0.1/include
 /usr/local/lib/gcc/arm-apple-darwin/4.0.1/../../../../arm-apple-darwin/include
End of search list.
GNU Objective-C version 4.0.1 (Apple Computer, Inc. build 5449)(LLVM build
2.0-svn-iphone-dev-0.3-svn) (arm-apple-darwin)
        compiled by GNU C version 4.1.3 20070929 (prerelease) (Ubuntu 4.1.2-16ubuntu2).
GGC heuristics: --param ggc-min-expand=100 --param ggc-min-heapsize=131072
Compiler executable checksum: b228bfc0b1e7e126df7c3b444d63632e
In file included from
/usr/local/lib/gcc/arm-apple-darwin/4.0.1/../../../../arm-apple-darwin/include/C
arbonCore/ConditionalMacros.h:42,
                 from
/usr/local/lib/gcc/arm-apple-darwin/4.0.1/../../../../arm-apple-darwin/include/C
arbonCore/MacTypes.h:20,
                 from
/usr/local/lib/gcc/arm-apple-darwin/4.0.1/../../../../arm-apple-darwin/include/C
oreFoundation/CFBase.h:38,
                 from
/usr/local/lib/gcc/arm-apple-darwin/4.0.1/../../../../arm-apple-darwin/include/C
oreFoundation/CFByteOrder.h:16,
                 from
/usr/local/lib/gcc/arm-apple-darwin/4.0.1/../../../../arm-apple-darwin/include/C
oreGraphics/CGGeometry.h:10,
                 from
/usr/local/lib/gcc/arm-apple-darwin/4.0.1/../../../../arm-apple-darwin/include/C
oreGraphics/CGAffineTransform.h:12,
                 from
/usr/local/lib/gcc/arm-apple-darwin/4.0.1/../../../../arm-apple-darwin/include/C
oreGraphics/CoreGraphics.h:12,
                 from
/usr/local/lib/gcc/arm-apple-darwin/4.0.1/../../../../arm-apple-darwin/include/U
IKit/UIKit.h:3,
                 from hello.m:1:
/usr/local/lib/gcc/arm-apple-darwin/4.0.1/../../../../arm-apple-darwin/include/T
argetConditionals.h:123:10:
error: #error unrecognized GNU C compiler
In file included from
/usr/local/lib/gcc/arm-apple-darwin/4.0.1/../../../../arm-apple-darwin/include/C
arbonCore/DriverServices.h:32,
                 from
/usr/local/lib/gcc/arm-apple-darwin/4.0.1/../../../../arm-apple-darwin/include/C
arbonCore/CarbonCore.h:125,
                 from
/usr/local/lib/gcc/arm-apple-darwin/4.0.1/../../../../arm-apple-darwin/include/C
oreServices/CoreServices.h:21,
                 from
/usr/local/lib/gcc/arm-apple-darwin/4.0.1/../../../../arm-apple-darwin/include/C
oreGraphics/CGEvent.h:17,
                 from
/usr/local/lib/gcc/arm-apple-darwin/4.0.1/../../../../arm-apple-darwin/include/C
oreGraphics/CoreGraphics.h:24,
                 from
/usr/local/lib/gcc/arm-apple-darwin/4.0.1/../../../../arm-apple-darwin/include/U
IKit/UIKit.h:3,
                 from hello.m:1:
/usr/local/lib/gcc/arm-apple-darwin/4.0.1/../../../../arm-apple-darwin/include/C
arbonCore/MachineExceptions.h:286:
error: syntax error before ‘*’ token
/usr/local/lib/gcc/arm-apple-darwin/4.0.1/../../../../arm-apple-darwin/include/C
arbonCore/MachineExceptions.h:320:
error: syntax error before ‘*’ token
In file included from
/usr/local/lib/gcc/arm-apple-darwin/4.0.1/../../../../arm-apple-darwin/include/C
arbonCore/CarbonCore.h:161,
                 from
/usr/local/lib/gcc/arm-apple-darwin/4.0.1/../../../../arm-apple-darwin/include/C
oreServices/CoreServices.h:21,
                 from
/usr/local/lib/gcc/arm-apple-darwin/4.0.1/../../../../arm-apple-darwin/include/C
oreGraphics/CGEvent.h:17,
                 from
/usr/local/lib/gcc/arm-apple-darwin/4.0.1/../../../../arm-apple-darwin/include/C
oreGraphics/CoreGraphics.h:24,
                 from
/usr/local/lib/gcc/arm-apple-darwin/4.0.1/../../../../arm-apple-darwin/include/U
IKit/UIKit.h:3,
                 from hello.m:1:
/usr/local/lib/gcc/arm-apple-darwin/4.0.1/../../../../arm-apple-darwin/include/C
arbonCore/fp.h:93:2:
error: #error unsupported CPU
In file included from
/usr/local/lib/gcc/arm-apple-darwin/4.0.1/../../../../arm-apple-darwin/include/C
arbonCore/CarbonCore.h:161,
                 from
/usr/local/lib/gcc/arm-apple-darwin/4.0.1/../../../../arm-apple-darwin/include/C
oreServices/CoreServices.h:21,
                 from
/usr/local/lib/gcc/arm-apple-darwin/4.0.1/../../../../arm-apple-darwin/include/C
oreGraphics/CGEvent.h:17,
                 from
/usr/local/lib/gcc/arm-apple-darwin/4.0.1/../../../../arm-apple-darwin/include/C
oreGraphics/CoreGraphics.h:24,
                 from
/usr/local/lib/gcc/arm-apple-darwin/4.0.1/../../../../arm-apple-darwin/include/U
IKit/UIKit.h:3,
                 from hello.m:1:
/usr/local/lib/gcc/arm-apple-darwin/4.0.1/../../../../arm-apple-darwin/include/C
arbonCore/fp.h:471:
error: conflicting types for ‘scalb’
/usr/local/lib/gcc/arm-apple-darwin/4.0.1/../../../../arm-apple-darwin/include/C
arbonCore/fp.h:885:
error: conflicting types for ‘__fpclassifyd’
/usr/local/lib/gcc/arm-apple-darwin/4.0.1/../../../../arm-apple-darwin/include/a
rchitecture/arm/math.h:138:
error: previous declaration of ‘__fpclassifyd’ was here
/usr/local/lib/gcc/arm-apple-darwin/4.0.1/../../../../arm-apple-darwin/include/C
arbonCore/fp.h:896:
error: conflicting types for ‘__fpclassifyf’
/usr/local/lib/gcc/arm-apple-darwin/4.0.1/../../../../arm-apple-darwin/include/a
rchitecture/arm/math.h:137:
error: previous declaration of ‘__fpclassifyf’ was here
/usr/local/lib/gcc/arm-apple-darwin/4.0.1/../../../../arm-apple-darwin/include/C
arbonCore/fp.h:908:
error: conflicting types for ‘__fpclassify’
/usr/local/lib/gcc/arm-apple-darwin/4.0.1/../../../../arm-apple-darwin/include/a
rchitecture/arm/math.h:139:
error: previous declaration of ‘__fpclassify’ was here
/usr/local/lib/gcc/arm-apple-darwin/4.0.1/../../../../arm-apple-darwin/include/C
arbonCore/fp.h:1338:
error: ‘SIGDIGLEN’ undeclared here (not in a function)
In file included from
/usr/local/lib/gcc/arm-apple-darwin/4.0.1/../../../../arm-apple-darwin/include/O
SServices/OSServices.h:45,
                 from
/usr/local/lib/gcc/arm-apple-darwin/4.0.1/../../../../arm-apple-darwin/include/C
oreServices/CoreServices.h:25,
                 from
/usr/local/lib/gcc/arm-apple-darwin/4.0.1/../../../../arm-apple-darwin/include/C
oreGraphics/CGEvent.h:17,
                 from
/usr/local/lib/gcc/arm-apple-darwin/4.0.1/../../../../arm-apple-darwin/include/C
oreGraphics/CoreGraphics.h:24,
                 from
/usr/local/lib/gcc/arm-apple-darwin/4.0.1/../../../../arm-apple-darwin/include/U
IKit/UIKit.h:3,
                 from hello.m:1:
/usr/local/lib/gcc/arm-apple-darwin/4.0.1/../../../../arm-apple-darwin/include/O
SServices/OpenTransport.h:359:
error: syntax error before numeric constant
In file included from
/usr/local/lib/gcc/arm-apple-darwin/4.0.1/../../../../arm-apple-darwin/include/O
SServices/OSServices.h:47,
                 from
/usr/local/lib/gcc/arm-apple-darwin/4.0.1/../../../../arm-apple-darwin/include/C
oreServices/CoreServices.h:25,
                 from
/usr/local/lib/gcc/arm-apple-darwin/4.0.1/../../../../arm-apple-darwin/include/C
oreGraphics/CGEvent.h:17,
                 from
/usr/local/lib/gcc/arm-apple-darwin/4.0.1/../../../../arm-apple-darwin/include/C
oreGraphics/CoreGraphics.h:24,
                 from
/usr/local/lib/gcc/arm-apple-darwin/4.0.1/../../../../arm-apple-darwin/include/U
IKit/UIKit.h:3,
                 from hello.m:1:
/usr/local/lib/gcc/arm-apple-darwin/4.0.1/../../../../arm-apple-darwin/include/O
SServices/OpenTransportProtocol.h:121:
error: conflicting types for ‘uid_t’
/usr/local/lib/gcc/arm-apple-darwin/4.0.1/../../../../arm-apple-darwin/include/s
ys/types.h:167:
error: previous declaration of ‘uid_t’ was here
/usr/local/lib/gcc/arm-apple-darwin/4.0.1/../../../../arm-apple-darwin/include/O
SServices/OpenTransportProtocol.h:122:
error: conflicting types for ‘gid_t’
/usr/local/lib/gcc/arm-apple-darwin/4.0.1/../../../../arm-apple-darwin/include/s
ys/types.h:114:
error: previous declaration of ‘gid_t’ was here
/usr/local/lib/gcc/arm-apple-darwin/4.0.1/../../../../arm-apple-darwin/include/O
SServices/OpenTransportProtocol.h:124:
error: conflicting types for ‘dev_t’
/usr/local/lib/gcc/arm-apple-darwin/4.0.1/../../../../arm-apple-darwin/include/s
ys/types.h:97:
error: previous declaration of ‘dev_t’ was here
make: *** [hello.o] Error 1

Original comment by dou...@gmail.com on 18 May 2008 at 7:58

GoogleCodeExporter commented 8 years ago
SOLVED: Similar to the error seen in error #66. Solved by:

This can be fixed, on ubuntu 7.10, by installing "patch" ('sudo apt-get install 
patch') and rerunning the step 'sudo bash install-headers.sh'.

This works the same for ubuntu 8.

Original comment by dou...@gmail.com on 20 May 2008 at 4:56