Solved

PHP 4.3.1 "make" failing with "collect2: ld returned 1 exit status" "make: *** [sapi/cli/php] Error 1"

Posted on 2003-10-30
7
7,850 Views
Last Modified: 2013-12-13
I am attempting to install PHP 4.3.1 on a RedHat Linux 9.0 server. I'm running Apache 2.0.48. I am attempting to execute the installation using the following syntax:

./configure --with-mysql --with-apxs2=/usr/local/apache2/bin/apxs --with-zlib

The configure process works fine no errors. The tail end of the "make" process results in the following:

ext/mysql/libmysql/my_tempnam.lo(.text+0x4c): In function `my_tempnam':
/usr/local/src/php/php-4.3.1/ext/mysql/libmysql/my_tempnam.c:103: the use of `tempnam' is dangerous, better use `mkstemp'
ext/mysql/libmysql/my_lib.lo(.text+0x3d1): In function `my_dir':
/usr/local/src/php/php-4.3.1/ext/mysql/libmysql/my_lib.c:169: undefined reference to `errno'
ext/mysql/libmysql/my_lib.lo(.text+0x5ef): In function `my_stat':
/usr/local/src/php/php-4.3.1/ext/mysql/libmysql/my_lib.c:588: undefined reference to `errno'
ext/mysql/libmysql/my_malloc.lo(.text+0xde): In function `my_malloc':
/usr/local/src/php/php-4.3.1/ext/mysql/libmysql/my_malloc.c:24: undefined reference to `errno'
ext/mysql/libmysql/my_realloc.lo(.text+0xd5): In function `my_realloc':
/usr/local/src/php/php-4.3.1/ext/mysql/libmysql/my_realloc.c:44: undefined reference to `errno'
ext/mysql/libmysql/my_delete.lo(.text+0x86): In function `my_delete':
/usr/local/src/php/php-4.3.1/ext/mysql/libmysql/my_delete.c:16: undefined reference to `errno'
ext/mysql/libmysql/my_tempnam.lo(.text+0x89):/usr/local/src/php/php-4.3.1/ext/mysql/libmysql/my_tempnam.c:108: more undefined references to `errno' follow
collect2: ld returned 1 exit status
make: *** [sapi/cli/php] Error 1

I also tried running the "configure" without the "--with-zlib" option but it didn't make a difference.

Can you help?

Thanks!

-Samson
0
Comment
Question by:smartine
7 Comments
 
LVL 14

Accepted Solution

by:
ThG earned 105 total points
ID: 9654225

very weird. Do other programs compile correctly?
Completely wiping out the php directory and unpacking original sources again might help..
0
 
LVL 3

Expert Comment

by:red010knight
ID: 9657897
You may want to put this question to the Linux Gurus as well, because the problem may be something more inherent to Linux than PHP

Red010Knight
0
 

Author Comment

by:smartine
ID: 9670667
Thanks! Yes, all other apps (rrdtool, apache, etc.) compiled with no problem at all. I'll try starting from scratch again to see if it makes a difference.

Thanks again.

-Samson
0
Netscaler Common Configuration How To guides

If you use NetScaler you will want to see these guides. The NetScaler How To Guides show administrators how to get NetScaler up and configured by providing instructions for common scenarios and some not so common ones.

 

Author Comment

by:smartine
ID: 9671844
I proceeded to install 4.3.3 (still not sure why I was installing 4.3.1..:) ) and the process was seamless, no problems whatsoever. Still not sure why 4.3.1 was failing but, oh well... Thanks for your assistance.

-Samson
0
 
LVL 14

Expert Comment

by:ThG
ID: 9675252
Good. Did you try again with 4.3.1? same results?
that's weird.. anyway new releases happen because bugs are found in previous releases, so if everything is working fine now you can forget about it (and close the question)
0
 

Author Comment

by:smartine
ID: 9678573
No, I didn't try again with 4.3.1 due to time constraints. I had to get this going as quickly as possible, along with a million other things. How do I go about closing the question properly, given that there are 3 comments with "accept" possibilities?

Thanks!

-Samson
0
 
LVL 6

Expert Comment

by:aolXFT
ID: 9706611
If you think one of the comments was an answer to your question, you should accept the comment with an A Grade.*

If you think one of the comments led you to investigate installing php 4.3.3, then accept it with a B-Grade.*

If you think you answered your own question(which would seem to be the case) you can ask the CS Section to close the question for you and refund the points.

* This is my personal interpretion of the EE Rules only. I don't guarntee it to the only/correct one.
0

Featured Post

NAS Cloud Backup Strategies

This article explains backup scenarios when using network storage. We review the so-called “3-2-1 strategy” and summarize the methods you can use to send NAS data to the cloud

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
Exporting image to excel from php document 10 28
PHP and google maps 13 45
Google Maps API and PHP 25 34
how to use a switch statement with heredoc 11 23
Deprecated and Headed for the Dustbin By now, you have probably heard that some PHP features, while convenient, can also cause PHP security problems.  This article discusses one of those, called register_globals.  It is a thing you do not want.  …
Part of the Global Positioning System A geocode (https://developers.google.com/maps/documentation/geocoding/) is the major subset of a GPS coordinate (http://en.wikipedia.org/wiki/Global_Positioning_System), the other parts being the altitude and t…
Explain concepts important to validation of email addresses with regular expressions. Applies to most languages/tools that uses regular expressions. Consider email address RFCs: Look at HTML5 form input element (with type=email) regex pattern: T…
The viewer will learn how to dynamically set the form action using jQuery.

810 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question