[MacPorts] #34123: libdbi-drivers incorrect compiler parameter on mysql fails to compile

MacPorts noreply at macports.org
Wed Apr 18 23:27:43 PDT 2012


#34123: libdbi-drivers incorrect compiler parameter on mysql fails to compile
---------------------------+------------------------------------------------
 Reporter:  jrojas@…       |       Owner:  macports-tickets@…                   
     Type:  defect         |      Status:  new                                  
 Priority:  Normal         |   Milestone:                                       
Component:  ports          |     Version:  2.0.4                                
 Keywords:  clang, libdbi  |        Port:  libdbi-drivers                       
---------------------------+------------------------------------------------
 I was installing gnucash and tried to add mysql support, upgrading libdbi-
 drivers.

 Default compile (+sqlite3 driver) works

 mysql (+mysql5) fails because of -O20 parameter; it's for gcc, not clang.

 My solution: After editing [Makefile] & [configure] on msql directory,
 removing the offending parameter ([-O20], I retried and compiled/installed
 fine. I think just removing the parameter from configure (cflags=...,
 profile=...) will do it.

 Note: Postgress driver fails with same error. Others may too.

 OSX 10.7, spanish, xcode 4.3.2

 Detail of log (note wrong [-O20]):

 sudo port install libdbi-drivers +mysql5 +sqlite3

 ...
 :info:build make[3]: Entering directory
 `/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports
 .org_release_tarballs_ports_databases_libdbi-drivers/libdbi-drivers/work
 /libdbi-drivers-0.8.3-1/drivers/sqlite3'
 :info:build if /bin/sh ../../libtool --tag=CC --mode=compile
 /usr/bin/clang -DHAVE_CONFIG_H -I. -I. -I../.. -I../.. -I../../include
 -I/opt/local/include -I/opt/local/include  -I/opt/local/include
 '''-O20''' -D__NO_MATH_INLINES -fsigned-char -MT dbd_sqlite3.lo -MD -MP
 -MF ".deps/dbd_sqlite3.Tpo" -c -o dbd_sqlite3.lo dbd_sqlite3.c; \
 :info:build     then mv -f ".deps/dbd_sqlite3.Tpo"
 ".deps/dbd_sqlite3.Plo"; else rm -f ".deps/dbd_sqlite3.Tpo"; exit 1; fi
 :info:build  /usr/bin/clang -DHAVE_CONFIG_H -I. -I. -I../.. -I../..
 -I../../include -I/opt/local/include -I/opt/local/include
 -I/opt/local/include -O20 -D__NO_MATH_INLINES -fsigned-char -MT
 dbd_sqlite3.lo -MD -MP -MF .deps/dbd_sqlite3.Tpo -c dbd_sqlite3.c  -fno-
 common -DPIC -o .libs/dbd_sqlite3.o
 :info:build error: invalid value '4' in '-O20'
 :info:build make[3]: *** [dbd_sqlite3.lo] Error 1

 Keep up the good work :)

-- 
Ticket URL: <https://trac.macports.org/ticket/34123>
MacPorts <http://www.macports.org/>
Ports system for Mac OS


More information about the macports-tickets mailing list