News:

When registered with our forums, feel free to send a "here I am" post here to differ human beings from SPAM bots.

Main Menu

windres.exe problem in recompiling C::B from sources

Started by vix, February 17, 2009, 09:02:41 AM

Previous topic - Next topic

vix

I've been trying to recompile C::B from sources (WinXP SP2) as Jens suggested me in this post http://forums.next.codeblocks.org/index.php?topic=9980.0
I followed the Nightly Cookbook step by step
- I downloaded the last sources with RapidSVN
- I downloaded the wxWidgets 2-8-9 sources and I successfully recompile them

but when I try to rebuild th C::B sources I have this error
Compiling: src\resources\resources.rc
gcc: Blocks\: No such file or directory
gcc: Nightly\sdk\include: No such file or directory
windres.exe: preprocessing failed.
Process terminated with status 1 (0 minutes, 5 seconds)
1 errors, 0 warnings


I put C::B sources in D:\projects\CodeBlocks and wxWidgets in D:\projects\wxMSW-2.8.9 (so without spaces in the path)
I updated MinGW to the 5.1.4 version and binutils to the 2.19.1 version, but this didn't help

Could you help me?

Jenna

Please turn on full commandline logging and post the appropriate part of the build log:

Change "Settings -> Compiler and debugger... -> Global compiler settings -> Other settings(rightmost tab) -> Compiler logging" to "Full commandline".

The version of windres might be of interest, because, there was a change in commandline parameters (if that's the problem your version is really old).

On my windows machine at work I get:
Quote
C:\Dokumente und Einstellungen\jens>windres -V
GNU windres 2.17.50 20060824
Copyright 2005 Free Software Foundation, Inc.
This program is free software; you may redistribute it under the terms of
the GNU General Public License.  This program has absolutely no warranty.

vix

windres.exe -i D:\projects\CODEBL~1\src\src\RESOUR~1\RESOUR~1.RC -J rc -o .objs\src\resources\resources.res -O coff -ID:\projects\wxMSW-2.8.9\include -IC:\Programmi\MinGW\include -I"C:\Programmi\Code Blocks Nightly\sdk\include" -IC:\Programmi\wxWidgets-2.8.0\include
gcc: Blocks\: No such file or directory
gcc: Nightly\sdk\include: No such file or directory
windres.exe: preprocessing failed.
Process terminated with status 1 (0 minutes, 4 seconds)
1 errors, 0 warnings


GNU windres (GNU Binutils) 2.19.1
Copyright 2007 Free Software Foundation, Inc.
This program is free software; you may redistribute it under the terms of
the GNU General Public License version 3 or (at your option) any later version.
This program has absolutely no warranty.


Hope this helps

Jenna

Quote from: vix on February 17, 2009, 10:02:38 AM
Quotewindres.exe -i D:\projects\CODEBL~1\src\src\RESOUR~1\RESOUR~1.RC -J rc -o .objs\src\resources\resources.res -O coff -ID:\projects\wxMSW-2.8.9\include -IC:\Programmi\MinGW\include -I"C:\Programmi\Code Blocks Nightly\sdk\include" -IC:\Programmi\wxWidgets-2.8.0\include
gcc: Blocks\: No such file or directory
gcc: Nightly\sdk\include: No such file or directory
windres.exe: preprocessing failed.
Process terminated with status 1 (0 minutes, 4 seconds)
1 errors, 0 warnings

You seem to have include dirs for windres, that include spaces.
Remove them and try it again.

If you use standard C::B sources, they are most likely set in the global compiler settings ("Settings -> Compiler and debugger -> Global compiler settings -> [your_compiler] -> Search directories -> Resource compiler".

Only use global compiler settings, if you really know what you do, and if you need them for every project you want to compile with this compiler.

vix

Thanks to your help I've been able to recompile C::B from the sources by myself  :D

Then I tried to compile the contrib plugins, as in this tutorial http://wiki.codeblocks.org/index.php?title=Installing_Code::Blocks_from_source_on_Windows
But the process ended with a lot of errors
D:\projects\CodeBlocks\src\plugins\contrib\AutoVersioning\avSvnRevision.cpp:6:29: tinyxml/tinyxml.h: No such file or directory
D:\projects\CodeBlocks\src\plugins\contrib\AutoVersioning\avSvnRevision.cpp:7:21: globals.h: No such file or directory
D:\projects\CodeBlocks\src\plugins\contrib\AutoVersioning\avSvnRevision.cpp: In function `bool QuerySvn(const wxString&, wxString&, wxString&)':
D:\projects\CodeBlocks\src\plugins\contrib\AutoVersioning\avSvnRevision.cpp:26: error: `TiXmlDocument' was not declared in this scope
D:\projects\CodeBlocks\src\plugins\contrib\AutoVersioning\avSvnRevision.cpp:26: error: expected `;' before "doc"
D:\projects\CodeBlocks\src\plugins\contrib\AutoVersioning\avSvnRevision.cpp:27: error: `doc' was not declared in this scope
D:\projects\CodeBlocks\src\plugins\contrib\AutoVersioning\avSvnRevision.cpp:27: error: `cbU2C' was not declared in this scope
D:\projects\CodeBlocks\src\plugins\contrib\AutoVersioning\avSvnRevision.cpp:32: error: `TiXmlHandle' was not declared in this scope
D:\projects\CodeBlocks\src\plugins\contrib\AutoVersioning\avSvnRevision.cpp:32: error: expected `;' before "hCommit"
D:\projects\CodeBlocks\src\plugins\contrib\AutoVersioning\avSvnRevision.cpp:33: error: `hCommit' was not declared in this scope
D:\projects\CodeBlocks\src\plugins\contrib\AutoVersioning\avSvnRevision.cpp:34: error: expected primary-expression before "const"
D:\projects\CodeBlocks\src\plugins\contrib\AutoVersioning\avSvnRevision.cpp:34: error: expected `)' before "const"
D:\projects\CodeBlocks\src\plugins\contrib\AutoVersioning\avSvnRevision.cpp:36: error: `e' was not declared in this scope
D:\projects\CodeBlocks\src\plugins\contrib\AutoVersioning\avSvnRevision.cpp:36: error: `cbC2U' was not declared in this scope
D:\projects\CodeBlocks\src\plugins\contrib\AutoVersioning\avSvnRevision.cpp:37: error: expected initializer before '*' token
D:\projects\CodeBlocks\src\plugins\contrib\AutoVersioning\avSvnRevision.cpp:38: error: `d' was not declared in this scope
D:\projects\CodeBlocks\src\plugins\contrib\AutoVersioning\avSvnRevision.cpp:26: warning: unused variable 'TiXmlDocument'
D:\projects\CodeBlocks\src\plugins\contrib\AutoVersioning\avSvnRevision.cpp:27: warning: unused variable 'cbU2C'
D:\projects\CodeBlocks\src\plugins\contrib\AutoVersioning\avSvnRevision.cpp:32: warning: unused variable 'TiXmlHandle'
Process terminated with status 1 (0 minutes, 1 seconds)
15 errors, 3 warnings

Jenna

I guess the global variable cb is pointing to the wrong directory.
Make sure that in "Settings -> Global variables..." the base of cb points to the directory where C::B's project and workspace files are.
It's the first directory called src in the root directory of C::B's sources (on my linux box it's /home/jens/codeblocks-build/codeblocks.trunk/src).

vix

Thanks Jens,
I've been able to recompile C::B and contrib plugins  :D :D :D

Now I'm starting my attempt to recompile the old KeyMacs plugin, and if I'm having problems I'll start a new thread...