代码拉取完成,页面将自动刷新
PCRE is a library that is used by the optional "rules" feature for the command
line version of cppcheck. It is readily available on Linux and Mac OS X, but
must be obtained separately for Windows.
If you're using qmake to generate makefiles, the following behavior applies:
- If you're not on Windows, it assumes by default that you have PCRE and want
to enable rules support. You can disable rules support (removing the PCRE
dependency) by passing HAVE_RULES=no to qmake.
- If you are on Windows, but have PCRE available, you can enable rules support
by passing HAVE_RULES=yes to qmake.
- Note: This includes using build.bat since it calls qmake - to use PCRE and
build.bat, you need to run set HAVE_RULES=yes before each run of build.bat
Build instructions
------------------
Windows
-------
Visual Studio
To build PCRE, download the source code from www.pcre.org and
CMake (https://cmake.org/download/). We assume you use Visual Studio 2015 -
otherwise adapt the commands for your version.
VS Solution file
cmake . -G "Visual Studio 14 2015"
Open PCRE.sln with VS IDE or via cmd:
call "%VS140COMNTOOLS%..\..\VC\vcvarsall.bat" x86
MSBuild PCRE.sln /target:Build /property:Configuration="Release"
For 64-bit target: cmake . -G "Visual Studio 14 2015 Win64"
or using NMake
call "%VS140COMNTOOLS%..\..\VC\vcvarsall.bat" x86
cmake . -G "NMake Makefiles"
nmake
or using MSYS
cmake . -G "MSYS Makefiles"
make
Linux
-----
The normal Makefile should work.
Install PCRE on Ubuntu might be needed:
sudo apt-get install libpcre3 libpcre3-dev
Mac OSX
-------
Install PCRE:
homebre
brew install pcre
or macport
sudo port install pcre
Ensure /path/to/pcre.h is in CXXFLAGS, e.g:
for homebrew
export CXXFLAGS=${CXXFLAGS}:/usr/local/include
or macport
export CXXFLAGS=${CXXFLAGS}:/opt/local/include
Or for MSVC copy pcre.lib and pcre.h in /externals directory.
此处可能存在不合适展示的内容,页面不予展示。您可通过相关编辑功能自查并修改。
如您确认内容无涉及 不当用语 / 纯广告导流 / 暴力 / 低俗色情 / 侵权 / 盗版 / 虚假 / 无价值内容或违法国家有关法律法规的内容,可点击提交进行申诉,我们将尽快为您处理。