View Issue Details

IDProjectCategoryView StatusLast Update
0001879ardourbugspublic2008-11-21 00:04
Reportertimbyr Assigned Topaul  
PrioritynormalSeveritymajorReproducibilityalways
Status closedResolutionfixed 
Summary0001879: Ardour and Ardour 2 use the same translation domains which breaks translations
DescriptionI believe it is the intention that Ardour and Ardour 2 are able to be installed at the same time.

It appears that Ardour and Ardour 2 both use gtk_ardour and libardour as translation domain names. This means that when both are installed, whichever version was installed last will have working translations while the other will have at best partially working translations as the .mo files are overwritten.
TagsNo tags attached.

Activities

2007-09-21 23:56

 

translation_domain_change.patch (1,424 bytes)   
diff --git a/gtk2_ardour/SConscript b/gtk2_ardour/SConscript
index 0e6efdd..b6fff7e 100644
--- a/gtk2_ardour/SConscript
+++ b/gtk2_ardour/SConscript
@@ -13,7 +13,7 @@ gtkmmtests = env.Copy()
 # this defines the version number of the GTK interface to ardour
 #
 
-domain = 'gtk_ardour'
+domain = 'gtk2_ardour'
 
 gtkardour.Append(DOMAIN=domain, MAJOR=1,MINOR=0,MICRO=2)
 gtkardour.Append(CCFLAGS="-DPACKAGE=\\\"" + domain + "\\\"")
diff --git a/libs/ardour/SConscript b/libs/ardour/SConscript
index 6cceed0..dfa7396 100644
--- a/libs/ardour/SConscript
+++ b/libs/ardour/SConscript
@@ -12,7 +12,7 @@ ardour = env.Copy()
 # this defines the version number of libardour
 # 
 
-domain = 'libardour'
+domain = 'libardour2'
 
 ardour.Append(DOMAIN = domain, MAJOR = 2, MINOR = 0, MICRO = 0)
 ardour.Append(CXXFLAGS = "-DPACKAGE=\\\"" + domain + "\\\"")
diff --git a/libs/ardour/session_state.cc b/libs/ardour/session_state.cc
index 77c5c2c..8067ae5 100644
--- a/libs/ardour/session_state.cc
+++ b/libs/ardour/session_state.cc
@@ -902,7 +902,7 @@ Session::state(bool full_state)
 	// store libardour version, just in case
 	char buf[16];
 	snprintf(buf, sizeof(buf)-1, "%d.%d.%d", 
-		 libardour_major_version, libardour_minor_version, libardour_micro_version);
+		 libardour2_major_version, libardour2_minor_version, libardour2_micro_version);
 	node->add_property("version", string(buf));
 		
 	/* store configuration settings */

timbyr

2007-09-22 00:09

developer   ~0004384

I've uploaded a patch that changes the translation domains from gtk_ardour and libardour to gtk2_ardour and libardour2 which allows Ardour and Ardour2 to be installed at the same time and have working translations.

Changing the domain of libardour to libardour2 also changes the names of the version identifiers from libardour_major_version to libardour2_major_version etc, which is a bit silly but I couldn't see straight forward(easy) way to keep them the same as the domain name is used to generate ardour/version.h

The patch also doesn't change the library name to(libardour2) because it isn't strictly needed although perhaps it should.

timbyr

2007-09-22 00:09

developer   ~0004385

requesting feedback on the patch

timbyr

2007-09-22 00:48

developer   ~0004386

Another possibility that was discussed briefly on IRC was to install the message catalog files in a location other than the GNU convention of /usr[/local]/share/locale and perhaps use something like /usr[/local]/share/$ARDOUR_VERSION/locale which should fix the problem in that the translation domains don't need to be changed for each new version and there won't be any name/file clashes.

I'm not sure if I like the idea it would require larger changes, testing etc.

paul

2007-09-26 12:52

administrator   ~0004407

fixed in svn for 2.0-ongoing and pending in paul's tree for trunk

Issue History

Date Modified Username Field Change
2007-09-20 09:02 timbyr New Issue
2007-09-21 23:56 timbyr File Added: translation_domain_change.patch
2007-09-22 00:09 timbyr Note Added: 0004384
2007-09-22 00:09 timbyr Note Added: 0004385
2007-09-22 00:09 timbyr Status new => feedback
2007-09-22 00:48 timbyr Note Added: 0004386
2007-09-26 12:52 paul Status feedback => resolved
2007-09-26 12:52 paul Resolution open => fixed
2007-09-26 12:52 paul Assigned To => paul
2007-09-26 12:52 paul Note Added: 0004407
2008-11-21 00:04 seablade Status resolved => closed