User forums > Help

problem Custom command

(1/3) > >>

rob:
I made the strange experience that Custom commands only work, when defined at the Project-Setting. When trying to add such custom comands to an inidividal target (which of course id defined for adding its settings to the projectsettings), they don't get executed.
To be honest, I think I do something wrong, otherwise I would have posted it to the sourceforge Bugreports.

mandrav:
I guess you 're talking about pre/post build steps. These are executed if your target's output is not up-to-date.

Example:
You have a target (with custom post-build step) producing a .dll. When this target compiles and links the dll, the post-build step is ran. Until you make any changes requiring the re-linking of the dll, the defined post-build step will not run again.
It behaves like its name suggests: "post-build step". If there is no "build" (the dll is up-to-date) there can be no post-build step.

I don't know if this is the expected behaviour, though, at least for guys coming from Visual Studio world. It's just what makes more sense. Still, I can see the need for commands being executed no matter if the build is up-to-date or not...

Opinions anyone?

Yiannis.

EricBurnett:
I personally would like them to execute every time. It is more what I expect, and I think it would be more useful.

rickg22:
I got an idea. Why not follow the Dev-C++ model? This is, generating the targets and re-generating them everytime the compile (ctrl-f9) is done?

mandrav:

--- Quote from: rickg22 ---I got an idea. Why not follow the Dev-C++ model? This is, generating the targets and re-generating them everytime the compile (ctrl-f9) is done?
--- End quote ---

If we had to like every function of devcpp, we better use it then and stop working on Code::Blocks   :D
For my needs, for example, I want the commands executed only when linking (a.k.a refreshing the exe/dll/etc).
But, as mentioned, I understand the need for commands that execute no matter what.

I can think of two solutions:
[*]Put a checkbox at the commands page, indicating if we want them to be executed every time or not
[*]Add two more commands boxes and have different commands for every-time execution and different for linking-time-only execution[/list:u]

How does it sound? Which do you prefer? Any more ideas?

Yiannis.

Navigation

[0] Message Index

[#] Next page

Go to full version