From 63496400d7e70d1035809f01430de6e2fa4efb57 Mon Sep 17 00:00:00 2001 From: Tom Callaway Date: Fri, 27 Feb 2009 14:25:33 +0000 Subject: [PATCH] pick up patches from John Ellson (bz 486045) --- graphviz-2.20.3-configure-php.patch | 13 +++++++++ graphviz-2.20.3-gv.i.patch | 45 +++++++++++++++++++++++++++++ graphviz.spec | 10 ++++++- 3 files changed, 67 insertions(+), 1 deletion(-) create mode 100644 graphviz-2.20.3-configure-php.patch create mode 100644 graphviz-2.20.3-gv.i.patch diff --git a/graphviz-2.20.3-configure-php.patch b/graphviz-2.20.3-configure-php.patch new file mode 100644 index 0000000..a2e19b5 --- /dev/null +++ b/graphviz-2.20.3-configure-php.patch @@ -0,0 +1,13 @@ +--- graphviz-2.20.3/configure.orig 2009-02-25 13:14:22.000000000 -0500 ++++ graphviz-2.20.3/configure 2009-02-25 13:15:02.000000000 -0500 +@@ -27376,8 +27376,8 @@ + if test "x$use_swig" != "xYes"; then + use_php="No (swig not available)" + else +- if test `$SWIG -help 2>&1 | $GREP -c '\-php5 *- Generate'` = 0; then +- use_php="No (swig does not support -php5 option)" ++ if test `$SWIG -help 2>&1 | $GREP -c '\-php5* *- Generate'` = 0; then ++ use_php="No (swig does not support -php or -php5 option)" + else + # Extract the first word of "php", so it can be a program name with args. + set dummy php; ac_word=$2 diff --git a/graphviz-2.20.3-gv.i.patch b/graphviz-2.20.3-gv.i.patch new file mode 100644 index 0000000..8f878f9 --- /dev/null +++ b/graphviz-2.20.3-gv.i.patch @@ -0,0 +1,45 @@ +--- graphviz-2.20.3/tclpkg/gv/gv.i.orig 2009-02-25 13:44:36.000000000 -0500 ++++ graphviz-2.20.3/tclpkg/gv/gv.i 2009-02-25 13:46:29.000000000 -0500 +@@ -15,8 +15,22 @@ + **********************************************************/ + + %module gv +-%{ + ++#ifdef SWIGTCL ++// A typemap telling SWIG to ignore an argument for input ++// However, we still need to pass a pointer to the C function ++%typemap(in,numinputs=0) char *outdata (char *temp) { ++ $1 = &temp; ++} ++// A typemap defining how to return an argument by appending it to the result ++%typemap(argout) char *outdata { ++ Tcl_Obj *o = Tcl_NewStringObj($1); ++ Tcl_ListObjAppendElement(interp,$result,o); ++} ++#endif ++ ++ ++%{ + /* some language headers (e.g. php.h, ruby.h) leave these defined */ + #undef PACKAGE_BUGREPORT + #undef PACKAGE_STRING +@@ -371,18 +385,4 @@ + extern bool write(Agraph_t *g, char *filename); + extern bool write(Agraph_t *g, FILE *f); + +- +-#ifdef SWIGTCL +-// A typemap telling SWIG to ignore an argument for input +-// However, we still need to pass a pointer to the C function +-%typemap(in,numinputs=0) char *outdata (char *temp) { +- $1 = &temp; +-} +-// A typemap defining how to return an argument by appending it to the result +-%typemap(argout) char *outdata { +- Tcl_Obj *o = Tcl_NewStringObj($1); +- Tcl_ListObjAppendElement(interp,$result,o); +-} +-#endif +- + %} diff --git a/graphviz.spec b/graphviz.spec index 406a272..966285d 100644 --- a/graphviz.spec +++ b/graphviz.spec @@ -8,7 +8,7 @@ Name: graphviz Summary: Graph Visualization Tools Version: 2.20.3 -%define truerelease 1 +%define truerelease 2 %{?distroagnostic: %define release %{truerelease}} %{!?distroagnostic: %define release %{truerelease}%{?dist}} @@ -18,6 +18,9 @@ Group: Applications/Multimedia License: CPL URL: http://www.graphviz.org/ Source0: http://www.graphviz.org/pub/graphviz/ARCHIVE/%{name}-%{version}.tar.gz +Patch0: graphviz-2.20.3-configure-php.patch +Patch1: graphviz-2.20.3-gv.i.patch + # graphviz is relocatable - Caution: this feature is used in AT&T, # but probably will not be supported in Redhat/Fedora/Centos distros @@ -535,6 +538,8 @@ Provides some additional PDF and HTML documentation for graphviz. %prep %setup -q +%patch0 -p1 +%patch1 -p1 %build %if ! %{SHARP} @@ -620,6 +625,9 @@ rm -rf %{buildroot} #-- changelog -------------------------------------------------- %changelog +* Wed Feb 25 2009 John Ellson 2.20.3-2.2 +- fixes for swig changes + * Tue Feb 24 2009 Fedora Release Engineering - 2.20.3-1.3 - Rebuilt for https://fedoraproject.org/wiki/Fedora_11_Mass_Rebuild