summaryrefslogtreecommitdiffstats
path: root/kgamma/configure.in.in
diff options
context:
space:
mode:
Diffstat (limited to 'kgamma/configure.in.in')
-rw-r--r--kgamma/configure.in.in65
1 files changed, 65 insertions, 0 deletions
diff --git a/kgamma/configure.in.in b/kgamma/configure.in.in
new file mode 100644
index 00000000..d4e1a9f4
--- /dev/null
+++ b/kgamma/configure.in.in
@@ -0,0 +1,65 @@
+#MIN_CONFIG(3)
+
+AM_INIT_AUTOMAKE(kgamma,1.0.2)
+
+dnl CXXFLAGS="$NOOPT_CXXFLAGS" dnl __kdevelop[noopt]__
+dnl CFLAGS="$NOOPT_CFLAGS" dnl __kdevelop[noopt]__
+dnl CXXFLAGS="$CXXFLAGS $USE_EXCEPTIONS" dnl __kdevelop[exc]__
+
+dnl KDE_NEED_FLEX dnl __kdevelop__
+dnl AC_PROG_YACC dnl __kdevelop__
+
+dnl This test is taken from the aktion configure.in.in
+dnl Modified by Michael v.Ostheim
+dnl Checking for XFree86 VidMode Extensions
+AC_MSG_CHECKING([for XFree86-VidModeExtension])
+
+AC_CACHE_VAL(ac_cv_lib_vm,
+ [ac_save_LIBS="$LIBS"
+ kgamma_save_CFLAGS=$CFLAGS
+ CFLAGS="$CFLAGS $all_includes"
+ LIBS="-L$x_libraries -lXxf86vm -lXext -lX11"
+ AC_TRY_LINK( [
+ #include <X11/Xlib.h>
+ #include <X11/Xatom.h>
+ #include <X11/extensions/xf86vmode.h>
+ ],
+ [],
+ eval "ac_cv_lib_vm='-lXxf86vm'",
+ [AC_MSG_RESULT(no)
+ eval "ac_cv_lib_vm=no"])
+ LIBS="$ac_save_LIBS"
+ CFLAGS=$kgamma_save_CFLAGS
+])
+
+if eval "test ! \"`echo $ac_cv_lib_vm`\" = no"; then
+ LIBVM="$ac_cv_lib_vm"
+ AC_SUBST(LIBVM)
+ AC_MSG_RESULT($ac_cv_lib_vm)
+
+ AC_MSG_CHECKING([for gamma functions in XFree86-VidModeExtension])
+
+ AC_CACHE_VAL(ac_cv_lib_vmgamma,
+ [ac_save_LIBS="$LIBS"
+ kgamma_save_CFLAGS=$CFLAGS
+ CFLAGS="$CFLAGS $all_includes"
+ LIBS="-L$x_libraries -lXxf86vm -lXext -lX11"
+ AC_TRY_LINK( [],
+ [XF86VidModeGetGamma();],
+ [AC_MSG_RESULT(yes)
+ eval "ac_cv_lib_vm='-lXxf86vm'"],
+ [AC_MSG_RESULT(no)
+ eval "ac_cv_lib_vm=no"])
+ LIBS="$ac_save_LIBS"
+ CFLAGS=$kgamma_save_CFLAGS
+ ])
+fi
+
+if eval "test \"`echo $ac_cv_lib_vm`\" = no"; then
+ DO_NOT_COMPILE="$DO_NOT_COMPILE kgamma"
+fi
+
+AC_LANG_SAVE
+AC_LANG_CPLUSPLUS
+AC_CHECK_HEADERS(sstream)
+AC_LANG_RESTORE