源码安装swig

1. ./configure --prefix=/opt

报错:


configure: error: 

        Cannot find pcre-config script from PCRE (Perl Compatible Regular Expressions)

        library package. This dependency is needed for configure to complete,
        Either:
        - Install the PCRE developer package on your system (preferred approach).
        - Download the PCRE source tarball, build and install on your system
          as you would for any package built from source distribution.
        - Use the Tools/pcre-build.sh script to build PCRE just for SWIG to statically
          link against. Run 'Tools/pcre-build.sh --help' for instructions.
          (quite easy and does not require privileges to install PCRE on your system)
        - Use configure --without-pcre to disable regular expressions support in SWIG
          (not recommended).

See `config.log' for more details


需要安装pcre的开发包:

yum search pcre

 yum install pcre-devel.x86_64(根据搜索结果自己选)


你可能感兴趣的:(源码安装swig)