1.get sourse code
wget https://ftp.postgresql.org/pub/source/v9.6.1/postgresql-9.6.1.tar.gz
2.Unpack
tar -zxvf postgresql-9.6.1.tar.gz
[root@bzm soft_bak]# ll
total 24588
drwxrwxrwx. 6 1107 1107 4096 Oct 25 04:27 postgresql-9.6.1
-rw-r–r–. 1 root root 25172850 Dec 8 17:39 postgresql-9.6.1.tar.gz
3.configure
./configure –prefix=/opt/postgresql961 –with-pgport=1921 –without-ldap –with-libxml –with-libxslt –enable-thread-safety –with-wal-blocksize=16 –with-blocksize=16
–ERROR处理 DEMO:
configure: error: library ‘xslt’ is required for XSLT support
[root@bzm postgresql-9.6.1]# yum search xslt
Failed to set locale, defaulting to C
Loaded plugins: fastestmirror, langpacks
Loading mirror speeds from cached hostfile
* base: mirrors.yun-idc.com
* extras: mirrors.aliyun.com
* updates: mirrors.aliyun.com
==================================================================== N/S matched: xslt =====================================================================
libreoffice-xsltfilter.x86_64 : Optional xsltfilter module for LibreOffice
libxslt.i686 : Library providing the Gnome XSLT engine
libxslt.x86_64 : Library providing the Gnome XSLT engine
libxslt-devel.i686 : Development files for libxslt
libxslt-devel.x86_64 : Development files for libxslt
libxslt-python.x86_64 : Python bindings for the libxslt library
perl-XML-LibXSLT.x86_64 : Perl module for interfacing to GNOME’s libxslt
xalan-j2-xsltc.noarch : XSLT compiler
python-lxml.x86_64 : ElementTree-like Python bindings for libxml2 and libxslt
saxon.noarch : Java XPath, XSLT 2.0 and XQuery implementation
xalan-j2.noarch : Java XSLT processor
Name and summary matches only, use “search all” for everything.
[root@bzm postgresql-9.6.1]# yum install libxslt-devel.x86_64
4.gmake world (gmake 等价于 make)
5.*gmake check-world – (可选, 耗时较长)
6.gmake install-world
–很迷你的数据库文件大小啊
[root@bzm opt]# du -sm
46 .