#28444: gdb fails to build universal ----------------------------------+----------------------------------------- Reporter: jonnyflash@… | Owner: dweber@… Type: defect | Status: new Priority: Normal | Milestone: Component: ports | Version: 1.9.2 Keywords: universal | Port: gdb ----------------------------------+----------------------------------------- Comment(by alex.mailhuhn@…):
By a quick look at the offending code in libbfd.c, the compiler warning looks unsubstantiated. Hence, wondering if building w/o > -Werror would do. Not sure how to do that from macports.
This indeed helps directly pointing to the core of the problem: After disabling the -Werror compiler flag (adding --disable-werror to the function call configure.args-append inside the Portfile) the "port build gdb" command still yields an error message in the file "/opt/local/var/macports/logs/_opt_local_var_macports_sources_rsync.macports.org_release_ports_devel_gdb/gdb/main.log": :info:build /usr/bin/gcc-4.2 -O2 -I/opt/local/include -arch x86_64 -arch i386 -I. -I. -I./common -I./config -DLOCALEDIR="\"/opt/local/share/locale\"" -DHAVE_CONFIG_H -I./../include/opcode -I./../opcodes/.. -I./../readline/.. -I../bfd -I./../bfd -I./../include -I../libdecnumber -I./../libdecnumber -I./gnulib -Ignulib -DMI_OUT=1 -DTUI=1 -I/opt/local/include -I/System/Library/Frameworks/Python.framework/Versions/2.6/include -I/System/Library/Frameworks/Python.framework/Versions/2.6/include -Wall -Wdeclaration-after-statement -Wpointer-arith -Wformat-nonliteral -Wno- pointer-sign -Wno-unused -Wunused-value -Wunused-function -Wno-switch -Wno-char-subscripts -c -o gdb.o -MT gdb.o -MMD -MP -MF .deps/gdb.Tpo gdb.c :info:build gcc-4.2: -E, -S, -save-temps and -M options are not allowed with multiple -arch flags :info:build make[2]: *** [gdb.o] Error 1 This seems to be an incompatibility with the multi architechture build in the +universal variant, which is the only one available for gdb. Is there any way to switch off the compiler flag "-arch i386"? or the other one? and include a combination of single architecture builds with "lipo"? I have no idea what the flags -M... are used for and who created the Makefiles that contain them. Can these be circumvented? -- Ticket URL: <https://trac.macports.org/ticket/28444#comment:4> MacPorts <http://www.macports.org/> Ports system for Mac OS