aboutsummaryrefslogtreecommitdiffstats
path: root/textproc
diff options
context:
space:
mode:
authoradamw <adamw@FreeBSD.org>2014-08-27 00:50:55 +0800
committeradamw <adamw@FreeBSD.org>2014-08-27 00:50:55 +0800
commitbc158b52b394611b5bec62d8838c5a99f396043c (patch)
treef6008cf061a4dfd187063ddbcd5e6ddca76bf206 /textproc
parent26a5c3c4183828375dea66b6b6fc3cf4cdb9fff8 (diff)
downloadfreebsd-ports-gnome-bc158b52b394611b5bec62d8838c5a99f396043c.tar.gz
freebsd-ports-gnome-bc158b52b394611b5bec62d8838c5a99f396043c.tar.zst
freebsd-ports-gnome-bc158b52b394611b5bec62d8838c5a99f396043c.zip
Apply a patch from upstream to fix build against gcc 4.7. This fixes
ctemplate-based build failures in mysql-workbench.
Diffstat (limited to 'textproc')
-rw-r--r--textproc/google-ctemplate/Makefile2
-rw-r--r--textproc/google-ctemplate/files/patch-src__ctemplate__template_string.h.in11
-rw-r--r--textproc/google-ctemplate/files/patch-src__template_dictionary.cc11
3 files changed, 23 insertions, 1 deletions
diff --git a/textproc/google-ctemplate/Makefile b/textproc/google-ctemplate/Makefile
index 617a35efaba3..395765195d5a 100644
--- a/textproc/google-ctemplate/Makefile
+++ b/textproc/google-ctemplate/Makefile
@@ -3,7 +3,7 @@
PORTNAME= google-ctemplate
PORTVERSION= 2.2
-PORTREVISION= 2
+PORTREVISION= 3
CATEGORIES= textproc
MASTER_SITES= GOOGLE_CODE
PROJECTHOST= ctemplate
diff --git a/textproc/google-ctemplate/files/patch-src__ctemplate__template_string.h.in b/textproc/google-ctemplate/files/patch-src__ctemplate__template_string.h.in
new file mode 100644
index 000000000000..ac1f89a75d57
--- /dev/null
+++ b/textproc/google-ctemplate/files/patch-src__ctemplate__template_string.h.in
@@ -0,0 +1,11 @@
+--- ./src/ctemplate/template_string.h.in.orig 2014-08-26 12:35:28.229739993 -0400
++++ ./src/ctemplate/template_string.h.in 2014-08-26 12:35:50.132984993 -0400
+@@ -337,7 +337,7 @@
+
+ // Don't use this. This is used only in auto-generated .varnames.h files.
+ #define STS_INIT_WITH_HASH(name, str, hash) \
+- { { str, sizeof(""str"")-1, hash } }; \
++ { { str, sizeof("" str "")-1, hash } }; \
+ namespace ctemplate_sts_init { \
+ static const @ac_google_namespace@::StaticTemplateStringInitializer name##_init(&name); \
+ }
diff --git a/textproc/google-ctemplate/files/patch-src__template_dictionary.cc b/textproc/google-ctemplate/files/patch-src__template_dictionary.cc
new file mode 100644
index 000000000000..9f04884d07c6
--- /dev/null
+++ b/textproc/google-ctemplate/files/patch-src__template_dictionary.cc
@@ -0,0 +1,11 @@
+--- ./src/template_dictionary.cc.orig 2014-08-26 12:36:15.829733992 -0400
++++ ./src/template_dictionary.cc 2014-08-26 12:36:37.238772992 -0400
+@@ -861,7 +861,7 @@
+
+ string GetDictNum(size_t index, size_t size) const {
+ char buf[64]; // big enough for two ints
+- snprintf(buf, sizeof(buf), "%" PRIuS" of %" PRIuS, index, size);
++ snprintf(buf, sizeof(buf), "%" PRIuS " of %" PRIuS, index, size);
+ return buf;
+ }
+