perl-5.14.0 compilation in new GCC does not pass the workaround

Source: Internet
Author: User

1?? ? Because in the new version GCC divides the standard library in the C99 into the libc and LIBM two parts, LIBM contains some mathematical libraries, etc., if you want to use LIBM, you must add the-LM option

After extracting configure, and then in Makefile, Ldflags and cldflags two parameters plus-lm can solve the problem

2?? ? Reference: Http://serverfault.com/questions/145288/make-error-when-compiling-perl-5-12-1-rhel-5-5

??? Modify Dist/io/poll.h: Modify the #include to #include

3?? ? Reference: HTTP://BLOG.163.COM/ZHANGLIYE_2009/BLOG/STATIC/1223120282013518104148904/

In Makefile, the Ldflags and cldflags two parameters are followed by a-LRT?

Related error message:

1

Cc-fstack-protector-l/usr/lib64-o miniperl \????????????? gv.o toke.o perly.o pad.o regcomp.o dump.o util.o mg.o reentr.o mro.o keywords.o hv.o av.o run.o pp_hot.o sv.o pp.o scope. o pp_ctl.o pp_sys.o doop.o doio.o regexec.o utf8.o taint.o deb.o universal.o globals.o perlio.o perlapi.o numeric.o Mathom S.O locale.o pp_pack.o pp_sort.o?? \??????????? MINIPERLMAIN.O opmini.o perlmini.opp.o:in function ' Perl_pp_int ':p p.c: (. text+0x9151): Undefined reference to ' floor ' PP.C: (. text+0x9171): Undefined reference to ' ceil ' pp.o:in function ' Perl_pp_sin ':p p.c: (. text+0x944d): undefined Reference to ' sin ' pp.o:in function ' perl_pp_atan2 ':p p.c: (. text+0xc2c3): Undefined reference to ' atan2 ' pp.o:in function ' Perl_pp_modulo ':p p.c: (. text+0xdc71): Undefined reference to ' floor ' pp.c: (. Text+0xde3d): Undefined reference to ' fmod ' PP.C: (. text+0xde6f): Undefined reference to ' floor ' pp.o:in function ' Perl_pp_pow ':p p.c: (. text+0xe1b3): undefined Reference to ' POW ' PP.O: (. rodata+0x260): Undefined reference to 'Cos ' PP.O: (. rodata+0x268): Undefined reference to ' sin ' pp.o: (. rodata+0x270): Undefined reference to ' sin ' pp.o: (. rodata+ 0x278): Undefined reference to ' exp ' PP.O: (. rodata+0x280): Undefined reference to ' log ' PP.O: (. rodata+0x288): undefined Reference to ' sqrt ' pp_sys.o:in function ' S_gmtime64_r ':p p_sys.c: (. text+0x1c21): Undefined reference to ' Ceil ' PP_SYS.C :(. text+0x1c7e): Undefined reference to ' Ceil ' PP_SYS.C: (. text+0x1ce3): Undefined reference to ' Ceil ' PP_SYS.C: (. text+ 0X1DA1): Undefined reference to "floor" PP_SYS.C: (. text+0x1f11): Undefined reference to ' floor ' pp_sys.c: (. text+0x1f65): Undefined reference to "floor" PP_SYS.C: (. text+0x1f85): Undefined reference to ' floor ' pp_sys.c: (. text+0x1fc0): Undefined reference to ' Ceil ' PP_SYS.C: (. text+0x2119): Undefined reference to ' Fmod ' PP_SYS.C: (. text+0x2155): undefined Reference to ' Fmod ' PP_SYS.C: (. text+0x2193): Undefined reference to ' Fmod ' PP_SYS.C: (. text+0x21cb): undefined reference To ' fmod ' pp_sys.o:in function ' perl_pp_gmtime ':p p_sys.c: (. text+0x2287): Undefined reference to ' floor ' pp_pack.o:in function ' S_pack_rec ':p p_pack.c: (. text+0x369b): undefined reference To "Floor" PP_PACK.C: (. text+0x36c3): Undefined reference to ' floor ' Collect2:ld returned 1 exit statusmake: * * * [Miniperl] Error 1

2

MAKE[1]: Entering directory '/data_center_02/user/wucy/soft/perl-5.14.0/dist/io ' Cc-c?? -dovr_dbl_dig=14-fno-strict-aliasing-pipe-fstack-protector-i/usr/local/include-d_largefile_source-d_file_ Offset_bits=64-o2?? -dversion=\ "1.25_04\"-dxs_version=\ "1.25_04\"? "-I.. /.."?? IO.cIO.xs:In function ' Xs_io__poll__poll ': io.xs:249:error:invalid application of ' sizeof ' to incomplete type ' struct PO LLFD ' io.xs:253:error:invalid use of undefined type ' struct POLLFD ' io.xs:253:error:dereferencing pointer to incomplete Typeio.xs:255:error:invalid use of undefined type ' struct POLLFD ' io.xs:255:error:dereferencing pointer to incomplete t Ypeio.xs:257:error:invalid use of undefined type ' struct POLLFD ' io.xs:257:error:dereferencing pointer to incomplete TY Peio.xs:261:error:invalid use of undefined type ' struct POLLFD ' io.xs:261:error:dereferencing pointer to incomplete Typ Eio.xs:262:error:invalid use of undefined type ' struct POLLFD ' io.xs:262:error:dereferencing Pointer to IncOmplete typemake[1]: * * * [IO.O] Error 1make[1]: Leaving directory '/data_center_02/user/wucy/soft/perl-5.14.0/dist/io ' unsuccessful make (Dist/io): code=512 @ make_ext.pl Line 463.make: * * * [LIB/AUTO/IO/IO.A] Error 2

3

Can ' t find extension encode/byte in any of the CPAN dist ext at make_ext.pl line 251.Can ' t find extension encode/cn in any of CPAN Dist ext at make_ext.pl line 251.Can ' t find extension encode/ebcdic in any of the CPAN dist ext at make_ext.pl line 251.C A ' t find extension encode/jp in any of the CPAN dist ext at make_ext.pl line 251.Can ' t find extension encode/kr in any of CPA N Dist ext at make_ext.pl line 251.Can ' t find extension encode/symbol in any of CPAN dist ext at make_ext.pl line 251.Can ' t find extension encode/tw in no of CPAN dist ext at make_ext.pl line 251.Can ' t find extension encode/unicode in any of C Pan Dist ext at make_ext.pl line 251.lib/auto/posix/posix.a (POSIX.O): in function ' Xs_posix_tmpnam ':P osix.c: (. text+ 0x4614): warning:the use of ' tmpnam ' was dangerous, better use ' mkstemp ' Lib/auto/time/hires/hires.a (HIRES.O): in function ' Xs_time__hires_clock_nanosleep ': hires.c: (. text+0xac3): Undefined reference to ' Clock_nanosleep ' lib/auto/time/ HIRES/HIRES.A (HIRES.O): in function ' Xs_timE__hires_clock_getres ': hires.c: (. text+0xc8e): Undefined reference to ' Clock_getres ' LIB/AUTO/TIME/HIRES/HIRES.A ( HIRES.O): In function ' Xs_time__hires_clock_gettime ': hires.c: (. text+0xdbe): Undefined reference to ' clock_gettime ' Collect2:ld returned 1 exit statusmake: * * * [Perl] Error 1

perl-5.14.0 compilation in new GCC does not work through the workaround

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.