diff --git a/PowerEditor/visual.net/notepadPlus.vcxproj b/PowerEditor/visual.net/notepadPlus.vcxproj index 84c11ca7..a2adbae6 100755 --- a/PowerEditor/visual.net/notepadPlus.vcxproj +++ b/PowerEditor/visual.net/notepadPlus.vcxproj @@ -228,7 +228,7 @@ copy ..\src\contextMenu.xml ..\bin\contextMenu.xml Level4 true ProgramDatabase - NoExtensions + NotSet true diff --git a/README.md b/README.md index 09e2a6a8..53c67861 100644 --- a/README.md +++ b/README.md @@ -41,29 +41,33 @@ like to debug Notepad++, but don't have boost. ## To build `SciLexer.dll` with boost: -Here are the instructions to build SciLexer.dll for Notepad++: +Here are the instructions to build SciLexer.dll (for both 32-bit & 64-bit) for Notepad++: 1. Download the [Boost source code](http://sourceforge.net/projects/boost/files/boost/1.55.0/). v1.55 should be used with VS 2013. Then unzip it. In my case, `boost_1_55_0` is copied in `C:\sources\` 2. Go to `scintilla\boostregex\` then run BuildBoost.bat with your boost path. In my case: `BuildBoost.bat C:\sources\boost_1_55_0` + If you are compiling a 64 bit Scintilla under your *VS2013 x64 Native tool command prompt*, add `-x64` flag. + In my case: `BuildBoost.bat C:\sources\boost_1_55_0 -x64` 3. Go in `scintilla\win32\` then run `nmake -f scintilla.mak` ## To build `SciLexer.dll` *without* boost: -This will work with `notepad++.exe`, however some functionality in Notepad++ might be broken. +This will work with `notepad++.exe`, however some functionality in Notepad++ will be broken. -To build SciLexer.dll without PCRE support: +To build SciLexer.dll without PCRE support (for both 32-bit & 64-bit): - 1. Open a command prompt *for building* ([a.k.a. the *Developer Command Prompt for VS2013*](https://msdn.microsoft.com/en-us/library/f2ccy3wt.aspx)) + 1. For 32-bit, open a command prompt *for building* ([a.k.a. the *Developer Command Prompt for VS2013*](https://msdn.microsoft.com/en-us/library/f2ccy3wt.aspx)) - From the IDE, you can do this by right clicking on a file in Solution Explorer, and clicking "Open Command Prompt". This will open up a command prompt with all the proper environment variables. - From the Windows Start screen/menu, type `Developer Command Prompt for VS2013`, and click/select the result. - From an *already open* command prompt, run `vcvarsall.bat` (e.g. "C:\Program Files (x86)\Microsoft Visual Studio 12.0\VC\vcvarsall.bat"). + + For 64-bit, open *VS2013 x64 Native tool command prompt*. 2. Change directory (`cd` or `pushd`) to `scintilla\win32\` diff --git a/scintilla/boostregex/BuildBoost.bat b/scintilla/boostregex/BuildBoost.bat index 116a1a98..83d328d2 100644 --- a/scintilla/boostregex/BuildBoost.bat +++ b/scintilla/boostregex/BuildBoost.bat @@ -7,7 +7,10 @@ SET TOOLSETCOMMAND= SET BOOSTVERSION= SET WORKPATH=%~dp0% -:PARAMLOOP +SET BUILDTARGETPARAM= +SET BUILDTARGETPATH= + +rem :PARAMLOOP IF [%1]==[] ( GOTO PARAMCONTINUE ) @@ -21,10 +24,13 @@ IF [%1]==[--toolset] ( SHIFT ) +IF [%2]==[-x64] ( + SET BUILDTARGETPARAM=architecture=ia64 + SET BUILDTARGETPATH=architecture-ia64\ +) - -SHIFT -GOTO PARAMLOOP +rem SHIFT +rem GOTO PARAMLOOP :PARAMCONTINUE IF [%BOOSTPATH%]==[] ( @@ -40,6 +46,7 @@ IF NOT [%MSVCTOOLSET%]==[] ( IF NOT EXIST "%BOOSTPATH%\boost\regex.hpp" ( + ECHO Not found: %BOOSTPATH%\boost\regex.hpp GOTO BOOSTNOTFOUND ) @@ -103,12 +110,12 @@ ECHO. PUSHD %BOOSTPATH%\libs\regex\build -%BOOSTPATH%\bjam\bin\bjam %TOOLSETCOMMAND% variant=release threading=multi link=static runtime-link=static +%BOOSTPATH%\bjam\bin\bjam %TOOLSETCOMMAND% variant=release threading=multi link=static runtime-link=static %BUILDTARGETPARAM% IF NOT ERRORLEVEL 0 ( GOTO BUILDERROR ) -%BOOSTPATH%\bjam\bin\bjam %TOOLSETCOMMAND% variant=debug threading=multi link=static runtime-link=static +%BOOSTPATH%\bjam\bin\bjam %TOOLSETCOMMAND% variant=debug threading=multi link=static runtime-link=static %BUILDTARGETPARAM% IF NOT ERRORLEVEL 0 ( GOTO BUILDERROR ) @@ -118,7 +125,7 @@ IF NOT [%MSVCTOOLSET%]==[] ( ) :: VS2013 -IF EXIST %BOOSTPATH%\bin.v2\libs\regex\build\msvc-12.0\release\link-static\runtime-link-static\threading-multi\libboost_regex-vc120-mt-s-%BOOSTVERSION%.lib ( +IF EXIST %BOOSTPATH%\bin.v2\libs\regex\build\msvc-12.0\release\%BUILDTARGETPATH%link-static\runtime-link-static\threading-multi\libboost_regex-vc120-mt-s-%BOOSTVERSION%.lib ( SET MSVCTOOLSET=msvc-12.0 ) @@ -195,6 +202,7 @@ IF [%BOOSTLIBPATH%] == [] ( ECHO # Autogenerated file, run BuildBoost.bat [path_to_boost] to generate > %WORKPATH%\boostpath.mak ECHO BOOSTPATH=%BOOSTPATH% >> %WORKPATH%\boostpath.mak ECHO BOOSTLIBPATH=%BOOSTLIBPATH% >> %WORKPATH%\boostpath.mak +ECHO BUILDTARGETPATH=%BUILDTARGETPATH% >> %WORKPATH%\boostpath.mak POPD ECHO. ECHO. @@ -222,7 +230,12 @@ ECHO Unzip the file downloaded from www.boost.org, and give the absolute path ECHO as the first parameter to buildboost.bat ECHO. ECHO e.g. -ECHO buildboost.bat d:\libs\boost_1_48_0 +ECHO buildboost.bat d:\libs\boost_1_48_0 + +ECHO. +ECHO To build 64 bit version, add "-x64" flag after the full file path. +ECHO e.g. +ECHO buildboost.bat d:\libs\boost_1_48_0 -x64 ECHO. ECHO. diff --git a/scintilla/boostregex/nppSpecifics.mak b/scintilla/boostregex/nppSpecifics.mak index 55d7ace5..a01a2e3a 100644 --- a/scintilla/boostregex/nppSpecifics.mak +++ b/scintilla/boostregex/nppSpecifics.mak @@ -24,11 +24,16 @@ LOBJS=\ INCLUDEDIRS=$(INCLUDEDIRS) -I$(BOOSTPATH) +!IFDEF BUILDTARGETPATH +CXXFLAGS=$(CXXFLAGS) -DSCI_OWNREGEX +!ELSE CXXFLAGS=$(CXXFLAGS) -DSCI_OWNREGEX -arch:IA32 +!ENDIF + !IFDEF DEBUG LDFLAGS=$(LDFLAGS) -LIBPATH:$(BOOSTLIBPATH)\debug\link-static\runtime-link-static\threading-multi !ELSE -LDFLAGS=$(LDFLAGS) -LIBPATH:$(BOOSTLIBPATH)\release\link-static\runtime-link-static\threading-multi +LDFLAGS=$(LDFLAGS) -LIBPATH:$(BOOSTLIBPATH)\release\$(BUILDTARGETPATH)link-static\runtime-link-static\threading-multi !ENDIF