diff -u yelp-2.21.90/debian/changelog yelp-2.21.90/debian/changelog --- yelp-2.21.90/debian/changelog +++ yelp-2.21.90/debian/changelog @@ -1,3 +1,11 @@ +yelp (2.21.90-0ubuntu2) UNRELEASED; urgency=low + + * debian/patches/07_man_utf8.patch: + - Recode manual pages to UTF-8 (LP: #154829). Requires man-db (>= + 2.5.1-1). + + -- Colin Watson Thu, 31 Jan 2008 13:22:27 +0000 + yelp (2.21.90-0ubuntu1) hardy; urgency=low * New upstream version only in patch2: unchanged: --- yelp-2.21.90.orig/debian/patches/07_man_utf8.patch +++ yelp-2.21.90/debian/patches/07_man_utf8.patch @@ -0,0 +1,35 @@ +diff -Nur -x '*.orig' -x '*~' yelp-2.21.90/src/yelp-man-parser.c yelp-2.21.90.new/src/yelp-man-parser.c +--- yelp-2.21.90/src/yelp-man-parser.c 2008-01-31 13:35:50.000000000 +0000 ++++ yelp-2.21.90.new/src/yelp-man-parser.c 2008-01-31 13:43:32.000000000 +0000 +@@ -99,12 +99,30 @@ + { + GError *errormsg = NULL; + /*gchar *ptr = NULL;*/ ++ gchar **recode_argv; ++ gint recode_stdout_fd; + + g_return_val_if_fail (parser != NULL, NULL); + g_return_val_if_fail (file != NULL, NULL); + g_return_val_if_fail (encoding != NULL, NULL); + +- parser->channel = yelp_io_channel_new_file (file, NULL); ++ recode_argv = g_new (gchar *, 5); ++ recode_argv[0] = g_strdup ("man"); ++ recode_argv[1] = g_strdup ("--recode"); ++ recode_argv[2] = g_strdup ("UTF-8"); ++ recode_argv[3] = g_strdup (file); ++ recode_argv[4] = NULL; ++ if (g_spawn_async_with_pipes (NULL, recode_argv, NULL, ++ G_SPAWN_SEARCH_PATH | ++ G_SPAWN_STDERR_TO_DEV_NULL, ++ NULL, NULL, NULL, ++ NULL, &recode_stdout_fd, NULL, ++ NULL)) { ++ parser->channel = g_io_channel_unix_new (recode_stdout_fd); ++ encoding = "UTF-8"; ++ } else ++ parser->channel = yelp_io_channel_new_file (file, NULL); ++ g_strfreev (recode_argv); + + if (!parser->channel) + return NULL;