rpms/xorg-x11-drv-fbdev/devel fbdev-0.2.0-debug.patch, NONE, 1.1 xorg-x11-drv-fbdev.spec, 1.9, 1.10
fedora-cvs-commits at redhat.com
fedora-cvs-commits at redhat.com
Tue May 16 14:11:25 UTC 2006
Author: ajackson
Update of /cvs/dist/rpms/xorg-x11-drv-fbdev/devel
In directory cvs.devel.redhat.com:/tmp/cvs-serv17636
Modified Files:
xorg-x11-drv-fbdev.spec
Added Files:
fbdev-0.2.0-debug.patch
Log Message:
- Move debugging output from compile-time option to run-time option.
fbdev-0.2.0-debug.patch:
fbdev.c | 24 +++++++++++++-----------
1 files changed, 13 insertions(+), 11 deletions(-)
--- NEW FILE fbdev-0.2.0-debug.patch ---
Cheesy hack to move debugging output from a compile-time option to a
run-time option. Should probably be moved to be per-screen instead of
per-driver, but would need to check all callers of TRACE* first to make
sure we can find the screen private. This works for now.
--- xf86-video-fbdev-0.2.0/src/fbdev.c.debug 2006-04-07 14:52:28.000000000 -0400
+++ xf86-video-fbdev-0.2.0/src/fbdev.c 2006-05-15 13:23:27.000000000 -0400
@@ -36,17 +36,15 @@
#include "xf86xv.h"
-#define DEBUG 0
+/* Yes, this is global, sue me */
+static Bool debug = 0;
-#if DEBUG
-# define TRACE_ENTER(str) ErrorF("fbdev: " str " %d\n",pScrn->scrnIndex)
-# define TRACE_EXIT(str) ErrorF("fbdev: " str " done\n")
-# define TRACE(str) ErrorF("fbdev trace: " str "\n")
-#else
-# define TRACE_ENTER(str)
-# define TRACE_EXIT(str)
-# define TRACE(str)
-#endif
+#define TRACE_ENTER(str) \
+ do { if (debug) ErrorF("fbdev: " str " %d\n",pScrn->scrnIndex); } while (0)
+#define TRACE_EXIT(str) \
+ do { if (debug) ErrorF("fbdev: " str " done\n"); } while (0)
+#define TRACE(str) \
+ do { if (debug) ErrorF("fbdev trace: " str "\n"); } while (0)
/* -------------------------------------------------------------------- */
/* prototypes */
@@ -115,13 +113,15 @@
typedef enum {
OPTION_SHADOW_FB,
OPTION_ROTATE,
- OPTION_FBDEV
+ OPTION_FBDEV,
+ OPTION_DEBUG
} FBDevOpts;
static const OptionInfoRec FBDevOptions[] = {
{ OPTION_SHADOW_FB, "ShadowFB", OPTV_BOOLEAN, {0}, FALSE },
{ OPTION_ROTATE, "Rotate", OPTV_STRING, {0}, FALSE },
{ OPTION_FBDEV, "fbdev", OPTV_STRING, {0}, FALSE },
+ { OPTION_DEBUG, "debug", OPTV_BOOLEAN, {0}, FALSE },
{ -1, NULL, OPTV_NONE, {0}, FALSE }
};
@@ -476,6 +476,8 @@
/* use shadow framebuffer by default */
fPtr->shadowFB = xf86ReturnOptValBool(fPtr->Options, OPTION_SHADOW_FB, TRUE);
+ debug = xf86ReturnOptValBool(fPtr->Options, OPTION_DEBUG, FALSE);
+
/* rotation */
fPtr->rotate = FBDEV_ROTATE_NONE;
if ((s = xf86GetOptValString(fPtr->Options, OPTION_ROTATE)))
Index: xorg-x11-drv-fbdev.spec
===================================================================
RCS file: /cvs/dist/rpms/xorg-x11-drv-fbdev/devel/xorg-x11-drv-fbdev.spec,v
retrieving revision 1.9
retrieving revision 1.10
diff -u -r1.9 -r1.10
--- xorg-x11-drv-fbdev.spec 10 Apr 2006 03:17:22 -0000 1.9
+++ xorg-x11-drv-fbdev.spec 16 May 2006 14:11:21 -0000 1.10
@@ -7,7 +7,7 @@
Summary: Xorg X11 fbdev video driver
Name: xorg-x11-drv-fbdev
Version: 0.2.0
-Release: 1
+Release: 2
URL: http://www.x.org
Source0: http://xorg.freedesktop.org/releases/individual/driver/%{tarball}-%{version}.tar.bz2
License: MIT/X11
@@ -16,6 +16,9 @@
ExclusiveArch: %{ix86} x86_64 ia64 ppc alpha sparc sparc64
+# TODO: move me upstream
+Patch0: fbdev-0.2.0-debug.patch
+
BuildRequires: pkgconfig
BuildRequires: xorg-x11-server-sdk >= 1.0.99.901
@@ -26,6 +29,7 @@
%prep
%setup -q -n %{tarball}-%{version}
+%patch0 -p1 -b .debug
%build
%configure --disable-static
@@ -52,6 +56,9 @@
%{_mandir}/man4/fbdev.4*
%changelog
+* Tue May 16 2006 Adam Jackson <ajackson at redhat.com> 0.2.0-2
+- Move debugging output from compile-time option to run-time option.
+
* Sun Apr 9 2006 Adam Jackson <ajackson at redhat.com> 0.2.0-1
- Update to 0.2.0 from 7.1RC1.
More information about the fedora-cvs-commits
mailing list