Description: Upstream changes introduced in version 1.1.5-1
 This patch has been created by dpkg-source during the package build.
 Here's the last changelog entry, hopefully it gives details on why
 those changes were made:
 .
 xcompmgr (1.1.5-1) unstable; urgency=low
 .
   * New upstream release.
   * Switch to dpkg-source 3.0 (quilt) format.
   * debian/control:
     - Standards-Version updated to 3.8.4.
 .
 The person named in the Author field signed this changelog entry.
Author: Gustavo Franco <stratus@debian.org>

---
The information above should follow the Patch Tagging Guidelines, please
checkout http://dep.debian.net/deps/dep3/ to learn about the format. Here
are templates for supplementary fields that you might want to add:

Origin: <vendor|upstream|other>, <url of original patch>
Bug: <url in upstream bugtracker>
Bug-Debian: http://bugs.debian.org/<bugnumber>
Forwarded: <no|not-needed|url proving that it has been forwarded>
Reviewed-By: <name and email of someone who approved the patch>
Last-Update: <YYYY-MM-DD>

--- xcompmgr-1.1.5.orig/xcompmgr.1
+++ xcompmgr-1.1.5/xcompmgr.1
@@ -3,37 +3,37 @@
 .SH NAME
 xcompmgr \- sample X compositing manager
 .SH SYNOPSIS
-.BI "xcompmgr [\-d " display "] [\-r " radius "]"
-.BI "[\-o " opacity "] [\-l " left-offset "]"
-.BI "[\-t " top-offset "] [\-acCfFnsS]"
+.nf
+.B xcompmgr [\-d display] [\-r radius] [\-o opacity] [\-l left-offset] [\-t top-offset] [\-acCfFnsS]
+.fi
 .SH DESCRIPTION
 .B xcompmgr
 is a sample compositing manager for X servers supporting the XFIXES, DAMAGE,
 and COMPOSITE extensions.  It enables basic eye-candy effects.
 .SH OPTIONS
 .TP
-.BI \-d\  display
+.BI \-d\ display
 Specifies the display to manage.
 .TP
-.BI \-r\  radius
+.BI \-r\ radius
 Specifies the blur radius for client-side shadows.
 .TP
-.BI \-o\  opacity
+.BI \-o\ opacity
 Specifies the opacity for client-side shadows.
 .TP
-.BI \-l\  left-offset
+.BI \-l\ left-offset
 Specifies the left offset for client-side shadows.
 .TP
-.BI \-t\  top-offset
+.BI \-t\ top-offset
 Specifies the top offset for client-side shadows. 
 .TP
-.BI \-I\  fade-in-step
+.BI \-I\ fade-in-step
 Specifies the opacity change between steps while fading in.
 .TP
-.BI \-O\  fade-out-step
+.BI \-O\ fade-out-step
 Specifies the opacity change between steps while fading out.
 .TP
-.BI \-D\  fade-delta
+.BI \-D\ fade-delta
 Specifies the time (in milliseconds) between steps in a fade.
 .TP
 .BI \-a
--- xcompmgr-1.1.5.orig/Makefile.am
+++ xcompmgr-1.1.5/Makefile.am
@@ -1,8 +1,9 @@
 bin_PROGRAMS = xcompmgr
 man_MANS = xcompmgr.1
 
-AM_CFLAGS = $(CWARNFLAGS) $(XCOMPMGR_CFLAGS)
-xcompmgr_LDADD = $(XCOMPMGR_LIBS) -lm
+xcompmgr_LDADD = @XCOMPMGR_LIBS@ -lm
+
+INCLUDES = @XCOMPMGR_CFLAGS@
 
 EXTRA_DIST = \
 	autogen.sh \
@@ -14,7 +15,7 @@ MAINTAINERCLEANFILES=ChangeLog
 .PHONY: ChangeLog
 
 ChangeLog:
-	$(CHANGELOG_CMD)
+	(GIT_DIR=$(top_srcdir)/.git git-log > .changelog.tmp && mv .changelog.tmp ChangeLog; rm -f .changelog.tmp) || (touch ChangeLog; echo 'git directory not found: installing possibly empty changelog.' >&2)
 
 dist-hook: ChangeLog
 
--- xcompmgr-1.1.5.orig/ChangeLog
+++ xcompmgr-1.1.5/ChangeLog
@@ -1,102 +1,3 @@
-commit 2af85f6d21d175c2a16411540d4e44851c803fbe
-Author: Alan Coopersmith <alan.coopersmith@sun.com>
-Date:   Mon Nov 2 15:21:09 2009 -0800
-
-    xcompmgr 1.1.5
-    
-    Signed-off-by: Alan Coopersmith <alan.coopersmith@sun.com>
-
-commit 664ef69cda82f23a4bdbaff0d7522d81503d3393
-Author: Alan Coopersmith <alan.coopersmith@sun.com>
-Date:   Mon Nov 2 14:19:33 2009 -0800
-
-    Add COPYING file with copyright/license notice from xcompmgr.c
-    
-    Signed-off-by: Alan Coopersmith <alan.coopersmith@sun.com>
-
-commit 62c0df919bfaf2a379767ad7dc7a0113a8151255
-Author: Alan Coopersmith <alan.coopersmith@sun.com>
-Date:   Mon Nov 2 12:55:11 2009 -0800
-
-    Fix formatting of options/arguments in man page
-    
-    Signed-off-by: Alan Coopersmith <alan.coopersmith@sun.com>
-
-commit d8068fe9e666bb384a9eeac8983cb1ac8c2824a1
-Author: Alan Coopersmith <alan.coopersmith@sun.com>
-Date:   Mon Oct 19 15:48:59 2009 -0700
-
-    Migrate to xorg macros 1.3 & XORG_DEFAULT_OPTIONS
-    
-    Signed-off-by: Alan Coopersmith <alan.coopersmith@sun.com>
-
-commit 1d7eab63f9aee89767d8083dc971623863173c78
-Author: Alan Coopersmith <alan.coopersmith@sun.com>
-Date:   Thu Oct 1 14:54:21 2009 -0700
-
-    Add README with pointers to mailing lists, bugzilla, & git
-    
-    Signed-off-by: Alan Coopersmith <alan.coopersmith@sun.com>
-
-commit f15e054cfb103f78a04ace9eefaecddac8bc70e6
-Author: Yann Droneaud <ydroneaud@mandriva.com>
-Date:   Tue Mar 24 12:59:01 2009 +0100
-
-    Try to report current composite manager name
-    
-    Try to read NET_WM_CM_Sn owner's NET_WM_NAME (or WM_NAME) property,
-    otherwise report it's window id.
-    Remarks: metacity and kwin currently don't set a window name for
-    NET_WM_CM_Sn owner, but xcompmgr and compiz do. This should be added
-    to wm-spec.
-
-commit 3b6155eb533936f756d9e3e4c5802c188b7db35a
-Author: Yann Droneaud <ydroneaud@mandriva.com>
-Date:   Tue Mar 24 12:02:03 2009 +0100
-
-    Check for _NET_WM_CM_Sn before trying to install ourself as composite manager
-    
-    Check for a selection owner of _NET_WM_CM_Sn is the first thing to do
-    before taking ownership on it, so clients watching for selection ownership
-    changes won't be disturbed.
-
-commit 56b0b324ae0dbe5dda2bb89ef43427a6c19777bc
-Author: Yann Droneaud <ydroneaud@mandriva.com>
-Date:   Tue Mar 24 11:50:20 2009 +0100
-
-    Don't hard code the screen number
-
-commit a78f73b0d01374089ca7fcd838b647f6cfd1663a
-Author: Yann Droneaud <ydroneaud@mandriva.com>
-Date:   Thu Mar 26 12:05:30 2009 +0100
-
-    Fix error reporting
-    
-    Use the 'name' looked up for extension errors
-    If 'name' is NULL, use XGetErrorText().
-    Report error on stderr.
-
-commit 58d299e54e1198bfa64c39e49c2c0020f9f62b98
-Author: Paulo Cesar Pereira de Andrade <pcpa@mandriva.com.br>
-Date:   Mon Jan 19 19:49:37 2009 -0200
-
-    Ansification and compile warning fixes.
-    
-      This also uses XORG_CHANGELOG and XORG_CWARNFLAGS, corrects
-    make distcheck and all gcc 4.3 and sparse warnings.
-
-commit b04819d129a9a74ab2f17c4a6f9cceabf3aa18d2
-Author: James Cloos <cloos@jhcloos.com>
-Date:   Wed Apr 2 12:52:40 2008 -0400
-
-    Make usage() report the current version.
-
-commit e895139f38a3fa717ef652ee896f2ea6cc52811f
-Author: Adam Jackson <ajax@redhat.com>
-Date:   Thu Mar 6 17:01:31 2008 -0500
-
-    xcompmgr 1.1.4
-
 commit 73f6ed3310d15300ba38f6a338d640705a83ef36
 Author: Dana Jansens <danakj@orodu.net>
 Date:   Wed Feb 13 11:24:32 2008 -0800
--- xcompmgr-1.1.5.orig/README
+++ xcompmgr-1.1.5/README
@@ -1,27 +0,0 @@
-xcompmgr is a sample compositing manager for X servers supporting the
-XFIXES, DAMAGE, RENDER, and COMPOSITE extensions.  It enables basic
-eye-candy effects.
-
-All questions regarding this software should be directed at the
-Xorg mailing list:
-
-        http://lists.freedesktop.org/mailman/listinfo/xorg
-
-Please submit bug reports to the Xorg bugzilla:
-
-        https://bugs.freedesktop.org/enter_bug.cgi?product=xorg
-
-The master development code repository can be found at:
-
-        git://anongit.freedesktop.org/git/xorg/app/xcompmgr
-
-        http://cgit.freedesktop.org/xorg/app/xcompmgr
-
-For patch submission instructions, see:
-
-	http://www.x.org/wiki/Development/Documentation/SubmittingPatches
-
-For more information on the git code manager, see:
-
-        http://wiki.x.org/wiki/GitPage
-
--- xcompmgr-1.1.5.orig/xcompmgr.c
+++ xcompmgr-1.1.5/xcompmgr.c
@@ -104,41 +104,41 @@ typedef struct _fade {
     Bool		gone;
 } fade;
 
-static win		*list;
-static fade		*fades;
-static Display		*dpy;
-static int		scr;
-static Window		root;
-static Picture		rootPicture;
-static Picture		rootBuffer;
-static Picture		blackPicture;
-static Picture		transBlackPicture;
-static Picture		rootTile;
-static XserverRegion	allDamage;
-static Bool		clipChanged;
+win             *list;
+fade		*fades;
+Display		*dpy;
+int		scr;
+Window		root;
+Picture		rootPicture;
+Picture		rootBuffer;
+Picture		blackPicture;
+Picture		transBlackPicture;
+Picture		rootTile;
+XserverRegion	allDamage;
+Bool		clipChanged;
 #if HAS_NAME_WINDOW_PIXMAP
-static Bool		hasNamePixmap;
+Bool		hasNamePixmap;
 #endif
-static int		root_height, root_width;
-static ignore		*ignore_head, **ignore_tail = &ignore_head;
-static int		xfixes_event, xfixes_error;
-static int		damage_event, damage_error;
-static int		composite_event, composite_error;
-static int		render_event, render_error;
-static Bool		synchronize;
-static int		composite_opcode;
+int		root_height, root_width;
+ignore		*ignore_head, **ignore_tail = &ignore_head;
+int		xfixes_event, xfixes_error;
+int		damage_event, damage_error;
+int		composite_event, composite_error;
+int		render_event, render_error;
+Bool		synchronize;
+int		composite_opcode;
 
 /* find these once and be done with it */
-static Atom		opacityAtom;
-static Atom		winTypeAtom;
-static Atom		winDesktopAtom;
-static Atom		winDockAtom;
-static Atom		winToolbarAtom;
-static Atom		winMenuAtom;
-static Atom		winUtilAtom;
-static Atom		winSplashAtom;
-static Atom		winDialogAtom;
-static Atom		winNormalAtom;
+Atom		opacityAtom;
+Atom            winTypeAtom;
+Atom            winDesktopAtom;
+Atom            winDockAtom;
+Atom            winToolbarAtom;
+Atom            winMenuAtom;
+Atom            winUtilAtom;
+Atom            winSplashAtom;
+Atom            winDialogAtom;
+Atom            winNormalAtom;
 
 /* opacity property name; sometime soon I'll write up an EWMH spec for it */
 #define OPACITY_PROP	"_NET_WM_WINDOW_OPACITY"
@@ -146,7 +146,7 @@ static Atom		winNormalAtom;
 #define TRANSLUCENT	0xe0000000
 #define OPAQUE		0xffffffff
 
-static conv		*gaussianMap;
+conv            *gaussianMap;
 
 #define WINDOW_SOLID	0
 #define WINDOW_TRANS	1
@@ -176,30 +176,30 @@ get_opacity_percent(Display *dpy, win *w
 static XserverRegion
 win_extents (Display *dpy, win *w);
 
-static CompMode		compMode = CompSimple;
+CompMode    compMode = CompSimple;
 
-static int		shadowRadius = 12;
-static int		shadowOffsetX = -15;
-static int		shadowOffsetY = -15;
-static double		shadowOpacity = .75;
-
-static double		fade_in_step =  0.028;
-static double		fade_out_step = 0.03;
-static int		fade_delta =	10;
-static int		fade_time =	0;
-static Bool		fadeWindows = False;
-static Bool		excludeDockShadows = False;
-static Bool		fadeTrans = False;
+int	    shadowRadius = 12;
+int         shadowOffsetX = -15;
+int         shadowOffsetY = -15;
+double      shadowOpacity = .75;
+
+double  fade_in_step =  0.028;
+double  fade_out_step = 0.03;
+int	fade_delta =	10;
+int	fade_time =	0;
+Bool	fadeWindows = False;
+Bool    excludeDockShadows = False;
+Bool	fadeTrans = False;
 
-static Bool		autoRedirect = False;
+Bool	autoRedirect = False;
 
 /* For shadow precomputation */
-static int		Gsize = -1;
-static unsigned char	*shadowCorner = NULL;
-static unsigned char	*shadowTop = NULL;
+int            Gsize = -1;
+unsigned char *shadowCorner = NULL;
+unsigned char *shadowTop = NULL;
 
-static int
-get_time_in_milliseconds (void)
+int
+get_time_in_milliseconds ()
 {
     struct timeval  tv;
 
@@ -207,7 +207,7 @@ get_time_in_milliseconds (void)
     return tv.tv_sec * 1000 + tv.tv_usec / 1000;
 }
 
-static fade *
+fade *
 find_fade (win *w)
 {
     fade    *f;
@@ -217,10 +217,10 @@ find_fade (win *w)
 	if (f->w == w)
 	    return f;
     }
-    return NULL;
+    return 0;
 }
 
-static void
+void
 dequeue_fade (Display *dpy, fade *f)
 {
     fade    **prev;
@@ -236,7 +236,7 @@ dequeue_fade (Display *dpy, fade *f)
 	}
 }
 
-static void
+void
 cleanup_fade (Display *dpy, win *w)
 {
     fade *f = find_fade (w);
@@ -244,7 +244,7 @@ cleanup_fade (Display *dpy, win *w)
 	dequeue_fade (dpy, f);
 }
 
-static void
+void
 enqueue_fade (Display *dpy, fade *f)
 {
     if (!fades)
@@ -264,7 +264,7 @@ set_fade (Display *dpy, win *w, double s
     if (!f)
     {
 	f = malloc (sizeof (fade));
-	f->next = NULL;
+	f->next = 0;
 	f->w = w;
 	f->cur = start;
 	enqueue_fade (dpy, f);
@@ -302,7 +302,7 @@ set_fade (Display *dpy, win *w, double s
     }
 }
 
-static int
+int
 fade_timeout (void)
 {
     int now;
@@ -317,7 +317,7 @@ fade_timeout (void)
     return delta;
 }
 
-static void
+void
 run_fades (Display *dpy)
 {
     int	    now = get_time_in_milliseconds();
@@ -537,7 +537,7 @@ make_shadow (Display *dpy, double opacit
     int             opacity_int = (int)(opacity * 25);
     data = malloc (swidth * sheight * sizeof (unsigned char));
     if (!data)
-	return NULL;
+	return 0;
     ximage = XCreateImage (dpy,
 			   DefaultVisual(dpy, DefaultScreen(dpy)),
 			   8,
@@ -548,7 +548,7 @@ make_shadow (Display *dpy, double opacit
     if (!ximage)
     {
 	free (data);
-	return NULL;
+	return 0;
     }
     /*
      * Build the gaussian in sections
@@ -646,21 +646,21 @@ shadow_picture (Display *dpy, double opa
 
     shadowPicture = XRenderCreatePicture (dpy, shadowPixmap,
 					  XRenderFindStandardFormat (dpy, PictStandardA8),
-					  0, NULL);
+					  0, 0);
     if (!shadowPicture)
     {
 	XDestroyImage (shadowImage);
 	XFreePixmap (dpy, shadowPixmap);
-	return (Picture)None;
+	return None;
     }
 
-    gc = XCreateGC (dpy, shadowPixmap, 0, NULL);
+    gc = XCreateGC (dpy, shadowPixmap, 0, 0);
     if (!gc)
     {
 	XDestroyImage (shadowImage);
 	XFreePixmap (dpy, shadowPixmap);
 	XRenderFreePicture (dpy, shadowPicture);
-	return (Picture)None;
+	return None;
     }
     
     XPutImage (dpy, shadowPixmap, gc, shadowImage, 0, 0, 0, 0, 
@@ -674,7 +674,7 @@ shadow_picture (Display *dpy, double opa
     return shadowPicture;
 }
 
-static Picture
+Picture
 solid_picture (Display *dpy, Bool argb, double a, double r, double g, double b)
 {
     Pixmap			pixmap;
@@ -706,7 +706,7 @@ solid_picture (Display *dpy, Bool argb, 
     return picture;
 }
 
-static void
+void
 discard_ignore (Display *dpy, unsigned long sequence)
 {
     while (ignore_head)
@@ -724,19 +724,19 @@ discard_ignore (Display *dpy, unsigned l
     }
 }
 
-static void
+void
 set_ignore (Display *dpy, unsigned long sequence)
 {
     ignore  *i = malloc (sizeof (ignore));
     if (!i)
 	return;
     i->sequence = sequence;
-    i->next = NULL;
+    i->next = 0;
     *ignore_tail = i;
     ignore_tail = &i->next;
 }
 
-static int
+int
 should_ignore (Display *dpy, unsigned long sequence)
 {
     discard_ignore (dpy, sequence);
@@ -751,13 +751,13 @@ find_win (Display *dpy, Window id)
     for (w = list; w; w = w->next)
 	if (w->id == id)
 	    return w;
-    return NULL;
+    return 0;
 }
 
 static const char *backgroundProps[] = {
     "_XROOTPMAP_ID",
     "_XSETROOT_ID",
-    NULL,
+    0,
 };
     
 static Picture
@@ -906,7 +906,7 @@ static void
 paint_all (Display *dpy, XserverRegion region)
 {
     win	*w;
-    win	*t = NULL;
+    win	*t = 0;
     
     if (!region)
     {
@@ -927,7 +927,7 @@ paint_all (Display *dpy, XserverRegion r
 	rootBuffer = XRenderCreatePicture (dpy, rootPixmap,
 					   XRenderFindVisualFormat (dpy,
 								    DefaultVisual (dpy, scr)),
-					   0, NULL);
+					   0, 0);
 	XFreePixmap (dpy, rootPixmap);
     }
 #endif
@@ -1021,7 +1021,7 @@ paint_all (Display *dpy, XserverRegion r
 	}
 	if (!w->borderClip)
 	{
-	    w->borderClip = XFixesCreateRegion (dpy, NULL, 0);
+	    w->borderClip = XFixesCreateRegion (dpy, 0, 0);
 	    XFixesCopyRegion (dpy, w->borderClip, region);
 	}
 	w->prev_trans = t;
@@ -1147,7 +1147,7 @@ repair_win (Display *dpy, win *w)
     else
     {
 	XserverRegion	o;
-	parts = XFixesCreateRegion (dpy, NULL, 0);
+	parts = XFixesCreateRegion (dpy, 0, 0);
 	set_ignore (dpy, NextRequest (dpy));
 	XDamageSubtract (dpy, w->damage, None, parts);
 	XFixesTranslateRegion (dpy, parts,
@@ -1155,7 +1155,7 @@ repair_win (Display *dpy, win *w)
 			       w->a.y + w->a.border_width);
 	if (compMode == CompServerShadows)
 	{
-	    o = XFixesCreateRegion (dpy, NULL, 0);
+	    o = XFixesCreateRegion (dpy, 0, 0);
 	    XFixesCopyRegion (dpy, o, parts);
 	    XFixesTranslateRegion (dpy, o, w->shadow_dx, w->shadow_dy);
 	    XFixesUnionRegion (dpy, parts, parts, o);
@@ -1193,7 +1193,7 @@ map_win (Display *dpy, Window id, unsign
     w->damaged = 0;
 
     if (fade && fadeWindows)
-	set_fade (dpy, w, 0, get_opacity_percent (dpy, w, 1.0), fade_in_step, NULL, False, True, True);
+	set_fade (dpy, w, 0, get_opacity_percent (dpy, w, 1.0), fade_in_step, 0, False, True, True);
 }
 
 static void
@@ -1324,7 +1324,7 @@ get_wintype_prop(Display * dpy, Window w
 				     XA_ATOM, &actual, &format,
 				     &n, &left, &data);
 
-    if (result == Success && data != (unsigned char *)None)
+    if (result == Success && data != None)
     {
 	Atom a;
 	memcpy (&a, data, sizeof (Atom));
@@ -1355,7 +1355,7 @@ determine_mode(Display *dpy, win *w)
 
     if (w->a.class == InputOnly)
     {
-	format = NULL;
+	format = 0;
     }
     else
     {
@@ -1378,7 +1378,7 @@ determine_mode(Display *dpy, win *w)
     if (w->extents)
     {
 	XserverRegion damage;
-	damage = XFixesCreateRegion (dpy, NULL, 0);
+	damage = XFixesCreateRegion (dpy, 0, 0);
 	XFixesCopyRegion (dpy, damage, w->extents);
 	add_damage (dpy, damage);
     }
@@ -1471,7 +1471,7 @@ add_win (Display *dpy, Window id, Window
     new->opacity = OPAQUE;
 
     new->borderClip = None;
-    new->prev_trans = NULL;
+    new->prev_trans = 0;
 
     new->windowType = determine_wintype (dpy, new->id);
     
@@ -1481,7 +1481,7 @@ add_win (Display *dpy, Window id, Window
 	map_win (dpy, id, new->damage_sequence - 1, True);
 }
 
-static void
+void
 restack_win (Display *dpy, win *w, Window new_above)
 {
     Window  old_above;
@@ -1535,7 +1535,7 @@ configure_win (Display *dpy, XConfigureE
     if (w->usable)
 #endif
     {
-	damage = XFixesCreateRegion (dpy, NULL, 0);
+	damage = XFixesCreateRegion (dpy, 0, 0);
 	if (w->extents != None)	
 	    XFixesCopyRegion (dpy, damage, w->extents);
     }
@@ -1741,8 +1741,7 @@ static int
 error (Display *dpy, XErrorEvent *ev)
 {
     int	    o;
-    const char    *name = NULL;
-    static char buffer[256];
+    const char    *name = 0;
     
     if (should_ignore (dpy, ev->serial))
 	return 0;
@@ -1773,17 +1772,9 @@ error (Display *dpy, XErrorEvent *ev)
     case BadGlyph: name ="BadGlyph"; break;
     default: break;
     }
-
-    if (name == NULL)
-    {
-	buffer[0] = '\0';
-	XGetErrorText (dpy, ev->error_code, buffer, sizeof (buffer));
-	name = buffer;
-    }
-
-    fprintf (stderr, "error %d: %s request %d minor %d serial %lu\n",
-	     ev->error_code, (strlen (name) > 0) ? name : "unknown",
-	     ev->request_code, ev->minor_code, ev->serial);
+	
+    printf ("error %d request %d minor %d serial %lu\n",
+	    ev->error_code, ev->request_code, ev->minor_code, ev->serial);
 
 /*    abort ();	    this is just annoying to most people */
     return 0;
@@ -1851,10 +1842,10 @@ ev_window (XEvent *ev)
 }
 #endif
 
-static void
+void
 usage (char *program)
 {
-    fprintf (stderr, "%s v1.1.4\n", program);
+    fprintf (stderr, "%s v1.1.3\n", program);
     fprintf (stderr, "usage: %s [options]\n", program);
     fprintf (stderr, "Options\n");
     fprintf (stderr, "   -d display\n      Specifies which display should be managed.\n");
@@ -1876,55 +1867,22 @@ usage (char *program)
     exit (1);
 }
 
-static Bool
+static void
 register_cm (void)
 {
     Window w;
     Atom a;
-    static char net_wm_cm[] = "_NET_WM_CM_Sxx";
 
-    snprintf (net_wm_cm, sizeof (net_wm_cm), "_NET_WM_CM_S%d", scr);
-    a = XInternAtom (dpy, net_wm_cm, False);
-
-    w = XGetSelectionOwner (dpy, a);
-    if (w != None)
-    {
-	XTextProperty tp;
-	char **strs;
-	int count;
-	Atom winNameAtom = XInternAtom (dpy, "_NET_WM_NAME", False);
-      
-	if (!XGetTextProperty (dpy, w, &tp, winNameAtom) &&
-	    !XGetTextProperty (dpy, w, &tp, XA_WM_NAME))
-	{
-		fprintf (stderr,
-			 "Another composite manager is already running (0x%lx)\n",
-			 (unsigned long) w);
-		return False;
-	}
-	if (XmbTextPropertyToTextList (dpy, &tp, &strs, &count) == Success) 
-	{
-		fprintf (stderr, 
-			 "Another composite manager is already running (%s)\n",
-			 strs[0]);
-	  
-		XFreeStringList (strs);
-	}
-
-	XFree (tp.value);
-
-	return False;
-    }
-
-    w = XCreateSimpleWindow (dpy, RootWindow (dpy, scr), 0, 0, 1, 1, 0, None,
+    w = XCreateSimpleWindow (dpy, RootWindow (dpy, 0), 0, 0, 1, 1, 0, None,
 			     None);
 
     Xutf8SetWMProperties (dpy, w, "xcompmgr", "xcompmgr", NULL, 0, NULL, NULL,
 			  NULL);
 
-    XSetSelectionOwner (dpy, a, w, 0);
+    /* FIXME: Don't hard code the screen number */
+    a = XInternAtom (dpy, "_NET_WM_CM_S0", False);
 
-    return True;
+    XSetSelectionOwner (dpy, a, w, 0);
 }
 
 int
@@ -1936,13 +1894,13 @@ main (int argc, char **argv)
     unsigned int    nchildren;
     int		    i;
     XRenderPictureAttributes	pa;
-    XRectangle	    *expose_rects = NULL;
+    XRectangle	    *expose_rects = 0;
     int		    size_expose = 0;
     int		    n_expose = 0;
     struct pollfd   ufd;
     int		    p;
     int		    composite_major, composite_minor;
-    char	    *display = NULL;
+    char	    *display = 0;
     int		    o;
 
     while ((o = getopt (argc, argv, "D:I:O:d:r:o:l:t:scnfFCaS")) != -1)
@@ -2048,10 +2006,7 @@ main (int argc, char **argv)
 	exit (1);
     }
 
-    if (!register_cm())
-    {
-	exit (1);
-    }
+    register_cm();
 
     /* get atoms */
     opacityAtom = XInternAtom (dpy, OPACITY_PROP, False);
@@ -2208,7 +2163,7 @@ main (int argc, char **argv)
 		    {
 			if (fadeTrans)
 			    set_fade (dpy, w, w->opacity*1.0/OPAQUE, get_opacity_percent (dpy, w, 1.0),
-				      fade_out_step, NULL, False, True, False);
+				      fade_out_step, 0, False, True, False);
 			else
 			{
 			w->opacity = get_opacity_prop(dpy, w, OPAQUE);
--- xcompmgr-1.1.5.orig/configure.ac
+++ xcompmgr-1.1.5/configure.ac
@@ -2,21 +2,14 @@
 # Process this file with autoconf to produce a configure script.
 
 AC_PREREQ(2.57)
-AC_INIT([xcompmgr], [1.1.5], [https://bugs.freedesktop.org/enter_bug.cgi?product=xorg])
+AC_INIT([xcompmgr], [1.1.4], [xorg@freedesktop.org])
 AC_CONFIG_SRCDIR([xcompmgr.c])
 AM_INIT_AUTOMAKE([dist-bzip2 foreign])
 AM_MAINTAINER_MODE
-
-# Require xorg-macros 1.3 or later: XORG_DEFAULT_OPTIONS
-m4_ifndef([XORG_MACROS_VERSION],
-	  [m4_fatal([must install xorg-macros 1.3 or later before running autoconf/autogen])])
-XORG_MACROS_VERSION(1.3)
-
 AC_CONFIG_HEADER([config.h])
 
 # Checks for programs.
 AC_PROG_CC
-XORG_DEFAULT_OPTIONS
 
 # Checks for header files.
 AC_HEADER_STDC
@@ -31,7 +24,6 @@ AC_FUNC_MALLOC
 AC_CHECK_FUNCS([gettimeofday localtime_r])
 
 PKG_CHECK_MODULES(XCOMPMGR, xcomposite xfixes xdamage xrender)
-AC_SUBST(XCOMPMGR_CFLAGS)
-AC_SUBST(XCOMPMGR_LIBS)
 
-AC_OUTPUT([Makefile])
+AC_CONFIG_FILES([Makefile])
+AC_OUTPUT
