找回密码
 注册
查看: 7|回复: 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
2 N/ K" g" u+ O  ~: W" Qconfigure: error: GNU MP Library version 4.2 or greater required.5 ~1 u* K+ S  b& P2 O& |7 W

2 {6 `, u$ e. I' Q: S
+ ]* H6 f& o* G) E  Lconfigure: error: GNU MP Library version 4.2 or greater required.$ Q' N: d4 Q! k" ]& {0 p
解决:
) E8 R1 {. a& f7 R6 y  y# T, M#yum -y install gmp-devel
# g; C# H7 a: F; C' ]) U
% N( g+ K  E! x; @/ }6 y- I8 r8 f2 F  ?& h3 z  R
' a; Z# m2 `8 P- o& T% Y3 ?
[root@ipam2 gmp]# ./configure --with-php-config=/usr/local/php/bin/php-config
( X5 O8 D" j7 Hchecking for grep that handles long lines and -e... /bin/grep* v2 }6 Q5 B& C  B3 W2 N
checking for egrep... /bin/grep -E+ w5 r3 P; I; _& O7 t; q9 @+ I$ X7 W$ p" q
checking for a sed that does not truncate output... /bin/sed
3 `# U  R) ^5 ?/ `, x* I  k- b' U1 nchecking for pkg-config... /bin/pkg-config# F! V2 U- _5 D, q" @2 X9 }0 Y$ B; Y- m
checking pkg-config is at least version 0.9.0... yes
9 H2 W9 @& H/ r5 H: d, Y: Zchecking for cc... cc
% }4 G4 j2 z3 A, |$ Hchecking whether the C compiler works... yes% C7 e" _' h1 Z6 Y3 C. F: o/ S
checking for C compiler default output file name... a.out
, I7 n! a8 A4 |5 Ychecking for suffix of executables...
/ Q% Z5 O" R8 a5 p0 Z" [checking whether we are cross compiling... no5 m5 u# A# H% c8 v& O  ?" U& O
checking for suffix of object files... o
& B- q( F8 P/ V2 z- y# T( rchecking whether we are using the GNU C compiler... yes. q. P; T7 Z, V- I  Y* k
checking whether cc accepts -g... yes
! O5 G5 E0 r4 Z! kchecking for cc option to accept ISO C89... none needed* d( W; r9 ]7 i  ~! h
checking how to run the C preprocessor... cc -E* E' N: r/ r& s  h0 @* X3 `
checking for icc... no
8 L% ^. ~6 y! p/ a; ?( Fchecking for suncc... no
) A" W8 u' c6 ~  pchecking for system library directory... lib5 R5 f1 @6 \8 R2 L
checking if compiler supports -Wl,-rpath,... yes
7 W, U% i8 p/ i- z( Echecking build system type... x86_64-pc-linux-gnu4 H$ u5 X) z% v2 m8 Y! z0 d
checking host system type... x86_64-pc-linux-gnu
$ x' L9 h6 v2 N6 l" c: kchecking target system type... x86_64-pc-linux-gnu& J) g1 L- T. x8 t
checking for PHP prefix... /usr/local/php
; d6 S7 `" t$ z* ~) K( w5 lchecking 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) S4 R5 p; W5 a
checking for PHP extension directory... /usr/local/php/lib/php/extensions/no-debug-zts-20230831
+ {2 o7 Y# p% c1 _! K: s8 Jchecking for PHP installed headers prefix... /usr/local/php/include/php
  R, {" d' p. i# F6 ?- cchecking if debug is enabled... no
& f* ?4 ?0 h. \# L! }7 D4 }! o6 {* hchecking if zts is enabled... yes* b. n3 [. L% n2 E
checking for gawk... gawk' u+ G) G: U* S" p+ ]
checking for GNU MP support... yes, shared3 f1 \# E( R) M' D8 @
checking for __gmpz_rootrem in -lgmp... no1 v2 D: }) g8 U
configure: error: GNU MP Library version 4.2 or greater required.5 S5 d# z0 \* w2 U
[root@ipam2 gmp]# yum install -y gmp-dev! c2 l9 A* h. g
Loaded plugins: fastestmirror% p. m2 U' @5 O7 c% `$ g. K
Loading mirror speeds from cached hostfile  ^& O8 x( r% s  n
epel/x86_64/metalink                                                                                                                         | 6.4 kB  00:00:00     
5 X4 m  p7 u2 r% `9 W9 T- j' m * base: ftp.sjtu.edu.cn
6 a5 m- w  ~0 k& Y* _% A * epel: ftp.iij.ad.jp# I! F  R8 y9 \. n1 S: o" R# z& {- F
* extras: ftp.sjtu.edu.cn
. m, |" M+ z6 m) ~4 v * updates: mirrors.163.com
; _) q: @* r8 ?% e" vbase                                                                                                                                         | 3.6 kB  00:00:00     
4 x* [5 @* P' uepel                                                                                                                                         | 4.7 kB  00:00:00     
% s! R/ @& [8 v" R# Cextras                                                                                                                                       | 2.9 kB  00:00:00       ?2 ]" c' J0 J  h: Z) M
updates                                                                                                                                      | 2.9 kB  00:00:00     ! {8 Q; c* j1 D/ h
No package gmp-dev available.
2 p/ J  x8 Y: \$ d  l- mError: Nothing to do
% w6 t7 f6 @5 ^1 i' s[root@ipam2 gmp]# yum -y install gmp-devel
4 R$ h& M1 G$ t5 d+ \4 ELoaded plugins: fastestmirror: X' h, N7 ]2 H$ X) {! M! D) `0 x
Loading mirror speeds from cached hostfile' E! p) B3 G- z: i% _
* base: ftp.sjtu.edu.cn
* M; C+ H/ @, M$ T * epel: ftp.iij.ad.jp
/ w5 X5 i; q7 s$ W0 T" t( T * extras: ftp.sjtu.edu.cn6 R" T9 [) T: ?5 c6 o
* updates: mirrors.163.com1 Q; I' `& H) s- z6 z
Resolving Dependencies
) A5 _/ x! G, v* N' L8 ?4 v- g+ G( [--> Running transaction check
: O7 B$ V( X5 Q---> Package gmp-devel.x86_64 1:6.0.0-15.el7 will be installed; p! X. T" [5 v9 y. I/ T
--> Finished Dependency Resolution9 x$ u9 R) n# p4 g# U

' k8 f0 j+ t* o$ ^& `Dependencies Resolved
% y9 }* b! |4 j3 M# {' c
7 |9 N7 |1 d6 R) w7 j. r% U* x====================================================================================================================================================================
( D" n- q- |- `# {3 Y; K, y  @8 s Package                                 Arch                                 Version                                      Repository                          Size
' A/ L& f$ n- [; m====================================================================================================================================================================6 K& g. j$ J( x# @  ~
Installing:
& V! D! j4 \* E9 P, ] gmp-devel                               x86_64                               1:6.0.0-15.el7                               base                               181 k0 Z- |7 e$ b1 @3 o; L, q! O7 A3 |
" H8 F; G$ T& L: y5 T) L) _! b5 ^
Transaction Summary! R9 E4 H+ w; j2 a. i- ]
====================================================================================================================================================================: B! C" v1 @& M6 o! c7 {7 J
Install  1 Package
$ z8 u7 j, @  F! H' X
- X2 S3 @4 {7 d$ KTotal download size: 181 k$ d- q& y- b# [: {- K: \
Installed size: 340 k6 _- Q, j: ?2 S9 J8 g$ Y" _
Downloading packages:
" q4 P" ~" V. ~& H; kgmp-devel-6.0.0-15.el7.x86_64.rpm                                                                                                            | 181 kB  00:00:00     0 Y* N& H% H' Q0 i
Running transaction check# P! T* x# I( r, G' j4 J
Running transaction test
* f0 @) V# A$ `, }9 A" y( UTransaction test succeeded
! Z1 N2 @* y5 ^- k& kRunning transaction) R+ c/ M1 a% \* e4 t$ q4 `" M
Warning: RPMDB altered outside of yum., s0 Z- B8 m9 j/ @! }
** Found 2 pre-existing rpmdb problem(s), 'yum check' output follows:* g- z  C% s! J& ]" q
2:postfix-2.10.1-9.el7.x86_64 has missing requires of libmysqlclient.so.18()(64bit)! c- D: U  c2 D6 Z" S3 Z
2:postfix-2.10.1-9.el7.x86_64 has missing requires of libmysqlclient.so.18(libmysqlclient_18)(64bit)7 [& ]% `: j0 T4 C! m2 v" Y1 @. q
  Installing : 1:gmp-devel-6.0.0-15.el7.x86_64                                                                                                                  1/1 ' z' A5 Q" z; z, r2 Z
  Verifying  : 1:gmp-devel-6.0.0-15.el7.x86_64                                                                                                                  1/1
0 v$ L5 ~; B5 X9 P
/ P3 Q" G8 I2 Q2 lInstalled:
8 \( w. S  P' X, B  gmp-devel.x86_64 1:6.0.0-15.el7                                                                                                                                   2 s( m+ u- m% n/ ]. `

/ g  p/ p4 o' g# TComplete!
8 J$ s# l  X: q$ F" c[root@ipam2 gmp]# ./configure --with-php-config=/usr/local/php/bin/php-config + n4 x8 X0 s9 A) v' \. [* F0 o
checking for grep that handles long lines and -e... /bin/grep/ k, }3 `3 X6 k4 s
checking for egrep... /bin/grep -E
/ i. }4 g$ s- E3 z/ O9 O% A) h4 echecking for a sed that does not truncate output... /bin/sed( u3 `0 @$ Z% {
checking for pkg-config... /bin/pkg-config% U' @& B1 Y3 }4 O$ l/ o
checking pkg-config is at least version 0.9.0... yes9 P% _% J' m* u, Z: [, f7 T  X6 P
checking for cc... cc
3 C/ c. S+ A" `4 i* V/ p& _0 s, Xchecking whether the C compiler works... yes! R8 {8 h" z# W$ ~3 c% _; x: G
checking for C compiler default output file name... a.out
5 P9 x- R* ^5 G9 [# y& Lchecking for suffix of executables... : u5 a9 b  A- G; |8 \- V9 Z
checking whether we are cross compiling... no% p6 L9 W+ y) q& Z  ]
checking for suffix of object files... o5 n: }  w: n+ I! z+ x$ Y
checking whether we are using the GNU C compiler... yes
) @3 R" I. q2 q4 a. Tchecking whether cc accepts -g... yes% K" b# _# W0 G2 e% d# a
checking for cc option to accept ISO C89... none needed; F7 q/ q8 e2 c1 r5 B0 {
checking how to run the C preprocessor... cc -E# f+ r. P3 e$ S) r
checking for icc... no4 g# Y, H3 C& z" a0 [! ?8 }
checking for suncc... no
3 }# r3 W0 D  v3 W; Schecking for system library directory... lib* E$ q! ?8 a5 l8 v2 `; k1 A' `
checking if compiler supports -Wl,-rpath,... yes+ `5 K; |. {1 M0 a, y% {7 l
checking build system type... x86_64-pc-linux-gnu/ e% ]/ g6 j1 d. f7 P2 B
checking host system type... x86_64-pc-linux-gnu( \, X- r4 H4 g1 @5 }
checking target system type... x86_64-pc-linux-gnu
3 `! m5 k, D+ schecking for PHP prefix... /usr/local/php
9 @/ D1 V5 k1 [* X' achecking 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/lib1 I. ?0 z6 G8 r3 V
checking for PHP extension directory... /usr/local/php/lib/php/extensions/no-debug-zts-20230831
2 |' ]" e# Y3 H* A3 X/ U; T9 e  cchecking for PHP installed headers prefix... /usr/local/php/include/php8 U$ I3 H: y/ P3 ^* E+ m  W& ?
checking if debug is enabled... no
/ m4 Y& H; }, U- C' ochecking if zts is enabled... yes+ f4 N, ~" j- a0 ]: o
checking for gawk... gawk3 K# {7 U. M+ v9 a+ m) q  @; M
checking for GNU MP support... yes, shared
/ `' |7 Q$ x5 z1 l* I% schecking for __gmpz_rootrem in -lgmp... yes( Q' ^. ^! V8 _% \# z
checking for a sed that does not truncate output... /bin/sed* F. E  ~) I" J: e% o6 k, Q- ^
checking for ld used by cc... /bin/ld
% s% p& X2 Z. Q  [, o. gchecking if the linker (/bin/ld) is GNU ld... yes& x! Y! l! `6 @% @1 G
checking for /bin/ld option to reload object files... -r' G, {$ q6 ]5 D/ ]6 h
checking for BSD-compatible nm... /bin/nm -B
, _$ g$ a  E/ c( H, [checking whether ln -s works... yes
0 H8 S4 U; n6 X7 a2 _, Y/ S) n. ?checking how to recognize dependent libraries... pass_all
. Y5 A1 B9 z' n7 nchecking for ANSI C header files... yes
4 M: D7 C) `" _5 Nchecking for sys/types.h... yes
, k- ~/ ], E) _9 Z& B, u; y6 A" Gchecking for sys/stat.h... yes$ i) z& E5 x8 M- D& D( X! c
checking for stdlib.h... yes; {5 L, [# m- C# a4 f. Z9 t
checking for string.h... yes
' U# ^; ^* ^& O, l* Z! Schecking for memory.h... yes
* [& }% M! A& {& Lchecking for strings.h... yes$ T& t" u2 Q9 B
checking for inttypes.h... yes( _$ g/ V2 r% C1 T
checking for stdint.h... yes
7 ^: ]/ U1 c. v% R% `# ?* xchecking for unistd.h... yes
! ^$ B0 w; W, h& L' v) jchecking dlfcn.h usability... yes  p& ?4 C" w" d& B. Y
checking dlfcn.h presence... yes" J3 z4 h3 e* X/ b+ C$ g; Q
checking for dlfcn.h... yes
2 Z1 ~) \3 k/ A) F. nchecking the maximum length of command line arguments... 1572864
6 n7 G4 t, X" t, dchecking command to parse /bin/nm -B output from cc object... ok
1 i) f6 b9 J4 \checking for objdir... .libs  I7 g4 H; E) E6 t: Y# G7 F
checking for ar... ar/ y- e/ [/ L5 r; L2 `9 P
checking for ranlib... ranlib
2 V# E9 C0 @3 U3 T6 bchecking for strip... strip
# g9 ?( ~9 W" W+ x1 }+ R5 _9 Dchecking if cc supports -fno-rtti -fno-exceptions... no$ B4 k, x' Q0 p! b0 V! D/ S
checking for cc option to produce PIC... -fPIC
& ]  q5 U; ~& H$ v0 D+ M5 Gchecking if cc PIC flag -fPIC works... yes
: }1 t0 [! M9 b: B5 u6 c) a$ nchecking if cc static flag -static works... no' q; @% M5 d. V
checking if cc supports -c -o file.o... yes9 B/ r' W8 B9 A" x; A: H- x
checking whether the cc linker (/bin/ld -m elf_x86_64) supports shared libraries... yes
% F' A2 q. Y' x7 U0 Uchecking whether -lc should be explicitly linked in... no: M4 L; c$ U' S% W
checking dynamic linker characteristics... GNU/Linux ld.so
' |3 u) a4 P0 x/ K8 D8 rchecking how to hardcode library paths into programs... immediate
9 X9 i; U" c9 I1 [2 Q5 s. Y. Rchecking whether stripping libraries is possible... yes
1 F' S. e, c( E( l+ H% Tchecking if libtool supports shared libraries... yes# Z* I& [* g% `8 ]1 a
checking whether to build shared libraries... yes5 o( E9 S7 I5 T5 Y2 i" H& Y& w5 O
checking whether to build static libraries... no7 r- Q; O" }5 o' A( D& ?3 n5 n

: h! g5 V  D; ]& {creating libtool
& D" T. x2 j; B% M; uappending configuration tag "CXX" to libtool8 U6 b' c3 h, h& V
configure: patching config.h.in
" U# n5 [" s) x0 H& J) Vconfigure: creating ./config.status
+ F2 b$ m5 D4 T7 y. h0 iconfig.status: creating config.h
0 o: [0 }7 @7 v, J9 l7 ]

9 r/ q8 t* D7 c+ t
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

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

Powered by Discuz! X5.0

© 2001-2026 Discuz! Team.

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