Another attempt to fix wxWidgets i18n on Debian/Ubuntu.
authorCarl Hetherington <cth@carlh.net>
Mon, 13 Oct 2014 22:27:24 +0000 (23:27 +0100)
committerCarl Hetherington <cth@carlh.net>
Mon, 13 Oct 2014 22:27:24 +0000 (23:27 +0100)
debian/dcpomatic.install [deleted file]
debian/rules
src/wx/wx_util.cc

diff --git a/debian/dcpomatic.install b/debian/dcpomatic.install
deleted file mode 100644 (file)
index 67b55ae..0000000
+++ /dev/null
@@ -1,6 +0,0 @@
-usr/local/share/locale/de/LC_MESSAGES/wxstd.mo usr/share/locale/de/LC_MESSAGES/dcpomatic-wxstd.mo
-usr/local/share/locale/es/LC_MESSAGES/wxstd.mo usr/share/locale/es/LC_MESSAGES/dcpomatic-wxstd.mo
-usr/local/share/locale/fr/LC_MESSAGES/wxstd.mo usr/share/locale/fr/LC_MESSAGES/dcpomatic-wxstd.mo
-usr/local/share/locale/it/LC_MESSAGES/wxstd.mo usr/share/locale/it/LC_MESSAGES/dcpomatic-wxstd.mo
-usr/local/share/locale/sv/LC_MESSAGES/wxstd.mo usr/share/locale/sv/LC_MESSAGES/dcpomatic-wxstd.mo
-usr/local/share/locale/nl/LC_MESSAGES/wxstd.mo usr/share/locale/nl/LC_MESSAGES/dcpomatic-wxstd.mo
index 619dfff5ea6d4afce35cebadf39e0993cd9901d1..b8f7b7026ecf1ab80f4c18bc1985c9fb9820c13e 100755 (executable)
@@ -21,6 +21,12 @@ override_dh_auto_build:
 
 override_dh_auto_install:
        ./waf --nocache install --destdir=debian/dcpomatic
+       cp -a /usr/local/share/locale/de/LC_MESSAGES/wxstd.mo debian/dcpomatic/usr/share/locale/de/LC_MESSAGES/dcpomatic-wxstd.mo
+       cp -a /usr/local/share/locale/es/LC_MESSAGES/wxstd.mo debian/dcpomatic/usr/share/locale/es/LC_MESSAGES/dcpomatic-wxstd.mo
+       cp -a /usr/local/share/locale/fr/LC_MESSAGES/wxstd.mo debian/dcpomatic/usr/share/locale/fr/LC_MESSAGES/dcpomatic-wxstd.mo
+       cp -a /usr/local/share/locale/it/LC_MESSAGES/wxstd.mo debian/dcpomatic/usr/share/locale/it/LC_MESSAGES/dcpomatic-wxstd.mo
+       cp -a /usr/local/share/locale/sv/LC_MESSAGES/wxstd.mo debian/dcpomatic/usr/share/locale/sv/LC_MESSAGES/dcpomatic-wxstd.mo
+       cp -a /usr/local/share/locale/nl/LC_MESSAGES/wxstd.mo debian/dcpomatic/usr/share/locale/nl/LC_MESSAGES/dcpomatic-wxstd.mo
 
 .PHONY: override_dh_strip
 override_dh_strip:
index 1e501f54fd5650a892b0ab5a2d189ba950482eac..7f15217f14a65490345aacf3a4b81551de8f892c 100644 (file)
@@ -280,6 +280,14 @@ dcpomatic_setup_i18n ()
                locale->AddCatalogLookupPathPrefix (POSIX_LOCALE_PREFIX);
 #endif
 
+#ifdef DCPOMATIC_LINUX
+               /* We have to include the wxWidgets .mo in our distribution,
+                  so we rename it to avoid clashes with any other installation
+                  of wxWidgets.
+               */
+               locale->AddCatalog (wxT ("dcpomatic-wxstd"));
+#endif         
+               
                locale->AddCatalog (wxT ("libdcpomatic-wx"));
                locale->AddCatalog (wxT ("dcpomatic"));