Menu

How do I build NPP in Mingw?

2007-03-27
2012-11-13
  • James Yoneda

    James Yoneda - 2007-03-27

    I've got the binary NPP v4.0.2 and I'd love to play around with building it.  I can't figure it out, as the instructions don't mention how to build, and simply trying "make" gives errors.  I assume the dev's are primarily using Visual Studio, so that the gcc side of thing is out of date.

    1) The file "readmeFirst.txt" says "To build this package:" and then "For generating the executable file, you can use VC++ 7 or MinGW 3.0 / 2.X".  No instructions on how to build.  It'd be helpful if it stated "Goto \PowerEditor\gcc, type make".

    2) If I try to "make" in PowerEditor\gcc, then I get this:

    In file included from ../src/winmain.cpp:18:
    ../src/Notepad_plus.h:45:25: RunMacroDlg.h: No such file or directory
    In file included from ../src/winmain.cpp:18:
    ../src/Notepad_plus.h: At global scope:
    ../src/Notepad_plus.h:357: error: `RunMacroDlg' does not name a type
    ../src/Notepad_plus.h: In member function `int Notepad_plus::getCurrentView() const':
    ../src/Notepad_plus.h:511: error: `MAIN_VIEW' undeclared (first use this function)
    ../src/Notepad_plus.h:511: error: `SUB_VIEW' undeclared (first use this function)
    ../src/Notepad_plus.h: In member function `int Notepad_plus::getNonCurrentView() const':
    ../src/Notepad_plus.h:515: error: `SUB_VIEW' undeclared (first use this function)
    ../src/Notepad_plus.h:515: error: `MAIN_VIEW' undeclared (first use this function)
    ../src/Notepad_plus.h: In member function `void Notepad_plus::setDisplayFormat(formatType)':
    ../src/Notepad_plus.h:547: error: `STATUSBAR_EOF_FORMAT' undeclared (first use this function)
    ../src/Notepad_plus.h: In member function `void Notepad_plus::setUniModeText(UniMode)':
    ../src/Notepad_plus.h:566: error: `STATUSBAR_UNICODE_TYPE' undeclared (first use this function)
    ../src/ScitillaComponent/ScintillaEditView.h: At global scope:
    ../src/ScitillaComponent/ScintillaEditView.h:430: warning: inline function `void ScintillaEditView::makeStyle(const char*, const char**)' used but never defined
    ../src/Parameters.h:134: warning: 'int decStrVal(const char*)' defined but not used
    ../src/Parameters.h:138: warning: 'int hexStrVal(const char*)' defined but not used
    ../src/Parameters.h:143: warning: 'int getKwClassFromName(const char*)' defined but not used
    ../src/ScitillaComponent/UserDefineDialog.h:34: warning: 'int min(int, int)' defined but not used
    ../src/ScitillaComponent/UserDefineDialog.h:38: warning: 'int max(int, int)' defined but not used
    ../src/Notepad_plus.h:64: warning: 'TiXmlNode* searchDlgNode(TiXmlNode*, const char*)' declared `static' but never defined
    mingw32-make.exe: *** [winmain.o] Error 1

    Looks like I'm missing "RunMacroDlg.h".  Where can I find it?

    3) For fun, going to \scintilla has a "README" which says to goto \scintilla\win32 and type "make".  This gives the following:

    dllwrap --add-stdcall-alias --target i386-mingw32 -o ../bin/SciLexer.dll ScintillaWinL.o ScintillaBaseL.o Editor.o Document.o ContractionState.o CellBuffer.o CallTip.o ScintRes.o PlatWin.o KeyMap.o Indicator.o LineMarker.o RESearch.o Style.o ViewStyle.o AutoComplete.o UniConversion.o KeyWords.o DocumentAccessor.o PropSet.o ExternalLexer.o StyleContext.o XPM.o LexAda.o LexAPDL.o LexAsm.o LexAsn1.o LexAU3.o LexAVE.o LexBaan.o LexBash.o LexBasic.o LexBullant.o LexCaml.o LexCLW.o LexConf.o LexCPP.o LexCrontab.o LexCsound.o LexCSS.o LexEiffel.o LexErlang.o LexEScript.o LexFlagship.o LexForth.o LexFortran.o LexGui4Cli.o LexHaskell.o LexHTML.o LexKix.o LexLisp.o LexLout.o LexLua.o LexMatlab.o LexMetapost.o LexMMIXAL.o LexMPT.o LexMSSQL.o LexNsis.o LexOthers.o LexPascal.o LexPB.o LexPerl.o LexPOV.o LexPS.o LexPython.o LexRebol.o LexRuby.o LexScriptol.o LexSmalltalk.o LexSpecman.o LexSQL.o LexTADS3.o LexTeX.o LexVB.o LexVerilog.o LexVHDL.o LexYAML.o -mwindows -lstdc++ -limm32 -lole32 -luuid -mno-cygwin -s --relocatable
    KeyWords.o(.text+0x2d2):KeyWords.cxx: undefined reference to `lmUserDefine'
    collect2: ld returned 1 exit status
    dllwrap: no export definition file provided.
    Creating one, but that may not be what you want
    dllwrap: gcc exited with status 1
    mingw32-make.exe: *** [../bin/SciLexer.dll] Error 1

    Any help is appreciated.  Thanks!

     
    • Chris Severance

      Chris Severance - 2007-03-27

      http://textfx.no-ip.com/textfx/

      I've made project files for many compilers. They are out of date but it shouldn't take much to update them.