chance destination of object files using QNX Momentics IDE

Hi!

I have a little problem with the kind of folder hierarchy in an standard QNX-C++ project under QNX Momentics IDE.

when I create a new project, the tree looks like this:

project1
|
L_ x86
|…|
|…L_ o-g
|…|
|…L
|…
L_ project1.cpp
|…
L_ makefile
|…

I want to chance the folders hierarchy in this way:

project1
|
L_ bin
|…|
|…L
|…
L_ project1.cpp
|…
L_ makefile
|…

but i cant find a possibility to chance the path where momentics stores the create files.

Is it possible to chance the path?

regards … Marco

Hello,

I doubt you can do it because this directory structure is used by the recursive Makefile hierarchy invented by QNX. The directory names are used to figure out what compiler to invoke, what options to pass and what the name and type of the executable should be.

What you can try is to set INSTALL_ROOT_nto and the like such that when you issue make install it copies the binaries in the directories where you want them.

Another possibility is to create your own Makefiles outside the IDE and then import the entire source tree into the IDE. This means, however, that you cannot benefit from the automatic selection of compiler, options etc, and you probably cannot use the IDE to set any options (for instance, switching profiling on and off with the GUI would no longer work - you would have to edit your Makefile)

Regards,
Albrecht

I don’t think you want to. the x86/o path is what separates the object modules from powerpc, mips, sh and arm object files. If you don’t have separate folders for them you will have mingled architectures.

Rennie

True. I like this architecture very much because it really makes life simple.

However, many people have projects that for one reason or another will only be built for one platform and configuration. So, creating your own Makefile hierarchy can make sense although I don’t recommend it - just stick to the given architecture, many people have thought about it for quite a while, and after a while you will start to appreciate it.

Regards,
Albrecht

Yes, the only way to change is to use own Makefiles. This gives you complete freedom, but the IDE of course won’t parse your makefiles, so if you want to switch debugging on/off you need to do this in the makefile. But that’s not too hard isn’t it? :slight_smile: