[PATCH] Janitor: make distcheck, compile warnings, .gitignore.
Paulo Cesar Pereira de Andrade
pcpa at mandriva.com.br
Thu Feb 5 12:25:05 PST 2009
Use `` instead of $().
Use $PKG_CONFIG to honor user build setup.
Replace ChangeLog with automatically generated version, this is
also the "make distcheck" correction.
Use XORG_CWARNFLAGS to help find possible driver problems.
"Compile warning" was a simple sparse warning of usage of integer
where a pointer was expected.
Random thought completely out of place: When using 0 instead of
(void *)0, a warning should not be generated in the first place,
as compilers and humans should be smart enough to understand what
is going on in that case.
Signed-off-by: Paulo Cesar Pereira de Andrade <pcpa at mandriva.com.br>
---
.gitignore | 5 +++++
ChangeLog | 48 ------------------------------------------------
Makefile.am | 9 +++++++++
configure.ac | 12 ++++++------
src/.gitignore | 6 ------
src/Makefile.am | 2 ++
src/ark_driver.c | 2 +-
7 files changed, 23 insertions(+), 61 deletions(-)
delete mode 100644 ChangeLog
delete mode 100644 src/.gitignore
diff --git a/.gitignore b/.gitignore
index 2df4a8d..48eeff0 100644
--- a/.gitignore
+++ b/.gitignore
@@ -1,3 +1,5 @@
+.deps
+.libs
Makefile
Makefile.in
*.la
@@ -18,3 +20,6 @@ ltmain.sh
missing
stamp-h1
*~
+xf86-video-ark-*.tar.*
+ChangeLog
+tags
diff --git a/ChangeLog b/ChangeLog
deleted file mode 100644
index e41fc6a..0000000
--- a/ChangeLog
+++ /dev/null
@@ -1,48 +0,0 @@
-2006-04-06 Adam Jackson <ajax at freedesktop.org>
-
- * configure.ac:
- * src/ark.h:
- * src/ark_accel.c:
- * src/ark_driver.c:
- Unlibcwrap. Bump server version requirement. Bump to 0.6.0.
-
-2006-02-08 Luc Verhaegen <libv at skynet.be>
-
- * src/ark_driver.c: (ARKPreInit):
-
- Remove wrong usage of pScrn->clock.
-
-2005-12-20 Kevin E. Martin <kem-at-freedesktop-dot-org>
-
- * configure.ac:
- Update package version for X11R7 release.
-
-2005-12-14 Kevin E. Martin <kem-at-freedesktop-dot-org>
-
- * configure.ac:
- Update package version number for final X11R7 release candidate.
-
-2005-12-03 Kevin E. Martin <kem-at-freedesktop-dot-org>
-
- * configure.ac:
- Update package version number for X11R7 RC3 release.
-
-2005-12-01 Kevin E. Martin <kem-at-freedesktop-dot-org>
-
- * configure.ac:
- Remove extraneous AC_MSG_RESULT.
-
-2005-11-29 Adam Jackson <ajax at freedesktop.org>
-
- * configure.ac:
- Only build dlloader modules by default.
-
-2005-11-09 Kevin E. Martin <kem-at-freedesktop-dot-org>
-
- * configure.ac:
- Update package version number for X11R7 RC2 release.
-
-2005-11-01 Kevin E. Martin <kem-at-freedesktop-dot-org>
-
- * configure.ac:
- Update pkgcheck dependencies to work with separate build roots.
diff --git a/Makefile.am b/Makefile.am
index 16f4412..ffefdab 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -20,3 +20,12 @@
AUTOMAKE_OPTIONS = foreign
SUBDIRS = src
+EXTRA_DIST = ChangeLog
+MAINTAINERCLEANFILES=ChangeLog
+
+.PHONY: ChangeLog
+
+ChangeLog:
+ $(CHANGELOG_CMD)
+
+dist-hook: ChangeLog
diff --git a/configure.ac b/configure.ac
index 5d8ec8b..eccce50 100644
--- a/configure.ac
+++ b/configure.ac
@@ -27,6 +27,9 @@ AC_INIT([xf86-video-ark],
xf86-video-ark)
AC_CONFIG_SRCDIR([Makefile.am])
+# Require xorg-macros: XORG_CWARNFLAGS, XORG_CHANGELOG
+m4_ifndef([XORG_MACROS_VERSION], [AC_FATAL([must install xorg-macros 1.2 or later before running autoconf/autogen])])
+XORG_MACROS_VERSION(1.2)
AM_CONFIG_HEADER([config.h])
AC_CONFIG_AUX_DIR(.)
@@ -38,6 +41,7 @@ AM_MAINTAINER_MODE
AC_DISABLE_STATIC
AC_PROG_LIBTOOL
AC_PROG_CC
+XORG_CWARNFLAGS
AH_TOP([#include "xorg-server.h"])
@@ -54,12 +58,7 @@ XORG_DRIVER_CHECK_EXT(DPMSExtension, xextproto)
# Checks for pkg-config packages
PKG_CHECK_MODULES(XORG, [xorg-server >= 1.0.99.901] xproto fontsproto $REQUIRED_MODULES)
-sdkdir=$(pkg-config --variable=sdkdir xorg-server)
-
-CFLAGS="$CFLAGS $XORG_CFLAGS "' -I$(top_srcdir)/src'
-INCLUDES="$XORG_INCS -I${sdkdir} "'-I$(top_srcdir)/src -I$(prefix)/include'
-AC_SUBST([CFLAGS])
-AC_SUBST([INCLUDES])
+sdkdir=`$PKG_CONFIG --variable=sdkdir xorg-server`
# Checks for libraries.
SAVE_CPPFLAGS="$CPPFLAGS"
@@ -84,6 +83,7 @@ AC_SUBST([DRIVER_NAME])
XORG_MANPAGE_SECTIONS
XORG_RELEASE_VERSION
+XORG_CHANGELOG
AC_OUTPUT([
Makefile
diff --git a/src/.gitignore b/src/.gitignore
deleted file mode 100644
index 9730646..0000000
--- a/src/.gitignore
+++ /dev/null
@@ -1,6 +0,0 @@
-.deps
-.libs
-Makefile
-Makefile.in
-*.la
-*.lo
diff --git a/src/Makefile.am b/src/Makefile.am
index a605e6c..2cd15b2 100644
--- a/src/Makefile.am
+++ b/src/Makefile.am
@@ -24,6 +24,8 @@
# -avoid-version prevents gratuitous .0.0.0 version numbers on the end
# _ladir passes a dummy rpath to libtool so the thing will actually link
# TODO: -nostdlib/-Bstatic/-lgcc platform magic, not installing the .a, etc.
+AM_CFLAGS = $(CWARNFLAGS) $(XORG_CFLAGS)
+
ark_drv_la_LTLIBRARIES = ark_drv.la
ark_drv_la_LDFLAGS = -module -avoid-version
ark_drv_ladir = @moduledir@/drivers
diff --git a/src/ark_driver.c b/src/ark_driver.c
index 67eb076..6e396da 100644
--- a/src/ark_driver.c
+++ b/src/ark_driver.c
@@ -574,7 +574,7 @@ static Bool ARKScreenInit(int scrnIndex, ScreenPtr pScreen, int argc,
/* must be after RGB order fixed */
- fbPictureInit (pScreen, 0, 0);
+ fbPictureInit (pScreen, NULL, 0);
miInitializeBackingStore(pScreen);
xf86SetBackingStore(pScreen);
--
1.6.1
------=_20090205185629_15942--
More information about the xorg
mailing list