search
HomeBackend DevelopmentPHP TutorialAfter compiling and installing PHP through the source code package php-5.4.9.tar.gz, how to load dynamic modules without reconfiguring PHP_PHP tutorial

First confirm: when we installed PHP, we specified its installation directory: --prefix=/var/lib/php5; and the directory /home/guanli/php-5.4.9 is after we decompressed .tar.gz The path, that is, the source code path.

For example, install the bcmath module

# cd /home/guanli/php-5.4.9/ext

# cd openssl

#mv vonfig0.m4 config.m4

# cd -

# cd bcmath

# /var/lib/php5/bin/phpize

An error message is displayed at this time:
Configuring for:
PHP Api Version: 20100412
Zend Module Api No: 20100525
Zend Extension Api No: 220100525
Cannot find autoconf. Please check your autoconf installation and the $PHP_AUTOCONF environment variable. Then, rerun this script.

# yum install autoconf

#/var/lib/php5/bin/phpize

# ./configure --with-php-config=/var/lib/php5/bin/php-config

# make

# make test

# make install

After execution, we will automatically be prompted to add the bcmath.so module to the path: /var/lib/php5/lib/php/extensions/no-debug-non-zts-20100525

Next, set the extension directory in php.ini:

If the location of the configuration file is not specified when compiling PHP, the default php.ini should be placed under /var/lib/php5/lib before it can be loaded. This has been discussed elsewhere.

We find ; extension_dir = "./", cancel the previous comment and change it to:

extension_dir = "/var/lib/php5/lib/php/extensions/no-debug-non-zts-20100525"

Add extension module reference again

extension = bcmath.so

At this point, restart the httpd service and verify through phpinfo() that the bcmath module has been successfully loaded.


www.bkjia.comtruehttp: //www.bkjia.com/PHPjc/477896.htmlTechArticleFirst confirm: when we install PHP, we specify its installation directory: --prefix=/var/lib /php5; and the directory /home/guanli/php-5.4.9 is the path after we unzip the .tar.gz, which is the source code...
Statement
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
为什么我的Go程序需要更长的时间来编译?为什么我的Go程序需要更长的时间来编译?Jun 09, 2023 pm 06:00 PM

近年来,Go语言已经成为了越来越多开发者的选择。但是,相比其他编程语言而言,Go语言的编译速度却不够快。很多开发者在编译Go程序时都会遇到这样的问题:为什么我的Go程序需要更长时间来编译?本文将会从几个方面探讨这个问题。Go语言的编译器架构Go语言的编译器架构采用的是三阶段设计,分别是前端、中间层和后端。前端负责将源代码翻译成Go语言的中间代码,中间层则将中

Java 中的编译和反编译技术Java 中的编译和反编译技术Jun 09, 2023 am 09:43 AM

Java是一种非常流行的编程语言,广泛应用于开发各种类型的软件。在Java开发中,编译和反编译技术是非常重要的环节。编译技术用于将Java代码转换成可执行文件,而反编译技术则允许人们将可执行文件重新转换回Java代码。本文将介绍Java中的编译和反编译技术。一、编译技术编译是将高级语言(如Java)代码转换为机器语言的过程。在Java

linux为什么要编译源码linux为什么要编译源码Mar 17, 2023 am 10:21 AM

原因:1、Linux发型版本众多,但是每个版本采用的软件或者内核版本都不一样,而二进制包所依赖的环境不一定能够正常运行,所以大部分软件直接提供源码进行编译安装。2、方便定制,满足不同的需求。3、方便运维、开发人员维护;源码是可以打包二进制的,但是对于这个软件的打包都会有一份代价不小的额外工作,包括维护,所以如果是源码的话,软件产商会直接维护。

Python在软件源码保护中的应用实践Python在软件源码保护中的应用实践Jun 29, 2023 am 11:20 AM

Python语言作为一种高级编程语言,具有简单易学、易读易写等特点,在软件开发领域中得到了广泛的应用。然而,由于Python的开源特性,源代码很容易被他人轻易获取,这就给软件源码保护带来了一些挑战。因此,在实际应用中,我们常常需要采取一些方法来保护Python源代码,确保其安全性。在软件源码保护中,有多种针对Python的应用实践可供选择。下面将介绍几种常见

改进编程效率:最佳化Golang包的使用方式改进编程效率:最佳化Golang包的使用方式Jan 16, 2024 am 10:46 AM

随着人工智能和云计算的不断发展,软件开发在当今的商业世界中已经成为至关重要的一部分。而作为一种高效、可扩展性强的编程语言,Golang越来越受到软件开发者的青睐。但是,即使是使用Golang,开发人员也要始终守护着程序执行效率的标准。在这篇文章中,我们将着重探讨如何通过优化Golang包的使用方法,提升编程效率。并且,我们会提供代码示例来帮助读者更好地理解这

go语言能不能编译go语言能不能编译Dec 09, 2022 pm 06:20 PM

go语言能编译。Go语言是编译型的静态语言,是一门需要编译才能运行的编程语言。对Go语言程序进行编译的命令有两种:1、“go build”命令,可以将Go语言程序代码编译成二进制的可执行文件,但该二进制文件需要手动运行;2、“go run”命令,会在编译后直接运行Go语言程序,编译过程中会产生一个临时文件,但不会生成可执行文件。

网站在线看源码网站在线看源码Jan 10, 2024 pm 03:31 PM

可以使用浏览器的开发者工具来查看网站的源代码,在Google Chrome浏览器中:1、打开 Chrome 浏览器,访问要查看源代码的网站;2、右键单击网页上的任何位置,然后选择“检查”或按下快捷键 Ctrl + Shift + I打开开发者工具;3、在开发者工具的顶部菜单栏中,选择“Elements”选项卡;4、看到网站的 HTML 和 CSS 代码即可。

PHP代码在浏览器中如何显示源码而不被解释执行?PHP代码在浏览器中如何显示源码而不被解释执行?Mar 11, 2024 am 10:54 AM

PHP代码在浏览器中如何显示源码而不被解释执行?PHP是一种服务器端脚本语言,通常用于开发动态网页。当PHP文件在服务器上被请求时,服务器会解释执行其中的PHP代码,并将最终的HTML内容发送到浏览器以供显示。然而,有时我们希望在浏览器中直接展示PHP文件的源代码,而不是被执行。本文将介绍如何在浏览器中显示PHP代码的源码,而不被解释执行。在PHP中,可以使

See all articles

Hot AI Tools

Undresser.AI Undress

Undresser.AI Undress

AI-powered app for creating realistic nude photos

AI Clothes Remover

AI Clothes Remover

Online AI tool for removing clothes from photos.

Undress AI Tool

Undress AI Tool

Undress images for free

Clothoff.io

Clothoff.io

AI clothes remover

AI Hentai Generator

AI Hentai Generator

Generate AI Hentai for free.

Hot Article

R.E.P.O. Energy Crystals Explained and What They Do (Yellow Crystal)
2 weeks agoBy尊渡假赌尊渡假赌尊渡假赌
R.E.P.O. Best Graphic Settings
2 weeks agoBy尊渡假赌尊渡假赌尊渡假赌
R.E.P.O. How to Fix Audio if You Can't Hear Anyone
2 weeks agoBy尊渡假赌尊渡假赌尊渡假赌

Hot Tools

SublimeText3 Chinese version

SublimeText3 Chinese version

Chinese version, very easy to use

mPDF

mPDF

mPDF is a PHP library that can generate PDF files from UTF-8 encoded HTML. The original author, Ian Back, wrote mPDF to output PDF files "on the fly" from his website and handle different languages. It is slower than original scripts like HTML2FPDF and produces larger files when using Unicode fonts, but supports CSS styles etc. and has a lot of enhancements. Supports almost all languages, including RTL (Arabic and Hebrew) and CJK (Chinese, Japanese and Korean). Supports nested block-level elements (such as P, DIV),

Notepad++7.3.1

Notepad++7.3.1

Easy-to-use and free code editor

DVWA

DVWA

Damn Vulnerable Web App (DVWA) is a PHP/MySQL web application that is very vulnerable. Its main goals are to be an aid for security professionals to test their skills and tools in a legal environment, to help web developers better understand the process of securing web applications, and to help teachers/students teach/learn in a classroom environment Web application security. The goal of DVWA is to practice some of the most common web vulnerabilities through a simple and straightforward interface, with varying degrees of difficulty. Please note that this software

SecLists

SecLists

SecLists is the ultimate security tester's companion. It is a collection of various types of lists that are frequently used during security assessments, all in one place. SecLists helps make security testing more efficient and productive by conveniently providing all the lists a security tester might need. List types include usernames, passwords, URLs, fuzzing payloads, sensitive data patterns, web shells, and more. The tester can simply pull this repository onto a new test machine and he will have access to every type of list he needs.