summaryrefslogtreecommitdiff
path: root/driver
diff options
context:
space:
mode:
authorMatthieu Herrb <matthieu@cvs.openbsd.org>2009-11-22 18:48:20 +0000
committerMatthieu Herrb <matthieu@cvs.openbsd.org>2009-11-22 18:48:20 +0000
commit6f73767b42867b3b0ae9284158f1abc03c830e00 (patch)
treedc4f2b031c309b3cad234b5f3cab9864c60e61ca /driver
parent52af93f48adb6322c4e80f3d3a1e185c42c9af51 (diff)
Update for resources/RAC API removal and bump to 0.3.0 to follow
upstreams numbering.
Diffstat (limited to 'driver')
-rw-r--r--driver/xf86-video-wsfb/aclocal.m489
-rw-r--r--driver/xf86-video-wsfb/configure20
-rw-r--r--driver/xf86-video-wsfb/configure.ac2
-rw-r--r--driver/xf86-video-wsfb/ltmain.sh11
-rw-r--r--driver/xf86-video-wsfb/src/wsfb_driver.c31
5 files changed, 81 insertions, 72 deletions
diff --git a/driver/xf86-video-wsfb/aclocal.m4 b/driver/xf86-video-wsfb/aclocal.m4
index a56c4a249..5d53347b9 100644
--- a/driver/xf86-video-wsfb/aclocal.m4
+++ b/driver/xf86-video-wsfb/aclocal.m4
@@ -7631,7 +7631,7 @@ AC_SUBST([am__tar])
AC_SUBST([am__untar])
]) # _AM_PROG_TAR
-dnl xorg-macros.m4. Generated from xorg-macros.m4.in:xorgversion.m4 by configure.
+dnl xorg-macros.m4. Generated from xorg-macros.m4.in xorgversion.m4 by configure.
dnl
dnl Copyright 2005-2006 Sun Microsystems, Inc. All rights reserved.
dnl
@@ -7668,27 +7668,24 @@ dnl of the copyright holder.
# your configure.ac with the minimum required version, such as:
# XORG_MACROS_VERSION(1.1)
#
-# To force at least a version with this macro defined, also add:
-# m4_ifndef([XORG_MACROS_VERSION], [AC_FATAL([must install xorg-macros 1.1 or later before running autoconf/autogen])])
+# To ensure that this macro is defined, also add:
+# m4_ifndef([XORG_MACROS_VERSION],
+# [m4_fatal([must install xorg-macros 1.1 or later before running autoconf/autogen])])
#
#
# See the "minimum version" comment for each macro you use to see what
# version you require.
-AC_DEFUN([XORG_MACROS_VERSION],[
- [XORG_MACROS_needed_version=$1
- XORG_MACROS_needed_major=`echo $XORG_MACROS_needed_version | sed 's/\..*$//'`
- XORG_MACROS_needed_minor=`echo $XORG_MACROS_needed_version | sed -e 's/^[0-9]*\.//' -e 's/\..*$//'`]
- AC_MSG_CHECKING([if xorg-macros used to generate configure is at least ${XORG_MACROS_needed_major}.${XORG_MACROS_needed_minor}])
- [XORG_MACROS_version=1.2.1
- XORG_MACROS_major=`echo $XORG_MACROS_version | sed 's/\..*$//'`
- XORG_MACROS_minor=`echo $XORG_MACROS_version | sed -e 's/^[0-9]*\.//' -e 's/\..*$//'`]
- if test $XORG_MACROS_major -ne $XORG_MACROS_needed_major ; then
- AC_MSG_ERROR([configure built with incompatible version of xorg-macros.m4 - requires version ${XORG_MACROS_major}.x])
- fi
- if test $XORG_MACROS_minor -lt $XORG_MACROS_needed_minor ; then
- AC_MSG_ERROR([configure built with too old of a version of xorg-macros.m4 - requires version ${XORG_MACROS_major}.${XORG_MACROS_minor}.0 or newer])
- fi
- AC_MSG_RESULT([yes, $XORG_MACROS_version])
+m4_defun([XORG_MACROS_VERSION],[
+m4_define([vers_have], [1.3.0])
+m4_define([maj_have], m4_substr(vers_have, 0, m4_index(vers_have, [.])))
+m4_define([maj_needed], m4_substr([$1], 0, m4_index([$1], [.])))
+m4_if(m4_cmp(maj_have, maj_needed), 0,,
+ [m4_fatal([xorg-macros major version ]maj_needed[ is required but ]vers_have[ found])])
+m4_if(m4_version_compare(vers_have, [$1]), -1,
+ [m4_fatal([xorg-macros version $1 or higher is required but ]vers_have[ found])])
+m4_undefine([vers_have])
+m4_undefine([maj_have])
+m4_undefine([maj_needed])
]) # XORG_MACROS_VERSION
# XORG_PROG_RAWCPP()
@@ -7955,7 +7952,7 @@ AC_SUBST(MAKE_HTML)
# their AM_CFLAGS (or other appropriate *_CFLAGS) to use them.
AC_DEFUN([XORG_CHECK_MALLOC_ZERO],[
AC_ARG_ENABLE(malloc0returnsnull,
- AC_HELP_STRING([--enable-malloc0returnsnull],
+ AS_HELP_STRING([--enable-malloc0returnsnull],
[malloc(0) returns NULL (default: auto)]),
[MALLOC_ZERO_RETURNS_NULL=$enableval],
[MALLOC_ZERO_RETURNS_NULL=auto])
@@ -8007,7 +8004,7 @@ AC_SUBST([XTMALLOC_ZERO_CFLAGS])
AC_DEFUN([XORG_WITH_LINT],[
# Allow checking code with lint, sparse, etc.
-AC_ARG_WITH(lint, [AC_HELP_STRING([--with-lint],
+AC_ARG_WITH(lint, [AS_HELP_STRING([--with-lint],
[Use a lint-style source code checker (default: disabled)])],
[use_lint=$withval], [use_lint=no])
if test "x$use_lint" = "xyes" ; then
@@ -8048,7 +8045,7 @@ AM_CONDITIONAL(LINT, [test x$LINT != xno])
AC_DEFUN([XORG_LINT_LIBRARY],[
AC_REQUIRE([XORG_WITH_LINT])
# Build lint "library" for more indepth checks of programs calling this library
-AC_ARG_ENABLE(lint-library, [AC_HELP_STRING([--enable-lint-library],
+AC_ARG_ENABLE(lint-library, [AS_HELP_STRING([--enable-lint-library],
[Create lint library (default: disabled)])],
[make_lint_lib=$enableval], [make_lint_lib=no])
if test "x$make_lint_lib" != "xno" ; then
@@ -8078,9 +8075,9 @@ if test "x$GCC" = xyes ; then
CWARNFLAGS="-Wall -Wpointer-arith -Wstrict-prototypes -Wmissing-prototypes \
-Wmissing-declarations -Wnested-externs -fno-strict-aliasing \
-Wbad-function-cast"
- case `gcc -dumpversion` in
+ case `$CC -dumpversion` in
3.4.* | 4.*)
- CWARNFLAGS+=" -Wold-style-definition -Wdeclaration-after-statement"
+ CWARNFLAGS="$CWARNFLAGS -Wold-style-definition -Wdeclaration-after-statement"
;;
esac
else
@@ -8090,7 +8087,51 @@ else
fi
fi
AC_SUBST(CWARNFLAGS)
+m4_ifdef([AM_SILENT_RULES], [AM_SILENT_RULES([yes])])
]) # XORG_CWARNFLAGS
+
+# XORG_STRICT_OPTION
+# -----------------------
+# Minimum version: 1.3.0
+#
+# Add configure option to enable strict compilation
+AC_DEFUN([XORG_STRICT_OPTION], [
+AC_REQUIRE([AC_PROG_CC])
+AC_REQUIRE([AC_PROG_CC_C99])
+AC_REQUIRE([XORG_CWARNFLAGS])
+
+AC_ARG_ENABLE(strict-compilation,
+ AS_HELP_STRING([--enable-strict-compilation],
+ [Enable all warnings from compiler and make them errors (default: disabled)]),
+ [STRICT_COMPILE=$enableval], [STRICT_COMPILE=no])
+if test "x$STRICT_COMPILE" = "xyes"; then
+ AC_CHECK_DECL([__SUNPRO_C], [SUNCC="yes"], [SUNCC="no"])
+ AC_CHECK_DECL([__INTEL_COMPILER], [INTELCC="yes"], [INTELCC="no"])
+ if test "x$GCC" = xyes ; then
+ STRICT_CFLAGS="-pedantic -Werror"
+ elif test "x$SUNCC" = "xyes"; then
+ STRICT_CFLAGS="-errwarn"
+ elif test "x$INTELCC" = "xyes"; then
+ STRICT_CFLAGS="-Werror"
+ fi
+fi
+CWARNFLAGS="$CWARNFLAGS $STRICT_CFLAGS"
+AC_SUBST([CWARNFLAGS])
+]) # XORG_STRICT_OPTION
+
+# XORG_DEFAULT_OPTIONS
+# --------------------
+# Minimum version: 1.3.0
+#
+# Defines default options for X.Org modules.
+#
+AC_DEFUN([XORG_DEFAULT_OPTIONS], [
+XORG_CWARNFLAGS
+XORG_STRICT_OPTION
+XORG_RELEASE_VERSION
+XORG_CHANGELOG
+XORG_MANPAGE_SECTIONS
+]) # XORG_DEFAULT_OPTIONS
dnl Copyright 2005 Red Hat, Inc
dnl
dnl Permission to use, copy, modify, distribute, and sell this software and its
@@ -8125,7 +8166,7 @@ dnl
AC_DEFUN([XORG_RELEASE_VERSION],[
AC_ARG_WITH(release-version,
- AC_HELP_STRING([--with-release-version=STRING],
+ AS_HELP_STRING([--with-release-version=STRING],
[Use release version string in package name]),
[RELEASE_VERSION="$withval"],
[RELEASE_VERSION=""])
diff --git a/driver/xf86-video-wsfb/configure b/driver/xf86-video-wsfb/configure
index 7ca9c5764..17d8bd572 100644
--- a/driver/xf86-video-wsfb/configure
+++ b/driver/xf86-video-wsfb/configure
@@ -1,6 +1,6 @@
#! /bin/sh
# Guess values for system-dependent variables and create Makefiles.
-# Generated by GNU Autoconf 2.62 for xf86-video-wsfb 0.2.1.
+# Generated by GNU Autoconf 2.62 for xf86-video-wsfb 0.3.0.
#
# Report bugs to <https://bugs.freedesktop.org/enter_bug.cgi?product=xorg>.
#
@@ -750,8 +750,8 @@ SHELL=${CONFIG_SHELL-/bin/sh}
# Identity of this package.
PACKAGE_NAME='xf86-video-wsfb'
PACKAGE_TARNAME='xf86-video-wsfb'
-PACKAGE_VERSION='0.2.1'
-PACKAGE_STRING='xf86-video-wsfb 0.2.1'
+PACKAGE_VERSION='0.3.0'
+PACKAGE_STRING='xf86-video-wsfb 0.3.0'
PACKAGE_BUGREPORT='https://bugs.freedesktop.org/enter_bug.cgi?product=xorg'
ac_unique_file="Makefile.am"
@@ -1501,7 +1501,7 @@ if test "$ac_init_help" = "long"; then
# Omit some internal or obsolete options to make the list less imposing.
# This message is too long to be a string in the A/UX 3.1 sh.
cat <<_ACEOF
-\`configure' configures xf86-video-wsfb 0.2.1 to adapt to many kinds of systems.
+\`configure' configures xf86-video-wsfb 0.3.0 to adapt to many kinds of systems.
Usage: $0 [OPTION]... [VAR=VALUE]...
@@ -1571,7 +1571,7 @@ fi
if test -n "$ac_init_help"; then
case $ac_init_help in
- short | recursive ) echo "Configuration of xf86-video-wsfb 0.2.1:";;
+ short | recursive ) echo "Configuration of xf86-video-wsfb 0.3.0:";;
esac
cat <<\_ACEOF
@@ -1686,7 +1686,7 @@ fi
test -n "$ac_init_help" && exit $ac_status
if $ac_init_version; then
cat <<\_ACEOF
-xf86-video-wsfb configure 0.2.1
+xf86-video-wsfb configure 0.3.0
generated by GNU Autoconf 2.62
Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001,
@@ -1700,7 +1700,7 @@ cat >config.log <<_ACEOF
This file contains any messages produced by compilers while
running configure, to aid debugging if configure makes a mistake.
-It was created by xf86-video-wsfb $as_me 0.2.1, which was
+It was created by xf86-video-wsfb $as_me 0.3.0, which was
generated by GNU Autoconf 2.62. Invocation command line was
$ $0 $@
@@ -2354,7 +2354,7 @@ fi
# Define the identity of the package.
PACKAGE='xf86-video-wsfb'
- VERSION='0.2.1'
+ VERSION='0.3.0'
cat >>confdefs.h <<_ACEOF
@@ -22001,7 +22001,7 @@ exec 6>&1
# report actual input values of CONFIG_FILES etc. instead of their
# values after options handling.
ac_log="
-This file was extended by xf86-video-wsfb $as_me 0.2.1, which was
+This file was extended by xf86-video-wsfb $as_me 0.3.0, which was
generated by GNU Autoconf 2.62. Invocation command line was
CONFIG_FILES = $CONFIG_FILES
@@ -22054,7 +22054,7 @@ Report bugs to <bug-autoconf@gnu.org>."
_ACEOF
cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
ac_cs_version="\\
-xf86-video-wsfb config.status 0.2.1
+xf86-video-wsfb config.status 0.3.0
configured by $0, generated by GNU Autoconf 2.62,
with options \\"`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`\\"
diff --git a/driver/xf86-video-wsfb/configure.ac b/driver/xf86-video-wsfb/configure.ac
index a0882e9fb..93bccaa62 100644
--- a/driver/xf86-video-wsfb/configure.ac
+++ b/driver/xf86-video-wsfb/configure.ac
@@ -22,7 +22,7 @@
AC_PREREQ(2.57)
AC_INIT([xf86-video-wsfb],
- 0.2.1,
+ 0.3.0,
[https://bugs.freedesktop.org/enter_bug.cgi?product=xorg],
xf86-video-wsfb)
diff --git a/driver/xf86-video-wsfb/ltmain.sh b/driver/xf86-video-wsfb/ltmain.sh
index 248cd4047..fccf69e28 100644
--- a/driver/xf86-video-wsfb/ltmain.sh
+++ b/driver/xf86-video-wsfb/ltmain.sh
@@ -2127,17 +2127,6 @@ EOF
;;
esac
for pass in $passes; do
- # The preopen pass in lib mode reverses $deplibs; put it back here
- # so that -L comes before libs that need it for instance...
- if test "$linkmode,$pass" = "lib,link"; then
- ## FIXME: Find the place where the list is rebuilt in the wrong
- ## order, and fix it there properly
- tmp_deplibs=
- for deplib in $deplibs; do
- tmp_deplibs="$deplib $tmp_deplibs"
- done
- deplibs="$tmp_deplibs"
- fi
if test "$linkmode,$pass" = "lib,link" ||
test "$linkmode,$pass" = "prog,scan"; then
libs="$deplibs"
diff --git a/driver/xf86-video-wsfb/src/wsfb_driver.c b/driver/xf86-video-wsfb/src/wsfb_driver.c
index d01e42d11..e3e5df59e 100644
--- a/driver/xf86-video-wsfb/src/wsfb_driver.c
+++ b/driver/xf86-video-wsfb/src/wsfb_driver.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: wsfb_driver.c,v 1.18 2009/10/19 20:01:30 matthieu Exp $ */
+/* $OpenBSD: wsfb_driver.c,v 1.19 2009/11/22 18:48:19 matthieu Exp $ */
/*
* Copyright (c) 2001 Matthieu Herrb
* All rights reserved.
@@ -68,8 +68,10 @@
#endif
#include "fb.h"
+#if GET_ABI_MAJOR(ABI_VIDEODRV_VERSION) < 6
#include "xf86Resources.h"
#include "xf86RAC.h"
+#endif
#ifdef XvExtension
#include "xf86xv.h"
@@ -183,22 +185,6 @@ static const OptionInfoRec WsfbOptions[] = {
{ -1, NULL, OPTV_NONE, {0}, FALSE}
};
-/* Symbols needed from other modules. */
-static const char *fbSymbols[] = {
- "fbPictureInit",
- "fbScreenInit",
- NULL
-};
-static const char *shadowSymbols[] = {
- "shadowAdd",
- "shadowSetup",
- "shadowUpdatePacked",
- "shadowUpdatePackedWeak",
- "shadowUpdateRotatePacked",
- "shadowUpdateRotatePackedWeak",
- NULL
-};
-
#ifdef XFree86LOADER
static XF86ModuleVersionInfo WsfbVersRec = {
"wsfb",
@@ -236,7 +222,6 @@ WsfbSetup(pointer module, pointer opts, int *errmaj, int *errmin)
if (!setupDone) {
setupDone = TRUE;
xf86AddDriver(&WSFB, module, HaveDriverFuncs);
- LoaderRefSymLists(fbSymbols, shadowSymbols, NULL);
return (pointer)1;
} else {
if (errmaj != NULL)
@@ -433,8 +418,10 @@ WsfbPreInit(ScrnInfoPtr pScrn, int flags)
fPtr->pEnt = xf86GetEntityInfo(pScrn->entityList[0]);
+#if GET_ABI_MAJOR(ABI_VIDEODRV_VERSION) < 6
pScrn->racMemFlags = RAC_FB | RAC_COLORMAP | RAC_CURSOR | RAC_VIEWPORT;
pScrn->racIoFlags = pScrn->racMemFlags;
+#endif
dev = xf86FindOptionValue(fPtr->pEnt->device->options, "device");
fPtr->fd = wsfb_open(dev);
@@ -779,19 +766,11 @@ WsfbPreInit(ScrnInfoPtr pScrn, int flags)
WsfbFreeRec(pScrn);
return FALSE;
}
- xf86LoaderReqSymLists(shadowSymbols, NULL);
}
if (mod && xf86LoadSubModule(pScrn, mod) == NULL) {
WsfbFreeRec(pScrn);
return FALSE;
}
- if (mod) {
- if (reqSym) {
- xf86LoaderReqSymbols(reqSym, NULL);
- } else {
- xf86LoaderReqSymLists(fbSymbols, NULL);
- }
- }
TRACE_EXIT("PreInit");
return TRUE;
}