先编译安装php-7.2.24,然后编译安装扩展

主版本地址地址:https://www.php.net/distributions/php-7.2.24.tar.gz

# 编译 php-7.2.24 参数
./configure  --prefix=/usr/local/php-7.2.24_fpm --with-config-file-path=/usr/local/php-7.2.24_fpm/etc --with-openssl=/usr/local/lab/openssl-1.0.2p --with-libxml-dir=/usr --with-zlib-dir=/usr/local/lab/zlib-1.2.11 --with-bz2 --enable-calendar --with-curl=/usr/local/lab/curl-7.36.0 --enable-dba --enable-exif --enable-ftp --with-jpeg-dir=/usr/local/lab/jpeg-9b --with-png-dir=/usr/local/lab/libpng-1.6.10/ --with-freetype-dir=/usr/local/lab/freetype-2.5.4 --with-gd=/usr/local/lab/libgd-2.1.1 --with-gettext --enable-mbstring --with-ldap=/usr/local/openldap-2.4.23 --with-mcrypt=/usr/local/lab/libmcrypt-2.5.8_php7.2 --with-mhash=/usr/local/lab/mhash-0.9.9.9 --with-mysql=mysqlnd --with-mysqli=mysqlnd --with-pdo-mysql=mysqlnd --with-unixODBC=/usr/local/lab/unixODBC-2.3.2 --with-pdo-dblib=/usr/local/lab/freetds-0.92 --enable-zip --with-iconv-dir=/usr/local/lab/libiconv-1.14 --with-fpm-user=apache --with-fpm-group=users --enable-fpm --with-xmlrpc --enable-soap --enable-mbregex --enable-opcache --enable-inline-optimization --enable-xml --enable-sockets --disable-debug --enable-pcntl --enable-shmop
# make && make install

注意:在centos7上编译的php-7.2.24程序,直接拷贝到centos6中无法运行,提示缺少一些组件,需要升级glibc和gcc等底层的软件,建议不要升级glibc和gcc可能引发其他应用故障,如果是centos6,直接在centos6中编译后运行

扩展包的下载地址:
http://pecl.php.net/package-stats.php

# openssl的编译(经过测试1.1.10i 这个版本问题太多,舍弃,使用1.0.2p)

cd /usr/local/src && wget https://www.openssl.org/source/openssl-1.1.0i.tar.gz --no-check-certificate
tar -xzf /usr/local/lab/openssl-1.1.0i.tar.gz
cd /usr/local/lab/openssl-1.1.0i
./config --prefix=/usr/local/lab/openssl-1.1.0i
make && make install

# openssl-OpenSSL_1_0_2p编译安装
unzip openssl-OpenSSL_1_0_2p.zip
cd openssl-OpenSSL_1_0_2p
./config --prefix=/usr/local/lab/openssl-1.0.2p
make && make install

wget https://www.openssl.org/source/openssl-1.0.2p.tar.gz

./config --prefix=/usr/local/lab/openssl-1.0.2p/openssl-1.0.2p

###event安装记录
wget http://pecl.php.net/get/event-2.4.2.tgz
tar -zxf event-2.4.2.tgz
cd event-2.4.2
/usr/local/php/bin/phpize
./configure --with-event-core --with-event-extra --enable-event-debug  --with-php-config=/usr/local/php/bin/php-config
make && make install

# zlib编译
cd /usr/local/src && wget http://www.zlib.net/zlib-1.2.11.tar.gz
tar -xvzf zlib-1.2.11.tar.gz
cd zlib-1.2.11
./configure --prefix=/usr/local/lab/zlib-1.2.11
make && make install

# 安装jpeg
#wget:http://ftp.gnu.org/gnu/libtool/libtool-2.2.6a.tar.gz
tar -zxf libtool-2.2.6a.tar.gz -C /usr/local/lab
cd /usr/local/lab/libtool-2.2.6
./configure
make && make install

然后进入jpeg-6b的源码目录,然后执行以下步骤,切记!COPY到当前目录注意后面的点(.)
网上好多都把config.sub和config.guess的路径弄错了,应该是在/usr/share/libtool/config/下,而不是在
/usr/share/libtool/下

cd jpeg
cp /usr/share/libtool/config/config.sub .
cp /usr/share/libtool/config/config.guess .

mkdir -p /usr/local/libjpeg-6b/bin
mkdir -p /usr/local/libjpeg-6b/lib
mkdir -p /usr/local/libjpeg-6b/man/man1

./configure --prefix=/usr/local/libjpeg-6b --enable-shared --enable-static
make && make install

# 安装freetype2.5.4
mkdir -p /usr/local/lab/freetype-2.5.4/include/freetype2/config
mkdir -p /usr/local/lab/freetype-2.5.4/include/freetype2/freetype/config
./configure --prefix=/usr/local/lab/freetype-2.5.4
make && make install

# php7.2安装mcrypt
tar -zxf mcrypt-1.0.1.tgz
cd mcrypt-1.0.1
# 在mcrypt-1.0.1目录下执行phpize命令,会生成configure命令
[root@ws_compile-release:/usr/local/src/mcrypt-1.0.1]# /usr/local/php-7.2.24_fpm/bin/phpize
Configuring for:
PHP Api Version:         20170718
Zend Module Api No:      20170718
Zend Extension Api No:   320170718

./configure --with-php-config=/usr/local/php-7.2.24_fpm/bin/php-config
make && make install

## Redis扩展
echo "*******************install Redis扩展 start*******************"
cd /usr/local/src && wget http://pecl.php.net/get/redis-4.1.1.tgz
tar -zxvf redis-4.1.1.tgz
cd redis-4.1.1/
/usr/local/php/bin/phpize
./configure --with-php-config=/usr/local/php/bin/php-config
make && make install

## SeasLog扩展
[root@web01:/usr/local/src]# tar -zxf SeasLog-1.8.6.tgz
[root@web01:/usr/local/src]# cd SeasLog-1.8.6
[root@web01:/usr/local/src/SeasLog-1.8.6]# /usr/local/php-7.2.11_fpm/bin/phpize
Configuring for:
PHP Api Version:         20170718
Zend Module Api No:      20170718
Zend Extension Api No:   320170718
[root@web01:/usr/local/src/SeasLog-1.8.6]# ./configure --with-php-config=/usr/local/php-7.2.11_fpm/bin/php-config
[root@web01:/usr/local/src/SeasLog-1.8.6]# make && make install

### memcached扩展
# 编译安装libmemcached-1.0.18
tar -zxf libmemcached-1.0.18.tar.gz
cd libmemcached-1.0.18
./configure --prefix=/usr/local/lab/libmemcached-1.0.18 --with-memcached

# 安装php-memcached扩展
php使用memcache的扩展有两个,一个memcache,一个memcached,前者比较老,推荐使用第二个,我们这里以第二个为例:

在github上找到适用于php7的分支https://github.com/php-memcached-dev/php-memcached/tree/php7

# 解压
unzip php-memcached-php7.zip
cd php-memcached-php7

# 执行phpize会生成configure文件
/usr/local/php/bin/phpize
# 执行预编译
./configure --enable-memcached --with-php-config=/usr/local/php/bin/php-config --with-libmemcached-dir=/usr/local/lab/libmemcached-1.0.18 --disable-memcached-sasl
make && make install

# 安装rar扩展
tar -zxf rar-4.0.0.tgz
cd rar-4.0.0
/usr/local/php/bin/phpize
./configure --with-php-config=/usr/local/php/bin/php-config
make && make install

# php7.2.24安装swoole扩展

# wget https://github.com/swoole/swoole-src/archive/v4.4.15.tar.gz
# /usr/local/php-7.2.24_fpm/bin/phpize
# ./configure --with-php-config=/usr/local/php-7.2.24_fpm/bin/php-config
# make && make install

####安装zmq扩展

1.到zeromq官网查看版本信息:http://zeromq.org/intro:get-the-software

2.Linux服务器跟目录下依次执行以下命令:

wget https://github.com/zeromq/libzmq/releases/download/v4.2.2/zeromq-4.2.5.tar.gz

tar zxvf zeromq-4.2.5.tar.gz
cd zeromq-4.2.5
./configure
make
make install

3.切回根目录,执行以下步骤:

下载https://codeload.github.com/mkoppanen/php-zmq/zip/master/php-zmq-master.zip
unzip php-zmq-master.zip
cd php-zmq-master
/usr/local/php/bin/phpize
./configure --with-php-config=/usr/local/php/bin/php-config
make
make install

# 编辑php配置文件,在最后面加入
# vim /usr/local/php/etc/php.ini

extension=zmq.so

# 编辑php.ini文件添加扩展,并重启php-fpm

extension=rar.so
extension=memcache.so
extension=memcached.so
extension=redis.so
extension=seaslog.so
extension=pcntl.so
extension=rar.so
extension=mcrypt.so

###编译安装bcmath
1.进入PHP源码包目录下的ext/bcmath目录
2.执行phpize命令,phpize命令在PHP安装目录的bin目录下,如 /usr/local/php/bin/phpize
3.执行./configure --with-php-config=/usr/local/php/bin/php-config
make && make install

####安装 amqp扩展
# 安装前要先安装rabbitmq-c
wget -c https://github.com/alanxz/rabbitmq-c/releases/download/v0.8.0/rabbitmq-c-0.8.0.tar.gz
tar zxf rabbitmq-c-0.8.0.tar.gz
cd rabbitmq-c-0.8.0
./configure --prefix=/usr/local/rabbitmq-c-0.8.0
make && make install

# 安装amqp
tar zxf amqp-1.9.3.tgz
cd amqp-1.9.3
/usr/local/php/bin/phpize
./configure --with-php-config=/usr/local/php/bin/php-config --with-amqp --with-librabbitmq-dir=/usr/local/rabbitmq-c-0.8.0
make && make install

# 安装amqp的时候报错:
 cc -I. -I/usr/local/src/amqp-1.9.3 -DPHP_ATOM_INC -I/usr/local/src/amqp-1.9.3/include -I/usr/local/src/amqp-1.9.3/main -I/usr/local/src/amqp-1.9.3 -I/usr/local/php-7.2.11_fpm/include/php -I/usr/local/php-7.2.11_fpm/include/php/main -I/usr/local/php-7.2.11_fpm/include/php/TSRM -I/usr/local/php-7.2.11_fpm/include/php/Zend -I/usr/local/php-7.2.11_fpm/include/php/ext -I/usr/local/php-7.2.11_fpm/include/php/ext/date/lib -I/usr/local/rabbitmq-c-0.8.0//include -DHAVE_CONFIG_H -g -O2 -c /usr/local/src/amqp-1.9.3/amqp_connection_resource.c  -fPIC -DPIC -o .libs/amqp_connection_resource.o
/usr/local/src/amqp-1.9.3/amqp_connection_resource.c:45:29: error: amqp_ssl_socket.h: No such file or directory
/usr/local/src/amqp-1.9.3/amqp_connection_resource.c: In function ‘connection_resource_constructor’:
/usr/local/src/amqp-1.9.3/amqp_connection_resource.c:409: warning: assignment makes pointer from integer without a cast
make: *** [amqp_connection_resource.lo] Error 1

解决:

参考:https://github.com/alanxz/rabbitmq-c/issues/463
[root@sz_xx_cmsby01_11_99:/usr/local/src/amqp-1.9.3]# find /usr/local -name amqp_ssl_socket.h
/usr/local/src/rabbitmq-c-0.8.0/librabbitmq/amqp_ssl_socket.h
[root@sz_xx_cmsby01_11_99:/usr/local/src/amqp-1.9.3]# cp /usr/local/src/rabbitmq-c-0.8.0/librabbitmq/amqp_ssl_socket.h ./

# 重新make && make install 即可

# 安装memcache扩展
unzip pecl-memcache-NON_BLOCKING_IO_php7.zip
cd pecl-memcache-NON_BLOCKING_IO_php7
/usr/local/php/bin/phpize
./configure --with-php-config=/usr/local/php/bin/php-config
make
make install

####### 安装imap扩展
# 安装imap依赖

yum install -y libc-client-devel freetype-devel libcurl-devel libjpeg-turbo-devel openssl-devel libicu-devel libmcrypt-devel
ln -s /usr/lib64/libc-client.so /usr/lib/libc-client.so
cd /usr/local/src && tar -zxf  php-7.2.24.tar.gz
cd /usr/local/src/php-7.2.24/ext/imap
/usr/local/php/bin/phpize
./configure --with-php-config=/usr/local/php/bin/php-config --with-imap=/usr/lib64 --with-imap-ssl --with-kerberos
make && make install

#####安装mysql扩展
# 下载扩展地址,最上面最新的:http://git.php.net/?p=pecl/database/mysql.git;a=summary
unzip mysql-386776d.zip
cd mysql-386776d
/usr/local/php/bin/phpize
./configure --with-php-config=/usr/local/php/bin/php-config --with-mysql=mysqlnd
make && make install

# vim /usr/local/php-7.2.11_fpm/etc/php.ini
extension=mysql.so

#### 安装gmp扩展 php5.6.30为例
/usr/local/php5.6.30/bin/phpize
./configure --with-php-config=/usr/local/php5.6.30/bin/php-config --with-gmp

### 安装php7.2.24版本中自带的扩展intl

一.PHP intl 是国际化扩展,是ICU 库的一个包装器。所以在安装PHP intl扩展前要先安装ICU库,安装ICU库的具体步骤:

mkdir /usr/local/lab/icu
cd /usr/local/lab/icu
wget http://download.icu-project.org/files/icu4c/52.1/icu4c-52_1-src.tgz
tar xf icu4c-52_1-src.tgz
cd icu/source
./configure --prefix=/usr/local/lab/icu
make && make install
安装完毕:
注:icu版本你也可以去官网下载:http://site.icu-project.org/download  。--prefix=/usr/local/icu为icu的安装路径,也可以通过find /  -name  icu查找。

二.安装扩展intl.so

1。进入php7源码:cd /usr/local/src/php-7.2.24/ext/intl

2。运行:phpize ,找不到命令时,将路径补全:/usr/local/php/bin/phpize(是php的安装路径),出现如下:

[root@ws_compile-release:/usr/local/src/php-7.2.24/ext/intl]#  /usr/local/php/bin/phpize
Configuring for:
PHP Api Version:         20170718
Zend Module Api No:      20170718
Zend Extension Api No:   320170718

三。运行配置

./configure --enable-intl --with-icu-dir=/usr/local/lab/icu --with-php-config=/usr/local/php/bin/php-config
make && make install

注:前面路径为icu的安装路径,后面路径为php的安装路径

# 启动脚本

# cat /etc/init.d/php7.-fpm
#! /bin/sh ### BEGIN INIT INFO
# Provides: php-fpm
# Required-Start: $remote_fs $network
# Required-Stop: $remote_fs $network
# Default-Start:
# Default-Stop:
# Short-Description: starts php-fpm
# Description: starts the PHP FastCGI Process Manager daemon
### END INIT INFO prefix=/usr/local/php-7.2.24_fpm
exec_prefix=${prefix} php_fpm_BIN=${exec_prefix}/sbin/php-fpm
php_fpm_CONF=${prefix}/etc/php-fpm.conf
php_fpm_PID=${prefix}/var/run/php-fpm.pid php_opts="--fpm-config $php_fpm_CONF --pid $php_fpm_PID" wait_for_pid () {
try= while test $try -lt ; do case "$1" in
'created')
if [ -f "$2" ] ; then
try=''
break
fi
;; 'removed')
if [ ! -f "$2" ] ; then
try=''
break
fi
;;
esac echo -n .
try=`expr $try + `
sleep done } case "$1" in
start)
echo -n "Starting php-fpm " $php_fpm_BIN --daemonize $php_opts if [ "$?" != ] ; then
echo " failed"
exit
fi wait_for_pid created $php_fpm_PID if [ -n "$try" ] ; then
echo " failed"
exit
else
echo " done"
fi
;; stop)
echo -n "Gracefully shutting down php-fpm " if [ ! -r $php_fpm_PID ] ; then
echo "warning, no pid file found - php-fpm is not running ?"
exit
fi kill -QUIT `cat $php_fpm_PID` wait_for_pid removed $php_fpm_PID if [ -n "$try" ] ; then
echo " failed. Use force-quit"
exit
else
echo " done"
fi
;; force-quit)
echo -n "Terminating php-fpm " if [ ! -r $php_fpm_PID ] ; then
echo "warning, no pid file found - php-fpm is not running ?"
exit
fi kill -TERM `cat $php_fpm_PID` wait_for_pid removed $php_fpm_PID if [ -n "$try" ] ; then
echo " failed"
exit
else
echo " done"
fi
;; restart)
$ stop
$ start
;; reload) echo -n "Reload service php-fpm " if [ ! -r $php_fpm_PID ] ; then
echo "warning, no pid file found - php-fpm is not running ?"
exit
fi kill -USR2 `cat $php_fpm_PID` echo " done"
;; *)
echo "Usage: $0 {start|stop|force-quit|restart|reload}"
exit
;; esac

php.ini配置文件

[root@ws_compile-release:~]# egrep -v '^;|^$' /usr/local/php-7.2.24_fpm/etc/php.ini
[PHP]
engine = On
short_open_tag = On
asp_tags = Off
precision =
y2k_compliance = On
output_buffering =
zlib.output_compression = Off
implicit_flush = Off
unserialize_callback_func =
serialize_precision = -
allow_call_time_pass_reference = Off
safe_mode = Off
safe_mode_gid = Off
safe_mode_allowed_env_vars = PHP_
safe_mode_protected_env_vars = LD_LIBRARY_PATH
disable_functions = passthru,shell_exec
disable_classes =
expose_php = Off
max_execution_time =
max_input_time =
memory_limit = 256M
error_reporting = E_ALL & ~E_DEPRECATED & ~(E_NOTICE) & ~(E_WARNING)
display_errors = Off
display_startup_errors = Off
log_errors = On
log_errors_max_len =
ignore_repeated_errors = Off
ignore_repeated_source = Off
report_memleaks = On
track_errors = Off
html_errors = Off
error_log = /data/www/logs/php_log/php_error.log
variables_order = "EGPCS"
request_order = "GP"
register_globals = Off
register_argc_argv = Off
auto_globals_jit = On
post_max_size = 50M
magic_quotes_runtime = Off
magic_quotes_sybase = Off
auto_prepend_file =
auto_append_file =
default_mimetype = "text/html"
doc_root =
user_dir =
enable_dl = On
file_uploads = On
upload_max_filesize = 50M
max_file_uploads =
allow_url_fopen = On
allow_url_include = Off
default_socket_timeout =
[Date]
date.timezone = America/Los_Angeles
[filter]
[iconv]
[intl]
[sqlite]
[sqlite3]
[Pcre]
[Pdo]
[Pdo_mysql]
pdo_mysql.cache_size =
pdo_mysql.default_socket=
[Phar]
[Syslog]
define_syslog_variables = Off
[mail function]
SMTP = localhost
smtp_port =
sendmail_path =/usr/sbin/sendmail -t -i
mail.add_x_header = On
[SQL]
sql.safe_mode = Off
[ODBC]
odbc.allow_persistent = On
odbc.check_persistent = On
odbc.max_persistent = -
odbc.max_links = -
odbc.defaultlrl =
odbc.defaultbinmode =
[Interbase]
ibase.allow_persistent =
ibase.max_persistent = -
ibase.max_links = -
ibase.timestampformat = "%Y-%m-%d %H:%M:%S"
ibase.dateformat = "%Y-%m-%d"
ibase.timeformat = "%H:%M:%S"
[MySQL]
mysql.allow_local_infile = On
mysql.allow_persistent = On
mysql.cache_size =
mysql.max_persistent = -
mysql.max_links = -
mysql.default_port =
mysql.default_socket =
mysql.default_host =
mysql.default_user =
mysql.default_password =
mysql.connect_timeout =
mysql.trace_mode = Off
[MySQLi]
mysqli.max_persistent = -
mysqli.allow_persistent = On
mysqli.max_links = -
mysqli.cache_size =
mysqli.default_port =
mysqli.default_socket =
mysqli.default_host =
mysqli.default_user =
mysqli.default_pw =
mysqli.reconnect = Off
[mysqlnd]
mysqlnd.collect_statistics = On
mysqlnd.collect_memory_statistics = Off
[OCI8]
[PostgresSQL]
pgsql.allow_persistent = On
pgsql.auto_reset_persistent = Off
pgsql.max_persistent = -
pgsql.max_links = -
pgsql.ignore_notice =
pgsql.log_notice =
[Sybase-CT]
sybct.allow_persistent = On
sybct.max_persistent = -
sybct.max_links = -
sybct.min_server_severity =
sybct.min_client_severity =
[bcmath]
bcmath.scale =
[browscap]
[Session]
session.save_handler = files
session.save_path = /tmp
session.use_cookies =
session.use_only_cookies =
session.name = PHPSESSID
session.auto_start =
session.cookie_lifetime =
session.cookie_path = /
session.cookie_domain =
session.cookie_httponly =
session.serialize_handler = php
session.gc_probability =
session.gc_divisor =
session.gc_maxlifetime =
session.bug_compat_42 = Off
session.bug_compat_warn = Off
session.referer_check =
session.entropy_length =
session.cache_limiter = nocache
session.cache_expire =
session.use_trans_sid =
session.hash_function =
session.hash_bits_per_character =
url_rewriter.tags = "a=href,area=href,frame=src,input=src,form=fakeentry"
[MSSQL]
mssql.allow_persistent = On
mssql.max_persistent = -
mssql.max_links = -
mssql.min_error_severity =
mssql.min_message_severity =
mssql.compatability_mode = Off
mssql.secure_connection = Off
[Assertion]
[COM]
[mbstring]
[gd]
[exif]
[Tidy]
tidy.clean_output = Off
[soap]
soap.wsdl_cache_enabled=
soap.wsdl_cache_dir="/tmp"
soap.wsdl_cache_ttl=
soap.wsdl_cache_limit =
[sysvshm]
[ldap]
ldap.max_links = -
[mcrypt]
[dba]
extension_dir=/usr/local/php-7.2.24_fpm/lib/php/extensions/no-debug-non-zts-/
extension=zmq.so
extension=memcached.so
extension=memcache.so
extension=redis.so
extension=rar.so
extension=mcrypt.so
extension=bcmath.so
extension=amqp.so
extension=imap.so
extension=intl.so
[opcache]
zend_extension=/usr/local/php-7.2.24_fpm/lib/php/extensions/no-debug-non-zts-/opcache.so
opcache.memory_consumption=
opcache.interned_strings_buffer=
opcache.max_accelerated_files=
opcache.revalidate_freq=
opcache.fast_shutdown=
opcache.enable_cli=
opcache.enable=
opcache.force_restart_timeout=
opcache.optimization_level=

centos7.6环境编译安装php-7.2.24修复最新 CVE-2019-11043 漏洞的更多相关文章

  1. centos7.2环境编译安装mysql5.5.48

    一.安装cmake编译工具 跨平台编译器 查看是否已经安装了gcc # rpm -qa | grep gcc # yum install -y gcc-c++ # yum install -y cma ...

  2. Centos7之LNMP环境编译安装

    Centos7之LNMP环境编译安装 一.系统环境准备 注:安装时间过长,只做参考!!!1.系统信息 [root@localhost ~]# uname -r 3.10.0-957.el7.x86_6 ...

  3. Centos7源码编译安装PHP7.2(生产环境)

    安装PHP依赖包,否则在编译的过程中可能会出现各种报错 # Centos 安装epel-release源并将系统包更新到最新版本 $ yum install epel-release-y $ yum ...

  4. centos7源码编译安装lamp/lnmp

    centos7源码编译安装lamp/lnmp 进程:是包工头(相当于是个门,只管开门关门,不管门内的事儿) 线程:是各种工种(cpu调度的是线程) 进程 是一件事情, 线程 是 同一个时间范围内 同时 ...

  5. centos7.2下编译安装&&使用-git代码库

    centos7.2下编译安装git Git简介 Git是一个分布式版本控制系统 Git vs SVN SVN是典型的集中式版本控制起,版本库集中存放在服务器,当我们用自己的电脑干活儿的时候,需要先从中 ...

  6. centos7.2环境下安装smokeping对网络状态进行监控

    centos7.2环境下安装smokeping对网络状态进行监控 安装smokeping建议用centos7,用centos6.5一直卡在smokeping那里,下载不了perl的扩展插件,可能是因为 ...

  7. CentOS-7.3.1611编译安装 Nginx-1.12.1+mysql-5.7.19+PHP-7.1.8+zabbix-3.4.1

    CentOS-7.3.1611编译安装 Nginx-1.12.1+mysql-5.7.19+PHP-7.1.8+zabbix-3.4.1 下载软件 1.下载nginx http://nginx.org ...

  8. centos7 源码编译安装TensorFlow CPU 版本

    一.前言 我们都知道,普通使用pip安装的TensorFlow是万金油版本,当你运行的时候,会提示你不是当前电脑中最优的版本,特别是CPU版本,没有使用指令集优化会让TensorFlow用起来更慢. ...

  9. CentOS7源码编译安装Postgresql9.5

    1.安装必要的基本软件 yum install -y gcc.x86_64 glibc.x86_64 glibc-devel.x86_64 vim-enhanced.x86_64 gcc-java a ...

随机推荐

  1. Kotlin反射重要组件与流程详解

    继续学习Kotlin反射,我们知道对于Java的反射类是Class,而在Kotlin中的反射类是KClass,而在Java当中对于反射中的方法是用Method,而在Kotlin中是用KFunction ...

  2. danci1

    oddball 英 ['ɒdbɔːl] 美 adj. 古怪的:奇怪的 n. 古怪:古怪的人 rather than 英 美 而不是:宁可…也不愿 grasp 英 [grɑːsp] 美 [ɡræsp] ...

  3. Linux——配置maven

    前言 Maven是一个项目管理工具,它包含了一个项目对象模型 (Project Object Model),一组标准集合,一个项目生命周期(Project Lifecycle),一个依赖管理系统(De ...

  4. 八.python文件操作

    一,初识文件操作. 引子: 现在这个世界上,如果可以操作文件的所有软件都消失了,比如word,wps等等,此时你的朋友通过qq给你发过来一个文件,文件名是:美女模特空姐护士联系方式.txt,在座的所有 ...

  5. LeetCode 923. 3Sum With Multiplicity

    原题链接在这里:https://leetcode.com/problems/3sum-with-multiplicity/ 题目: Given an integer array A, and an i ...

  6. MySQL 开启远程链接(localhost 以外的主机)

    1.在连接服务器后,操作mysql系统数据库 命令为:  mysql -u root -p use mysql: 查询用户表命令:select  User,authentication_string, ...

  7. 非旋转 treap

    其实之前学过一次非旋转 treap,但是全忘光了,今天复习一下. 洛谷 P3369 [模板]普通平衡树 code: #include <bits/stdc++.h> #define N 1 ...

  8. jedis的连接池

    1.需要先打开虚拟机,并开启Linux系统的端口号:6379: 其中,第一行代码为修改字符编码格式,解决SSH中文乱码问题. 2.开启redis: 3.利用连接池实现数据的存取: (1)代码实现: i ...

  9. 1-移远GSM/GPRS M26 模块 Mini板 开发板(使用说明)

    板子预览 引脚说明 供电 关于串口电压匹配引脚: 上面一版朋友测试反应的问题 (上面的内容不删除,因为已经出售了1套) 1,源码开发完以后,烧录完成 PWRKEY按键不能使用了,需要断电上电,那么就需 ...

  10. 【JOISC2018|2019】【20190622】mergers

    题目 一\(n\)个节点的树,节点被分成\(k\)个集合,\(i\)属于\(S_i\), 一条边是可划分的当且仅当左右两边的子树不存在相同集合的点 你一次可以合并两个集合,求最少的操作次数使得所有边都 ...