FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

More on versioning

 
Post new topic   Reply to topic     Forum Index -> Derelict
View previous topic :: View next topic  
Author Message
aldacron



Joined: 05 May 2004
Posts: 1322
Location: Seoul, South Korea

PostPosted: Thu May 18, 2006 5:01 am    Post subject: More on versioning Reply with quote

Someone recently submitted to me some updates for the DerelictSDLImage/Mixer/Net/ttf packages. I was looking at a diff of the new mixer.d, 1.2.7, and the one in the trunk, which is 1.2.5. I have the C headers for 1.2.6 and 1.2.7 on my system, so I hit Google to find the 1.2.5 header.

Next, I started updating mixer.d using a version approach - (version(SDLMixer_127) else version(SDLMixer_126) else). In mixer.d, this isn't a big deal. But considering some of the larger packages, like DerelictSDL and DerelictGLFW, I realized this can become a horrible nightmare to maintain. I then started questioning the need to maintain compatibility with multiple versions of the library.

If we go with the versioning approach, everyone who wants to use the latest version will have to add version statements to each package's forbuild.txt file. We could get around that by making the latest version the default and making the user specify older versions instead, but that makes maintenance even crazier. Using the minimal version as default means that there is a base subset that is common to all versions. Using a newer version as default basically means a whole new module for each version.

Then there's updates. Every time a new version of the library comes out, any changes to the base subset must then be split out into version blocks. That is going to be tedious and error prone.

In summary, I'm now of the mind that maintaining version compatibility is going to be horribly time consuming and just not worth the effort. Most users, if not all, will want to use the latest version anyway. So, I'm going to say to hell with it. When new versions of a library are released and includes interface changes, Derelict can be updated to match it. That will become the new minimum supported version. Any user who wants to use an older interface can use SVN to check out an older version of the trunk.

And that, my friends, is the law Smile Direct complaints to clayasaurus.
Back to top
View user's profile Send private message Send e-mail
Crispy



Joined: 26 Nov 2005
Posts: 67

PostPosted: Thu May 18, 2006 6:22 am    Post subject: Reply with quote

Sounds fair enough to me. Smile
Back to top
View user's profile Send private message
JoeCoder



Joined: 29 Oct 2005
Posts: 294

PostPosted: Thu May 18, 2006 9:06 pm    Post subject: Reply with quote

I agree that this is the best approach. Time is better spent adding new libraries.

Speaking of which, I still need to finish my work with ogg vorbis. It's still using the older build system and a few things that need to be finished up with it, but I have been able to load and play files with it and OpenAL.
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic     Forum Index -> Derelict All times are GMT - 6 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group