diff -Nurd -x'*~' gqview-2.1.5.orig/configure.in gqview-2.1.5/configure.in --- gqview-2.1.5.orig/configure.in 2006-12-02 20:40:34.000000000 -0500 +++ gqview-2.1.5/configure.in 2015-02-23 05:53:39.000000000 -0500 @@ -30,17 +30,11 @@ have_lcms=no if test "x$with_lcms" != "xno"; then - AC_CHECK_LIB(lcms, cmsCreate_sRGBProfile, [ - AC_CHECK_HEADER(lcms.h, - have_lcms=yes, [ - AC_CHECK_HEADER(lcms/lcms.h, - have_lcms=yes - AC_DEFINE(HAVE_LCMS_LCMS_H, 1, - [Define to 1 if the lcms header must be included as lcms/lcms.h])) - ]) + PKG_CHECK_MODULES(LCMS, [lcms2 >= 2.0], [ + have_lcms=yes + AC_DEFINE(HAVE_LCMS2, 1, [lcms2 is used]) ]) if test "$have_lcms" = "yes"; then - LCMS_LIBS="-llcms" AC_DEFINE(HAVE_LCMS, 1, [define to enable use of color profiles with lcms]) else have_lcms="no (lcms not found or unusable)" diff -Nurd -x'*~' gqview-2.1.5.orig/src/Makefile.in gqview-2.1.5/src/Makefile.in --- gqview-2.1.5.orig/src/Makefile.in 2006-12-02 20:41:25.000000000 -0500 +++ gqview-2.1.5/src/Makefile.in 2015-02-23 05:46:52.000000000 -0500 @@ -198,7 +198,7 @@ target_alias = @target_alias@ SUBDIRS = icons DIST_SUBDIRS = icons -INCLUDES = -I$(srcdir) -I$(builddir) \ +INCLUDES = -I$(srcdir) \ -I$(top_srcdir) -I$(top_builddir) \ -I$(includedir) $(GTK_CFLAGS) diff -Nurd -x'*~' gqview-2.1.5.orig/src/color-man.c gqview-2.1.5/src/color-man.c --- gqview-2.1.5.orig/src/color-man.c 2006-11-28 11:22:33.000000000 -0500 +++ gqview-2.1.5/src/color-man.c 2015-02-23 05:44:45.000000000 -0500 @@ -20,11 +20,15 @@ #ifdef HAVE_LCMS /*** color support enabled ***/ +#ifdef HAVE_LCMS2 +#include +#else #ifdef HAVE_LCMS_LCMS_H #include #else #include #endif +#endif typedef struct _ColorManCache ColorManCache; @@ -55,7 +59,9 @@ if (init_done) return; init_done = TRUE; +#ifndef HAVE_LCMS2 cmsErrorAction(LCMS_ERROR_IGNORE); +#endif } diff -Nurd -x'*~' gqview-2.1.5.orig/src/print.c gqview-2.1.5/src/print.c --- gqview-2.1.5.orig/src/print.c 2006-12-01 14:00:42.000000000 -0500 +++ gqview-2.1.5/src/print.c 2013-07-23 03:06:22.000000000 -0400 @@ -1220,7 +1220,7 @@ } text[6] = '\0'; - fprintf(f, text); + fprintf(f, "%s", text); } static gint print_job_ps_page_image(PrintWindow *pw, GdkPixbuf *pixbuf, gdouble x, gdouble y, gdouble w, gdouble h, @@ -1345,7 +1345,7 @@ text[1] = hex_digits[*p & 0xf]; text[2] = '\0'; - fprintf(f, text); + fprintf(f, "%s", text); p++; } diff -Nurd -x'*~' gqview-2.1.5.orig/src/remote.c gqview-2.1.5/src/remote.c --- gqview-2.1.5.orig/src/remote.c 2005-08-15 17:06:37.000000000 -0400 +++ gqview-2.1.5/src/remote.c 2013-07-23 03:16:57.000000000 -0400 @@ -52,7 +52,7 @@ GList *work; gchar *buffer = NULL; GError *error = NULL; - guint termpos; + gsize termpos; while (g_io_channel_read_line(source, &buffer, NULL, &termpos, &error) == G_IO_STATUS_NORMAL) { diff -Nurd -x'*~' gqview-2.1.5.orig/src/ui_fileops.c gqview-2.1.5/src/ui_fileops.c --- gqview-2.1.5.orig/src/ui_fileops.c 2006-11-17 17:55:32.000000000 -0500 +++ gqview-2.1.5/src/ui_fileops.c 2013-07-23 03:04:52.000000000 -0400 @@ -44,7 +44,7 @@ gchar *text_l; text_l = g_locale_from_utf8(text_utf8, -1, NULL, NULL, NULL); - printf((text_l) ? text_l : text_utf8); + printf("%s", (text_l) ? text_l : text_utf8); g_free(text_l); } diff -Nurd -x'*~' gqview-2.1.5.orig/src/view_file_icon.c gqview-2.1.5/src/view_file_icon.c --- gqview-2.1.5.orig/src/view_file_icon.c 2006-11-24 20:01:43.000000000 -0500 +++ gqview-2.1.5/src/view_file_icon.c 2013-07-23 03:03:54.000000000 -0400 @@ -614,7 +614,7 @@ uri_text = uri_text_from_list(list, &total, (info == TARGET_TEXT_PLAIN)); path_list_free(list); - if (debug) printf(uri_text); + if (debug) printf("%s", uri_text); gtk_selection_data_set(selection_data, selection_data->target, 8, (guchar *)uri_text, total); diff -Nurd -x'*~' gqview-2.1.5.orig/src/view_file_list.c gqview-2.1.5/src/view_file_list.c --- gqview-2.1.5.orig/src/view_file_list.c 2006-11-24 20:02:18.000000000 -0500 +++ gqview-2.1.5/src/view_file_list.c 2013-07-23 03:03:50.000000000 -0400 @@ -136,7 +136,7 @@ uri_text = uri_text_from_list(list, &total, (info == TARGET_TEXT_PLAIN)); path_list_free(list); - if (debug) printf(uri_text); + if (debug) printf("%s", uri_text); gtk_selection_data_set(selection_data, selection_data->target, 8, (guchar *)uri_text, total);