I'm currently working on a new module to implement the TeamSpeak API. I have a quick question about the key I should use when declaring the library in hook_libraries_info().

I originally thought I would name the key simply 'teamspeak'. However, I found out that when you download and extract the library it gets put into a directory like the following 'TS3_PHP_Framework-1.1.20'. I'm sure the version number on the end will change with each version that comes out.

So my problem here is I have no idea what to name the key and would like to know if anyone has some pointers on what to do for situations like these. I'm sure I am not and will not be the only one with this issue.


FatGuyLaughing’s picture

Since the TeamSpeak API has specific versions for v2, v3 and soon v4 (when TeamSpeak 4 is realeased) should I try in some way of having the key with a version number in it? e.g. ('teamspeakv3' or 'teamspeak3')

FatGuyLaughing’s picture

I've settled on doing 'teamspeak3' as the key because more than likely when the php framework comes out for 4 it sound like it will be a different download.

tstoeckler’s picture

Issue summary: View changes
Status: Active » Fixed

Generally we should try to avoid versions in library names and instead solve problems like this in a better way. For example, in D7 you can provide a 'versions' key in hook_libraries_info() to provide different info for different versions.

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.