[MacPorts] #14387: php5 +apache2 +mysql fails to build

MacPorts trac at macosforge.org
Sat Mar 1 19:16:16 PST 2008


#14387: php5 +apache2 +mysql fails to build
----------------------------------+-----------------------------------------
  Reporter:  paulbeard at gmail.com  |       Owner:  ryandesign at macports.org
      Type:  defect               |      Status:  new                    
  Priority:  Normal               |   Milestone:  Port Bugs              
 Component:  ports                |     Version:  1.6.0                  
Resolution:                       |    Keywords:                         
----------------------------------+-----------------------------------------
Comment (by mitizhi at gmail.com):

 > ...
 >/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_ports_www_php5/work/php-5.2.5/ext/mysqli/mysqli_api.c:2112:
 error: 'NET' has no member named 'last_error'
 > make: *** [ext/mysqli/mysqli_api.lo] Error 1
 >
 > Warning: the following items did not execute (for php5):
 org.macports.activate org.macports.build org.macports.destroot
 org.macports.install
 > Error: Status 1 encountered during processing.
 > }}}


 I stumbled on this same thing. I am using variant '''+mysql5'''. My exact
 install command was:

   {{{
    port install php5 +apache2 +tidy +mysql5 +sqlite +ipc +pcntl +pear
 +sockets
   }}}

 but I think installing '''mysql5-devel''' (version '''5.1.23-rc''') and
 attempting to install php5 with '''+mysql5''' should be enough to
 reproduce.

 I researched the cause. It is due to current API change in mysql
 libraries, introduced by mysql version 5.1.23-rc. It seems mysql and PHP
 communities are discussing whose bug it is (behind the curtains):

  * http://bugs.mysql.com/bug.php?id=34655
  * http://bugs.php.net/bug.php?id=44137&edit=1

 You can search the net with the file name `mysqli_api.c` and relevant
 parts of the error message to come up with other communities stumbling on
 this.

 Except also build problems with perl with mysql5 (according to mysql bug
 report ticket page)?

 To reproduce with macports, you need to install mysql5-devel. mysql5 is
 older version and probably does not cause problems?? [I am very newbie
 with macports and BSD thinking; I thought -devel packages are needed for
 development (like in Debian Linux), but it seems now to me -devel packages
 are newer versions of the package; maybe the meaning of -devel could be
 documented more clearly in macports guide?]

 Relevant version information describing my situation:

   {{{
   $ for action in list installed; do echo $action:;port $action | grep
 mysql5; done
   list:
   mysql5                         @5.0.51         databases/mysql5
   mysql5-devel                   @5.1.23-rc      databases/mysql5-devel
   installed:
     mysql5 @5.0.51_0
     mysql5-devel @5.1.23-rc_1+darwin_8+server (active)
     py25-mysql @1.2.2_0+mysql5 (active)
   }}}

-- 
Ticket URL: <http://trac.macosforge.org/projects/macports/ticket/14387#comment:3>
MacPorts </projects/macports>
Ports system for Mac OS


More information about the macports-tickets mailing list