[MacPorts] #22766: octave-database-1.0.4 fails to compile because gcc43 doesn't understand command line option "-arch"
#22766: octave-database-1.0.4 fails to compile because gcc43 doesn't understand command line option "-arch" ------------------------------+--------------------------------------------- Reporter: earcar@… | Owner: macports-tickets@… Type: defect | Status: new Priority: Normal | Milestone: Component: ports | Version: 1.8.1 Keywords: | Port: octave-database ------------------------------+--------------------------------------------- Other strange things happens in octave related packages: {{{ checking for gcc... /usr/bin/gcc-4.2 checking whether /usr/bin/gcc-4.2 accepts -g... yes checking for /usr/bin/gcc-4.2 option to accept ISO C89... none needed checking how to run the C preprocessor... /usr/bin/gcc-4.2 -E [cut] /opt/local/bin/g++-mp-4.3 -c -I/opt/local/include -I/opt/local/include -fPIC -I/opt/local/include/octave-3.2.3 -I/opt/local/include/octave-3.2.3/octave -I/opt/local/include -mieee-fp -I/opt/local/include/freetype2 -I/opt/local/include -pipe -arch x86_64 -DHAVE_OCTAVE_32 sqlite3_wrap.cpp -o sqlite3_wrap.o cc1plus: error: unrecognized command line option "-arch" }}} This happens because the configure script at first tests for the default compiler (the apple one in my case) and then uses the compiler that built octave (gcc43). The worst part is that it seems to use MacPorts' default CXXFLAGS: {{{ -pipe -O2 -arch x86_64 }}} in combination with the compiler that built octave: {{{ $ mkoctfile -p CXX /opt/local/bin/g++-mp-4.3 }}} The Makeconf file is in fact hilarious about this: {{{ # Most octave programs will be compiled with $(MKOCTFILE). Those which # cannot use mkoctfile directly can request the flags that mkoctfile # would use as follows: # FLAG = $(shell $(MKOCTFILE) -p FLAG) # The following flags are for compiling programs that are independent # of Octave. How confusing. }}} Yeah, how confusing. -- Ticket URL: <http://trac.macports.org/ticket/22766> MacPorts <http://www.macports.org/> Ports system for Mac OS
#22766: octave-database-1.0.4 fails to compile because gcc43 doesn't understand command line option "-arch" ------------------------------+--------------------------------------------- Reporter: earcar@… | Owner: and.damore@… Type: defect | Status: new Priority: Normal | Milestone: Component: ports | Version: 1.8.1 Keywords: | Port: octave-database ------------------------------+--------------------------------------------- Changes (by jmr@…): * cc: alakazam@… (added) * owner: macports-tickets@… => and.damore@… -- Ticket URL: <http://trac.macports.org/ticket/22766#comment:1> MacPorts <http://www.macports.org/> Ports system for Mac OS
#22766: octave-database-1.0.4 fails to compile because gcc43 doesn't understand command line option "-arch" ------------------------------+--------------------------------------------- Reporter: earcar@… | Owner: and.damore@… Type: defect | Status: assigned Priority: Normal | Milestone: Component: ports | Version: 1.8.1 Keywords: | Port: octave-database ------------------------------+--------------------------------------------- Changes (by and.damore@…): * status: new => assigned Comment: The build script from octave-forge packages uses mkoctfile that is in turn a script created from octave so the dual compiler behavior is not that weird. Two mkoctfile jobs are launched and both break with errors complaining for -arch being not recognized, I'm assuming your macports joblevel is 2. I just checked man page for g++-mp-4.3 and it has got a '''-arch''' options, still not g++-mp-4.3 nor g++-mp-4.2 are not able to understand it, maybe this is an issue of macports' gcc ports, try filing a ticket for those. -- Ticket URL: <http://trac.macports.org/ticket/22766#comment:2> MacPorts <http://www.macports.org/> Ports system for Mac OS
#22766: octave-database-1.0.4 fails to compile because gcc43 doesn't understand command line option "-arch" ------------------------------+--------------------------------------------- Reporter: earcar@… | Owner: and.damore@… Type: defect | Status: assigned Priority: Normal | Milestone: Component: ports | Version: 1.8.1 Keywords: | Port: octave-database ------------------------------+--------------------------------------------- Changes (by alakazam@…): * cc: alakazam@… (removed) -- Ticket URL: <http://trac.macports.org/ticket/22766#comment:3> MacPorts <http://www.macports.org/> Ports system for Mac OS
#22766: octave-database-1.0.4 fails to compile because gcc43 doesn't understand command line option "-arch" ------------------------------+--------------------------------------------- Reporter: earcar@… | Owner: and.damore@… Type: defect | Status: assigned Priority: Normal | Milestone: Component: ports | Version: 1.8.1 Keywords: | Port: octave-database ------------------------------+--------------------------------------------- Comment(by jmr@…): Might just need to set configure.compiler? -- Ticket URL: <http://trac.macports.org/ticket/22766#comment:4> MacPorts <http://www.macports.org/> Ports system for Mac OS
#22766: octave-database-1.0.4 fails to compile because gcc43 doesn't understand command line option "-arch" ------------------------------+--------------------------------------------- Reporter: earcar@… | Owner: and.damore@… Type: defect | Status: assigned Priority: Normal | Milestone: Component: ports | Version: 1.8.1 Keywords: | Port: octave-database ------------------------------+--------------------------------------------- Comment(by and.damore@…): Replying to [comment:4 jmr@…]:
Might just need to set configure.compiler?
Do you mean to set configure.compiler to the output of "mkoctave -p CXX"? -- Ticket URL: <http://trac.macports.org/ticket/22766#comment:5> MacPorts <http://www.macports.org/> Ports system for Mac OS
#22766: octave-database-1.0.4 fails to compile because gcc43 doesn't understand command line option "-arch" ------------------------------+--------------------------------------------- Reporter: earcar@… | Owner: and.damore@… Type: defect | Status: assigned Priority: Normal | Milestone: Component: ports | Version: 1.9.1 Keywords: swig | Port: octave-database ------------------------------+--------------------------------------------- Changes (by and.damore@…): * keywords: => swig * version: 1.8.1 => 1.9.1 Comment: I tried ''configure.compiler macports-gcc-4.4'' and built with a single build job, I get different errors from the SWIG generated interface files. Apparently the package is broken mainstream, so apart committing the small fix for compiler I can't do much for now. I'm attaching output using same compiler of octave, mp-gcc-4.4 in my case. -- Ticket URL: <http://trac.macports.org/ticket/22766#comment:6> MacPorts <http://www.macports.org/> Ports system for Mac OS
#22766: octave-database-1.0.4 fails to compile because gcc43 doesn't understand command line option "-arch" ------------------------------+--------------------------------------------- Reporter: earcar@… | Owner: and.damore@… Type: defect | Status: assigned Priority: Normal | Milestone: Component: ports | Version: 1.9.1 Keywords: swig | Port: octave-database ------------------------------+--------------------------------------------- Comment(by and.damore@…): cf. [http://permalink.gmane.org/gmane.comp.programming.swig.devel/19194 this reply] -- Ticket URL: <http://trac.macports.org/ticket/22766#comment:7> MacPorts <http://www.macports.org/> Ports system for Mac OS
#22766: octave-database-1.0.4 fails to compile because gcc43 doesn't understand command line option "-arch" ------------------------------+--------------------------------------------- Reporter: earcar@… | Owner: and.damore@… Type: defect | Status: assigned Priority: Normal | Milestone: Component: ports | Version: 1.9.1 Keywords: swig | Port: octave-database ------------------------------+--------------------------------------------- Comment(by and.damore@…): earcar, can you reproduce the error? -- Ticket URL: <https://trac.macports.org/ticket/22766#comment:8> MacPorts <http://www.macports.org/> Ports system for Mac OS
#22766: octave-database-1.0.4 fails to compile because gcc43 doesn't understand command line option "-arch" ------------------------------+--------------------------------------------- Reporter: earcar@… | Owner: and.damore@… Type: defect | Status: assigned Priority: Normal | Milestone: Component: ports | Version: 1.9.1 Keywords: swig | Port: octave-database ------------------------------+--------------------------------------------- Comment(by macports@…): Same error here, and there seems to have been no action on this ticket for quite a while. Anyone come up with a fix? -- Ticket URL: <https://trac.macports.org/ticket/22766#comment:9> MacPorts <http://www.macports.org/> Ports system for Mac OS
#22766: octave-database-1.0.4 fails to compile because gcc43 doesn't understand command line option "-arch" ------------------------------+--------------------------------------------- Reporter: earcar@… | Owner: and.damore@… Type: defect | Status: assigned Priority: Normal | Milestone: Component: ports | Version: 1.9.1 Keywords: swig | Port: octave-database ------------------------------+--------------------------------------------- Comment(by and.damore@…): As I already wrote I don't have the compiler issue that the port submitter has. I'm using {{{ configure.compiler macports-gcc-4.4 use_parallel_build no }}} and I get {{{ CXXFLAGS="-pipe -m64" mkoctfile -DHAVE_OCTAVE_32 -v -o sqlite3.oct -lsqlite3 sqlite3_wrap.cpp /opt/local/bin/g++-mp-4.4 -c -I/opt/local/include -I/opt/local/include -fPIC -I/opt/local/include/octave-3.2.4 -I/opt/local/include/octave-3.2.4/octave -I/opt/local/include -mieee-fp -I/opt/local/include/freetype2 -I/opt/local/include -pipe -m64 -DHAVE_OCTAVE_32 sqlite3_wrap.cpp -o sqlite3_wrap.o sqlite3_wrap.cpp: In member function 'void octave_swig_type::install_global()': sqlite3_wrap.cpp:1197: error: 'curr_sym_tab' was not declared in this scope sqlite3_wrap.cpp:1197: error: 'link_to_global_variable' was not declared in this scope sqlite3_wrap.cpp:1204: error: 'symbol_record' was not declared in this scope sqlite3_wrap.cpp:1204: error: 'sr' was not declared in this scope sqlite3_wrap.cpp:1204: error: 'global_sym_tab' was not declared in this scope sqlite3_wrap.cpp: In function 'void SWIG_Octave_SetModule(void*, swig_module_info*)': sqlite3_wrap.cpp:2110: error: 'curr_sym_tab' was not declared in this scope sqlite3_wrap.cpp:2110: error: 'link_to_global_variable' was not declared in this scope sqlite3_wrap.cpp: In function 'octave_value_list _wrap_sqlite3_vmprintf(const octave_value_list&, int)': sqlite3_wrap.cpp:3029: error: invalid array assignment sqlite3_wrap.cpp: In function 'octave_value_list Fsqlite3(const octave_value_list&, int)': sqlite3_wrap.cpp:10430: error: 'curr_sym_tab' was not declared in this scope sqlite3_wrap.cpp:10430: error: 'link_to_global_variable' was not declared in this scope make[1]: *** [sqlite3.oct] Error 1 make[1]: Leaving directory `/opt/local/var/macports/build/_opt_local_var_macports_sources_svn.macports .org_trunk_dports_math_octave-database/octave- database/work/database-1.0.4/src' make: *** [build] Error 2 make: Leaving directory `/opt/local/var/macports/build/_opt_local_var_macports_sources_svn.macports .org_trunk_dports_math_octave-database/octave- database/work/database-1.0.4' shell command " cd "/opt/local/var/macports/build/_opt_local_var_macports_sources_svn.macports .org_trunk_dports_math_octave-database/octave- database/work/database-1.0.4" && /usr/bin/make -w all " returned error 2 Error: Target org.macports.build returned: shell command failed (see log for details) }}} This seems to be related to [http://permalink.gmane.org/gmane.comp.programming.swig.devel/19194 this issue] that dates back to July '09. Swig's [http://www.swig.org/Release/RELEASENOTES release notes] talks about fix and enhancements for Octave in 2.0.4 version that is from May '11 but even with latest swig and swig-octave I have the upward issue. I've asked the package author for comments. -- Ticket URL: <https://trac.macports.org/ticket/22766#comment:10> MacPorts <http://www.macports.org/> Ports system for Mac OS
#22766: octave-database-1.0.4 fails to compile because gcc43 doesn't understand command line option "-arch" -------------------------------+-------------------------------------------- Reporter: earcar@… | Owner: and.damore@… Type: defect | Status: closed Priority: Normal | Milestone: Component: ports | Version: 1.9.1 Resolution: worksforme | Keywords: swig Port: octave-database | -------------------------------+-------------------------------------------- Changes (by and.damore@…): * status: assigned => closed * cc: macports@…, rjbailey@… (added) * resolution: => worksforme Comment: I'm closing this ticket as worksforme. If someone can reproduce after the latest octave upgrades then reopen it. -- Ticket URL: <https://trac.macports.org/ticket/22766#comment:11> MacPorts <http://www.macports.org/> Ports system for Mac OS
#22766: octave-database-1.0.4 fails to compile because gcc43 doesn't understand command line option "-arch" -------------------------------+-------------------------------------------- Reporter: earcar@… | Owner: and.damore@… Type: defect | Status: reopened Priority: Normal | Milestone: Component: ports | Version: 1.9.1 Resolution: | Keywords: swig Port: octave-database | -------------------------------+-------------------------------------------- Changes (by macports@…): * status: closed => reopened * resolution: worksforme => Comment: I can reproduce the error after the latest octave upgrades. -- Ticket URL: <https://trac.macports.org/ticket/22766#comment:12> MacPorts <http://www.macports.org/> Ports system for Mac OS
#22766: octave-database-1.0.4 fails to compile because gcc43 doesn't understand command line option "-arch" -------------------------------+-------------------------------------------- Reporter: earcar@… | Owner: and.damore@… Type: defect | Status: closed Priority: Normal | Milestone: Component: ports | Version: 1.9.1 Resolution: wontfix | Keywords: swig Port: octave-database | -------------------------------+-------------------------------------------- Changes (by and.damore@…): * status: reopened => closed * resolution: => wontfix Old description:
Other strange things happens in octave related packages:
{{{ checking for gcc... /usr/bin/gcc-4.2 checking whether /usr/bin/gcc-4.2 accepts -g... yes checking for /usr/bin/gcc-4.2 option to accept ISO C89... none needed checking how to run the C preprocessor... /usr/bin/gcc-4.2 -E [cut] /opt/local/bin/g++-mp-4.3 -c -I/opt/local/include -I/opt/local/include -fPIC -I/opt/local/include/octave-3.2.3 -I/opt/local/include/octave-3.2.3/octave -I/opt/local/include -mieee-fp -I/opt/local/include/freetype2 -I/opt/local/include -pipe -arch x86_64 -DHAVE_OCTAVE_32 sqlite3_wrap.cpp -o sqlite3_wrap.o cc1plus: error: unrecognized command line option "-arch" }}}
This happens because the configure script at first tests for the default compiler (the apple one in my case) and then uses the compiler that built octave (gcc43).
The worst part is that it seems to use MacPorts' default CXXFLAGS:
{{{ -pipe -O2 -arch x86_64 }}}
in combination with the compiler that built octave:
{{{ $ mkoctfile -p CXX /opt/local/bin/g++-mp-4.3 }}}
The Makeconf file is in fact hilarious about this:
{{{ # Most octave programs will be compiled with $(MKOCTFILE). Those which # cannot use mkoctfile directly can request the flags that mkoctfile # would use as follows: # FLAG = $(shell $(MKOCTFILE) -p FLAG) # The following flags are for compiling programs that are independent # of Octave. How confusing. }}}
Yeah, how confusing.
New description: Other strange things happens in octave related packages: {{{ checking for gcc... /usr/bin/gcc-4.2 checking whether /usr/bin/gcc-4.2 accepts -g... yes checking for /usr/bin/gcc-4.2 option to accept ISO C89... none needed checking how to run the C preprocessor... /usr/bin/gcc-4.2 -E [cut] /opt/local/bin/g++-mp-4.3 -c -I/opt/local/include -I/opt/local/include -fPIC \ -I/opt/local/include/octave-3.2.3 -I/opt/local/include/octave-3.2.3/octave \ -I/opt/local/include -mieee-fp -I/opt/local/include/freetype2 -I/opt/local/include \ -pipe -arch x86_64 -DHAVE_OCTAVE_32 sqlite3_wrap.cpp -o sqlite3_wrap.o cc1plus: error: unrecognized command line option "-arch" }}} This happens because the configure script at first tests for the default compiler (the apple one in my case) and then uses the compiler that built octave (gcc43). The worst part is that it seems to use MacPorts' default CXXFLAGS: {{{ -pipe -O2 -arch x86_64 }}} in combination with the compiler that built octave: {{{ $ mkoctfile -p CXX /opt/local/bin/g++-mp-4.3 }}} The Makeconf file is in fact hilarious about this: {{{ # Most octave programs will be compiled with $(MKOCTFILE). Those which # cannot use mkoctfile directly can request the flags that mkoctfile # would use as follows: # FLAG = $(shell $(MKOCTFILE) -p FLAG) # The following flags are for compiling programs that are independent # of Octave. How confusing. }}} Yeah, how confusing. -- Comment: The '-march' option is easily corrected in r91251 but the package is broken upstream, cf. [http://octave.1599824.n4.nabble.com/Best- replacement-for-curr-sym-tab-in-octave-3-2-td1638528.html 1] and [http://octave.1599824.n4.nabble.com/Issue-installing-Octave-forge- database-1-0-4-td4173368.html 2] because it has not been upgraded for working with new octave's API. I'm closing the ticket, I suggest to ask the [http://octave.sourceforge.net/database/index.html upstream package author] to update the package for octave 3.2.x -- Ticket URL: <https://trac.macports.org/ticket/22766#comment:13> MacPorts <http://www.macports.org/> Ports system for Mac OS
participants (1)
-
MacPorts