Developer forums (C::B DEVELOPMENT STRICTLY!) > Development
batchbuild issues with backticked commands
takeshimiya:
--- Quote from: tiwag on October 18, 2006, 09:57:41 pm ---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
--- End quote ---
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.
--- Quote from: tiwag on October 18, 2006, 09:57:41 pm ---the reason, why it behaves different when using from the IDE or from batchbuild
is obviously located in the environment variables plugin.
--- End quote ---
Another 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.
--- Quote from: tiwag on October 18, 2006, 09:57:41 pm ---normally i don't have an environment variable WXWIN defined,
but i defined it to a valid value in the environmentvariables plugin,
which works fine with wx-config when using from the ide
--- End quote ---
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.
--- Quote from: tiwag on October 18, 2006, 09:57:41 pm ---CB environment variables plugin should also work in batch-build mode !!!!
--- End quote ---
SDK :)
tiwag:
--- Quote from: MortenMacFly on October 18, 2006, 10:04:36 pm ---
--- Quote from: tiwag on October 18, 2006, 09:57:41 pm ---conclusion:
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 !!!!
--- End quote ---
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)?
With regards, Morten.
Ps.: You said previously that you've disabled all plugins for the batch-build. How should the envvar plugin work then?!
--- End quote ---
the compiler and environmentvariables plugins are enabled, and it works from the ide,
and yes, it does freeze CB when building from the ide, when i disable the WXWIN environment variable.
we have shot the problem !
btw. i tested a program, which return nothing, and this DOES NOT FREEZE CB !!!
my previous assumption was wrong !
but also wx-config is no longer running, when CB freezes
tiwag:
--- Quote from: Takeshi Miya on October 18, 2006, 10:09:32 pm ---
--- Quote from: tiwag on October 18, 2006, 09:57:41 pm ---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
--- End quote ---
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.
--- Quote from: tiwag on October 18, 2006, 09:57:41 pm ---the reason, why it behaves different when using from the IDE or from batchbuild
is obviously located in the environment variables plugin.
--- End quote ---
Another 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.
--- Quote from: tiwag on October 18, 2006, 09:57:41 pm ---normally i don't have an environment variable WXWIN defined,
but i defined it to a valid value in the environmentvariables plugin,
which works fine with wx-config when using from the ide
--- End quote ---
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.
--- Quote from: tiwag on October 18, 2006, 09:57:41 pm ---CB environment variables plugin should also work in batch-build mode !!!!
--- End quote ---
SDK :)
--- End quote ---
i guess this goes to stderr and not to stdout !
try
wx-config --leckmich > wx-config.log
what do you see in the log file ? nothing !
takeshimiya:
--- Quote from: tiwag on October 18, 2006, 10:14:07 pm ---wx-config --leckmich > wx-config.log
what do you see in the log file ? nothing !
--- End quote ---
*** Error: Unrecognised option: '--leckmich'
Usage: wx-config [options]
Options:
--prefix[=DIR] Path of the wxWidgets installation (ie. C:\wxWidgets2.6.3)
--wxcfg[=DIR] Relative path of the build.cfg file (ie. gcc_dll\mswud)
--cflags Outputs all pre-processor and compiler flags.
--cxxflags Same as --cflags but for C++.
--rcflags Outputs all resource compiler flags. [UNTESTED]
--libs Outputs all linker flags.
--debug[=yes|no] Uses a debug configuration if found.
--unicode[=yes|no] Uses an unicode configuration if found.
--static[=yes|no] Uses a static configuration if found.
--universal[=yes|no] Uses an universal configuration if found.
--easymode[=yes|no] Outputs warnings, and optimize flags.
--compiler[=gcc,dmc,vc] Selects the compiler.
--release Outputs the wxWidgets release number.
--cc Outputs the name of the C compiler.
--cxx Outputs the name of the C++ compiler.
--ld Outputs the linker command.
-v Outputs the revision of wx-config.
Note that using --prefix is not needed if you have defined the
environmental variable WXWIN.
Also note that using --wxcfg is not needed if you have defined the
environmental variable WXCFG.
:?
But anyways I get the C::B crash from the IDE.
tiwag:
maybe a buffer overflow in CB ?
Navigation
[0] Message Index
[#] Next page
[*] Previous page
Go to full version