summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--driver/xf86-input-keyboard/Makefile.bsd-wrapper8
-rw-r--r--driver/xf86-input-keyboard/config.h.in3
-rw-r--r--driver/xf86-input-keyboard/configure64
-rw-r--r--driver/xf86-input-keyboard/configure.ac9
-rw-r--r--driver/xf86-input-keyboard/src/bsd_kbd.c4
-rw-r--r--driver/xf86-input-keyboard/src/kbd.c5
-rw-r--r--kdrive/Makefile.bsd-wrapper5
-rw-r--r--xserver/Makefile.bsd-wrapper5
8 files changed, 77 insertions, 26 deletions
diff --git a/driver/xf86-input-keyboard/Makefile.bsd-wrapper b/driver/xf86-input-keyboard/Makefile.bsd-wrapper
index cd59c5869..233ceaa49 100644
--- a/driver/xf86-input-keyboard/Makefile.bsd-wrapper
+++ b/driver/xf86-input-keyboard/Makefile.bsd-wrapper
@@ -1,3 +1,9 @@
-# $OpenBSD: Makefile.bsd-wrapper,v 1.2 2006/11/27 19:30:44 matthieu Exp $
+# $OpenBSD: Makefile.bsd-wrapper,v 1.3 2011/05/30 10:52:57 shadchin Exp $
+
+.include <bsd.xconf.mk>
+
+.if ${XENOCARA_USE_XKEYBOARD_CONFIG:L} == "yes"
+CONFIGURE_ARGS+= --enable-xkeyboard-config
+.endif
.include <bsd.xorg.mk>
diff --git a/driver/xf86-input-keyboard/config.h.in b/driver/xf86-input-keyboard/config.h.in
index 14da6e208..1f3dde794 100644
--- a/driver/xf86-input-keyboard/config.h.in
+++ b/driver/xf86-input-keyboard/config.h.in
@@ -60,5 +60,8 @@
/* Define to 1 if you have the ANSI C header files. */
#undef STDC_HEADERS
+/* Enable using xkeyboard-config */
+#undef USE_XKEYBOARD_CONFIG
+
/* Version number of package */
#undef VERSION
diff --git a/driver/xf86-input-keyboard/configure b/driver/xf86-input-keyboard/configure
index 44e525289..fb83a33a3 100644
--- a/driver/xf86-input-keyboard/configure
+++ b/driver/xf86-input-keyboard/configure
@@ -944,6 +944,7 @@ with_pic
with_tags
enable_strict_compilation
with_xorg_module_dir
+enable_xkeyboard_config
'
ac_precious_vars='build_alias
host_alias
@@ -1606,6 +1607,8 @@ Optional Features:
--enable-strict-compilation
Enable all warnings from compiler and make them
errors (default: disabled)
+ --enable-xkeyboard-config
+ Enable using xkeyboard-config (default: disabled)
Optional Packages:
--with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
@@ -4428,7 +4431,7 @@ ia64-*-hpux*)
;;
*-*-irix6*)
# Find out which ABI we are using.
- echo '#line 4431 "configure"' > conftest.$ac_ext
+ echo '#line 4434 "configure"' > conftest.$ac_ext
if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
(eval $ac_compile) 2>&5
ac_status=$?
@@ -7536,11 +7539,11 @@ else
-e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
-e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
-e 's:$: $lt_compiler_flag:'`
- (eval echo "\"\$as_me:7539: $lt_compile\"" >&5)
+ (eval echo "\"\$as_me:7542: $lt_compile\"" >&5)
(eval "$lt_compile" 2>conftest.err)
ac_status=$?
cat conftest.err >&5
- echo "$as_me:7543: \$? = $ac_status" >&5
+ echo "$as_me:7546: \$? = $ac_status" >&5
if (exit $ac_status) && test -s "$ac_outfile"; then
# The compiler can only warn and ignore the option if not recognized
# So say no if there are warnings other than the usual output.
@@ -7826,11 +7829,11 @@ else
-e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
-e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
-e 's:$: $lt_compiler_flag:'`
- (eval echo "\"\$as_me:7829: $lt_compile\"" >&5)
+ (eval echo "\"\$as_me:7832: $lt_compile\"" >&5)
(eval "$lt_compile" 2>conftest.err)
ac_status=$?
cat conftest.err >&5
- echo "$as_me:7833: \$? = $ac_status" >&5
+ echo "$as_me:7836: \$? = $ac_status" >&5
if (exit $ac_status) && test -s "$ac_outfile"; then
# The compiler can only warn and ignore the option if not recognized
# So say no if there are warnings other than the usual output.
@@ -7930,11 +7933,11 @@ else
-e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
-e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
-e 's:$: $lt_compiler_flag:'`
- (eval echo "\"\$as_me:7933: $lt_compile\"" >&5)
+ (eval echo "\"\$as_me:7936: $lt_compile\"" >&5)
(eval "$lt_compile" 2>out/conftest.err)
ac_status=$?
cat out/conftest.err >&5
- echo "$as_me:7937: \$? = $ac_status" >&5
+ echo "$as_me:7940: \$? = $ac_status" >&5
if (exit $ac_status) && test -s out/conftest2.$ac_objext
then
# The compiler can only warn and ignore the option if not recognized
@@ -10330,7 +10333,7 @@ else
lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
lt_status=$lt_dlunknown
cat > conftest.$ac_ext <<EOF
-#line 10333 "configure"
+#line 10336 "configure"
#include "confdefs.h"
#if HAVE_DLFCN_H
@@ -10430,7 +10433,7 @@ else
lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
lt_status=$lt_dlunknown
cat > conftest.$ac_ext <<EOF
-#line 10433 "configure"
+#line 10436 "configure"
#include "confdefs.h"
#if HAVE_DLFCN_H
@@ -12839,11 +12842,11 @@ else
-e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
-e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
-e 's:$: $lt_compiler_flag:'`
- (eval echo "\"\$as_me:12842: $lt_compile\"" >&5)
+ (eval echo "\"\$as_me:12845: $lt_compile\"" >&5)
(eval "$lt_compile" 2>conftest.err)
ac_status=$?
cat conftest.err >&5
- echo "$as_me:12846: \$? = $ac_status" >&5
+ echo "$as_me:12849: \$? = $ac_status" >&5
if (exit $ac_status) && test -s "$ac_outfile"; then
# The compiler can only warn and ignore the option if not recognized
# So say no if there are warnings other than the usual output.
@@ -12943,11 +12946,11 @@ else
-e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
-e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
-e 's:$: $lt_compiler_flag:'`
- (eval echo "\"\$as_me:12946: $lt_compile\"" >&5)
+ (eval echo "\"\$as_me:12949: $lt_compile\"" >&5)
(eval "$lt_compile" 2>out/conftest.err)
ac_status=$?
cat out/conftest.err >&5
- echo "$as_me:12950: \$? = $ac_status" >&5
+ echo "$as_me:12953: \$? = $ac_status" >&5
if (exit $ac_status) && test -s out/conftest2.$ac_objext
then
# The compiler can only warn and ignore the option if not recognized
@@ -14526,11 +14529,11 @@ else
-e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
-e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
-e 's:$: $lt_compiler_flag:'`
- (eval echo "\"\$as_me:14529: $lt_compile\"" >&5)
+ (eval echo "\"\$as_me:14532: $lt_compile\"" >&5)
(eval "$lt_compile" 2>conftest.err)
ac_status=$?
cat conftest.err >&5
- echo "$as_me:14533: \$? = $ac_status" >&5
+ echo "$as_me:14536: \$? = $ac_status" >&5
if (exit $ac_status) && test -s "$ac_outfile"; then
# The compiler can only warn and ignore the option if not recognized
# So say no if there are warnings other than the usual output.
@@ -14630,11 +14633,11 @@ else
-e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
-e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
-e 's:$: $lt_compiler_flag:'`
- (eval echo "\"\$as_me:14633: $lt_compile\"" >&5)
+ (eval echo "\"\$as_me:14636: $lt_compile\"" >&5)
(eval "$lt_compile" 2>out/conftest.err)
ac_status=$?
cat out/conftest.err >&5
- echo "$as_me:14637: \$? = $ac_status" >&5
+ echo "$as_me:14640: \$? = $ac_status" >&5
if (exit $ac_status) && test -s out/conftest2.$ac_objext
then
# The compiler can only warn and ignore the option if not recognized
@@ -16845,11 +16848,11 @@ else
-e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
-e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
-e 's:$: $lt_compiler_flag:'`
- (eval echo "\"\$as_me:16848: $lt_compile\"" >&5)
+ (eval echo "\"\$as_me:16851: $lt_compile\"" >&5)
(eval "$lt_compile" 2>conftest.err)
ac_status=$?
cat conftest.err >&5
- echo "$as_me:16852: \$? = $ac_status" >&5
+ echo "$as_me:16855: \$? = $ac_status" >&5
if (exit $ac_status) && test -s "$ac_outfile"; then
# The compiler can only warn and ignore the option if not recognized
# So say no if there are warnings other than the usual output.
@@ -17135,11 +17138,11 @@ else
-e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
-e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
-e 's:$: $lt_compiler_flag:'`
- (eval echo "\"\$as_me:17138: $lt_compile\"" >&5)
+ (eval echo "\"\$as_me:17141: $lt_compile\"" >&5)
(eval "$lt_compile" 2>conftest.err)
ac_status=$?
cat conftest.err >&5
- echo "$as_me:17142: \$? = $ac_status" >&5
+ echo "$as_me:17145: \$? = $ac_status" >&5
if (exit $ac_status) && test -s "$ac_outfile"; then
# The compiler can only warn and ignore the option if not recognized
# So say no if there are warnings other than the usual output.
@@ -17239,11 +17242,11 @@ else
-e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
-e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
-e 's:$: $lt_compiler_flag:'`
- (eval echo "\"\$as_me:17242: $lt_compile\"" >&5)
+ (eval echo "\"\$as_me:17245: $lt_compile\"" >&5)
(eval "$lt_compile" 2>out/conftest.err)
ac_status=$?
cat out/conftest.err >&5
- echo "$as_me:17246: \$? = $ac_status" >&5
+ echo "$as_me:17249: \$? = $ac_status" >&5
if (exit $ac_status) && test -s out/conftest2.$ac_objext
then
# The compiler can only warn and ignore the option if not recognized
@@ -20883,6 +20886,21 @@ fi
DRIVER_NAME=kbd
+# Check whether --enable-xkeyboard-config was given.
+if test "${enable_xkeyboard_config+set}" = set; then
+ enableval=$enable_xkeyboard_config; XKEYBOARD_CONFIG="${enableval}"
+else
+ XKEYBOARD_CONFIG="no"
+fi
+
+if test "x$XKEYBOARD_CONFIG" = xyes ; then
+
+cat >>confdefs.h <<\_ACEOF
+#define USE_XKEYBOARD_CONFIG 1
+_ACEOF
+
+fi
+
ac_config_files="$ac_config_files Makefile src/Makefile man/Makefile"
cat >confcache <<\_ACEOF
diff --git a/driver/xf86-input-keyboard/configure.ac b/driver/xf86-input-keyboard/configure.ac
index 869283643..302d53710 100644
--- a/driver/xf86-input-keyboard/configure.ac
+++ b/driver/xf86-input-keyboard/configure.ac
@@ -88,6 +88,15 @@ AM_CONDITIONAL(HURD, [test "x$IS_HURD" = xyes])
DRIVER_NAME=kbd
AC_SUBST([DRIVER_NAME])
+AC_ARG_ENABLE(xkeyboard-config,
+ AS_HELP_STRING([--enable-xkeyboard-config],
+ [Enable using xkeyboard-config (default: disabled)]),
+ [ XKEYBOARD_CONFIG="${enableval}" ],
+ [ XKEYBOARD_CONFIG="no" ])
+if test "x$XKEYBOARD_CONFIG" = xyes ; then
+ AC_DEFINE(USE_XKEYBOARD_CONFIG, 1, [Enable using xkeyboard-config])
+fi
+
AC_CONFIG_FILES([Makefile
src/Makefile
man/Makefile])
diff --git a/driver/xf86-input-keyboard/src/bsd_kbd.c b/driver/xf86-input-keyboard/src/bsd_kbd.c
index 69ac04cbd..a8a198f85 100644
--- a/driver/xf86-input-keyboard/src/bsd_kbd.c
+++ b/driver/xf86-input-keyboard/src/bsd_kbd.c
@@ -57,7 +57,11 @@ struct nameint kbdvar[] = {
};
struct nameint kbdopt[] = {
+#ifndef USE_XKEYBOARD_CONFIG
{ KB_SWAPCTRLCAPS, "ctrl:swapcaps" },
+#else
+ { KB_SWAPCTRLCAPS, "ctrl:swapcaps,terminate:ctrl_alt_bksp" },
+#endif
{ 0 }
};
#endif
diff --git a/driver/xf86-input-keyboard/src/kbd.c b/driver/xf86-input-keyboard/src/kbd.c
index 06e1a6088..d8a43d27a 100644
--- a/driver/xf86-input-keyboard/src/kbd.c
+++ b/driver/xf86-input-keyboard/src/kbd.c
@@ -208,6 +208,11 @@ KbdPreInit(InputDriverPtr drv, InputInfoPtr pInfo, int flags)
xkb_variant = xf86SetStrOption(pInfo->options, "XkbVariant", NULL);
xkb_options = xf86SetStrOption(pInfo->options, "XkbOptions", NULL);
+#ifdef USE_XKEYBOARD_CONFIG
+ if (xkb_options == NULL)
+ xkb_options = "terminate:ctrl_alt_bksp";
+#endif
+
pKbd->CustomKeycodes = xf86SetBoolOption(pInfo->options, "CustomKeycodes",
FALSE);
diff --git a/kdrive/Makefile.bsd-wrapper b/kdrive/Makefile.bsd-wrapper
index 429b81d31..21e033c4e 100644
--- a/kdrive/Makefile.bsd-wrapper
+++ b/kdrive/Makefile.bsd-wrapper
@@ -1,4 +1,4 @@
-# $OpenBSD: Makefile.bsd-wrapper,v 1.9 2011/04/27 20:58:34 matthieu Exp $
+# $OpenBSD: Makefile.bsd-wrapper,v 1.10 2011/05/30 10:52:58 shadchin Exp $
.include <bsd.xconf.mk>
@@ -7,15 +7,18 @@ _SRCDIR= ${.CURDIR}/../xserver
.if ${XENOCARA_USE_XKEYBOARD_CONFIG:L} == "yes"
XKB_PATH= ${X11BASE}/share/X11/xkb
XKB_RULES= base
+XKB_OPTIONS= terminate:ctrl_alt_bksp
.else
XKB_PATH= /etc/X11/xkb
XKB_RULES= xorg
+XKB_OPTIONS=
.endif
CONFIGURE_ARGS= --localstatedir=/var --sysconfdir=/etc/X11 \
--with-xkb-path=${XKB_PATH} \
--with-xkb-output=/var/db/xkb \
--with-default-xkb-rules=${XKB_RULES} \
+ --with-default-xkb-options=${XKB_OPTIONS} \
--with-dri-driver-path=${LIBDIR}/modules/dri \
--enable-dri \
--disable-xorg \
diff --git a/xserver/Makefile.bsd-wrapper b/xserver/Makefile.bsd-wrapper
index 0dbb173b2..9b0d66017 100644
--- a/xserver/Makefile.bsd-wrapper
+++ b/xserver/Makefile.bsd-wrapper
@@ -1,4 +1,4 @@
-# $OpenBSD: Makefile.bsd-wrapper,v 1.36 2011/04/27 20:46:31 matthieu Exp $
+# $OpenBSD: Makefile.bsd-wrapper,v 1.37 2011/05/30 10:52:58 shadchin Exp $
.include <bsd.xconf.mk>
@@ -34,15 +34,18 @@ DRI_OPTION= --disable-dri --disable-dri2
.if ${XENOCARA_USE_XKEYBOARD_CONFIG:L} == "yes"
XKB_PATH= ${X11BASE}/share/X11/xkb
XKB_RULES= base
+XKB_OPTIONS= terminate:ctrl_alt_bksp
.else
XKB_PATH= /etc/X11/xkb
XKB_RULES= xorg
+XKB_OPTIONS=
.endif
CONFIGURE_ARGS= --localstatedir=/var --sysconfdir=/etc/X11 \
--with-xkb-path=${XKB_PATH} \
--with-xkb-output=/var/db/xkb \
--with-default-xkb-rules=${XKB_RULES} \
+ --with-default-xkb-options=${XKB_OPTIONS} \
--with-module-dir=${LIBDIR}/modules ${GLX_OPTION} \
--enable-install-setuid --enable-privsep \
--enable-xcsecurity \