User forums > Using Code::Blocks
Custom build commands and variables
Jabber:
Hi all,
I'm trying to add compilation support for a SWIG interface file (generating a Lua wrapper); to do so I added the following line in Options(for the .i file)->Build:
--- Code: ---swig -c++ -lua $FILENAME
--- End code ---
However, it seems that the variables like $FILENAME don't get substituted, the build log just says
--- Quote ---swig -c++ -lua
--- End quote ---
(that call fails, of course).
I'm using the SVN rev 2218 on Windows XP; it looks like someone had a similiar problem a while back:
http://forums.codeblocks.org/index.php?topic=1485.msg10583#msg10583.
Am I doing something wrong or is this a bug?
Thanks,
Jabber
takeshimiya:
--- Quote from: Jabber on March 21, 2006, 11:08:30 pm ---Hi all,
I'm trying to add compilation support for a SWIG interface file (generating a Lua wrapper); to do so I added the following line in Options(for the .i file)->Build:
--- Code: ---swig -c++ -lua $FILENAME
--- End code ---
However, it seems that the variables like $FILENAME don't get substituted, the build log just says
--- Quote ---swig -c++ -lua
--- End quote ---
(that call fails, of course).
I'm using the SVN rev 2218 on Windows XP; it looks like someone had a similiar problem a while back:
http://forums.codeblocks.org/index.php?topic=1485.msg10583#msg10583.
Am I doing something wrong or is this a bug?
Thanks,
Jabber
--- End quote ---
AFAIK, only variables in the form $(variable) or ${variable} are expanded.
Jabber:
Hi,
--- Quote from: Takeshi Miya on March 21, 2006, 11:16:24 pm ---AFAIK, only variables in the form $(variable) or ${variable} are expanded.
--- End quote ---
Yep, tried that too, but both versions don't work neither.
thomas:
--- Quote ---AFAIK, only variables in the form $(variable) or ${variable} are expanded.
--- End quote ---
Nope, they should be.
Where is that variable defined? If it is in the compiler's scope ( = global) then it does not work, that's a known bug.
Jabber:
Hi,
Under Options(for the file)->Build it says
--- Quote ---You can use the following variables:
--- End quote ---
and then a list of variables like $FILENAME and so on, so I didn't define that variable, but C::B should have ;)
Navigation
[0] Message Index
[#] Next page
Go to full version