php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #31193 iconv.c:254 undefined reference to 'libiconv'
Submitted: 2004-12-20 09:12 UTC Modified: 2005-01-31 22:29 UTC
Votes:35
Avg. Score:4.2 ± 0.9
Reproduced:31 of 31 (100.0%)
Same Version:6 (19.4%)
Same OS:13 (41.9%)
From: david at cubbieco dot com Assigned:
Status: No Feedback Package: Compile Failure
PHP Version: 5.0.3 OS: linux gcc-3.2
Private report: No CVE-ID: None
 [2004-12-20 09:12 UTC] david at cubbieco dot com
Description:
------------
Using either ./configure with no options or
./configure --prefix=/... --enable-sockets --enable-pcntl --enable-sockets --disable-pear --disable-cgi

Fails when building -o sapi/cli/php





Reproduce code:
---------------
SOLUTION:

Makefile  ends up being line 70

EXTRA_LIBS = -lcrypt ...

if you add -liconv to the EXTRA_LIBS line in Makefile then Make works just fine.

I don't know enough about ./configure to find where to tell it to add this.


tried: ./configure -- failed with libiconv error
./configure --enable-sockets --disable-pear --disable-cgi failed with libiconv error
./configure --with-apxs2=/... failed with liniconv error 


Patches

Pull Requests

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2005-01-10 15:03 UTC] sniper@php.net
What's the actual error?

 [2005-01-10 20:50 UTC] david at cubbieco dot com
sorry... here is the pertanent info

./configure
make 
...

gcc  -Iext/dom/ -I/home/david/php-5.0.3/ext/dom/ -DPHP_ATOM_INC -I/home/david/php-5.0.3/include -I/home/david/php-5.0.3/main -I/home/david/php-5.0.3 -I/home/david/php-5.0.3/Zend -I/usr/include/libxml2  -I/home/david/php-5.0.3/TSRM  -g -O2  -c /home/david/php-5.0.3/ext/dom/userdatahandler.c -o ext/dom/userdatahandler.o  && echo > ext/dom/userdatahandler.lo
gcc -I"/usr/include" -Iext/iconv/ -I/home/david/php-5.0.3/ext/iconv/ -DPHP_ATOM_INC -I/home/david/php-5.0.3/include -I/home/david/php-5.0.3/main -I/home/david/php-5.0.3 -I/home/david/php-5.0.3/Zend -I/usr/include/libxml2  -I/home/david/php-5.0.3/TSRM  -g -O2  -c /home/david/php-5.0.3/ext/iconv/iconv.c -o ext/iconv/iconv.o  && echo > ext/iconv/iconv.lo
cc1: warning: changing search order for system directory "/usr/include"
cc1: warning:   as it has already been specified as a non-system directory
/home/david/php-5.0.3/ext/iconv/iconv.c: In function `_php_iconv_appendl':
/home/david/php-5.0.3/ext/iconv/iconv.c:254: warning: passing arg 2 of `libiconv' from incompatible pointer type
/home/david/php-5.0.3/ext/iconv/iconv.c: In function `_php_iconv_strlen':
/home/david/php-5.0.3/ext/iconv/iconv.c:528: warning: passing arg 2 of `libiconv' from incompatible pointer type
/home/david/php-5.0.3/ext/iconv/iconv.c: In function `_php_iconv_substr':
/home/david/php-5.0.3/ext/iconv/iconv.c:628: warning: passing arg 2 of `libiconv' from incompatible pointer type
/home/david/php-5.0.3/ext/iconv/iconv.c: In function `_php_iconv_strpos':
/home/david/php-5.0.3/ext/iconv/iconv.c:759: warning: passing arg 2 of `libiconv' from incompatible pointer type
/home/david/php-5.0.3/ext/iconv/iconv.c: In function `_php_iconv_mime_encode':
/home/david/php-5.0.3/ext/iconv/iconv.c:1012: warning: passing arg 2 of `libiconv' from incompatible pointer type
/home/david/php-5.0.3/ext/iconv/iconv.c:1112: warning: passing arg 2 of `libiconv' from incompatible pointer type
/home/david/php-5.0.3/ext/iconv/iconv.c: In function `php_iconv_stream_filter_append_bucket':
/home/david/php-5.0.3/ext/iconv/iconv.c:2365: warning: passing arg 2 of `libiconv' from incompatible pointer type
/home/david/php-5.0.3/ext/iconv/iconv.c:2444: warning: passing arg 2 of `libiconv' from incompatible pointer type
gcc -DSUPPORT_UTF8 -DLINK_SIZE=2 -DPOSIX_MALLOC_THRESHOLD=10 -I/home/david/php-5.0.3/ext/pcre/pcrelib -Iext/pcre/ -I/home/david/php-5.0.3/ext/pcre/ -DPHP_ATOM_INC -I/home/david/php-5.0.3/include -I/home/david/php-5.0.3/main -I/home/david/php-5.0.3 -I/home/david/php-5.0.3/Zend -I/usr/include/libxml2  -I/home/david/php-5.0.3/TSRM  -g -O2  -c /home/david/php-5.0.3/ext/pcre/pcrelib/maketables.c -o ext/pcre/pcrelib/maketables.o  && echo > ext/pcre/pcrelib/maketables.lo
gcc -DSUPPORT_UTF8 -DLINK_SIZE=2 -DPOSIX_MALLOC_THRESHOLD=10 -I/home/david/php-5.0.3/ext/pcre/pcrelib -Iext/pcre/ -I/home/david/php-5.0.3/ext/pcre/ -DPHP_ATOM_INC -I/home/david/php-5.0.3/include -I/home/david/php-5.0.3/main -I/home/david/php-5.0.3 -I/home/david/php-5.0.3/Zend -I/usr/include/libxml2  -I/home/david/php-5.0.3/TSRM  -g -O2  -c /home/david/php-5.0.3/ext/pcre/pcrelib/get.c -o ext/pcre/pcrelib/get.o  && echo > ext/pcre/pcrelib/get.lo
...
gcc  -Isapi/cgi/ -I/home/david/php-5.0.3/sapi/cgi/ -DPHP_ATOM_INC -I/home/david/php-5.0.3/include -I/home/david/php-5.0.3/main -I/home/david/php-5.0.3 -I/home/david/php-5.0.3/Zend -I/usr/include/libxml2  -I/home/david/php-5.0.3/TSRM  -g -O2  -c /home/david/php-5.0.3/sapi/cgi/getopt.c -o sapi/cgi/getopt.o  && echo > sapi/cgi/getopt.lo
gcc  -Imain/ -I/home/david/php-5.0.3/main/ -DPHP_ATOM_INC -I/home/david/php-5.0.3/include -I/home/david/php-5.0.3/main -I/home/david/php-5.0.3 -I/home/david/php-5.0.3/Zend -I/usr/include/libxml2  -I/home/david/php-5.0.3/TSRM  -g -O2  -c main/internal_functions.c -o main/internal_functions.o  && echo > main/internal_functions.lo
/bin/sh /home/david/php-5.0.3/libtool --silent --preserve-dup-deps --mode=link gcc -export-dynamic -g -O2     ext/libxml/libxml.lo ext/ctype/ctype.lo ext/dom/php_dom.lo ext/dom/attr.lo ext/dom/document.lo ext/dom/domerrorhandler.lo ext/dom/domstringlist.lo ext/dom/domexception.lo ext/dom/namelist.lo ext/dom/processinginstruction.lo ext/dom/cdatasection.lo ext/dom/documentfragment.lo ext/dom/domimplementation.lo ext/dom/element.lo ext/dom/node.lo ext/dom/string_extend.lo ext/dom/characterdata.lo ext/dom/documenttype.lo ext/dom/domimplementationlist.lo ext/dom/entity.lo ext/dom/nodelist.lo ext/dom/text.lo ext/dom/comment.lo ext/dom/domconfiguration.lo ext/dom/domimplementationsource.lo ext/dom/entityreference.lo ext/dom/notation.lo ext/dom/xpath.lo ext/dom/dom_iterators.lo ext/dom/typeinfo.lo ext/dom/domerror.lo ext/dom/domlocator.lo ext/dom/namednodemap.lo ext/dom/userdatahandler.lo ext/iconv/iconv.lo ext/pcre/pcrelib/maketables.lo ext/pcre/pcrelib/get.lo ext/pcre/pcrelib/study.lo ext/pcre/pcrelib/pcre.lo ext/pcre/php_pcre.lo ext/posix/posix.lo ext/session/session.lo ext/session/mod_files.lo ext/session/mod_mm.lo ext/session/mod_user.lo ext/simplexml/simplexml.lo ext/spl/php_spl.lo ext/spl/spl_functions.lo ext/spl/spl_engine.lo ext/spl/spl_iterators.lo ext/spl/spl_array.lo ext/spl/spl_directory.lo ext/spl/spl_sxe.lo ext/sqlite/sqlite.lo ext/sqlite/sess_sqlite.lo ext/sqlite/libsqlite/src/opcodes.lo ext/sqlite/libsqlite/src/parse.lo ext/sqlite/libsqlite/src/encode.lo ext/sqlite/libsqlite/src/auth.lo ext/sqlite/libsqlite/src/btree.lo ext/sqlite/libsqlite/src/build.lo ext/sqlite/libsqlite/src/delete.lo ext/sqlite/libsqlite/src/expr.lo ext/sqlite/libsqlite/src/func.lo ext/sqlite/libsqlite/src/hash.lo ext/sqlite/libsqlite/src/insert.lo ext/sqlite/libsqlite/src/main.lo ext/sqlite/libsqlite/src/os.lo ext/sqlite/libsqlite/src/pager.lo ext/sqlite/libsqlite/src/printf.lo ext/sqlite/libsqlite/src/random.lo ext/sqlite/libsqlite/src/select.lo ext/sqlite/libsqlite/src/table.lo ext/sqlite/libsqlite/src/tokenize.lo ext/sqlite/libsqlite/src/update.lo ext/sqlite/libsqlite/src/util.lo ext/sqlite/libsqlite/src/vdbe.lo ext/sqlite/libsqlite/src/attach.lo ext/sqlite/libsqlite/src/btree_rb.lo ext/sqlite/libsqlite/src/pragma.lo ext/sqlite/libsqlite/src/vacuum.lo ext/sqlite/libsqlite/src/copy.lo ext/sqlite/libsqlite/src/vdbeaux.lo ext/sqlite/libsqlite/src/date.lo ext/sqlite/libsqlite/src/where.lo ext/sqlite/libsqlite/src/trigger.lo regex/regcomp.lo regex/regexec.lo regex/regerror.lo regex/regfree.lo ext/standard/array.lo ext/standard/base64.lo ext/standard/basic_functions.lo ext/standard/browscap.lo ext/standard/crc32.lo ext/standard/crypt.lo ext/standard/cyr_convert.lo ext/standard/datetime.lo ext/standard/dir.lo ext/standard/dl.lo ext/standard/dns.lo ext/standard/exec.lo ext/standard/file.lo ext/standard/filestat.lo ext/standard/flock_compat.lo ext/standard/formatted_print.lo ext/standard/fsock.lo ext/standard/head.lo ext/standard/html.lo ext/standard/image.lo ext/standard/info.lo ext/standard/iptc.lo ext/standard/lcg.lo ext/standard/link.lo ext/standard/mail.lo ext/standard/math.lo ext/standard/md5.lo ext/standard/metaphone.lo ext/standard/microtime.lo ext/standard/pack.lo ext/standard/pageinfo.lo ext/standard/parsedate.lo ext/standard/quot_print.lo ext/standard/rand.lo ext/standard/reg.lo ext/standard/soundex.lo ext/standard/string.lo ext/standard/scanf.lo ext/standard/syslog.lo ext/standard/type.lo ext/standard/uniqid.lo ext/standard/url.lo ext/standard/url_scanner.lo ext/standard/var.lo ext/standard/versioning.lo ext/standard/assert.lo ext/standard/strnatcmp.lo ext/standard/levenshtein.lo ext/standard/incomplete_class.lo ext/standard/url_scanner_ex.lo ext/standard/ftp_fopen_wrapper.lo ext/standard/http_fopen_wrapper.lo ext/standard/php_fopen_wrapper.lo ext/standard/credits.lo ext/standard/css.lo ext/standard/var_unserializer.lo ext/standard/ftok.lo ext/standard/sha1.lo ext/standard/user_filters.lo ext/standard/uuencode.lo ext/standard/filters.lo ext/standard/proc_open.lo ext/standard/sunfuncs.lo ext/standard/streamsfuncs.lo ext/standard/http.lo ext/tokenizer/tokenizer.lo ext/xml/xml.lo ext/xml/compat.lo TSRM/TSRM.lo TSRM/tsrm_strtok_r.lo TSRM/tsrm_virtual_cwd.lo main/main.lo main/snprintf.lo main/spprintf.lo main/php_sprintf.lo main/safe_mode.lo main/fopen_wrappers.lo main/alloca.lo main/php_scandir.lo main/php_ini.lo main/SAPI.lo main/rfc1867.lo main/php_content_types.lo main/strlcpy.lo main/strlcat.lo main/mergesort.lo main/reentrancy.lo main/php_variables.lo main/php_ticks.lo main/network.lo main/php_open_temporary_file.lo main/php_logos.lo main/output.lo main/streams/streams.lo main/streams/cast.lo main/streams/memory.lo main/streams/filter.lo main/streams/plain_wrapper.lo main/streams/userspace.lo main/streams/transports.lo main/streams/xp_socket.lo main/streams/mmap.lo Zend/zend_language_parser.lo Zend/zend_language_scanner.lo Zend/zend_ini_parser.lo Zend/zend_ini_scanner.lo Zend/zend_alloc.lo Zend/zend_compile.lo Zend/zend_constants.lo Zend/zend_dynamic_array.lo Zend/zend_execute_API.lo Zend/zend_highlight.lo Zend/zend_llist.lo Zend/zend_opcode.lo Zend/zend_operators.lo Zend/zend_ptr_stack.lo Zend/zend_stack.lo Zend/zend_variables.lo Zend/zend.lo Zend/zend_API.lo Zend/zend_extensions.lo Zend/zend_hash.lo Zend/zend_list.lo Zend/zend_indent.lo Zend/zend_builtin_functions.lo Zend/zend_sprintf.lo Zend/zend_ini.lo Zend/zend_qsort.lo Zend/zend_multibyte.lo Zend/zend_ts_hash.lo Zend/zend_stream.lo Zend/zend_iterators.lo Zend/zend_interfaces.lo Zend/zend_exceptions.lo Zend/zend_strtod.lo Zend/zend_objects.lo Zend/zend_object_handlers.lo Zend/zend_objects_API.lo Zend/zend_mm.lo Zend/zend_default_classes.lo Zend/zend_reflection_api.lo Zend/zend_execute.lo sapi/cgi/cgi_main.lo sapi/cgi/getopt.lo main/internal_functions.lo -lcrypt -lcrypt -lresolv -lm -ldl -lnsl -lxml2 -lz -lm -lxml2 -lz -lm -lxml2 -lz -lm -lcrypt -lxml2 -lz -lm -lcrypt  -o sapi/cgi/php
ext/iconv/iconv.o: In function `_php_iconv_appendl':
/home/david/php-5.0.3/ext/iconv/iconv.c:254: undefined reference to `libiconv'
/home/david/php-5.0.3/ext/iconv/iconv.c:291: undefined reference to `libiconv'
ext/iconv/iconv.o: In function `php_iconv_string':
/home/david/php-5.0.3/ext/iconv/iconv.c:347: undefined reference to `libiconv_open'
/home/david/php-5.0.3/ext/iconv/iconv.c:356: undefined reference to `libiconv'
/home/david/php-5.0.3/ext/iconv/iconv.c:369: undefined reference to `libiconv'
/home/david/php-5.0.3/ext/iconv/iconv.c:380: undefined reference to `libiconv_close'
ext/iconv/iconv.o: In function `_php_iconv_strlen':
/home/david/php-5.0.3/ext/iconv/iconv.c:505: undefined reference to `libiconv_open'
/home/david/php-5.0.3/ext/iconv/iconv.c:528: undefined reference to `libiconv'
/home/david/php-5.0.3/ext/iconv/iconv.c:561: undefined reference to `libiconv_close'
ext/iconv/iconv.o: In function `_php_iconv_substr':
/home/david/php-5.0.3/ext/iconv/iconv.c:605: undefined reference to `libiconv_open'
/home/david/php-5.0.3/ext/iconv/iconv.c:628: undefined reference to `libiconv'
/home/david/php-5.0.3/ext/iconv/iconv.c:685: undefined reference to `libiconv_close'
/home/david/php-5.0.3/ext/iconv/iconv.c:689: undefined reference to `libiconv_close'
/home/david/php-5.0.3/ext/iconv/iconv.c:636: undefined reference to `libiconv_open'
ext/iconv/iconv.o: In function `_php_iconv_strpos':
/home/david/php-5.0.3/ext/iconv/iconv.c:734: undefined reference to `libiconv_open'
/home/david/php-5.0.3/ext/iconv/iconv.c:759: undefined reference to `libiconv'
/home/david/php-5.0.3/ext/iconv/iconv.c:877: undefined reference to `libiconv_close'
ext/iconv/iconv.o: In function `_php_iconv_mime_encode':
/home/david/php-5.0.3/ext/iconv/iconv.c:1200: undefined reference to `libiconv_close'
/home/david/php-5.0.3/ext/iconv/iconv.c:1203: undefined reference to `libiconv_close'
/home/david/php-5.0.3/ext/iconv/iconv.c:927: undefined reference to `libiconv_open'
/home/david/php-5.0.3/ext/iconv/iconv.c:941: undefined reference to `libiconv_open'
/home/david/php-5.0.3/ext/iconv/iconv.c:1112: undefined reference to `libiconv'
/home/david/php-5.0.3/ext/iconv/iconv.c:1143: undefined reference to `libiconv'
/home/david/php-5.0.3/ext/iconv/iconv.c:1187: undefined reference to `libiconv'
/home/david/php-5.0.3/ext/iconv/iconv.c:1012: undefined reference to `libiconv'
/home/david/php-5.0.3/ext/iconv/iconv.c:1044: undefined reference to `libiconv'
ext/iconv/iconv.o:/home/david/php-5.0.3/ext/iconv/iconv.c:1060: more undefined references to `libiconv' follow
ext/iconv/iconv.o: In function `_php_iconv_mime_decode':
/home/david/php-5.0.3/ext/iconv/iconv.c:1238: undefined reference to `libiconv_open'
/home/david/php-5.0.3/ext/iconv/iconv.c:1705: undefined reference to `libiconv_close'
/home/david/php-5.0.3/ext/iconv/iconv.c:1708: undefined reference to `libiconv_close'
/home/david/php-5.0.3/ext/iconv/iconv.c:1349: undefined reference to `libiconv_close'
/home/david/php-5.0.3/ext/iconv/iconv.c:1352: undefined reference to `libiconv_open'
ext/iconv/iconv.o: In function `php_iconv_stream_filter_dtor':
/home/david/php-5.0.3/ext/iconv/iconv.c:2293: undefined reference to `libiconv_close'
ext/iconv/iconv.o: In function `php_iconv_stream_filter_ctor':
/home/david/php-5.0.3/ext/iconv/iconv.c:2319: undefined reference to `libiconv_open'
ext/iconv/iconv.o: In function `php_iconv_stream_filter_append_bucket':
/home/david/php-5.0.3/ext/iconv/iconv.c:2365: undefined reference to `libiconv'
/home/david/php-5.0.3/ext/iconv/iconv.c:2443: undefined reference to `libiconv'
collect2: ld returned 1 exit status
make: *** [sapi/cgi/php] Error 1

it's the /bin/sh ... -o sapi/cgi/php (or sapi/cli/php) that fails.  Adding a -liconv to that line makes it finish compiling (linking?) on my machine.
 [2005-01-10 22:45 UTC] nlopess@php.net
similar to #31263.

I can reproduce the first part (pointers warnings) on Solaris 9. The link part has worked on my test box.
 [2005-01-11 06:53 UTC] moriyoshi@php.net
Where (and why) did you install libiconv ? It wouldn't 
be needed because glibc provides nearly the same 
functionality as libiconv. I think there's kind of 
confusion going on through configure. If you have 
installed libiconv in /usr on the linux box, you may 
finally have to restore the glibc devel package as 
installation of libiconv overwrites iconv.h that also 
comes from that package.

Compiler warnings are safe and just ignorable.
 [2005-01-31 22:29 UTC] sniper@php.net
No feedback was provided. The bug is being suspended because
we assume that you are no longer experiencing the problem.
If this is not the case and you are able to provide the
information that was requested earlier, please do so and
change the status of the bug back to "Open". Thank you.


 [2006-04-11 16:05 UTC] gaikwad_s at rediffmail dot com
I am trying to install php 5 on fedora linux 5 
it has generating error like
I searched on net but did got any clue regarding this 
usr/local/src/php-5.1.2/ext/iconv/iconv.c:772: undefined reference to `libiconv'
:/usr/local/src/php-5.1.2/ext/iconv/iconv.c:890: undefined reference to `libiconv_close'
ext/iconv/.libs/iconv.o: In function `_php_iconv_appendl':/usr/local/src/php-5.1.2/ext/iconv/iconv.c:254: undefined reference to `libiconv'
:/usr/local/src/php-5.1.2/ext/iconv/iconv.c:291: undefined reference to `libiconv'
ext/iconv/.libs/iconv.o: In function `_php_iconv_mime_decode':/usr/local/src/php-5.1.2/ext/iconv/iconv.c:1251: undefined reference to `libiconv_open'
:/usr/local/src/php-5.1.2/ext/iconv/iconv.c:1362: undefined reference to `libiconv_close'
:/usr/local/src/php-5.1.2/ext/iconv/iconv.c:1365: undefined reference to `libiconv_open'
:/usr/local/src/php-5.1.2/ext/iconv/iconv.c:1718: undefined reference to `libiconv_close'
:/usr/local/src/php-5.1.2/ext/iconv/iconv.c:1721: undefined reference to `libiconv_close'
ext/iconv/.libs/iconv.o: In function `php_iconv_stream_filter_dtor':/usr/local/src/php-5.1.2/ext/iconv/iconv.c:2309: undefined reference to `libiconv_close'
ext/iconv/.libs/iconv.o: In function `php_iconv_stream_filter_append_bucket':/usr/local/src/php-5.1.2/ext/iconv/iconv.c:2459: undefined reference to `libiconv'
:/usr/local/src/php-5.1.2/ext/iconv/iconv.c:2381: undefined reference to `libiconv'
ext/iconv/.libs/iconv.o: In function `php_iconv_stream_filter_ctor':/usr/local/src/php-5.1.2/ext/iconv/iconv.c:2335: undefined reference to `libiconv_open'
ext/iconv/.libs/iconv.o: In function `_php_iconv_substr':/usr/local/src/php-5.1.2/ext/iconv/iconv.c:618: undefined reference to `libiconv_open'
:/usr/local/src/php-5.1.2/ext/iconv/iconv.c:641: undefined reference to `libiconv'
:/usr/local/src/php-5.1.2/ext/iconv/iconv.c:698: undefined reference to `libiconv_close'
:/usr/local/src/php-5.1.2/ext/iconv/iconv.c:702: undefined reference to `libiconv_close'
:/usr/local/src/php-5.1.2/ext/iconv/iconv.c:649: undefined reference to `libiconv_open'
ext/iconv/.libs/iconv.o: In function `_php_iconv_mime_encode':/usr/local/src/php-5.1.2/ext/iconv/iconv.c:940: undefined reference to `libiconv_open'
:/usr/local/src/php-5.1.2/ext/iconv/iconv.c:954: undefined reference to `libiconv_open'
:/usr/local/src/php-5.1.2/ext/iconv/iconv.c:1213: undefined reference to `libiconv_close'
:/usr/local/src/php-5.1.2/ext/iconv/iconv.c:1216: undefined reference to `libiconv_close'
:/usr/local/src/php-5.1.2/ext/iconv/iconv.c:1216: undefined reference to `libiconv_close'
:/usr/local/src/php-5.1.2/ext/iconv/iconv.c:1073: undefined reference to `libiconv'
:/usr/local/src/php-5.1.2/ext/iconv/iconv.c:1025: undefined reference to `libiconv'
:/usr/local/src/php-5.1.2/ext/iconv/iconv.c:1057: undefined reference to `libiconv'
:/usr/local/src/php-5.1.2/ext/iconv/iconv.c:1125: undefined reference to `libiconv'
:/usr/local/src/php-5.1.2/ext/iconv/iconv.c:1156: undefined reference to `libiconv'
ext/iconv/.libs/iconv.o:/usr/local/src/php-5.1.2/ext/iconv/iconv.c:1200: more undefined references to `libiconv' follow
collect2: ld returned 1 exit status
make: *** [sapi/cli/php] Error 1
 [2007-05-15 09:16 UTC] weber at lviv dot farlep dot net
Latest PHP 5.2.2.
Faced the same problem on RHES4.

My options:
./configure --with-apxs2=/usr/local/apache2/bin/apxs --with-mysql=shared,/usr --with-xml --with-dom --enable-sockets --enable-ftp

Even I compiled clean libiconv the problem persists. 
Solution was the same as described in the first post.
 [2007-07-24 09:09 UTC] janarbek at icu dot ac dot kr
I tried to install Php5.2.3  on Fedora 4 with Apache 2

if you add -liconv to EXTRA_LIBS then make works fine.
 [2007-11-02 23:41 UTC] w dot peter dot howell at meccahosting dot com
This problem still occurs in v5.2.4.  It's been 3 years now.  Does someone plan to fix this?
 [2007-11-15 08:57 UTC] fr33z at inmail dot cz
I have the same problem with PHP 5.2.5 on Slackware 11, why it isn't still fixed?
 [2008-02-17 18:53 UTC] marrtins at hackers dot lv
undefined reference to `libiconv_open'

php 5.2.5, slackware 10
 [2008-02-18 14:55 UTC] bugs dot php dot net at michaelrack dot de
Same Problem here in v5.2.5. libiconv exists on my Gentoo Base 2007.1 System. PHP automaticly derminates the location of libiconv and compile against this library. The Configure-Script have to add -liconv to the EXTRA_LIBS variable.

After i've added this library to the EXTRA_LIBS variable, PHP compiles without a error-message.

Another solution is --without-libiconv ... but there is still a bug in the configure-script!

Kind regards,
Michael Rack
http://www.michaelrack.de
 [2008-02-23 16:47 UTC] kspetter at curreyadkinscook dot com
What did you add in the EXTRA_LIBS variable?  I'm having the same issue with version 5.2.5 as well and I can also tell that it's looking for a different area for the libary even if I'm doing a --with-iconv=dirname

If someone can point out what they did I'll be glad to test out if it resolves it for me as well.
 [2008-06-12 14:01 UTC] spadefinger at hotmail dot com
PHP version 5.2.6 on VectorLinux 5.8 deault configure gives error as earlier posts. Using ./configure --without-libiconv did not work, adding -liconv to the EXTRA_LIBS did not work. Used ./configure --without-iconv to get past the errors.
 [2008-11-25 00:52 UTC] justincase at mailcatch dot com
Run configure like this:
[root@david php-5.0.3]# ./configure CFLAGS=-liconv
 [2010-04-27 15:43 UTC] wolfgang_weber at gmx dot at
This problem still exists on CentOS 5.4 (64bit), when you try to build PHP 5.3.2 with PHP-FPM-Patch from SVN.

My config:

./configure \
--with-config-file-path=/etc \
--with-config-file-scan-dir=/etc/php.d \
--cache-file=config.cache \
--with-system-tzdata \
--disable-debug \
--disable-posix \
--disable-safe-mode \
--disable-magic-quotes \
--disable-pdo \
--disable-sqlite \
--disable-phar \
--disable-dba \
--without-sqlite \
--without-pdo-sqlite \
--enable-fpm \
--enable-fastcgi \
--with-fpm-bin=/usr/bin/php-cgi \
--with-fpm-port=9000 \
--with-fpm-conf=/etc/php-fpm.conf \
--with-fpm-log=/var/log/php-fpm.log \
--with-fpm-pid=/var/run/php-fpm.pid \
--with-fpm-user=nobody \
--with-fpm-group=nobody \
--enable-ftp \
--enable-mbstring \
--enable-mbregex \
--enable-zip \
--enable-calendar \
--enable-bcmath \
--with-mysql=mysqlnd \
--with-mysqli=mysqlnd \
--with-pcre-regex=/opt/pcre \
--with-curl=/opt/curl \
--with-zlib=/opt/zlib \
--with-mcrypt \
--with-ttf \
--with-t1lib=/opt/t1lib \
--with-jpeg-dir=/usr/lib64 \
--with-png-dir=/usr/lib64 \
--with-gd \
--enable-gd-native-ttf

When I added --without-iconv, not only "configure" but also "make" was successful.
Unfortunately "make test" failed with:

output buffering - fatalism [tests/output/ob_011.phpt]
Inconsistencies when accessing protected members [Zend/tests/access_modifiers_008.phpt]
Inconsistencies when accessing protected members - 2 [Zend/tests/access_modifiers_009.phpt]
Bug #48770 (call_user_func_array() fails to call parent from inheriting class) [Zend/tests/bug48770.phpt]
Bug #48770 (call_user_func_array() fails to call parent from inheriting class) [Zend/tests/bug48770_2.phpt]
Bug #48770 (call_user_func_array() fails to call parent from inheriting class) [Zend/tests/bug48770_3.phpt]
SimpleXML: array casting bug [ext/simplexml/tests/034.phpt]

Bugreport already automatically posted to qa.php.net /buildtest-process.php

Regards
Wolfgang
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Sun Dec 22 10:01:28 2024 UTC