找回密码
 注册
查看: 6|回复: 0

php添加模块报错configure: error: GNU MP Library version 4.2 or greater required. 解决办法

[复制链接]

1

主题

0

回帖

12

积分

管理员

积分
12
QQ
发表于 2024-1-6 22:07:30 | 显示全部楼层 |阅读模式
报错:checking for __gmpz_rootrem in -lgmp... no
; N% C' t& u' n7 r! m% |9 G' `, dconfigure: error: GNU MP Library version 4.2 or greater required.
0 i! H7 p' _2 i7 v3 B% u5 C7 D
5 @0 ]( Q3 v, i' S: P  h( Q5 K5 |5 F
configure: error: GNU MP Library version 4.2 or greater required.
' `8 ?  q; \" F6 X! D8 c- M解决:# @+ B/ r% F9 g. Y* t
#yum -y install gmp-devel
) e7 |- f5 m5 `3 y! s. y  h5 G5 A8 P$ u4 `$ A3 M

; V9 ~/ \; ]6 A4 l4 C  @, z
- u. n, ?- T% _: |0 [& g* I' L
[root@ipam2 gmp]# ./configure --with-php-config=/usr/local/php/bin/php-config
+ H& \! k1 s( ^! G$ N5 rchecking for grep that handles long lines and -e... /bin/grep
4 X) ~. P1 {: G1 s5 O5 D6 o4 uchecking for egrep... /bin/grep -E6 b% j$ V/ [. n6 v7 n
checking for a sed that does not truncate output... /bin/sed
' j: B/ L! N0 c/ a" J' Z: V3 pchecking for pkg-config... /bin/pkg-config+ z* L5 f( F6 M, }9 Z  q
checking pkg-config is at least version 0.9.0... yes& L! v: D: }8 s7 T
checking for cc... cc  ]2 u1 A# {' x- Y9 T
checking whether the C compiler works... yes$ ~  t9 i5 \( ^! u8 G$ x" b. q
checking for C compiler default output file name... a.out+ }  c) v! ?$ ?. X  Z5 I# S
checking for suffix of executables... 1 [( a) k* h5 Z, E
checking whether we are cross compiling... no
. l9 E/ J" _! O# X- i7 @checking for suffix of object files... o3 q7 [3 ^  p: G, v6 K
checking whether we are using the GNU C compiler... yes3 c, r6 L/ t7 V  k8 m2 B8 V2 N
checking whether cc accepts -g... yes
6 M7 t, }* K1 F" ~; ]' d$ R5 }/ Gchecking for cc option to accept ISO C89... none needed
; \! Z6 |$ S" M! qchecking how to run the C preprocessor... cc -E* l6 K! y, y8 s% W+ T! @' S
checking for icc... no
3 y1 Z+ E9 \/ Q# ^  Lchecking for suncc... no, @) a: _5 J2 t0 H2 x
checking for system library directory... lib
. _  I: g# m9 |checking if compiler supports -Wl,-rpath,... yes. X7 @* _' P2 n+ s5 g
checking build system type... x86_64-pc-linux-gnu
7 J& Z: Y, M8 S8 Z6 H* Z. Ichecking host system type... x86_64-pc-linux-gnu8 s, J- `* a  s/ `) M
checking target system type... x86_64-pc-linux-gnu
$ F; g7 d1 j9 Nchecking for PHP prefix... /usr/local/php7 k) C1 V6 J' V& w0 u
checking for PHP includes... -I/usr/local/php/include/php -I/usr/local/php/include/php/main -I/usr/local/php/include/php/TSRM -I/usr/local/php/include/php/Zend -I/usr/local/php/include/php/ext -I/usr/local/php/include/php/ext/date/lib
2 B' h* a$ I8 J3 Ichecking for PHP extension directory... /usr/local/php/lib/php/extensions/no-debug-zts-20230831
& B' O6 O+ l/ }' schecking for PHP installed headers prefix... /usr/local/php/include/php
- {% Y: o  t: w, _& ^checking if debug is enabled... no0 n# i6 H, ~3 d- M( ]& p- e
checking if zts is enabled... yes
/ U3 n, }$ o. ?6 Zchecking for gawk... gawk
6 B# i# ?7 x' I, ^: P* j/ cchecking for GNU MP support... yes, shared
$ N: {, [5 Q3 R3 k- ?! {checking for __gmpz_rootrem in -lgmp... no6 d2 i, M1 X# c" o
configure: error: GNU MP Library version 4.2 or greater required.. ~5 V: ?2 Q, r% ?% n2 h! A
[root@ipam2 gmp]# yum install -y gmp-dev& a& y) |' N! D) w! y- p. z
Loaded plugins: fastestmirror
4 o* y, [* A1 D3 N6 \Loading mirror speeds from cached hostfile& V1 x5 ?8 E+ [  r( ?& X- k% _
epel/x86_64/metalink                                                                                                                         | 6.4 kB  00:00:00     $ ]* c6 r+ K( G6 q. s
* base: ftp.sjtu.edu.cn
$ H; R2 a7 s3 Q$ f * epel: ftp.iij.ad.jp5 Z9 i: v$ X6 o3 w
* extras: ftp.sjtu.edu.cn
3 r4 G' c4 x) K/ A * updates: mirrors.163.com
3 z6 L1 ~2 }6 F# |8 C4 d4 ?. K( `base                                                                                                                                         | 3.6 kB  00:00:00     ! k$ ]. b- X1 t$ W7 O3 Y3 {, ?1 `
epel                                                                                                                                         | 4.7 kB  00:00:00     / w  ]: a5 W0 R7 K" k
extras                                                                                                                                       | 2.9 kB  00:00:00     " D* @( F" @; K
updates                                                                                                                                      | 2.9 kB  00:00:00     
# {; E; s8 W+ v* z& B$ ANo package gmp-dev available., R& d" c( ~8 s  \! h- ]! I
Error: Nothing to do
5 u: |- g( \% e[root@ipam2 gmp]# yum -y install gmp-devel
$ N6 a( p" ]% pLoaded plugins: fastestmirror& [$ r1 b# M7 X1 }/ W
Loading mirror speeds from cached hostfile8 [: ?' e3 q5 N  O6 \
* base: ftp.sjtu.edu.cn$ |' R0 J" Q; U, H, ?
* epel: ftp.iij.ad.jp
1 R; O* A/ f% A8 q: H1 d# m7 r/ @5 J * extras: ftp.sjtu.edu.cn
9 s' T+ c* q; P, C * updates: mirrors.163.com$ U  Q+ t9 G5 I: Z  H
Resolving Dependencies( ^, q, |' V+ l" y, S/ B% M
--> Running transaction check2 N6 y7 w5 n; S& {4 z& o
---> Package gmp-devel.x86_64 1:6.0.0-15.el7 will be installed
& X" h# @- I4 K/ f' }--> Finished Dependency Resolution
, z- ^* _3 l- m9 J8 i' O3 h. g; V: d5 G
Dependencies Resolved- G( o8 V) J3 R$ a" T9 \: I

4 a8 U$ {* e# ~: J====================================================================================================================================================================) M' ?$ Q# L% Y3 O$ U  N# P  k/ l
Package                                 Arch                                 Version                                      Repository                          Size
; B0 S% K2 T0 H1 P====================================================================================================================================================================# H: I  W" f, L0 j  B1 F& I
Installing:$ f+ K4 m7 p; H8 a7 \
gmp-devel                               x86_64                               1:6.0.0-15.el7                               base                               181 k
8 G" q* V' m, O- g/ t" K
+ x, f/ C; S) h/ F  ^; I3 BTransaction Summary8 i# ~+ H7 Z: r/ }4 v
====================================================================================================================================================================
4 [* A; M9 q% J) a+ |) p# G2 \Install  1 Package
4 T, H7 n9 a' [, S" ]- B$ j$ `; x
Total download size: 181 k4 E/ r" p) {) a# s) [8 u# B, h
Installed size: 340 k
8 I- f- Y8 g0 O, r+ bDownloading packages:5 T3 u1 A& A9 p* l! i
gmp-devel-6.0.0-15.el7.x86_64.rpm                                                                                                            | 181 kB  00:00:00     * `8 |+ W5 T! E0 ?! R8 b+ [
Running transaction check" \3 k/ }. X3 v  ]8 ]9 @& X
Running transaction test0 I  ]5 i% x7 T
Transaction test succeeded
$ x& ^3 O: w! SRunning transaction1 P0 A' g! J# l' n8 Z/ ^+ N2 U$ i
Warning: RPMDB altered outside of yum.2 \! @7 S  I& [/ t7 \! a2 a
** Found 2 pre-existing rpmdb problem(s), 'yum check' output follows:
. S4 M; M; c! L( R- k. ^( [" ^7 p2:postfix-2.10.1-9.el7.x86_64 has missing requires of libmysqlclient.so.18()(64bit)
3 |+ _9 H% G0 b& h% d2:postfix-2.10.1-9.el7.x86_64 has missing requires of libmysqlclient.so.18(libmysqlclient_18)(64bit)3 q6 M* H! A! y2 X( v/ u/ T; G
  Installing : 1:gmp-devel-6.0.0-15.el7.x86_64                                                                                                                  1/1
& `9 F$ y: {" I, q  Verifying  : 1:gmp-devel-6.0.0-15.el7.x86_64                                                                                                                  1/1
) Q) R) E- T. r0 s$ y5 J
0 e" ~* ^7 \! @# A) g+ ?- DInstalled:
- C- {1 k8 _* z2 i, A  gmp-devel.x86_64 1:6.0.0-15.el7                                                                                                                                   3 B3 m! k( |1 Y7 F
- @# B: Q$ ]1 v
Complete!5 y1 _" ]5 Z9 F2 f9 e# O
[root@ipam2 gmp]# ./configure --with-php-config=/usr/local/php/bin/php-config
& ]8 N9 ~$ J9 e( K( l5 ~# i2 w# schecking for grep that handles long lines and -e... /bin/grep
0 g3 @" [% r4 A; `9 B/ i9 Rchecking for egrep... /bin/grep -E) Z. c2 C4 N3 B, E9 Y; N6 x3 x
checking for a sed that does not truncate output... /bin/sed, e1 w& z1 o6 U2 v- a
checking for pkg-config... /bin/pkg-config
' o! m! x; ^2 W( hchecking pkg-config is at least version 0.9.0... yes8 l0 {3 B3 M+ C# R* D4 n& `# k
checking for cc... cc
9 ^, m0 k: s/ M2 m$ k6 Uchecking whether the C compiler works... yes) j, G: I" U/ K4 F7 z+ e4 y
checking for C compiler default output file name... a.out
3 O. V0 I8 w& E" V5 r  qchecking for suffix of executables... ! z. _7 p- H& s+ {" v
checking whether we are cross compiling... no. b7 }" q  c" k- a
checking for suffix of object files... o
& k- d( s, c6 d, r$ \  R7 D. M& Uchecking whether we are using the GNU C compiler... yes
1 S/ O6 y5 j7 {9 ]checking whether cc accepts -g... yes
5 B! a- D/ N$ B( j. Ichecking for cc option to accept ISO C89... none needed
$ o4 w0 R( I1 ?/ g7 E/ C' fchecking how to run the C preprocessor... cc -E
  m2 _4 t9 ?! B. |5 s  M5 rchecking for icc... no
' V1 G& n) _+ i2 X+ Cchecking for suncc... no' ^4 o1 S0 s# c) r3 F- I
checking for system library directory... lib
1 q% q+ H, {; ^% E9 M* dchecking if compiler supports -Wl,-rpath,... yes  o7 B# A$ Q6 Z( u0 U
checking build system type... x86_64-pc-linux-gnu: a- L, K  Q# ?+ q$ B0 g  J; t
checking host system type... x86_64-pc-linux-gnu& `- s0 U& ]# x, C& T
checking target system type... x86_64-pc-linux-gnu! ^! q6 \& L7 Q0 A0 w
checking for PHP prefix... /usr/local/php
9 ]) ^8 {, @- ^- s- @( Z  x  ichecking for PHP includes... -I/usr/local/php/include/php -I/usr/local/php/include/php/main -I/usr/local/php/include/php/TSRM -I/usr/local/php/include/php/Zend -I/usr/local/php/include/php/ext -I/usr/local/php/include/php/ext/date/lib
8 ?1 M/ [/ j3 p+ I8 cchecking for PHP extension directory... /usr/local/php/lib/php/extensions/no-debug-zts-20230831
; i, j) J1 r' M/ c2 ~2 Wchecking for PHP installed headers prefix... /usr/local/php/include/php5 g0 l& g" M& q( h% v  |
checking if debug is enabled... no
( L* q2 g+ E% p1 Dchecking if zts is enabled... yes
! r. ~. g* D! z  X1 |7 t8 fchecking for gawk... gawk$ W, g" R' M4 O7 W1 b" U( [7 z3 W; u
checking for GNU MP support... yes, shared) R( x; Z& L4 b' l
checking for __gmpz_rootrem in -lgmp... yes
( }& V! ]4 M8 l0 U0 uchecking for a sed that does not truncate output... /bin/sed& @6 o, j" A% A7 C/ [( C  L- z" i: N
checking for ld used by cc... /bin/ld
5 ?- S7 J% B' Z, p' |# Nchecking if the linker (/bin/ld) is GNU ld... yes
4 k) T  |5 x2 q! E3 wchecking for /bin/ld option to reload object files... -r4 b6 i/ [" A4 T: b
checking for BSD-compatible nm... /bin/nm -B. H0 T; a7 f" }" e3 k2 W: S3 s
checking whether ln -s works... yes9 V! r8 K: D) P( |- k
checking how to recognize dependent libraries... pass_all
9 E; f; ^& T& T3 R$ q  U1 wchecking for ANSI C header files... yes
! W7 P. ?: L/ e1 u) jchecking for sys/types.h... yes% W! {1 E, S) r0 G! ]
checking for sys/stat.h... yes
( K+ \. o5 x: d/ Y2 y9 @8 f5 M0 Qchecking for stdlib.h... yes! @2 k; Q7 T; k6 [- l- E
checking for string.h... yes4 i& f/ N( u3 r# _2 O& S- m, m1 H
checking for memory.h... yes" k0 m9 I; r( I8 v- _4 H0 F
checking for strings.h... yes
" |7 v* S' e6 F8 y- zchecking for inttypes.h... yes) i+ [9 X0 w* L* C4 q
checking for stdint.h... yes
+ l6 J% K8 E+ U6 M. l4 @5 g" Fchecking for unistd.h... yes
0 C! q5 W. E1 q# x( d, Echecking dlfcn.h usability... yes
; p# s& S" Y+ ]. t. t5 @8 i* j; @/ ochecking dlfcn.h presence... yes7 _2 x8 b( f( `) p: A8 [1 U
checking for dlfcn.h... yes- E  q4 q+ Z4 v
checking the maximum length of command line arguments... 1572864
7 H% o* ]; ~0 C% }- ]/ Q: V; wchecking command to parse /bin/nm -B output from cc object... ok7 r7 M9 ]4 {4 @6 t! V5 ]
checking for objdir... .libs. b  j& W0 ]6 v( y7 C
checking for ar... ar& {, d9 E  O/ b% P2 }
checking for ranlib... ranlib
, b: a  r7 u  @' l  H3 u1 K% Z5 ochecking for strip... strip1 l. m$ |+ u7 i( Y$ E
checking if cc supports -fno-rtti -fno-exceptions... no
% p+ V9 V* O9 n3 x7 i+ Qchecking for cc option to produce PIC... -fPIC
5 c; N& S, _6 Q& P% q: ochecking if cc PIC flag -fPIC works... yes7 ^1 w, {- x9 U9 A$ r7 X8 |
checking if cc static flag -static works... no
- u0 j6 z9 O, Z1 E$ \# S( Xchecking if cc supports -c -o file.o... yes
8 k2 c( g. u" q6 p& Wchecking whether the cc linker (/bin/ld -m elf_x86_64) supports shared libraries... yes, ]9 V7 \8 c0 h  g7 j& d% {, v, o
checking whether -lc should be explicitly linked in... no, `3 t2 G7 w$ r6 m
checking dynamic linker characteristics... GNU/Linux ld.so1 q' ?, r' R/ v5 g
checking how to hardcode library paths into programs... immediate0 w! P! g: @+ u4 n% q/ p; p$ b0 N
checking whether stripping libraries is possible... yes: Z; U1 X! q( ]9 r5 J% n6 W  v
checking if libtool supports shared libraries... yes
6 c  a! q" |6 T% I, c3 tchecking whether to build shared libraries... yes
/ Y+ D. U5 L4 z1 E0 X% Dchecking whether to build static libraries... no0 A1 f# ]3 A" W6 |' T

7 @6 J$ M4 K8 G7 }# j) xcreating libtool
$ k  h1 k! P1 l- c0 zappending configuration tag "CXX" to libtool8 |5 z$ T" h+ V) E0 s, w. d
configure: patching config.h.in: {% A. f: r) J5 |8 K& u
configure: creating ./config.status
3 d. k5 H( X, J& _& w  Z- C1 V2 g0 vconfig.status: creating config.h4 }3 z2 G% r, j% J- ^

! u+ ^' l8 M9 u7 J- R! T' s
您需要登录后才可以回帖 登录 | 注册

本版积分规则

返回首页|Archiver|手机版|小黑屋|易陆发现技术论坛 ( 蜀ICP备2026014127号-1 )

GMT+8, 2026-6-12 00:40 , Processed in 0.019496 second(s), 23 queries .

Powered by Discuz! X5.0

© 2001-2026 Discuz! Team.

快速回复 返回顶部 返回列表