Opened 13 years ago

Last modified 13 years ago

#34430 closed defect

Php4 @4.4.9_12 -apache2 +mysql5 build fails in linking phase — at Version 1

Reported by: exile@… Owned by: ryandesign@…
Priority: Normal Milestone:
Component: ports Version: 2.0.4
Keywords: Cc:
Port: php4

Description (last modified by ryandesign (Ryan Carsten Schmidt))

Hi,

I know PHP4 has been dead for a long time but it still comes handy time to time when you need to be able to run legacy PHP applications prior to porting, as such I find it really useful for Macports to keep the legacy php4 port alive.

Currently when trying to install (it seems the variants don't play role when trying to build php4 on Lion Server 10.7.3):

sudo port -v install php4 -apache2 +mysql5

On building I get the following error on linking:

sapi/cgi/php
Undefined symbols for architecture x86_64:
  "_res_9_search", referenced from:
      _zif_getmxrr in dns.o
      _zif_checkdnsrr in dns.o
  "_res_9_dn_skipname", referenced from:
      _zif_getmxrr in dns.o
  "_res_9_dn_expand", referenced from:
      _zif_getmxrr in dns.o
ld: symbol(s) not found for architecture x86_64
collect2: ld returned 1 exit status
make: *** [sapi/cgi/php] Error 1

This seems to be a an old PHP bug where -lresolv is missing from the EXTRA_LIBS in generated Makefile. Adding the -lresolv to Makefile fixes the issue and php installs successfully. Would be nice if this is included as a patch after the configuration phase.

Regards,

Sten

Change History (1)

comment:1 Changed 13 years ago by ryandesign (Ryan Carsten Schmidt)

Description: modified (diff)
Keywords: php4 removed
Owner: changed from macports-tickets@… to ryandesign@…
Status: newassigned
Note: See TracTickets for help on using tickets.