From bfb99c406766ada3c48b2f83d625674ddacb5787039096775b0567eacafcf791 Mon Sep 17 00:00:00 2001 From: OBS User unknown Date: Sat, 11 Oct 2008 22:29:41 +0000 Subject: [PATCH] OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/transfig?expand=0&rev=8 --- transfig.3.2.5-cups.dif | 51 +++++++++++++++++++++++++++++++++++++++++ transfig.changes | 5 ++++ transfig.spec | 17 +++++++++++--- 3 files changed, 70 insertions(+), 3 deletions(-) create mode 100644 transfig.3.2.5-cups.dif diff --git a/transfig.3.2.5-cups.dif b/transfig.3.2.5-cups.dif new file mode 100644 index 0000000..b6ddcc0 --- /dev/null +++ b/transfig.3.2.5-cups.dif @@ -0,0 +1,51 @@ +--- fig2dev/dev/genps.c ++++ fig2dev/dev/genps.c 2008-10-08 15:27:05.095587461 +0200 +@@ -686,6 +686,8 @@ F_compound *objects; + height = userury-userlly+1; + } + ++ /* put in the magnification for information purposes */ ++ fprintf(tfp, "%%Magnification: %.4f\n",metric? mag*76.2/80.0 : mag); + /* only include a pagesize command if PS */ + if (!epsflag && !pdfflag) { + /* add comment for ghostview to recognize the page size */ +@@ -694,6 +696,9 @@ F_compound *objects; + for (i=strlen(psize)-1; i>=0; i--) + psize[i] = tolower(psize[i]); + fprintf(tfp, "%%%%DocumentPaperSizes: %s\n",psize); ++ } ++ fprintf(tfp, "%%%%EndComments\n"); ++ if (!epsflag && !pdfflag) { + fprintf(tfp, "%%%%BeginSetup\n"); + fprintf(tfp, "[{\n"); + fprintf(tfp, "%%%%BeginFeature: *PageRegion %s\n", papersize); +@@ -711,10 +716,6 @@ F_compound *objects; + } + + +- /* put in the magnification for information purposes */ +- fprintf(tfp, "%%Magnification: %.4f\n",metric? mag*76.2/80.0 : mag); +- fprintf(tfp, "%%%%EndComments\n"); +- + /* if the user wants an ASCII preview, route the rest of the eps to a temp file */ + if (asciipreview) { + saveofile = tfp; +@@ -753,6 +754,7 @@ F_compound *objects; + + if (pats_used) + fprintf(tfp,"/MyAppDict 100 dict dup begin def\n"); ++ fprintf(tfp, "%%%%BeginProlog\n"); + fprintf(tfp, "%s", BEGIN_PROLOG1); + /* define the standard colors */ + genps_std_colors(); +@@ -870,8 +872,10 @@ F_compound *objects; + if (multi_page) { + /* reset the matrix for multipage mode */ + fprintf(tfp, "initmatrix\n"); ++ fprintf(tfp, "%%%%EndProlog\n"); + } else { + fprintf(tfp, " %.5f %.5f sc\n", scalex, scaley ); ++ fprintf(tfp, "%%%%EndProlog\n"); + if (!epsflag) { + fprintf(tfp,"%%%%Page: 1 1\n"); + fprintf(tfp, "%%%%BeginPageSetup\n"); diff --git a/transfig.changes b/transfig.changes index a22de19..a1ef11c 100644 --- a/transfig.changes +++ b/transfig.changes @@ -1,3 +1,8 @@ +------------------------------------------------------------------- +Wed Oct 8 15:30:13 CEST 2008 - werner@suse.de + +- Add patch to enable cups to print postscript (bnc#419432) + ------------------------------------------------------------------- Fri Apr 25 16:01:21 CEST 2008 - werner@suse.de diff --git a/transfig.spec b/transfig.spec index cc64a76..cf16010 100644 --- a/transfig.spec +++ b/transfig.spec @@ -2,9 +2,16 @@ # spec file for package transfig (Version 3.2.5) # # Copyright (c) 2008 SUSE LINUX Products GmbH, Nuernberg, Germany. -# This file and all modifications and additions to the pristine -# package are under the same license as the package itself. # +# All modifications and additions to the file contributed by third parties +# remain the property of their copyright owners, unless otherwise agreed +# upon. The license for this file, and modifications and additions to the +# file, is the same license as for the pristine package itself (unless the +# license for the pristine package is not an Open Source License, in which +# case the license is the MIT License). An "Open Source License" is a +# license that conforms to the Open Source Definition (Version 1.9) +# published by the Open Source Initiative. + # Please submit bugfixes or comments via http://bugs.opensuse.org/ # @@ -19,10 +26,11 @@ Provides: transfig.3.2.3d Requires: netpbm ghostscript-library ghostscript-fonts-std AutoReqProv: on Version: 3.2.5 -Release: 99 +Release: 159 Summary: Graphic Converter Source: transfig.%{version}.tar.bz2 Patch0: transfig.%{version}.dif +Patch1: transfig.%{version}-cups.dif BuildRoot: %{_tmppath}/%{name}-%{version}-build %{expand: %%global _exec_prefix %(type -p pkg-config &>/dev/null && pkg-config --variable prefix x11 || echo /usr/X11R6)} %if "%_exec_prefix" == "/usr/X11R6" @@ -59,6 +67,7 @@ Authors: %prep %setup -q -n transfig.%{version} %patch +%patch1 xmkmf -a -D_DATA='%{_data}' %build @@ -98,6 +107,8 @@ rm -vf %{buildroot}%{_docdir}/transfig/manual/*.div %doc %{_docdir}/transfig/ %changelog +* Wed Oct 08 2008 werner@suse.de +- Add patch to enable cups to print postscript (bnc#419432) * Fri Apr 25 2008 werner@suse.de - Remove unwanted debug code (bnc#383669) * Mon Nov 05 2007 werner@suse.de