From 63f1fff8fe1e7f94ebc0a72df773c6f77531f7a4 Mon Sep 17 00:00:00 2001 From: Mike Gabriel Date: Wed, 16 Mar 2016 11:11:43 +0100 Subject: Rename region macros to eliminate screen argument This is a huge mechanical patch and a few small fixups required to finish the job. They were reviewed separately, but because the server does not build without both pieces, I've merged them together at this time. The mechanical changes were performed by running the included 'fix-region' script over the whole nx-X11/programs/Xserver tree: $ cd nx-X11/programs/Xserver && ( git ls-files | grep -v '^fix-' | xargs ./fix-region; ) And then, the white space errors in the resulting patch were fixed using the provided fix-patch-whitespace script. $ sh ./fix-patch-whitespace Thanks to Jamey Sharp for the mighty fine sed-generating sed script. v1: Keith Packard (X.Org xserver commit: 2dc138922b7588515d5f2447e4b9dcdc0bef15e0) v2: Mike Gabriel (apply fix-region script to nx-libs) --- nx-X11/programs/Xserver/render/mipict.c | 80 ++++++++++++++++---------------- nx-X11/programs/Xserver/render/mirect.c | 4 +- nx-X11/programs/Xserver/render/picture.c | 18 +++---- 3 files changed, 51 insertions(+), 51 deletions(-) (limited to 'nx-X11/programs/Xserver/render') diff --git a/nx-X11/programs/Xserver/render/mipict.c b/nx-X11/programs/Xserver/render/mipict.c index cf9c27f01..ae7cf5a6d 100644 --- a/nx-X11/programs/Xserver/render/mipict.c +++ b/nx-X11/programs/Xserver/render/mipict.c @@ -48,7 +48,7 @@ void miDestroyPicture (PicturePtr pPicture) { if (pPicture->freeCompClip) - REGION_DESTROY(pPicture->pDrawable->pScreen, pPicture->pCompositeClip); + RegionDestroy(pPicture->pCompositeClip); } void @@ -65,7 +65,7 @@ miDestroyPictureClip (PicturePtr pPicture) * we know we'll never have a list of rectangles, since ChangeClip * immediately turns them into a region */ - REGION_DESTROY(pPicture->pDrawable->pScreen, pPicture->clientClip); + RegionDestroy(pPicture->clientClip); break; } pPicture->clientClip = NULL; @@ -86,7 +86,7 @@ miChangePictureClip (PicturePtr pPicture, switch (type) { case CT_PIXMAP: /* convert the pixmap to a region */ - clientClip = (void *) BITMAP_TO_REGION(pScreen, (PixmapPtr) value); + clientClip = (void *) BitmapToRegion(pScreen, (PixmapPtr) value); if (!clientClip) return BadAlloc; clientClipType = CT_REGION; @@ -101,7 +101,7 @@ miChangePictureClip (PicturePtr pPicture, clientClipType = CT_NONE; break; default: - clientClip = (void *) RECTS_TO_REGION(pScreen, n, + clientClip = (void *) RegionFromRects(n, (xRectangle *) value, type); if (!clientClip) @@ -162,7 +162,7 @@ miValidatePicture (PicturePtr pPicture, if (pPicture->clientClipType == CT_NONE) { if (freeCompClip) - REGION_DESTROY(pScreen, pPicture->pCompositeClip); + RegionDestroy(pPicture->pCompositeClip); pPicture->pCompositeClip = pregWin; pPicture->freeCompClip = freeTmpClip; } @@ -177,30 +177,30 @@ miValidatePicture (PicturePtr pPicture, * clip. if neither is real, create a new region. */ - REGION_TRANSLATE(pScreen, pPicture->clientClip, + RegionTranslate(pPicture->clientClip, pDrawable->x + pPicture->clipOrigin.x, pDrawable->y + pPicture->clipOrigin.y); if (freeCompClip) { - REGION_INTERSECT(pScreen, pPicture->pCompositeClip, + RegionIntersect(pPicture->pCompositeClip, pregWin, pPicture->clientClip); if (freeTmpClip) - REGION_DESTROY(pScreen, pregWin); + RegionDestroy(pregWin); } else if (freeTmpClip) { - REGION_INTERSECT(pScreen, pregWin, pregWin, pPicture->clientClip); + RegionIntersect(pregWin, pregWin, pPicture->clientClip); pPicture->pCompositeClip = pregWin; } else { - pPicture->pCompositeClip = REGION_CREATE(pScreen, NullBox, 0); - REGION_INTERSECT(pScreen, pPicture->pCompositeClip, + pPicture->pCompositeClip = RegionCreate(NullBox, 0); + RegionIntersect(pPicture->pCompositeClip, pregWin, pPicture->clientClip); } pPicture->freeCompClip = TRUE; - REGION_TRANSLATE(pScreen, pPicture->clientClip, + RegionTranslate(pPicture->clientClip, -(pDrawable->x + pPicture->clipOrigin.x), -(pDrawable->y + pPicture->clipOrigin.y)); } @@ -218,31 +218,31 @@ miValidatePicture (PicturePtr pPicture, if (pPicture->freeCompClip) { - REGION_RESET(pScreen, pPicture->pCompositeClip, &pixbounds); + RegionReset(pPicture->pCompositeClip, &pixbounds); } else { pPicture->freeCompClip = TRUE; - pPicture->pCompositeClip = REGION_CREATE(pScreen, &pixbounds, 1); + pPicture->pCompositeClip = RegionCreate(&pixbounds, 1); } if (pPicture->clientClipType == CT_REGION) { if(pDrawable->x || pDrawable->y) { - REGION_TRANSLATE(pScreen, pPicture->clientClip, + RegionTranslate(pPicture->clientClip, pDrawable->x + pPicture->clipOrigin.x, pDrawable->y + pPicture->clipOrigin.y); - REGION_INTERSECT(pScreen, pPicture->pCompositeClip, + RegionIntersect(pPicture->pCompositeClip, pPicture->pCompositeClip, pPicture->clientClip); - REGION_TRANSLATE(pScreen, pPicture->clientClip, + RegionTranslate(pPicture->clientClip, -(pDrawable->x + pPicture->clipOrigin.x), -(pDrawable->y + pPicture->clipOrigin.y)); } else { - REGION_TRANSLATE(pScreen, pPicture->pCompositeClip, + RegionTranslate(pPicture->pCompositeClip, -pPicture->clipOrigin.x, -pPicture->clipOrigin.y); - REGION_INTERSECT(pScreen, pPicture->pCompositeClip, + RegionIntersect(pPicture->pCompositeClip, pPicture->pCompositeClip, pPicture->clientClip); - REGION_TRANSLATE(pScreen, pPicture->pCompositeClip, + RegionTranslate(pPicture->pCompositeClip, pPicture->clipOrigin.x, pPicture->clipOrigin.y); } } @@ -274,11 +274,11 @@ miClipPictureReg (RegionPtr pRegion, int dx, int dy) { - if (REGION_NUM_RECTS(pRegion) == 1 && - REGION_NUM_RECTS(pClip) == 1) + if (RegionNumRects(pRegion) == 1 && + RegionNumRects(pClip) == 1) { - BoxPtr pRbox = REGION_RECTS(pRegion); - BoxPtr pCbox = REGION_RECTS(pClip); + BoxPtr pRbox = RegionRects(pRegion); + BoxPtr pCbox = RegionRects(pClip); int v; if (pRbox->x1 < (v = pCbox->x1 + dx)) @@ -292,21 +292,21 @@ miClipPictureReg (RegionPtr pRegion, if (pRbox->x1 >= pRbox->x2 || pRbox->y1 >= pRbox->y2) { - REGION_EMPTY(pScreen, pRegion); + RegionEmpty(pRegion); } } - else if (!REGION_NOTEMPTY (pScreen, pClip)) + else if (!RegionNotEmpty(pClip)) return FALSE; else { if (dx || dy) - REGION_TRANSLATE(pScreen, pRegion, -dx, -dy); - if (!REGION_INTERSECT (pScreen, pRegion, pRegion, pClip)) + RegionTranslate(pRegion, -dx, -dy); + if (!RegionIntersect(pRegion, pRegion, pClip)) return FALSE; if (dx || dy) - REGION_TRANSLATE(pScreen, pRegion, dx, dy); + RegionTranslate(pRegion, dx, dy); } - return REGION_NOTEMPTY(pScreen, pRegion); + return RegionNotEmpty(pRegion); } static __inline Bool @@ -322,13 +322,13 @@ miClipPictureSrc (RegionPtr pRegion, { if (pPicture->clientClipType != CT_NONE) { - REGION_TRANSLATE(pScreen, pRegion, + RegionTranslate(pRegion, dx - pPicture->clipOrigin.x, dy - pPicture->clipOrigin.y); - if (!REGION_INTERSECT (pScreen, pRegion, pRegion, + if (!RegionIntersect(pRegion, pRegion, (RegionPtr) pPicture->clientClip)) return FALSE; - REGION_TRANSLATE(pScreen, pRegion, + RegionTranslate(pRegion, - (dx - pPicture->clipOrigin.x), - (dy - pPicture->clipOrigin.y)); } @@ -432,13 +432,13 @@ miComputeCompositeRegion (RegionPtr pRegion, if (pRegion->extents.x1 >= pRegion->extents.x2 || pRegion->extents.y1 >= pRegion->extents.y2) { - REGION_EMPTY (pDst->pDrawable->pScreen, pRegion); + RegionEmpty(pRegion); return FALSE; } /* clip against dst */ if (!miClipPictureReg (pRegion, pDst->pCompositeClip, 0, 0)) { - REGION_UNINIT (pScreen, pRegion); + RegionUninit(pRegion); return FALSE; } if (pDst->alphaMap) @@ -447,14 +447,14 @@ miComputeCompositeRegion (RegionPtr pRegion, -pDst->alphaOrigin.x, -pDst->alphaOrigin.y)) { - REGION_UNINIT (pScreen, pRegion); + RegionUninit(pRegion); return FALSE; } } /* clip against src */ if (!miClipPictureSrc (pRegion, pSrc, xDst - xSrc, yDst - ySrc)) { - REGION_UNINIT (pScreen, pRegion); + RegionUninit(pRegion); return FALSE; } if (pSrc->alphaMap) @@ -463,7 +463,7 @@ miComputeCompositeRegion (RegionPtr pRegion, xDst - (xSrc + pSrc->alphaOrigin.x), yDst - (ySrc + pSrc->alphaOrigin.y))) { - REGION_UNINIT (pScreen, pRegion); + RegionUninit(pRegion); return FALSE; } } @@ -472,7 +472,7 @@ miComputeCompositeRegion (RegionPtr pRegion, { if (!miClipPictureSrc (pRegion, pMask, xDst - xMask, yDst - yMask)) { - REGION_UNINIT (pScreen, pRegion); + RegionUninit(pRegion); return FALSE; } if (pMask->alphaMap) @@ -481,7 +481,7 @@ miComputeCompositeRegion (RegionPtr pRegion, xDst - (xMask + pMask->alphaOrigin.x), yDst - (yMask + pMask->alphaOrigin.y))) { - REGION_UNINIT (pScreen, pRegion); + RegionUninit(pRegion); return FALSE; } } diff --git a/nx-X11/programs/Xserver/render/mirect.c b/nx-X11/programs/Xserver/render/mirect.c index c4aeb9aba..3ce7a7f4c 100644 --- a/nx-X11/programs/Xserver/render/mirect.c +++ b/nx-X11/programs/Xserver/render/mirect.c @@ -65,8 +65,8 @@ miColorRects (PicturePtr pDst, tmpval[4] = pDst->clipOrigin.y - yoff; mask |= GCClipXOrigin|GCClipYOrigin; - pClip = REGION_CREATE (pScreen, NULL, 1); - REGION_COPY (pScreen, pClip, + pClip = RegionCreate(NULL, 1); + RegionCopy(pClip, (RegionPtr) pClipPict->clientClip); (*pGC->funcs->ChangeClip) (pGC, CT_REGION, pClip, 0); } diff --git a/nx-X11/programs/Xserver/render/picture.c b/nx-X11/programs/Xserver/render/picture.c index 754d468bb..5d8496610 100644 --- a/nx-X11/programs/Xserver/render/picture.c +++ b/nx-X11/programs/Xserver/render/picture.c @@ -1390,7 +1390,7 @@ SetPictureClipRects (PicturePtr pPicture, RegionPtr clientClip; int result; - clientClip = RECTS_TO_REGION(pScreen, + clientClip = RegionFromRects( nRect, rects, CT_UNSORTED); if (!clientClip) return BadAlloc; @@ -1421,14 +1421,14 @@ SetPictureClipRegion (PicturePtr pPicture, if (pRegion) { type = CT_REGION; - clientClip = REGION_CREATE (pScreen, - REGION_EXTENTS(pScreen, pRegion), - REGION_NUM_RECTS(pRegion)); + clientClip = RegionCreate( + RegionExtents(pRegion), + RegionNumRects(pRegion)); if (!clientClip) return BadAlloc; - if (!REGION_COPY (pSCreen, clientClip, pRegion)) + if (!RegionCopy(clientClip, pRegion)) { - REGION_DESTROY (pScreen, clientClip); + RegionDestroy(clientClip); return BadAlloc; } } @@ -1538,9 +1538,9 @@ CopyPicture (PicturePtr pSrc, RegionPtr clientClip; RegionPtr srcClientClip = (RegionPtr)pSrc->clientClip; - clientClip = REGION_CREATE(pSrc->pDrawable->pScreen, - REGION_EXTENTS(pSrc->pDrawable->pScreen, srcClientClip), - REGION_NUM_RECTS(srcClientClip)); + clientClip = RegionCreate( + RegionExtents(srcClientClip), + RegionNumRects(srcClientClip)); (*ps->ChangePictureClip)(pDst, CT_REGION, clientClip, 0); } break; -- cgit v1.2.3 From d9e7f6ae42b30e32619e1d0979598c2ba2288a3e Mon Sep 17 00:00:00 2001 From: Mike Gabriel Date: Fri, 18 Mar 2016 05:13:43 +0100 Subject: pixman-devel: Build against shared library pkg-config(pixman-1). --- debian/control | 1 + nx-X11/programs/Xserver/GL/glx/Imakefile | 3 ++- nx-X11/programs/Xserver/GL/mesa/X/Imakefile | 3 ++- nx-X11/programs/Xserver/Imakefile | 15 +++++++-------- nx-X11/programs/Xserver/XTrap/Imakefile | 2 +- nx-X11/programs/Xserver/Xext/Imakefile | 3 ++- nx-X11/programs/Xserver/Xi/Imakefile | 2 +- nx-X11/programs/Xserver/composite/Imakefile | 3 ++- nx-X11/programs/Xserver/damageext/Imakefile | 3 ++- nx-X11/programs/Xserver/dbe/Imakefile | 2 +- nx-X11/programs/Xserver/dix/Imakefile | 3 ++- nx-X11/programs/Xserver/fb/Imakefile | 3 ++- nx-X11/programs/Xserver/hw/nxagent/Imakefile | 5 ++++- nx-X11/programs/Xserver/include/scrnintstr.h | 4 ++++ nx-X11/programs/Xserver/mi/Imakefile | 3 ++- nx-X11/programs/Xserver/miext/cw/Imakefile | 3 ++- nx-X11/programs/Xserver/miext/damage/Imakefile | 3 ++- nx-X11/programs/Xserver/os/Imakefile | 3 ++- nx-X11/programs/Xserver/randr/Imakefile | 4 +++- nx-X11/programs/Xserver/record/Imakefile | 2 +- nx-X11/programs/Xserver/render/Imakefile | 3 ++- nx-X11/programs/Xserver/xfixes/Imakefile | 3 ++- nx-X11/programs/Xserver/xkb/Imakefile | 3 ++- nx-libs.spec | 3 +++ nxcompext/configure.in | 2 ++ 25 files changed, 56 insertions(+), 28 deletions(-) (limited to 'nx-X11/programs/Xserver/render') diff --git a/debian/control b/debian/control index 83aee8e58..3e1f45e5d 100644 --- a/debian/control +++ b/debian/control @@ -28,6 +28,7 @@ Build-Depends: pkg-config, x11proto-core-dev, expat, + libpixman-1-dev, Standards-Version: 3.9.6 Homepage: http://code.x2go.org/gitweb?p=nx-libs.git;a=summary Vcs-Git: git://code.x2go.org/nx-libs.git diff --git a/nx-X11/programs/Xserver/GL/glx/Imakefile b/nx-X11/programs/Xserver/GL/glx/Imakefile index 506ef5539..bf2d760a0 100644 --- a/nx-X11/programs/Xserver/GL/glx/Imakefile +++ b/nx-X11/programs/Xserver/GL/glx/Imakefile @@ -43,7 +43,8 @@ LinkSourceFile(indirect_size.h, $(MESASRCDIR)/src/glx/x11) INCLUDES = -I$(SERVERSRC)/GL/glx -I$(SERVERSRC)/GL/include -I$(SERVERSRC)/include -I$(INCLUDESRC) -I$(MESASRCDIR)/include \ -I$(XINCLUDESRC) -I$(SERVERSRC)/mi \ -I$(EXTINCSRC) -I$(LIBSRC)/GL/include \ - -I$(XF86SRC) + -I$(XF86SRC) \ + `pkg-config --cflags-only-I pixman-1` #if defined(DarwinArchitecture) && ((OSMajorVersion == 6 && OSMinorVersion < 3) || OSMajorVersion < 6) NO_EXT_DEFS = -DMISSING_GL_EXTS diff --git a/nx-X11/programs/Xserver/GL/mesa/X/Imakefile b/nx-X11/programs/Xserver/GL/mesa/X/Imakefile index ee728b556..9fb00ef73 100644 --- a/nx-X11/programs/Xserver/GL/mesa/X/Imakefile +++ b/nx-X11/programs/Xserver/GL/mesa/X/Imakefile @@ -39,7 +39,8 @@ LinkSourceFile(compsize.c,$(MESASRCDIR)/src/glx/x11) -I$(SERVERSRC)/include -I$(SERVERSRC)/GL/include \ -I$(SERVERSRC)/GL/glx \ -I$(XF86OSSRC) \ - -I$(DRMSRCDIR)/shared-core + -I$(DRMSRCDIR)/shared-core \ + `pkg-config --cflags-only-I pixman-1` DEFINES = $(GLX_DEFINES) $(GLXSRV_DEFINES) -DNXAGENT_SERVER /*-DUSE_X86_ASM*/ /*-DUSE_SPARC_ASM*/ diff --git a/nx-X11/programs/Xserver/Imakefile b/nx-X11/programs/Xserver/Imakefile index c7e1af550..a2a3f7ced 100644 --- a/nx-X11/programs/Xserver/Imakefile +++ b/nx-X11/programs/Xserver/Imakefile @@ -384,10 +384,12 @@ NXAGENTOBJS = hw/nxagent/miinitext.o \ dix/main.o #endif -XPMLIB = -lXpm +XPMLIB = -lXpm +XMLLIB = `pkg-config --libs libxml-2.0` +PIXMANLIB = `pkg-config --libs pixman-1` NXAGENT = hw/nxagent/LibraryTargetName(nxagent) NXAGENTLIBS = PreFbLibs $(NXAGENT) FbPostFbLibs $(NXAGENT) $(MI) -NXAGENTSYSLIBS = $(LDPRELIBS) $(XLIB) $(SYSLIBS) $(XPMLIB) +NXAGENTSYSLIBS = $(LDPRELIBS) $(XLIB) $(SYSLIBS) $(XPMLIB) $(XMLLIB) $(PIXMANLIB) #if HasParallelMake MakeMutex($(NXAGENTDIRS) $(NXAGENTOBJS) $(NXAGENTLIBS) $(NXAGENTSYSLIBS)) #endif @@ -403,18 +405,15 @@ $(NXAGENTOBJS) $(NXAGENTLIBS) $(NXAGENTSYSLIBS):: $(NXAGENTDIRS) #if defined(SunArchitecture) NXAGENTNXLIBS = -L ../../../nxcomp -L ../../../nxcompext -L ../../../nxcompshad \ -lXcomp -lXcompext -lXcompshad -lrt -L/usr/sfw/lib -lXrender -lXfixes -lXfont \ - -L../../../nx-X11/exports/lib -lXtst -lXrandr -lXcomposite -lXdmcp \ -`pkg-config --libs libxml-2.0` + -L../../../nx-X11/exports/lib -lXtst -lXrandr -lXcomposite -lXdmcp #elif defined(cygwinArchitecture) NXAGENTNXLIBS = -L ../../../nxcomp -L ../../../nxcompext \ -lXcomp -lXcompext -lXrender -lX11 -lNX_Xext -lXcomposite -lXfixes -lXfont \ - -L ../../../nxcompshad -lXcompshad -L../../../nx-X11/exports/lib -lXtst -lXdmcp \ -`pkg-config --libs libxml-2.0` + -L ../../../nxcompshad -lXcompshad -L../../../nx-X11/exports/lib -lXtst -lXdmcp #else NXAGENTNXLIBS = -L ../../../nxcomp -L ../../../nxcompext -L ../../../nxcompshad \ -lXcomp -lXcompext -lXcompshad -lXrender -lNX_X11 -lNX_Xext -lXfixes -lXfont \ - -L../../../nx-X11/exports/lib -lXtst -lXrandr -lXcomposite -lXinerama -lXdmcp \ -`pkg-config --libs libxml-2.0` + -L../../../nx-X11/exports/lib -lXtst -lXrandr -lXcomposite -lXinerama -lXdmcp #endif #endif diff --git a/nx-X11/programs/Xserver/XTrap/Imakefile b/nx-X11/programs/Xserver/XTrap/Imakefile index 2362634c7..c61712f1d 100644 --- a/nx-X11/programs/Xserver/XTrap/Imakefile +++ b/nx-X11/programs/Xserver/XTrap/Imakefile @@ -11,7 +11,7 @@ XCOMM $XFree86: xc/programs/Xserver/XTrap/Imakefile,v 1.1 2001/11/02 23:29:29 da #endif SRCS = xtrapddmi.c xtrapdi.c xtrapdiswp.c xtrapditbl.c OBJS = xtrapddmi.o xtrapdi.o xtrapdiswp.o xtrapditbl.o - INCLUDES = -I../include -I$(EXTINCSRC) -I$(XINCLUDESRC) -I$(SERVERSRC)/Xext + INCLUDES = -I../include -I$(EXTINCSRC) -I$(XINCLUDESRC) -I$(SERVERSRC)/Xext `pkg-config --cflags-only-I pixman-1` NormalLibraryTarget(xtrap,$(OBJS)) LintLibraryTarget(xtrap,$(SRCS)) diff --git a/nx-X11/programs/Xserver/Xext/Imakefile b/nx-X11/programs/Xserver/Xext/Imakefile index eb4588e37..199e59f1d 100644 --- a/nx-X11/programs/Xserver/Xext/Imakefile +++ b/nx-X11/programs/Xserver/Xext/Imakefile @@ -161,7 +161,8 @@ XF86INCLUDES = -I$(XF86COMSRC) #endif INCLUDES = -I. -I../include -I$(XINCLUDESRC) -I$(EXTINCSRC) \ $(PNRXINCLUDES) $(XF86INCLUDES) \ - $(FONTCACHEINCLUDES) $(DMXINCLUDES) + $(FONTCACHEINCLUDES) $(DMXINCLUDES) \ + `pkg-config --cflags-only-I pixman-1` LINTLIBS = ../dix/llib-ldix.ln ../os/llib-los.ln #if defined(NXAgentServer) && NXAgentServer diff --git a/nx-X11/programs/Xserver/Xi/Imakefile b/nx-X11/programs/Xserver/Xi/Imakefile index 27e1f5df0..29190b711 100644 --- a/nx-X11/programs/Xserver/Xi/Imakefile +++ b/nx-X11/programs/Xserver/Xi/Imakefile @@ -83,7 +83,7 @@ XCOMM $XFree86: xc/programs/Xserver/Xi/Imakefile,v 3.2 1999/04/17 09:08:22 dawes ungrdev.o \ ungrdevb.o \ ungrdevk.o - INCLUDES = -I../include -I$(EXTINCSRC) -I$(XINCLUDESRC) + INCLUDES = -I../include -I$(EXTINCSRC) -I$(XINCLUDESRC) `pkg-config --cflags-only-I pixman-1` LINTLIBS = ../dix/llib-ldix.ln ../os/llib-los.ln NormalLibraryTarget(xinput,$(OBJS)) diff --git a/nx-X11/programs/Xserver/composite/Imakefile b/nx-X11/programs/Xserver/composite/Imakefile index c45aa7f6a..f121e0bbe 100644 --- a/nx-X11/programs/Xserver/composite/Imakefile +++ b/nx-X11/programs/Xserver/composite/Imakefile @@ -6,7 +6,8 @@ INCLUDES = -I../include -I../mi -I../Xext -I../render -I../xfixes \ -I../damageext -I../miext/damage -I$(EXTINCSRC) \ - -I$(XINCLUDESRC) + -I$(XINCLUDESRC) \ + `pkg-config --cflags-only-I pixman-1` LINTLIBS = ../dix/llib-ldix.ln ../os/llib-los.ln diff --git a/nx-X11/programs/Xserver/damageext/Imakefile b/nx-X11/programs/Xserver/damageext/Imakefile index f7ce4573b..24dcee85c 100644 --- a/nx-X11/programs/Xserver/damageext/Imakefile +++ b/nx-X11/programs/Xserver/damageext/Imakefile @@ -5,7 +5,8 @@ OBJS = damageext.o INCLUDES = -I../include -I../Xext -I../render -I../xfixes -I../miext/damage \ - -I$(EXTINCSRC) -I$(XINCLUDESRC) + -I$(EXTINCSRC) -I$(XINCLUDESRC) \ + `pkg-config --cflags-only-I pixman-1` LINTLIBS = ../dix/llib-ldix.ln ../os/llib-los.ln diff --git a/nx-X11/programs/Xserver/dbe/Imakefile b/nx-X11/programs/Xserver/dbe/Imakefile index 9d9c3fd67..5e5eac4a1 100644 --- a/nx-X11/programs/Xserver/dbe/Imakefile +++ b/nx-X11/programs/Xserver/dbe/Imakefile @@ -17,7 +17,7 @@ XCOMM $XFree86: xc/programs/Xserver/dbe/Imakefile,v 3.10 2001/01/17 22:36:41 daw SRCS = dbe.c midbe.c OBJS = dbe.o midbe.o - INCLUDES = -I$(SERVERSRC)/include -I$(XINCLUDESRC) -I$(EXTINCSRC) $(EXTRAINCLUDES) + INCLUDES = -I$(SERVERSRC)/include -I$(XINCLUDESRC) -I$(EXTINCSRC) $(EXTRAINCLUDES) `pkg-config --cflags-only-I pixman-1` LINTLIBS = ../dix/llib-ldix.ln ../os/llib-los.ln NormalLibraryObjectRule() diff --git a/nx-X11/programs/Xserver/dix/Imakefile b/nx-X11/programs/Xserver/dix/Imakefile index 47e617718..22b21eb95 100644 --- a/nx-X11/programs/Xserver/dix/Imakefile +++ b/nx-X11/programs/Xserver/dix/Imakefile @@ -25,7 +25,8 @@ OBJS = atom.o colormap.o cursor.o devices.o dispatch.o dixutils.o events.o \ tables.o window.o initatoms.o dixfonts.o privates.o pixmap.o $(FFS_OBJ) INCLUDES = -I../include -I$(XINCLUDESRC) -I$(EXTINCSRC) \ - -I$(SERVERSRC)/Xext -I$(SERVERSRC)/lbx + -I$(SERVERSRC)/Xext -I$(SERVERSRC)/lbx \ + `pkg-config --cflags-only-I pixman-1` LINTLIBS = ../os/llib-los.ln /* diff --git a/nx-X11/programs/Xserver/fb/Imakefile b/nx-X11/programs/Xserver/fb/Imakefile index 489d6a201..662a70717 100644 --- a/nx-X11/programs/Xserver/fb/Imakefile +++ b/nx-X11/programs/Xserver/fb/Imakefile @@ -123,7 +123,8 @@ OBJS = $(XFMODOBJ) \ INCLUDES = -I$(SERVERSRC)/fb -I$(SERVERSRC)/mi -I$(SERVERSRC)/include \ -I$(XINCLUDESRC) \ -I$(XF86SRC)/common $(EXTRAINCLUDES) \ - -I$(SERVERSRC)/render -I$(EXTINCSRC) -I$(SERVERSRC)/Xext + -I$(SERVERSRC)/render -I$(EXTINCSRC) -I$(SERVERSRC)/Xext \ + `pkg-config --cflags-only-I pixman-1` LINTLIBS = $(SERVERSRC)/dix/llib-ldix.ln $(SERVERSRC)/os/llib-los.ln \ $(SERVERSRC)/mi/llib-lmi.ln diff --git a/nx-X11/programs/Xserver/hw/nxagent/Imakefile b/nx-X11/programs/Xserver/hw/nxagent/Imakefile index 160d01e60..b0aff4b07 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Imakefile +++ b/nx-X11/programs/Xserver/hw/nxagent/Imakefile @@ -141,7 +141,8 @@ INCLUDES = -I. -I../../../../../nxcomp -I../../../../../nxcompext -I../../../../ -I../../GL/glx -I../../GL/include -I../../../../lib/GL/include -I../../Xext \ -I$(EXTINCSRC) -I$(XINCLUDESRC) \ $(VFBINCLUDES) \ - `pkg-config --cflags-only-I libxml-2.0` + `pkg-config --cflags-only-I libxml-2.0` \ + `pkg-config --cflags-only-I pixman-1` #ifdef SunArchitecture INCLUDES = -I. -I../../../../../nxcomp -I../../../../../nxcompext -I../../../../../nxcompshad \ -I../../../../extras/Mesa/include \ @@ -153,6 +154,7 @@ INCLUDES = -I. -I../../../../../nxcomp -I../../../../../nxcompext -I../../../../ -I$(EXTINCSRC) -I$(XINCLUDESRC) \ $(VFBINCLUDES) \ `pkg-config --cflags-only-I libxml-2.0` + `pkg-config --cflags-only-I pixman-1` #else #ifdef cygwinArchitecture INCLUDES = -I. -I$(XBUILDINCDIR) \ @@ -164,6 +166,7 @@ INCLUDES = -I. -I$(XBUILDINCDIR) \ -I$(EXTINCSRC) -I$(XINCLUDESRC) \ $(VFBINCLUDES) \ `pkg-config --cflags-only-I libxml-2.0` + `pkg-config --cflags-only-I pixman-1` #endif #endif diff --git a/nx-X11/programs/Xserver/include/scrnintstr.h b/nx-X11/programs/Xserver/include/scrnintstr.h index 0539ca516..2597d6b67 100644 --- a/nx-X11/programs/Xserver/include/scrnintstr.h +++ b/nx-X11/programs/Xserver/include/scrnintstr.h @@ -709,6 +709,10 @@ typedef struct _Screen { } ScreenRec; +static inline RegionPtr BitmapToRegion(ScreenPtr _pScreen, PixmapPtr pPix) { + return (*(_pScreen)->BitmapToRegion)(pPix); /* no mi version?! */ +} + typedef struct _ScreenInfo { int imageByteOrder; int bitmapScanlineUnit; diff --git a/nx-X11/programs/Xserver/mi/Imakefile b/nx-X11/programs/Xserver/mi/Imakefile index e62fb0005..290f85790 100644 --- a/nx-X11/programs/Xserver/mi/Imakefile +++ b/nx-X11/programs/Xserver/mi/Imakefile @@ -90,7 +90,8 @@ EXT_DEFINES = ExtensionDefines -UXINPUT -UXF86VIDMODE -UXFreeXDGA -UXF86MISC \ INCLUDES = -I. -I../include -I../render \ -I../xfixes -I../damageext -I../miext/damage \ - -I$(XINCLUDESRC) -I$(EXTINCSRC) -I$(SERVERSRC)/Xext + -I$(XINCLUDESRC) -I$(EXTINCSRC) -I$(SERVERSRC)/Xext \ + `pkg-config --cflags-only-I pixman-1` LINTLIBS = ../dix/llib-ldix.ln ../os/llib-los.ln DEFINES = $(FFS_DEFINES) diff --git a/nx-X11/programs/Xserver/miext/cw/Imakefile b/nx-X11/programs/Xserver/miext/cw/Imakefile index 39106ac13..795ed1987 100755 --- a/nx-X11/programs/Xserver/miext/cw/Imakefile +++ b/nx-X11/programs/Xserver/miext/cw/Imakefile @@ -7,7 +7,8 @@ OBJS = cw.o cw_ops.o cw_render.o INCLUDES = -I../../mi -I../../fb -I../../render -I../../composite \ -I../../include -I$(XINCLUDESRC) $(EXTRAINCLUDES) \ - -I$(EXTINCSRC) + -I$(EXTINCSRC) \ + `pkg-config --cflags-only-I pixman-1` LINTLIBS = ../../dix/llib-ldix.ln ../../os/llib-los.ln \ ../../mi/llib-lmi.ln diff --git a/nx-X11/programs/Xserver/miext/damage/Imakefile b/nx-X11/programs/Xserver/miext/damage/Imakefile index 7fa745b65..a28786203 100755 --- a/nx-X11/programs/Xserver/miext/damage/Imakefile +++ b/nx-X11/programs/Xserver/miext/damage/Imakefile @@ -11,7 +11,8 @@ OBJS = damage.o INCLUDES = -I. -I../shadow -I../../mi -I../../fb -I../../include -I$(XINCLUDESRC) \ -I$(XF86SRC)/common $(EXTRAINCLUDES) \ - -I../../render -I../cw -I$(EXTINCSRC) + -I../../render -I../cw -I$(EXTINCSRC) \ + `pkg-config --cflags-only-I pixman-1` LINTLIBS = ../../dix/llib-ldix.ln ../../os/llib-los.ln \ ../../mi/llib-lmi.ln diff --git a/nx-X11/programs/Xserver/os/Imakefile b/nx-X11/programs/Xserver/os/Imakefile index 18bb9804d..5245b7841 100644 --- a/nx-X11/programs/Xserver/os/Imakefile +++ b/nx-X11/programs/Xserver/os/Imakefile @@ -158,7 +158,8 @@ BOOTSTRAPCFLAGS = $(RANDOM_DEFINES) $(BUGMSG) $(XTRANS_FAILDEFINES) $(NX_DEFINES) INCLUDES = -I. -I../include -I$(XINCLUDESRC) -I$(EXTINCSRC) \ -I$(SERVERSRC)/Xext -I$(SERVERSRC)/render \ - -I$(TOP)/lib/Xau Krb5Includes $(NX_INCLUDES) + -I$(TOP)/lib/Xau Krb5Includes $(NX_INCLUDES) \ + `pkg-config --cflags-only-I pixman-1` DEPEND_DEFINES = $(DBM_DEFINES) $(XDMCP_DEFINES) $(EXT_DEFINES) \ $(TRANS_INCLUDES) $(CONNECTION_FLAGS) $(GETPEER_DEFINES) \ DependDefines diff --git a/nx-X11/programs/Xserver/randr/Imakefile b/nx-X11/programs/Xserver/randr/Imakefile index 19f8143e4..7f920aece 100644 --- a/nx-X11/programs/Xserver/randr/Imakefile +++ b/nx-X11/programs/Xserver/randr/Imakefile @@ -23,7 +23,9 @@ XCOMM $XFree86: xc/programs/Xserver/randr/Imakefile,v 1.1 2001/05/23 03:29:44 ke INCLUDES = -I../include -I../mi \ -I../fb -I../hw/kdrive -I$(EXTINCSRC) -I$(XINCLUDESRC) \ - -I../render + -I../render \ + `pkg-config --cflags-only-I pixman-1` + LINTLIBS = ../dix/llib-ldix.ln ../os/llib-los.ln DEFINES = -DNXAGENT_SERVER diff --git a/nx-X11/programs/Xserver/record/Imakefile b/nx-X11/programs/Xserver/record/Imakefile index 4d4bf6a73..c24cbb0d9 100644 --- a/nx-X11/programs/Xserver/record/Imakefile +++ b/nx-X11/programs/Xserver/record/Imakefile @@ -16,7 +16,7 @@ XCOMM $XFree86: xc/programs/Xserver/record/Imakefile,v 1.12 2001/11/02 23:29:34 #endif SRCS = record.c set.c OBJS = record.o set.o - INCLUDES = -I../include -I$(XINCLUDESRC) -I$(EXTINCSRC) -I$(SERVERSRC)/Xext + INCLUDES = -I../include -I$(XINCLUDESRC) -I$(EXTINCSRC) -I$(SERVERSRC)/Xext `pkg-config --cflags-only-I pixman-1` LINTLIBS = ../dix/llib-ldix.ln DEFINES = -DNDEBUG diff --git a/nx-X11/programs/Xserver/render/Imakefile b/nx-X11/programs/Xserver/render/Imakefile index 1331b1fb4..23f9476ea 100644 --- a/nx-X11/programs/Xserver/render/Imakefile +++ b/nx-X11/programs/Xserver/render/Imakefile @@ -29,7 +29,8 @@ XCOMM $XFree86: xc/programs/Xserver/render/Imakefile,v 1.10 2002/11/23 02:38:15 INCLUDES = -I. -I../include -I../mi \ -I../fb -I../hw/kdrive -I$(EXTINCSRC) -I$(XINCLUDESRC) \ - -I../Xext + -I../Xext \ + `pkg-config --cflags-only-I pixman-1` LINTLIBS = ../dix/llib-ldix.ln ../os/llib-los.ln NormalLibraryTarget(render,$(OBJS)) diff --git a/nx-X11/programs/Xserver/xfixes/Imakefile b/nx-X11/programs/Xserver/xfixes/Imakefile index e467ed149..84f7c6f16 100755 --- a/nx-X11/programs/Xserver/xfixes/Imakefile +++ b/nx-X11/programs/Xserver/xfixes/Imakefile @@ -5,7 +5,8 @@ OBJS = cursor.o region.o saveset.o select.o xfixes.o INCLUDES = -I. -I../include -I../Xext -I../fixes -I../render \ - -I$(EXTINCSRC) -I$(XINCLUDESRC) + -I$(EXTINCSRC) -I$(XINCLUDESRC) \ + `pkg-config --cflags-only-I pixman-1` LINTLIBS = ../dix/llib-ldix.ln ../os/llib-los.ln diff --git a/nx-X11/programs/Xserver/xkb/Imakefile b/nx-X11/programs/Xserver/xkb/Imakefile index 2ac6fe32d..e63ca4462 100644 --- a/nx-X11/programs/Xserver/xkb/Imakefile +++ b/nx-X11/programs/Xserver/xkb/Imakefile @@ -51,7 +51,8 @@ XF86INCLUDES = -I$(XF86COMSRC) -I$(XF86OSSRC) XKBMisc.o XKBMAlloc.o XKBAlloc.o XKBGAlloc.o \ $(XKBXI_OBJS) $(DDX_OBJS) INCLUDES = -I../include -I$(XINCLUDESRC) -I$(EXTINCSRC) -I$(SERVERSRC)/Xext \ - -I$(SERVERSRC)/mi $(XF86INCLUDES) + -I$(SERVERSRC)/mi $(XF86INCLUDES) \ + `pkg-config --cflags-only-I pixman-1` LINTLIBS = ../dix/llib-ldix.ln ../os/llib-los.ln DEFINES = -DXKB_IN_SERVER $(EXTRA_ALLOC_DEFINES) $(XKB_DDXDEFS) $(NX_DEFINES) diff --git a/nx-libs.spec b/nx-libs.spec index 24287f178..98cee6926 100644 --- a/nx-libs.spec +++ b/nx-libs.spec @@ -29,6 +29,7 @@ BuildRequires: fdupes BuildRequires: pkgconfig(expat) BuildRequires: pkgconfig(libpng) BuildRequires: pkgconfig(libxml-2.0) +BuildRequires: pkgconfig(pixman-1) BuildRequires: pkgconfig(x11) BuildRequires: pkgconfig(xext) BuildRequires: pkgconfig(xpm) @@ -44,6 +45,7 @@ BuildRequires: pkgconfig(xinerama) BuildRequires: libexpat-devel BuildRequires: libpng-devel BuildRequires: libxml2-devel +BuildRequires: pixman-devel BuildRequires: xorg-x11-libX11-devel BuildRequires: xorg-x11-libXext-devel BuildRequires: xorg-x11-libXpm-devel @@ -63,6 +65,7 @@ BuildRequires: xorg-x11-util-devel BuildRequires: expat-devel BuildRequires: libpng-devel BuildRequires: libxml2-devel +BuildRequires: pixman-devel BuildRequires: libX11-devel BuildRequires: libXext-devel BuildRequires: libXpm-devel diff --git a/nxcompext/configure.in b/nxcompext/configure.in index eb6604dba..5b9ccc4da 100644 --- a/nxcompext/configure.in +++ b/nxcompext/configure.in @@ -28,6 +28,8 @@ if test -d "../nx-X11/include" ; then LDFLAGS="$LDFLAGS -L../nx-X11/exports/lib" fi +X_CFLAGS=`pkg-config --cflags-only-I pixman-1` + dnl Check for programs. AC_PROG_CXX -- cgit v1.2.3 From ce8fb1f93f71246462d5692c42c88989eb32b1d2 Mon Sep 17 00:00:00 2001 From: Mike Gabriel Date: Mon, 21 Mar 2016 16:11:46 +0100 Subject: HAVE_STDINT_H: Always include . We don't define HAVE_STDINT_H anywhere and it should be more safe using the system's definition of UINT32_MAX. --- nx-X11/programs/Xserver/Xext/sampleEVI.c | 4 ---- nx-X11/programs/Xserver/Xext/xcmisc.c | 4 ---- nx-X11/programs/Xserver/hw/nxagent/NXglyph.c | 4 ---- nx-X11/programs/Xserver/render/glyph.c | 4 ---- 4 files changed, 16 deletions(-) (limited to 'nx-X11/programs/Xserver/render') diff --git a/nx-X11/programs/Xserver/Xext/sampleEVI.c b/nx-X11/programs/Xserver/Xext/sampleEVI.c index 598992742..961c108f9 100644 --- a/nx-X11/programs/Xserver/Xext/sampleEVI.c +++ b/nx-X11/programs/Xserver/Xext/sampleEVI.c @@ -37,11 +37,7 @@ THE USE OR PERFORMANCE OF THIS SOFTWARE. #include "EVIstruct.h" #include "scrnintstr.h" -#if HAVE_STDINT_H #include -#elif !defined(UINT32_MAX) -#define UINT32_MAX 0xffffffffU -#endif static int sampleGetVisualInfo( VisualID32 *visual, diff --git a/nx-X11/programs/Xserver/Xext/xcmisc.c b/nx-X11/programs/Xserver/Xext/xcmisc.c index 1d7ad0e09..e353d65ac 100644 --- a/nx-X11/programs/Xserver/Xext/xcmisc.c +++ b/nx-X11/programs/Xserver/Xext/xcmisc.c @@ -44,11 +44,7 @@ from The Open Group. #include #include "modinit.h" -#if HAVE_STDINT_H #include -#elif !defined(UINT32_MAX) -#define UINT32_MAX 0xffffffffU -#endif #if 0 static unsigned char XCMiscCode; diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXglyph.c b/nx-X11/programs/Xserver/hw/nxagent/NXglyph.c index 47db919ef..757ffff21 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXglyph.c +++ b/nx-X11/programs/Xserver/hw/nxagent/NXglyph.c @@ -76,11 +76,7 @@ #endif -#if HAVE_STDINT_H #include -#elif !defined(UINT32_MAX) -#define UINT32_MAX 0xffffffffU -#endif /* * From Knuth -- a good choice for hash/rehash values is p, p-2 where diff --git a/nx-X11/programs/Xserver/render/glyph.c b/nx-X11/programs/Xserver/render/glyph.c index 900cf9844..f15b199b5 100644 --- a/nx-X11/programs/Xserver/render/glyph.c +++ b/nx-X11/programs/Xserver/render/glyph.c @@ -43,11 +43,7 @@ #include "picturestr.h" #include "glyphstr.h" -#if HAVE_STDINT_H #include -#elif !defined(UINT32_MAX) -#define UINT32_MAX 0xffffffffU -#endif /* * From Knuth -- a good choice for hash/rehash values is p, p-2 where -- cgit v1.2.3