[epiphany] Stop using intltool



commit b74f5c614e4cb9886e8ff6404f220b23df212be4
Author: Michael Catanzaro <mcatanzaro gnome org>
Date:   Sun Aug 7 17:31:44 2016 -0500

    Stop using intltool

 autogen.sh                   |    1 -
 configure.ac                 |    3 +-
 data/Makefile.am             |   21 +++++------
 data/epiphany.appdata.xml.in |   14 ++++----
 data/epiphany.desktop.in     |   13 ++++---
 po/Makevars                  |   78 ++++++++++++++++++++++++++++++++++++++++++
 po/POTFILES.in               |   23 ++++++------
 7 files changed, 114 insertions(+), 39 deletions(-)
---
diff --git a/autogen.sh b/autogen.sh
index 07df19f..fd01f9c 100755
--- a/autogen.sh
+++ b/autogen.sh
@@ -24,7 +24,6 @@ fi
 git submodule update --init --recursive
 
 aclocal --install || exit 1
-intltoolize --force --copy --automake || exit 1
 autoreconf --verbose --force --install -Wno-portability || exit 1
 
 cd $olddir
diff --git a/configure.ac b/configure.ac
index 6b60ec0..525be55 100644
--- a/configure.ac
+++ b/configure.ac
@@ -165,7 +165,8 @@ else
        AC_MSG_ERROR([iso-codes is required])
 fi
 
-IT_PROG_INTLTOOL([0.50.0])
+AM_GNU_GETTEXT([external])
+AM_GNU_GETTEXT_VERSION([0.19.8])
 AC_SUBST([GETTEXT_PACKAGE], [epiphany])
 
 # ****************
diff --git a/data/Makefile.am b/data/Makefile.am
index 60a2466..faa375d 100644
--- a/data/Makefile.am
+++ b/data/Makefile.am
@@ -1,13 +1,12 @@
 SUBDIRS = pages
 
-@INTLTOOL_SERVER_RULE@
-@INTLTOOL_DESKTOP_RULE@
-@INTLTOOL_XML_RULE@
-
 desktop_in_files = epiphany.desktop.in
 desktopdir = $(datadir)/applications
 desktop_DATA = $(desktop_in_files:.desktop.in=.desktop)
 
+$(desktop_DATA): $(desktop_in_files)
+       $(AM_V_GEN) $(MSGFMT) --desktop --template $< -d $(top_srcdir)/po -o $@
+
 convertdir = $(datarootdir)/GConf/gsettings
 convert_DATA = epiphany.convert
 
@@ -21,6 +20,9 @@ appstream_in_files = epiphany.appdata.xml.in
 appstream_XML = $(appstream_in_files:.xml.in=.xml)
 @APPSTREAM_XML_RULES@
 
+$(appstream_XML): $(appstream_in_files)
+       $(AM_V_GEN) $(MSGFMT) --xml --template $< -d $(top_srcdir)/po -o $@
+
 aboutdialogdir = $(pkgdatadir)
 dist_aboutdialog_DATA = about.ini
 
@@ -38,19 +40,14 @@ service_DATA = $(service_in_files:.service.in=.service)
  
 # Rule to make the service file with bindir expanded
 $(service_DATA): $(service_in_files) Makefile
-       @sed -e "s|\@libexecdir\@|$(libexecdir)|" $< > $@
+       sed -e "s|\@libexecdir[@]|$(libexecdir)|g" $< > $@
 
 # Default bookmarks
-# We don't put translations in the resulting rdf since the code can get
-# the translations via gettext (although it can also get translations
-# from the rdf if they are there and not available via gettext)
 default_bookmarksdir = $(pkgdatadir)
 default_bookmarks_in_files = default-bookmarks.rdf.in
 default_bookmarks_DATA = $(default_bookmarks_in_files:.rdf.in=.rdf)
-$(default_bookmarks_DATA): $(default_bookmarks_in_files) Makefile $(INTLTOOL_MERGE)
-       LC_ALL=C $(INTLTOOL_MERGE) -x -u /tmp $< $@.tmp
-       sed -e "s|\@pkgdatadir\@|$(pkgdatadir)|g" $@.tmp > $@ || rm -f $@.tmp
-       rm -f $@.tmp
+$(default_bookmarks_DATA): $(default_bookmarks_in_files) Makefile
+       sed -e "s|\@pkgdatadir[@]|$(pkgdatadir)|g" $< > $@
 
 searchproviderdir = $(datadir)/gnome-shell/search-providers
 dist_searchprovider_DATA = epiphany-search-provider.ini
diff --git a/data/epiphany.appdata.xml.in b/data/epiphany.appdata.xml.in
index 82dd9d0..d0088f5 100644
--- a/data/epiphany.appdata.xml.in
+++ b/data/epiphany.appdata.xml.in
@@ -3,18 +3,18 @@
 <component type="desktop">
   <id>epiphany.desktop</id>
   <metadata_license>CC0-1.0</metadata_license>
-  <_name>GNOME Web</_name>
-  <_summary>Web browser for GNOME</_summary>
+  <name>GNOME Web</name>
+  <summary>Web browser for GNOME</summary>
   <description>
-    <_p>
+    <p>
       The web browser for GNOME, featuring tight integration with the desktop
       and a simple and intuitive user interface that allows you to focus on your
       web pages. If you’re looking for a simple, clean, beautiful view of the
       web, this is the browser for you.
-    </_p>
-    <_p>
+    </p>
+    <p>
       GNOME Web is often referred to by its code name, Epiphany.
-    </_p>
+    </p>
   </description>
   <screenshots>
     <screenshot type="default">
@@ -34,7 +34,7 @@
   <project_group>GNOME</project_group>
   <compulsory_for_desktop>GNOME</compulsory_for_desktop>
   <project_license>GPL-2.0+</project_license>
-  <_developer_name>The GNOME Project</_developer_name>
+  <developer_name>The GNOME Project</developer_name>
   <url type="bugtracker">https://bugzilla.gnome.org/enter_bug.cgi?product=epiphany</url>
   <url type="donation">http://www.gnome.org/friends/</url>
   <url type="help">https://help.gnome.org/users/epiphany/stable/</url>
diff --git a/data/epiphany.desktop.in b/data/epiphany.desktop.in
index 2824ef3..8a45a0d 100644
--- a/data/epiphany.desktop.in
+++ b/data/epiphany.desktop.in
@@ -1,18 +1,19 @@
 [Desktop Entry]
-_Name=Web
-_GenericName=Web Browser
-_X-GNOME-FullName=Epiphany Web Browser
-_Comment=Browse the web
-_Keywords=web;browser;internet;
+Name=Web
+GenericName=Web Browser
+Comment=Browse the web
+# Translators: Search terms to find this application. Do NOT translate or localize the semicolons! The list 
MUST also end with a semicolon!
+Keywords=web;browser;internet;
 Exec=epiphany %U
 StartupNotify=true
 Terminal=false
 Type=Application
+# Translators: Do NOT translate or transliterate this text (this is an icon file name)!
 Icon=web-browser
 Categories=Network;GNOME;GTK;WebBrowser;
 
MimeType=text/html;text/xml;application/xhtml+xml;x-scheme-handler/http;x-scheme-handler/https;multipart/related;application/x-mimearchive;message/rfc822;
 Actions=Incognito;
 
 [Desktop Action Incognito]
-_Name=New Incognito Window
+Name=New Incognito Window
 Exec=epiphany --incognito-mode
diff --git a/po/Makevars b/po/Makevars
new file mode 100644
index 0000000..25d345b
--- /dev/null
+++ b/po/Makevars
@@ -0,0 +1,78 @@
+# Makefile variables for PO directory in any package using GNU gettext.
+
+# Usually the message domain is the same as the package name.
+DOMAIN = $(PACKAGE)
+
+# These two variables depend on the location of this directory.
+subdir = po
+top_builddir = ..
+
+# These options get passed to xgettext.
+XGETTEXT_OPTIONS = --keyword=_ --keyword=N_ --from-code=UTF-8
+
+# This is the copyright holder that gets inserted into the header of the
+# $(DOMAIN).pot file.  Set this to the copyright holder of the surrounding
+# package.  (Note that the msgstr strings, extracted from the package's
+# sources, belong to the copyright holder of the package.)  Translators are
+# expected to transfer the copyright for their translations to this person
+# or entity, or to disclaim their copyright.  The empty string stands for
+# the public domain; in this case the translators are expected to disclaim
+# their copyright.
+COPYRIGHT_HOLDER = Free Software Foundation, Inc.
+
+# This tells whether or not to prepend "GNU " prefix to the package
+# name that gets inserted into the header of the $(DOMAIN).pot file.
+# Possible values are "yes", "no", or empty.  If it is empty, try to
+# detect it automatically by scanning the files in $(top_srcdir) for
+# "GNU packagename" string.
+PACKAGE_GNU = no
+
+# This is the email address or URL to which the translators shall report
+# bugs in the untranslated strings:
+# - Strings which are not entire sentences, see the maintainer guidelines
+#   in the GNU gettext documentation, section 'Preparing Strings'.
+# - Strings which use unclear terms or require additional context to be
+#   understood.
+# - Strings which make invalid assumptions about notation of date, time or
+#   money.
+# - Pluralisation problems.
+# - Incorrect English spelling.
+# - Incorrect formatting.
+# It can be your email address, or a mailing list address where translators
+# can write to without being subscribed, or the URL of a web page through
+# which the translators can contact you.
+MSGID_BUGS_ADDRESS =
+
+# This is the list of locale categories, beyond LC_MESSAGES, for which the
+# message catalogs shall be used.  It is usually empty.
+EXTRA_LOCALE_CATEGORIES =
+
+# This tells whether the $(DOMAIN).pot file contains messages with an 'msgctxt'
+# context.  Possible values are "yes" and "no".  Set this to yes if the
+# package uses functions taking also a message context, like pgettext(), or
+# if in $(XGETTEXT_OPTIONS) you define keywords with a context argument.
+USE_MSGCTXT = yes
+
+# These options get passed to msgmerge.
+# Useful options are in particular:
+#   --previous            to keep previous msgids of translated messages,
+#   --quiet               to reduce the verbosity.
+MSGMERGE_OPTIONS =
+
+# These options get passed to msginit.
+# If you want to disable line wrapping when writing PO files, add
+# --no-wrap to MSGMERGE_OPTIONS, XGETTEXT_OPTIONS, and
+# MSGINIT_OPTIONS.
+MSGINIT_OPTIONS =
+
+# This tells whether or not to regenerate a PO file when $(DOMAIN).pot
+# has changed.  Possible values are "yes" and "no".  Set this to no if
+# the POT file is checked in the repository and the version control
+# program ignores timestamps.
+PO_DEPENDS_ON_POT = no
+
+# This tells whether or not to forcibly update $(DOMAIN).pot and
+# regenerate PO files on "make dist".  Possible values are "yes" and
+# "no".  Set this to no if the POT file and PO files are maintained
+# externally.
+DIST_DEPENDS_ON_UPDATE_PO = no
diff --git a/po/POTFILES.in b/po/POTFILES.in
index c3e83fc..69806b1 100644
--- a/po/POTFILES.in
+++ b/po/POTFILES.in
@@ -1,4 +1,3 @@
-[encoding: UTF-8]
 # List of source files containing translatable strings.
 # Please keep this file sorted alphabetically.
 data/epiphany.appdata.xml.in
@@ -52,15 +51,15 @@ src/ephy-window.c
 src/passwords-dialog.c
 src/popup-commands.c
 src/prefs-dialog.c
-[type: gettext/glade]src/resources/bookmark-properties.ui
-[type: gettext/glade]src/resources/clear-data-dialog.ui
-[type: gettext/glade]src/resources/cookies-dialog.ui
-[type: gettext/glade]src/resources/encoding-dialog.ui
-[type: gettext/glade]src/resources/epiphany-application-menu.ui
-[type: gettext/glade]src/resources/gtk/menus.ui
-[type: gettext/glade]src/resources/history-dialog.ui
-[type: gettext/glade]src/resources/passwords-dialog.ui
-[type: gettext/glade]src/resources/prefs-dialog.ui
-[type: gettext/glade]src/resources/prefs-lang-dialog.ui
-[type: gettext/glade]src/resources/shortcuts-dialog.ui
+src/resources/bookmark-properties.ui
+src/resources/clear-data-dialog.ui
+src/resources/cookies-dialog.ui
+src/resources/encoding-dialog.ui
+src/resources/epiphany-application-menu.ui
+src/resources/gtk/menus.ui
+src/resources/history-dialog.ui
+src/resources/passwords-dialog.ui
+src/resources/prefs-dialog.ui
+src/resources/prefs-lang-dialog.ui
+src/resources/shortcuts-dialog.ui
 src/window-commands.c


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]