2013-03-29 21 views
0

我尝试将我的记事本++集成到之前成功安装的mingw应用程序。我得到的帮助来自这个网站:无法将Mingw集成到记事本++

http://iitdu.forumsmotion.com/t108-gcc-compiler-in-notepad

我把代码从该网站为:

// The script code, C source code compiling with GNU CC (GCC) in notepad++ (by    "NppExec" plug-in) and compressing with UPX... 
// 
// Enable? "//" signs remove in code line. 
// Sample: C:\Program Files\CodeBlocks\MinGW\bin\gcc.exe "$(FULL_CURRENT_PATH)" -o $(NAME_PART) 

YOUR_GCC\BIN\_PATH_HERE\gcc.exe "$(FULL_CURRENT_PATH)" -o $(NAME_PART) 

// UPX Compress (with "--best, --ultra-brute" options) 
// Enable? "//" signs remove in code line. 
// Sample: C:\WINDOWS\system32\upx.exe --best --ultra-brute $(NAME_PART).exe 

YOUR_UPX_PATH_HERE\upx.exe --best --ultra-brute $(NAME_PART).exe 

,并改变它为:在记事本中我Nppexec插件

// The script code, C source code compiling with GNU CC (GCC) in notepad++ (by "NppExec" plug-in) and compressing with UPX... 
// 
// Enable? "//" signs remove in code line. 
// Sample: C:\MinGW\bin\gcc.exe "$(FULL_CURRENT_PATH)" -o $(NAME_PART) 

C:\MinGW\bin\gcc.exe "$(FULL_CURRENT_PATH)" -o $(NAME_PART) 

// UPX Compress (with "--best, --ultra-brute" options) 
// Enable? "//" signs remove in code line. 
// Sample: C:\upx.exe --best --ultra-brute $(NAME_PART).exe 
C:\upx.exe --best --ultra-brute $(NAME_PART).exe 

++

然后当我尝试执行我刚刚上面的c颂我把这样的消息:

C:\MinGW\bin\gcc.exe "C:\Program Files\Notepad++\new 3.txt" -o new 3 
Process started >>> 
**gcc.exe: hata: 3: No such file or directory** 
<<< Process finished. 
C:\upx.exe --best --ultra-brute new 3.exe 
Process started >>> 
         Ultimate Packer for eXecutables 
          Copyright (C) 1996 - 2013 
UPX 3.09w  Markus Oberhumer, Laszlo Molnar & John Reiser Feb 18th 2013 

     File size   Ratio  Format  Name 
    -------------------- ------ ----------- ----------- 
upx: new: FileNotFoundException: new 
upx: 3.exe: FileNotFoundException: 3.exe 

Packed 0 files. 
<<< Process finished. 
================ READY ================ 

在我MinGW的文件夹:

C:\ MinGW的\ BIN \ gcc.exe是确定

那么,为什么它不能找到它,我不明白...

+0

尝试用'“$(NAME_PART)”.exe'替换'$(NAME_PART)'。但最好避免在目录和/或文件的名称中包含空格。 –

回答

1

我的记事本内++编译代码nppexec是

gcc $(FULL_CURRENT_PATH) -o $(CURRENT_DIRECTORY)\$(NAME_PART).exe 

这编译文件,请在同一个文件夹中创建一个.exe文件。

希望有所帮助。