--- a/configure.ac
+++ b/configure.ac
@@ -1110,7 +1110,7 @@
                 fi
 
                 CUPSINCLUDE="include $srcdir/cups/cups.mak"
-                CUPSDEV="cups"
+                CUPSDEV="cups pwgraster"
                 CUPSVERSION="`$CUPSCONFIG --version`"
                 LCUPSINCLUDE="include \$(GLSRCDIR)/lcups.mak"
                 LCUPSIINCLUDE="include \$(GLSRCDIR)/lcupsi.mak"
@@ -1128,7 +1128,7 @@
                 LCUPSBUILDTYPE=linux
                 LCUPSINCLUDE="include \$(GLSRCDIR)/lcups.mak"
                 LCUPSIINCLUDE="include \$(GLSRCDIR)/lcupsi.mak"
-                CUPSDEV="cups"
+                CUPSDEV="cups pwgraster"
             fi
         fi
     fi
--- a/cups/gdevcups.c
+++ b/cups/gdevcups.c
@@ -336,109 +336,118 @@
 	),\
 	prn_device_body_copies_rest_(print_pages)
 
-gx_device_cups	gs_cups_device =
-{
-  prn_device_body_copies(gx_device_cups,/* type */
-                         cups_procs,	/* procedures */
-			 "cups",	/* device name */
-			 85,		/* initial width */
-			 110,		/* initial height */
-			 100,		/* initial x resolution */
-			 100,		/* initial y resolution */
-                         0,		/* initial left offset */
-			 0,		/* initial top offset */
-			 0,		/* initial left margin */
-			 0,		/* initial bottom margin */
-			 0,		/* initial right margin */
-			 0,		/* initial top margin */
-			 1,		/* number of color components */
-			 1,		/* number of color bits */
-			 1,		/* maximum gray value */
-			 0,		/* maximum color value */
-			 2,		/* number of gray values */
-			 0,		/* number of color values */
-			 cups_print_pages),
-					/* print procedure */
-  0,					/* page */
-  NULL,					/* stream */
-  {					/* header */
-    "",					/* MediaClass */
-    "",					/* MediaColor */
-    "",					/* MediaType */
-    "",					/* OutputType */
-    0,					/* AdvanceDistance */
-    CUPS_ADVANCE_NONE,			/* AdvanceMedia */
-    CUPS_FALSE,				/* Collate */
-    CUPS_CUT_NONE,			/* CutMedia */
-    CUPS_FALSE,				/* Duplex */
-    { 100, 100 },			/* HWResolution */
-    { 0, 0, 612, 792 },			/* ImagingBoundingBox */
-    CUPS_FALSE,				/* InsertSheet */
-    CUPS_JOG_NONE,			/* Jog */
-    CUPS_EDGE_TOP,			/* LeadingEdge */
-    { 0, 0 },				/* Margins */
-    CUPS_FALSE,				/* ManualFeed */
-    0,					/* MediaPosition */
-    0,					/* MediaWeight */
-    CUPS_FALSE,				/* MirrorPrint */
-    CUPS_FALSE,				/* NegativePrint */
-    1,					/* NumCopies */
-    CUPS_ORIENT_0,			/* Orientation */
-    CUPS_FALSE,				/* OutputFaceUp */
-    { 612, 792 },			/* PageSize */
-    CUPS_FALSE,				/* Separations */
-    CUPS_FALSE,				/* TraySwitch */
-    CUPS_FALSE,				/* Tumble */
-    850,				/* cupsWidth */
-    1100,				/* cupsHeight */
-    0,					/* cupsMediaType */
-    1,					/* cupsBitsPerColor */
-    1,					/* cupsBitsPerPixel */
-    107,				/* cupsBytesPerLine */
-    CUPS_ORDER_CHUNKED,			/* cupsColorOrder */
-    CUPS_CSPACE_K,			/* cupsColorSpace */
-    0,					/* cupsCompression */
-    0,					/* cupsRowCount */
-    0,					/* cupsRowFeed */
-    0					/* cupsRowStep */
+
+
 #ifdef CUPS_RASTER_SYNCv1
-    ,
-    1,                                  /* cupsNumColors */
-    1.0,                                /* cupsBorderlessScalingFactor */
-    { 612.0, 792.0 },                   /* cupsPageSize */
-    { 0.0, 0.0, 612.0, 792.0 },         /* cupsImagingBBox */
-    { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 }, /* cupsInteger */
-    { 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0,
-      0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0 }, /* cupsReal */
-    { "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "" },
-                                        /* cupsString */
-    "",                                 /* cupsMarkerType */
-    "",                                 /* cupsRenderingIntent */
+#define RASTER_SYNCv1_ENTRIES \
+    ,\
+    1,                                  /* cupsNumColors */\
+    1.0,                                /* cupsBorderlessScalingFactor */\
+    { 612.0, 792.0 },                   /* cupsPageSize */\
+    { 0.0, 0.0, 612.0, 792.0 },         /* cupsImagingBBox */\
+    { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 }, /* cupsInteger */\
+    { 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0,\
+      0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0 }, /* cupsReal */\
+    { "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "" },\
+                                        /* cupsString */\
+    "",                                 /* cupsMarkerType */\
+    "",                                 /* cupsRenderingIntent */\
     ""                                  /* cupsPageSizeName */
+#else
+#define RASTER_SYNCv1_ENTRIES
 #endif /* CUPS_RASTER_SYNCv1 */
-  },
-  0,                                    /* landscape */
-  0,                                    /* lastpage */
-  0,                                    /* HaveProfile */
-  NULL,                                 /* Profile */
-  NULL,                                 /* PPD */
-  { 0x00, 0x08, 0x04, 0x0c, 0x02, 0x0a, 0x06, 0x0e,
-    0x01, 0x09, 0x05, 0x0d, 0x03, 0x0b, 0x07, 0x0f },/* RevLower1 */
-  { 0x00, 0x80, 0x40, 0xc0, 0x20, 0xa0, 0x60, 0xe0,
-    0x10, 0x90, 0x50, 0xd0, 0x30, 0xb0, 0x70, 0xf0 },/* RevUpper1 */
-  { 0x00, 0x04, 0x08, 0x0c, 0x01, 0x05, 0x09, 0x0d,
-    0x02, 0x06, 0x0a, 0x0e, 0x03, 0x07, 0x0b, 0x0f },/* RevLower2 */
-  { 0x00, 0x40, 0x80, 0xc0, 0x10, 0x50, 0x90, 0xd0,
-    0x20, 0x60, 0xa0, 0xe0, 0x30, 0x70, 0xb0, 0xf0 },/* RevUpper2 */
-  {0x00},                                  /* DecodeLUT */
-  {0x00},                                  /* EncodeLUT */
-  {0x00},                                  /* Density */
-  {{{0x00},{0x00},{0x00}},
-   {{0x00},{0x00},{0x00}},
-   {{0x00},{0x00},{0x00}}},                /* Matrix */
-  0,                                       /* user_icc */
+
+#define gs_xxx_device(dname, mediaclass)\
+  prn_device_body_copies(gx_device_cups,/* type */\
+                         cups_procs,	/* procedures */\
+			 dname,		/* device name */\
+			 85,		/* initial width */\
+			 110,		/* initial height */\
+			 100,		/* initial x resolution */\
+			 100,		/* initial y resolution */\
+                         0,		/* initial left offset */\
+			 0,		/* initial top offset */\
+			 0,		/* initial left margin */\
+			 0,		/* initial bottom margin */\
+			 0,		/* initial right margin */\
+			 0,		/* initial top margin */\
+			 1,		/* number of color components */\
+			 1,		/* number of color bits */\
+			 1,		/* maximum gray value */\
+			 0,		/* maximum color value */\
+			 2,		/* number of gray values */\
+			 0,		/* number of color values */\
+			 cups_print_pages),\
+					/* print procedure */\
+  0,					/* page */\
+  NULL,					/* stream */\
+  {					/* header */\
+    mediaclass,				/* MediaClass */\
+    "",					/* MediaColor */\
+    "",					/* MediaType */\
+    "",					/* OutputType */\
+    0,					/* AdvanceDistance */\
+    CUPS_ADVANCE_NONE,			/* AdvanceMedia */\
+    CUPS_FALSE,				/* Collate */\
+    CUPS_CUT_NONE,			/* CutMedia */\
+    CUPS_FALSE,				/* Duplex */\
+    { 100, 100 },			/* HWResolution */\
+    { 0, 0, 612, 792 },			/* ImagingBoundingBox */\
+    CUPS_FALSE,				/* InsertSheet */\
+    CUPS_JOG_NONE,			/* Jog */\
+    CUPS_EDGE_TOP,			/* LeadingEdge */\
+    { 0, 0 },				/* Margins */\
+    CUPS_FALSE,				/* ManualFeed */\
+    0,					/* MediaPosition */\
+    0,					/* MediaWeight */\
+    CUPS_FALSE,				/* MirrorPrint */\
+    CUPS_FALSE,				/* NegativePrint */\
+    1,					/* NumCopies */\
+    CUPS_ORIENT_0,			/* Orientation */\
+    CUPS_FALSE,				/* OutputFaceUp */\
+    { 612, 792 },			/* PageSize */\
+    CUPS_FALSE,				/* Separations */\
+    CUPS_FALSE,				/* TraySwitch */\
+    CUPS_FALSE,				/* Tumble */\
+    850,				/* cupsWidth */\
+    1100,				/* cupsHeight */\
+    0,					/* cupsMediaType */\
+    1,					/* cupsBitsPerColor */\
+    1,					/* cupsBitsPerPixel */\
+    107,				/* cupsBytesPerLine */\
+    CUPS_ORDER_CHUNKED,			/* cupsColorOrder */\
+    CUPS_CSPACE_K,			/* cupsColorSpace */\
+    0,					/* cupsCompression */\
+    0,					/* cupsRowCount */\
+    0,					/* cupsRowFeed */\
+    0					/* cupsRowStep */\
+    RASTER_SYNCv1_ENTRIES, /* See above */\
+  },\
+  0,                                    /* landscape */\
+  0,                                    /* lastpage */\
+  0,                                    /* HaveProfile */\
+  NULL,                                 /* Profile */\
+  NULL,                                 /* PPD */\
+  { 0x00, 0x08, 0x04, 0x0c, 0x02, 0x0a, 0x06, 0x0e,\
+    0x01, 0x09, 0x05, 0x0d, 0x03, 0x0b, 0x07, 0x0f },/* RevLower1 */\
+  { 0x00, 0x80, 0x40, 0xc0, 0x20, 0xa0, 0x60, 0xe0,\
+    0x10, 0x90, 0x50, 0xd0, 0x30, 0xb0, 0x70, 0xf0 },/* RevUpper1 */\
+  { 0x00, 0x04, 0x08, 0x0c, 0x01, 0x05, 0x09, 0x0d,\
+    0x02, 0x06, 0x0a, 0x0e, 0x03, 0x07, 0x0b, 0x0f },/* RevLower2 */\
+  { 0x00, 0x40, 0x80, 0xc0, 0x10, 0x50, 0x90, 0xd0,\
+    0x20, 0x60, 0xa0, 0xe0, 0x30, 0x70, 0xb0, 0xf0 },/* RevUpper2 */\
+  {0x00},                                  /* DecodeLUT */\
+  {0x00},                                  /* EncodeLUT */\
+  {0x00},                                  /* Density */\
+  {{{0x00},{0x00},{0x00}},\
+   {{0x00},{0x00},{0x00}},\
+   {{0x00},{0x00},{0x00}}},                /* Matrix */\
+  0,                                       /* user_icc */\
   3                                     /* cupsRasterVersion */
-};
+
+gx_device_cups	gs_cups_device = { gs_xxx_device("cups", "") };
+gx_device_cups	gs_pwgraster_device = { gs_xxx_device("pwgraster",
+						      "PwgRaster") };
 
 /*
  * Local functions...
--- a/devices/devs.mak
+++ b/devices/devs.mak
@@ -1905,6 +1905,10 @@
 	$(SETPDEV2) $(DD)cups $(cups_)
 	$(ADDMOD) $(DD)cups -include $(lcups_dev)
 	$(ADDMOD) $(DD)cups -include $(lcupsi_dev)
+$(DD)pwgraster.dev : $(DEVS_MAK) $(lcups_dev) $(lcupsi_dev) $(cups_) $(GDEV)
+	$(SETPDEV2) $(DD)pwgraster $(cups_)
+	$(ADDMOD) $(DD)pwgraster -include $(lcups_dev)
+	$(ADDMOD) $(DD)pwgraster -include $(lcupsi_dev)
 
 $(DEVOBJ)gdevcups.$(OBJ) : $(LCUPSSRCDIR)$(D)gdevcups.c $(std_h)
 	$(CUPS_CC) $(DEVO_)gdevcups.$(OBJ) $(C_) $(CFLAGS) $(I_)$(GLSRC) \
