diff configure.in @ 113:55166d93498d

Fri Nov 24 21:37:01 2006 John Ellis <johne@verizon.net> * configure.in: Add test for lcms (little cms). * Makefile.am: Add color-man.[ch]: * color-man.[ch]: New files for color management support. * globals.c, gqview.h, main.c, rcfile.c, typedefs.h: Add color profile variables and option saving. * image.[ch]: Add color profile functions. * layout.c, layout_image.[ch]: Add color profile icon, popup menu, and fix sort menu to use radio buttons. * menu.c: Use radio buttons for sort menu when appropriate. * preferences.c: Add color profile options to preferences. * ui_menu.[ch]: Add menu_item_add_radio() for radio item menus. * ui_misc.c: Fix gtk_table_attach() arg for vertical expansion. * view_file_icon.c, view_file_list.c: Check for active state in sort menu callbacks. * README: Add info about lcms, and how to disable.
author gqview
date Sat, 25 Nov 2006 03:00:33 +0000
parents d19b0de6d0bb
children 648881af5fb1
line wrap: on
line diff
--- a/configure.in	Sat Nov 18 00:12:22 2006 +0000
+++ b/configure.in	Sat Nov 25 03:00:33 2006 +0000
@@ -25,6 +25,33 @@
 dnl checks for functions
 AC_CHECK_FUNCS(strverscmp)
 
+dnl check for little cms (lcms, this test pulled from gimp)
+AC_ARG_WITH(lcms, [  --without-lcms          build without lcms support])
+
+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]))
+      ])
+  ])
+  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)"
+  fi
+else
+  have_lcms="no (lcms support disabled)"
+fi
+
+AC_SUBST(LCMS_LIBS)
+AM_CONDITIONAL(HAVE_LCMS, test "$have_lcms" = "yes")
+
 ALL_LINGUAS="ar be bg ca cs da de eo es et eu fi fr hu id it ja ko nl no pl pt_BR ro ru sk sl sv th tr uk vi zh_CN.GB2312 zh_TW"
 GETTEXT_PACKAGE=$PACKAGE
 AC_SUBST(GETTEXT_PACKAGE)