From ae4881a5b65be6ef7881aed0d4f234993da99857 Mon Sep 17 00:00:00 2001 From: Bernardo Gonzalez Kriegel Date: Sat, 12 Jan 2013 23:23:33 -0300 Subject: [PATCH] Bug 9381: Add Catalan language Simply add catalan language. No translation yet, so can't be really tested. But it will come soon. Until then, to test: 1) cp misc/translator/po/es-ES* to ca-ES* 2) do perl translate install ca-ES, 3) apply the patch 4) run updatedatabase.pl 5) enable language and display on system preferences. 6) check labels Signed-off-by: Chris Cormack Rebased to current master Signed-off-by: Katrin Fischer Signed-off-by: Jared Camins-Esakov --- .../mysql/en/mandatory/subtag_registry.sql | 19 +++++++++++++++++++ installer/data/mysql/updatedatabase.pl | 12 ++++++++++++ 2 files changed, 31 insertions(+) diff --git a/installer/data/mysql/en/mandatory/subtag_registry.sql b/installer/data/mysql/en/mandatory/subtag_registry.sql index dac8b29f10..b9cbd3c219 100755 --- a/installer/data/mysql/en/mandatory/subtag_registry.sql +++ b/installer/data/mysql/en/mandatory/subtag_registry.sql @@ -631,6 +631,25 @@ VALUES( 'es', 'language', 'fr', 'Espagnol'); INSERT INTO language_descriptions(subtag, type, lang, description) VALUES( 'es', 'language', 'de', 'Spanisch'); +-- Spanish, Catalan +INSERT INTO language_subtag_registry( subtag, type, description, added) +VALUES ( 'ca', 'language', 'Catalan','2013-01-12' ); + +INSERT INTO language_rfc4646_to_iso639(rfc4646_subtag,iso639_2_code) +VALUES( 'ca','cat'); + +INSERT INTO language_descriptions(subtag, type, lang, description) +VALUES( 'ca', 'language', 'es', 'Catalán'); + +INSERT INTO language_descriptions(subtag, type, lang, description) +VALUES( 'ca', 'language', 'en', 'Catalan'); + +INSERT INTO language_descriptions(subtag, type, lang, description) +VALUES( 'ca', 'language', 'fr', 'Catalan'); + +INSERT INTO language_descriptions(subtag, type, lang, description) +VALUES( 'ca', 'language', 'ca', 'Català'); + -- Swedish INSERT INTO language_subtag_registry( subtag, type, description, added) VALUES ( 'sv', 'language', 'Swedish','2005-10-16' ); diff --git a/installer/data/mysql/updatedatabase.pl b/installer/data/mysql/updatedatabase.pl index bc8375a24e..4cf26f258c 100755 --- a/installer/data/mysql/updatedatabase.pl +++ b/installer/data/mysql/updatedatabase.pl @@ -6758,6 +6758,18 @@ if ( CheckVersion($DBversion) ) { SetVersion($DBversion); } +$DBversion = "3.11.00.XXX"; +if ( CheckVersion($DBversion) ) { + $dbh->do("INSERT INTO language_subtag_registry( subtag, type, description, added) VALUES ( 'ca', 'language', 'Catalan','2013-01-12' )"); + $dbh->do("INSERT INTO language_rfc4646_to_iso639(rfc4646_subtag,iso639_2_code) VALUES( 'ca','cat')"); + $dbh->do("INSERT INTO language_descriptions(subtag, type, lang, description) VALUES( 'ca', 'language', 'es', 'Catalán')"); + $dbh->do("INSERT INTO language_descriptions(subtag, type, lang, description) VALUES( 'ca', 'language', 'en', 'Catalan')"); + $dbh->do("INSERT INTO language_descriptions(subtag, type, lang, description) VALUES( 'ca', 'language', 'fr', 'Catalan')"); + $dbh->do("INSERT INTO language_descriptions(subtag, type, lang, description) VALUES( 'ca', 'language', 'ca', 'Català')"); + print "Upgrade to $DBversion done (Bug 9381: Add Catalan laguage)\n"; + SetVersion ($DBversion); +} + =head1 FUNCTIONS =head2 TableExists($table) -- 2.39.5