since rev 3103 my CB hangs infinite when trying to do a batchbuild started from the explorer's right-click popupmenu.Works for me, batch-build and batch-re-build of a project from explorer (WinXP, wx263 but revision 3104...)?!
yes i've rebuilt it
normal build works fine, batchbuild hangs inf.
i'm out of ideas
Have you tried to run C::B in the batch-build profile but *not* for batch-building?yes that was the first thing i did, there it runs fine and i can build/rebuild everything ...
btw. i use a batchbuild profile, where all plugins but compiler are disabled,A wild guess: Could you try what happens if you just re-enable the 3 wxSmith plugins in addition to the compiler plugin in this profile? (Because they onces caused trouble when disabling them using the new plugin framework).
btw. i use a batchbuild profile, where all plugins but compiler are disabled,A wild guess: Could you try what happens if you just re-enable the 3 wxSmith plugins in addition to the compiler plugin in this profile? (Because they onces caused trouble when disabling them using the new plugin framework).
With regards, Morten.
attached is the project where it hangs for me.This works well for me (no hang). But: I don't have wx-config so this might be the reason...?!
attached is the project where it hangs for me.This works well for me (no hang). But: I don't have wx-config so this might be the reason...?!
(Will try and edit this post once I did this...)
With regards, Morten.
i don't understand how you could build this project successfully, when you don't have wx-config ?? :shock:No, I couldn't build... I forgot to mention that (did it in the other post now - including the "results").
I'm doing something wrong here :P
Agreed, with wx-config (D/L'ded from http://wxconfig.googlepages.com/ (http://wxconfig.googlepages.com/)) my C::B freezes, too. Anyway: This seems to be related to wx-config...
but it doesn't explain, why it freezes CB only when batch-building ?!No, actually this I didn't try - until now. The project I used for testing previously did not use wx-config.
wx-config doesn't freeze CB when you build a project normally from the IDE ?!
...Any other tools I enter just works fine (but of course causes a compilation error)...
conclusion:Our posts have crossed - sorry for that. But what I don't get: I don't have a WXWIN variable defined in the envvar plugin thus if I use wx-config it also freezes the IDE during non-batch-build-mode build. Did you say it doesn't freezes your IDE in non-batch-build-mode? Could you try what happens if you remove the WXWIN envvar and try to compile this project from the IDE (in non-batch-build-mode)?
wx-config should return at least an error message if it couldn't find the requested wx-library
CB should check if there was any character returned and handle the case if no chars are coming instead of hanging around lazy :P
CB environment variables plugin should also work in batch-build mode !!!!
i found the reason
the problem is, that wx-config doesn't return anything to stdout, when it errors out,
this obviously confuses the backticked-command expander
the reason, why it behaves different when using from the IDE or from batchbuildAnother side note: Don't you think environment variables should become part of the SDK? I happen to want to use it on plugins and wizards.
is obviously located in the environment variables plugin.
normally i don't have an environment variable WXWIN defined,Well, I can confirm that unsetting WXWIN, etc definitely hangs C::B, but it should be because wx-config outputs the "message garbage Error: wxWidgets hasn't been found installed...", not because it doesn't outputs anything.
but i defined it to a valid value in the environmentvariables plugin,
which works fine with wx-config when using from the ide
CB environment variables plugin should also work in batch-build mode !!!!SDK :)
conclusion:Our posts have crossed - sorry for that. But what I don't get: I don't have a WXWIN variable defined in the envvar plugin thus if I use wx-config it also freezes the IDE during non-batch-build-mode build. Did you say it doesn't freezes your IDE in non-batch-build-mode? Could you try what happens if you remove the WXWIN envvar and try to compile this project from the IDE (in non-batch-build-mode)?
wx-config should return at least an error message if it couldn't find the requested wx-library
CB should check if there was any character returned and handle the case if no chars are coming instead of hanging around lazy :P
CB environment variables plugin should also work in batch-build mode !!!!
With regards, Morten.
Ps.: You said previously that you've disabled all plugins for the batch-build. How should the envvar plugin work then?!
i found the reason
the problem is, that wx-config doesn't return anything to stdout, when it errors out,
this obviously confuses the backticked-command expander
Have you tested that from the command line? wx-config output this if you call wx-config --cxxflags:
*** Error: wxWidgets hasn't been found installed at 'C:\wxWidgets'.
Please use the --prefix flag (as in `wx-config --prefix=C:\wxWidgets`)
or set the environment variable WXWIN (as in WXWIN=C:\wxWidgets)
to specify where is your installation of wxWidgets.
Side note: I don't know if it's better to output those errors to std:cerr instead of std::cout.the reason, why it behaves different when using from the IDE or from batchbuildAnother side note: Don't you think environment variables should become part of the SDK? I happen to want to use it on plugins and wizards.
is obviously located in the environment variables plugin.normally i don't have an environment variable WXWIN defined,Well, I can confirm that unsetting WXWIN, etc definitely hangs C::B, but it should be because wx-config outputs the "message garbage Error: wxWidgets hasn't been found installed...", not because it doesn't outputs anything.
but i defined it to a valid value in the environmentvariables plugin,
which works fine with wx-config when using from the ideCB environment variables plugin should also work in batch-build mode !!!!SDK :)
wx-config --leckmich > wx-config.log
what do you see in the log file ? nothing !
wx-config --leckmich > wx-config.logI couldn't resist: lol :lol:
maybe a buffer overflow in CB ?But I don't see what could have caused this in the changes between those revisions we have identified...?!
maybe a buffer overflow in CB ?But I don't see what could have caused this in the changes between those revisions we have identified...?!
wx-config --prefix=from command line. It hangs.
//nix.cpp -> nix.exe
#include <iostream>
int main(){
std::string s1 = "`nix` ;-)";
std::cout << s1 << std::endl;
return 0;
}
I've narrowed it down to callingQuotewx-config --prefix=from command line. It hangs.
So it seems that when wx-config hangs it hangs C::B too.
Anyways the exe was built with MSVC 2005 Express and I can't debug it. :?
But when built with GCC or DMC it doesn't hangs and everything seems normal.
So in the meantime I've uploaded one built with DMC:
http://wx-config-win.googlecode.com/svn/binary/wx-config.exe
2.) the CB environmentvariables plugin doesn't work in batchbuild mode or isn't initialized at the time,I guess this is on my desk, then... will look into it... but not today.
when the compiler starts resolving backticked commands
Finally! The solution. Good work, tiwag - I guess we can go to bed then, right?! ;-)
3) The Environment Variables should be part of the SDK, if not, we have inter-plugin dependences and the side effect that you get different things between batch builds and normal builds.I wouldn't say this. It can (and should) be a plugin (otherwise you could argue that e.g. the compiler plugin should be in the sdk, too - right?). The only issue here is that obviously the OnAttach() method seems not to be called on a batch-build process for an obscure reason... will investigate in this...
1) wx-config --prefix= hangs even in command-line when the exe was built with MSVC2005 Express only.
2) Code::Blocks parses backticks outputs. Thus self-referencing backticks causes an infinite loop. Is this good behaviour or not?it is good behavior
3) The Environment Variables should be part of the SDK, if not, we have inter-plugin dependences and the side effect that you get different things between batch builds and normal builds.i'm shure, Morten will find a reliable solution for this ...
4) Question: for those who know, errors should be better printed in stdout or stderr? My idea is that a C::B regex can parse them.
5) DDE bug attacking again Windows cannot find 'file.cbp'....delete all dde related registry keys from CodeBlocks registered file extensions ( ".cbp" and so on )
6) The default.conf is getting unreliable lately, but this is for another post.true, i had a lot of issues too
Yes, both ways are arguable, but because you could say "have cbEditor as plugin", or for example you can "set the Network proxy" in Environment, but you can't "set environment variables"?3) The Environment Variables should be part of the SDK, if not, we have inter-plugin dependences and the side effect that you get different things between batch builds and normal builds.I wouldn't say this. It can (and should) be a plugin (otherwise you could argue that e.g. the compiler plugin should be in the sdk, too - right?).
I think this has already been resolved by Thomas meanwhile. IMHO the reason were the TinyXml changes related to <, > and consorts. But this works now properly... (I hadn't have any issues since then).6) The default.conf is getting unreliable lately, but this is for another post.true, i had a lot of issues too
Either way, it's fine as long while it can be accessed from Squirrel.So hopefully you've seen that I have edited the post you are refering to meanwhile (sorry if our posts crossed). So this should be fine then?!
Then try it first :wink:1) wx-config --prefix= hangs even in command-line when the exe was built with MSVC2005 Express only.didn't try but i don't believe this
set WXCFG=and
set WXWIN=to reproduce it.
OK, re-asking the question and having in mind that back-ticks in Windows are supposed to do exactly the same thing as in Linux.2) Code::Blocks parses backticks outputs. Thus self-referencing backticks causes an infinite loop. Is this good behaviour or not?it is good behavior
think of nested calls of some backticked commands
`aaa` -> `bbb` -> "something useful"
4) Question: for those who know, errors should be better printed in stdout or stderr? My idea is that a C::B regex can parse them.
PLEASE don't print novels as error messagesIn short, sending long messages to stderr and one-liners to stdout is what you suggest and what gcc does, for instance?
just send ( "ERROR: %d : %s\n", errornumber , errordescription )
I think this has already been resolved by Thomas meanwhile. IMHO the reason were the TinyXml changes related to <, > and consorts. But this works now properly... (I hadn't have any issues since then).Yes, but I'm talking about lot of different issues with it not related to that, which deserves a thread on it's own.
With regards, Morten.
So hopefully you've seen that I have edited the post you are refering to meanwhile (sorry if our posts crossed). So this should be fine then?!If one can Add new variables, Change variable values, Delete variables, Toggle variables and Set now variables from Squirrel, it's perfectly fine.
In short, sending long messages to stderr and one-liners to stdout is what you suggest and what gcc does, for instance?
I haven't tested this so if you can test it you 'd be doing me a favour :).it's working fine, thanks !
As you can understand, it is no longer necessary to even create a separate profile/personality for batch builds, since usually you create a different profile only to disable most of the plugins ;)in general you are right, but it's not entirely true,
maybe just "wx-config ERROR: 01 : error description ..." to stdout, this will then be seen in the buildlog,
the long text to stderr