Opened 19 years ago
Last modified 9 years ago
#7167 closed enhancement
willing to test gcc42 on Mac OS X 10.3.9, PowerBook G4 — at Initial Version
Reported by: | yaseppochi (Stephen J. Turnbull) | Owned by: | macports-tickets@… |
---|---|---|---|
Priority: | Normal | Milestone: | |
Component: | ports | Version: | |
Keywords: | Cc: | ||
Port: | gcc42 |
Description
If you have anything specific I should look for, please let me know. Here's progress to date
I've uncommented the darwin 7 variant in the Portfile. This gives the following kind of error in the build:
if [ x"" != x ]; then \
/opt/local/var/db/dports/build/_Users_steve_Software_Ports_dports_lang_gcc42/work/build/./prev-gcc/xgcc -B/opt/local/var/db/dports/build/_Users_steve_Software_Ports_dports_lang_gcc42/work/build/./prev-gcc/ -B/opt/local/powerpc-apple-darwin7.9.0/bin/ -c -DHAVE_CONFIG_H -g -O2 -I. -I/opt/local/var/db/dports/build/_Users_steve_Software_Ports_dports_lang_gcc42/work/gcc-4.2-20060204/libiberty/../include -W -Wall -pedantic -Wwrite-strings -Wstrict-prototypes -Wc++-compat /opt/local/var/db/dports/build/_Users_steve_Software_Ports_dports_lang_gcc42/work/gcc-4.2-20060204/libiberty/floatformat.c -o pic/floatformat.o; \
else true; fi /opt/local/var/db/dports/build/_Users_steve_Software_Ports_dports_lang_gcc42/work/build/./prev-gcc/xgcc -B/opt/local/var/db/dports/build/_Users_steve_Software_Ports_dports_lang_gcc42/work/build/./prev-gcc/ -B/opt/local/powerpc-apple-darwin7.9.0/bin/ -c -DHAVE_CONFIG_H -g -O2 -I. -I/opt/local/var/db/dports/build/_Users_steve_Software_Ports_dports_lang_gcc42/work/gcc-4.2-20060204/libiberty/../include -W -Wall -pedantic -Wwrite-strings -Wstrict-prototypes -Wc++-compat /opt/local/var/db/dports/build/_Users_steve_Software_Ports_dports_lang_gcc42/work/gcc-4.2-20060204/libiberty/floatformat.c -o floatformat.o /opt/local/var/db/dports/build/_Users_steve_Software_Ports_dports_lang_gcc42/work/gcc-4.2-20060204/libiberty/floatformat.c: In function 'floatformat_to_double': /opt/local/var/db/dports/build/_Users_steve_Software_Ports_dports_lang_gcc42/work/gcc-4.2-20060204/libiberty/floatformat.c:345: warning: floating constant exceeds range of 'float' /var/tmpccZfmQrf.s:480:stfiwx instruction is optional for the PowerPC (not allowed without -force_cpusubtype_ALL option) /var/tmpccZfmQrf.s:535:stfiwx instruction is optional for the PowerPC (not allowed without -force_cpusubtype_ALL option) make[3]: * [floatformat.o] Error 1 make[2]: * [all-stage2-libiberty] Error 2 make[1]: * [stage2-bubble] Error 2 make: * [bootstrap] Error 2 Error: Target com.apple.build returned: shell command "cd "/opt/local/var/db/dports/build/_Users_steve_Software_Ports_dports_lang_gcc42/work/build" && make bootstrap -j 2 XCFLAGS=-force_cpusubtype_ALL" returned error 2 Command output: no make[1]: * [stage2-bubble] Error 2 make: * [bootstrap] Error 2
Warning: the following items did not execute (for gcc42): com.apple.build Error: Status 1 encountered during processing.
This error will occur in several places and stages of the build, depending on which of the CFLAGS variables below are used; the above is just the most recent example (which occurred with only XCFLAGS set of the three). The following spec for darwin7 variant led to a successful build:
# hope springs eternal! uncommented by sjt # untested on darwin 7 platform darwin 7 {
depends_build port:odcctools patch {
reinplace "s|/usr/bin/libtool|${prefix}/bin/odlibtool|g" \
${workpath}/gcc-${version}/gcc/config/darwin.h
} configure.args-append --with-as=${prefix}/bin/odas \
--with-ld=${prefix}/bin/odld \ --with-ar=${prefix}/bin/odar
# added by sjt build.args-append XCFLAGS=-force_cpusubtype_ALL configure.env CFLAGS=-force_cpusubtype_ALL \
BOOT_CFLAGS="-g -O2 -force_cpusubtype_ALL"
}
The -force_cpusubtype_ALL may not be omitted from any of the three *CFLAGS variables. Of course it's possible (likely?) that there's a better way to achieve this end, but those are the variables I could find that seemed to be more or less appropriate.