Release/Debug binray naming issue

Discuss about anything related to the Irrlicht Engine, or read announcements about any significant features or usage changes.
Jiang
Posts: 77
Joined: Tue Feb 20, 2007 11:03 am

Release/Debug binray naming issue

Post by Jiang »

The current irrlicht windows project solutions define quite a few configurations for release/debug and static/shared builds. However, the binary outputs use the same name, "irrlicht.lib", "irrlicht.dll".

This is not convenient for library management, if the user want to put the binary files in the same directory. And even worse, the examples use pragma to detect and link the necessary library, which adds extra difficulties for building both the release and debug applications at the same time.

So, can we

1. Change the naming convention for libraries. Say, add postfix "D" or "d" for debug build. ( -> "irrlichtD.lib", "irrlichtD.dll")

2. For pragma, use "_DEBUG" to distinguish the debug and release build and further link the different libraries using the naming convention defined by step 1.

Another possible solution is, separating the output directory for different configurations and further specify the corresponding library path for different application builds.

Or, I missed something important & difficult?

Regards,

Jiang
vitek
Bug Slayer
Posts: 3919
Joined: Mon Jan 16, 2006 10:52 am
Location: Corvallis, OR

Post by vitek »

I do not understand why you would want to do this (build both debug and release and keep the files in the same directories). What is your motivation?

Travis
Jiang
Posts: 77
Joined: Tue Feb 20, 2007 11:03 am

Post by Jiang »

vitek wrote:I do not understand why you would want to do this (build both debug and release and keep the files in the same directories). What is your motivation?

Travis
Do you build your debug version application? If you do so what's your build policy ?
Dorth
Posts: 931
Joined: Sat May 26, 2007 11:03 pm

Post by Dorth »

Personally I like to have debug libs in debug and release builds in release, using #ifdef to get the proper lib. I also agree this should be how Irrlicht is built. The biggest convention I have found so far is D right after the name for debug and _d or _dll for the dll build. So:
irrlicht
irrlichtD
irrlicht_dll
irrlichtD_dll
rogerborg
Admin
Posts: 3590
Joined: Mon Oct 09, 2006 9:36 am
Location: Scotland - gonnae no slag aff mah Engleesh
Contact:

Post by rogerborg »

I'm minded to agree with Jiang and Dorth, but I'm not fanatical about it. Moved to open discussion.
Please upload candidate patches to the tracker.
Need help now? IRC to #irrlicht on irc.freenode.net
How To Ask Questions The Smart Way
vitek
Bug Slayer
Posts: 3919
Joined: Mon Jan 16, 2006 10:52 am
Location: Corvallis, OR

Post by vitek »

Jiang wrote:
vitek wrote:I do not understand why you would want to do this (build both debug and release and keep the files in the same directories). What is your motivation?

Travis
Do you build your debug version application? If you do so what's your build policy ?
You haven't answered the question. I'm simply asking what your motivation is. You have some sort of build policy requires that you have both debug and release builds in the same directory?

Regardless, I don't use Irrlicht for anything production, so I don't have a build policy.

Travis
rogerborg
Admin
Posts: 3590
Joined: Mon Oct 09, 2006 9:36 am
Location: Scotland - gonnae no slag aff mah Engleesh
Contact:

Post by rogerborg »

It's not much of an issue, but I would (for example) like to be able to unit/regression test against a variety of builds without having to juggle the .a/.lib/.so/.dll files around. OTOH, I could script it easily enough. Small earthquake, not many injured.
Please upload candidate patches to the tracker.
Need help now? IRC to #irrlicht on irc.freenode.net
How To Ask Questions The Smart Way
CuteAlien
Admin
Posts: 9734
Joined: Mon Mar 06, 2006 2:25 pm
Location: Tübingen, Germany
Contact:

Post by CuteAlien »

I'm also all for different folders&names for the different builds. I only wish I would find a way to create all builds at once somehow in c::b, like some uber-target that builds all the other targets.
IRC: #irrlicht on irc.libera.chat
Code snippet repository: https://github.com/mzeilfelder/irr-playground-micha
Free racer made with Irrlicht: http://www.irrgheist.com/hcraftsource.htm
rogerborg
Admin
Posts: 3590
Joined: Mon Oct 09, 2006 9:36 am
Location: Scotland - gonnae no slag aff mah Engleesh
Contact:

Post by rogerborg »

Build target: All ?

C::B command line arguments
Please upload candidate patches to the tracker.
Need help now? IRC to #irrlicht on irc.freenode.net
How To Ask Questions The Smart Way
CuteAlien
Admin
Posts: 9734
Joined: Mon Mar 06, 2006 2:25 pm
Location: Tübingen, Germany
Contact:

Post by CuteAlien »

Hm, I see. "Build Target: All" is for some reason no longer available in my projects. Though it wasn't exactly what I needed. I actually wanted to compile all settings - but only for one platform while this also tried to compile the Windows versions on Linux (et vice versa).

Using scripts and command line is probably the way to go.
IRC: #irrlicht on irc.libera.chat
Code snippet repository: https://github.com/mzeilfelder/irr-playground-micha
Free racer made with Irrlicht: http://www.irrgheist.com/hcraftsource.htm
rogerborg
Admin
Posts: 3590
Joined: Mon Oct 09, 2006 9:36 am
Location: Scotland - gonnae no slag aff mah Engleesh
Contact:

Post by rogerborg »

It should be available and working in 1.5. The targets are platform specific, so doing a build: All on Windows will only get you the Windows targets, and similarly on Linux.

Puzzled now. :?
Please upload candidate patches to the tracker.
Need help now? IRC to #irrlicht on irc.freenode.net
How To Ask Questions The Smart Way
CuteAlien
Admin
Posts: 9734
Joined: Mon Mar 06, 2006 2:25 pm
Location: Tübingen, Germany
Contact:

Post by CuteAlien »

rogerborg wrote:It should be available and working in 1.5. The targets are platform specific, so doing a build: All on Windows will only get you the Windows targets, and similarly on Linux.
Puzzled now. :?
Eh sorry - I had no time yet to switch my projects to 1.5... don't get confused :-) I was just talking about the experiences I had with it so far in my own experimentations . If this works with 1.5 it will be great and I will try to figure out why it works :-)

edit: Hm, I just tested it - doesn't work. The targets are not platform specific and so c::b tries to compile the Windows versions on Linux. And I have some suspicion that making it platform specific might result in losing the "All" target somehow, as that is what I did in my projects and those don't have this target anymore.

This really does work for you?
IRC: #irrlicht on irc.libera.chat
Code snippet repository: https://github.com/mzeilfelder/irr-playground-micha
Free racer made with Irrlicht: http://www.irrgheist.com/hcraftsource.htm
rogerborg
Admin
Posts: 3590
Joined: Mon Oct 09, 2006 9:36 am
Location: Scotland - gonnae no slag aff mah Engleesh
Contact:

Post by rogerborg »

Heh, nice spot. It was "Works For Me" on Windows only. The targets and All build should be sorted on the trunk and on 1.5.X (if we cut a bugfix release). Sorry about that.
Please upload candidate patches to the tracker.
Need help now? IRC to #irrlicht on irc.freenode.net
How To Ask Questions The Smart Way
Jiang
Posts: 77
Joined: Tue Feb 20, 2007 11:03 am

Post by Jiang »

Hey rogerborg, Dorth and CuteAlien

I just add a irrlicht build tool project to sourceforge.net, and check it at

http://irrlicht.sourceforge.net/phpBB2/ ... hp?t=31529

HTH,

Jiang

@ rogerborg

I saw you add several testsuites for testing, really good job! However in my build scripts the testsuite generation is disabled for now. Maybe I will add them after further stabilization of them.

Share your thoughts here please.

Regards,
Jiang
Posts: 77
Joined: Tue Feb 20, 2007 11:03 am

Post by Jiang »

vitek wrote: I don't use Irrlicht for anything production,
Neither do I.
vitek wrote: so I don't have a build policy. Travis
Then I don't believe answering your question really helps here.

Anyway, thanks for your interests.

Regards,

Jiang
Post Reply