pkgsrc-WIP-changes archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

swftools: fix build with clang.



Module Name:	pkgsrc-wip
Committed By:	Thomas Klausner <wiz%NetBSD.org@localhost>
Pushed By:	wiz
Date:		Thu Jul 6 13:38:15 2017 +0200
Changeset:	101cb6b0eb7cc696f5b312253362bb0118606437

Modified Files:
	swftools/distinfo
Added Files:
	swftools/patches/patch-lib_pdf_xpdf_GlobalParams.cc

Log Message:
swftools: fix build with clang.

To see a diff of this commit:
https://wip.pkgsrc.org/cgi-bin/gitweb.cgi?p=pkgsrc-wip.git;a=commitdiff;h=101cb6b0eb7cc696f5b312253362bb0118606437

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

diffstat:
 swftools/distinfo                                   |  1 +
 swftools/patches/patch-lib_pdf_xpdf_GlobalParams.cc | 18 ++++++++++++++++++
 2 files changed, 19 insertions(+)

diffs:
diff --git a/swftools/distinfo b/swftools/distinfo
index 4a26bbee2b..d80e7544b2 100644
--- a/swftools/distinfo
+++ b/swftools/distinfo
@@ -5,4 +5,5 @@ RMD160 (swftools-0.9.2.tar.gz) = 6743d847b3adcc2724799dc6a75c1359ff5a0377
 Size (swftools-0.9.2.tar.gz) = 2675939 bytes
 SHA1 (patch-lib_pdf_BitmapOutputDev.cc) = 66cbbebbadac3d6cfbd5061286151f3e88b3e3aa
 SHA1 (patch-lib_pdf_xpdf_GString.cc) = 30a5d65866c9d8f243ce181db7258a6cae6a644f
+SHA1 (patch-lib_pdf_xpdf_GlobalParams.cc) = cc061ed3f3f14ad587b1f70cc1dd3c357a404c55
 SHA1 (patch-src_gif2swf.c) = 6b4758793bba9f564e2a3e1057c2691e27c01cf0
diff --git a/swftools/patches/patch-lib_pdf_xpdf_GlobalParams.cc b/swftools/patches/patch-lib_pdf_xpdf_GlobalParams.cc
new file mode 100644
index 0000000000..d59629be5a
--- /dev/null
+++ b/swftools/patches/patch-lib_pdf_xpdf_GlobalParams.cc
@@ -0,0 +1,18 @@
+$NetBSD$
+
+Do not compare character pointers with integers.
+
+--- lib/pdf/xpdf/GlobalParams.cc.orig	2012-04-08 17:26:34.000000000 +0000
++++ lib/pdf/xpdf/GlobalParams.cc
+@@ -922,9 +922,9 @@ void GlobalParams::parseFile(GString *fi
+     char* p = pos1>pos2?pos1:pos2;
+     int pos = p ? p-cfgFileName : -1;
+     GString*path = new GString(new GString(cfgFileName), 0, (pos < 0 ? strlen(cfgFileName): pos));
+-    if(pos1>=0)
++    if(pos1 != NULL)
+ 	path->append('/');
+-    else if(pos2>=0)
++    else if(pos2 != NULL)
+ 	path->append('\\');
+     else
+ #ifdef WIN32


Home | Main Index | Thread Index | Old Index