aboutsummaryrefslogtreecommitdiffstats
path: root/textproc
diff options
context:
space:
mode:
authorantoine <antoine@FreeBSD.org>2018-02-24 19:28:14 +0800
committerantoine <antoine@FreeBSD.org>2018-02-24 19:28:14 +0800
commitc3ccd2719fcfe691b9e6655fdeaf42d6d6b1366d (patch)
tree6b4cc5bb2f3fab69eb2f268ef58349f742566335 /textproc
parente9f65e963e1082e186fa5502045278dfe6e35c74 (diff)
downloadfreebsd-ports-gnome-c3ccd2719fcfe691b9e6655fdeaf42d6d6b1366d.tar.gz
freebsd-ports-gnome-c3ccd2719fcfe691b9e6655fdeaf42d6d6b1366d.tar.zst
freebsd-ports-gnome-c3ccd2719fcfe691b9e6655fdeaf42d6d6b1366d.zip
Fix build with clang 6
Reported by: pkg-fallout
Diffstat (limited to 'textproc')
-rw-r--r--textproc/py-pyctpp2/files/patch-pyctpp2___pyctpp2__py2.cpp27
-rw-r--r--textproc/py-pyctpp2/files/patch-pyctpp2___pyctpp2__py3.cpp27
-rw-r--r--textproc/py-pyctpp2/files/patch-pyctpp2_cengine.cc34
3 files changed, 88 insertions, 0 deletions
diff --git a/textproc/py-pyctpp2/files/patch-pyctpp2___pyctpp2__py2.cpp b/textproc/py-pyctpp2/files/patch-pyctpp2___pyctpp2__py2.cpp
new file mode 100644
index 000000000000..57ec5314dd3a
--- /dev/null
+++ b/textproc/py-pyctpp2/files/patch-pyctpp2___pyctpp2__py2.cpp
@@ -0,0 +1,27 @@
+--- pyctpp2/_pyctpp2_py2.cpp.orig 2012-01-19 08:46:23 UTC
++++ pyctpp2/_pyctpp2_py2.cpp
+@@ -4471,7 +4471,7 @@ static void __Pyx_RaiseArgtupleInvalid(
+ more_or_less = "exactly";
+ }
+ PyErr_Format(PyExc_TypeError,
+- "%s() takes %s %"PY_FORMAT_SIZE_T"d positional argument%s (%"PY_FORMAT_SIZE_T"d given)",
++ "%s() takes %s %" PY_FORMAT_SIZE_T "d positional argument%s (%" PY_FORMAT_SIZE_T "d given)",
+ func_name, more_or_less, num_expected,
+ (num_expected == 1) ? "" : "s", num_found);
+ }
+@@ -4682,13 +4682,13 @@ bad:
+
+ static CYTHON_INLINE void __Pyx_RaiseNeedMoreValuesError(Py_ssize_t index) {
+ PyErr_Format(PyExc_ValueError,
+- "need more than %"PY_FORMAT_SIZE_T"d value%s to unpack",
++ "need more than %" PY_FORMAT_SIZE_T "d value%s to unpack",
+ index, (index == 1) ? "" : "s");
+ }
+
+ static CYTHON_INLINE void __Pyx_RaiseTooManyValuesError(Py_ssize_t expected) {
+ PyErr_Format(PyExc_ValueError,
+- "too many values to unpack (expected %"PY_FORMAT_SIZE_T"d)", expected);
++ "too many values to unpack (expected %" PY_FORMAT_SIZE_T "d)", expected);
+ }
+
+ static int __Pyx_IternextUnpackEndCheck(PyObject *retval, Py_ssize_t expected) {
diff --git a/textproc/py-pyctpp2/files/patch-pyctpp2___pyctpp2__py3.cpp b/textproc/py-pyctpp2/files/patch-pyctpp2___pyctpp2__py3.cpp
new file mode 100644
index 000000000000..1d01ed8725b0
--- /dev/null
+++ b/textproc/py-pyctpp2/files/patch-pyctpp2___pyctpp2__py3.cpp
@@ -0,0 +1,27 @@
+--- pyctpp2/_pyctpp2_py3.cpp.orig 2012-01-19 08:46:23 UTC
++++ pyctpp2/_pyctpp2_py3.cpp
+@@ -4551,7 +4551,7 @@ static void __Pyx_RaiseArgtupleInvalid(
+ more_or_less = "exactly";
+ }
+ PyErr_Format(PyExc_TypeError,
+- "%s() takes %s %"PY_FORMAT_SIZE_T"d positional argument%s (%"PY_FORMAT_SIZE_T"d given)",
++ "%s() takes %s %" PY_FORMAT_SIZE_T "d positional argument%s (%" PY_FORMAT_SIZE_T "d given)",
+ func_name, more_or_less, num_expected,
+ (num_expected == 1) ? "" : "s", num_found);
+ }
+@@ -4762,13 +4762,13 @@ bad:
+
+ static CYTHON_INLINE void __Pyx_RaiseNeedMoreValuesError(Py_ssize_t index) {
+ PyErr_Format(PyExc_ValueError,
+- "need more than %"PY_FORMAT_SIZE_T"d value%s to unpack",
++ "need more than %" PY_FORMAT_SIZE_T "d value%s to unpack",
+ index, (index == 1) ? "" : "s");
+ }
+
+ static CYTHON_INLINE void __Pyx_RaiseTooManyValuesError(Py_ssize_t expected) {
+ PyErr_Format(PyExc_ValueError,
+- "too many values to unpack (expected %"PY_FORMAT_SIZE_T"d)", expected);
++ "too many values to unpack (expected %" PY_FORMAT_SIZE_T "d)", expected);
+ }
+
+ static int __Pyx_IternextUnpackEndCheck(PyObject *retval, Py_ssize_t expected) {
diff --git a/textproc/py-pyctpp2/files/patch-pyctpp2_cengine.cc b/textproc/py-pyctpp2/files/patch-pyctpp2_cengine.cc
new file mode 100644
index 000000000000..ea4aefd20667
--- /dev/null
+++ b/textproc/py-pyctpp2/files/patch-pyctpp2_cengine.cc
@@ -0,0 +1,34 @@
+--- pyctpp2/cengine.cc.orig 2012-01-19 08:46:23 UTC
++++ pyctpp2/cengine.cc
+@@ -151,13 +151,13 @@ bool CEngine::Parse(const char *filename, CTemplate **
+ string line;
+ string pos;
+
+- int res = snprintf(buf, len, "%"PRIu32, static_cast<uint32_t>(e.GetLine()));
++ int res = snprintf(buf, len, "%" PRIu32, static_cast<uint32_t>(e.GetLine()));
+ if (!(res < 0 || static_cast<size_t>(res) == len)) {
+ line = string(buf);
+ }
+
+ memset(buf, 0, len);
+- res = snprintf(buf, len, "%"PRIu32, static_cast<uint32_t>(e.GetLinePos()));
++ res = snprintf(buf, len, "%" PRIu32, static_cast<uint32_t>(e.GetLinePos()));
+ if (!(res < 0 || static_cast<size_t>(res) == len)) {
+ pos = string(buf);
+ }
+@@ -198,13 +198,13 @@ bool CEngine::ParseText(const char *text, CTemplate **
+ string line;
+ string pos;
+
+- int res = snprintf(buf, len, "%"PRIu32, static_cast<uint32_t>(e.GetLine()));
++ int res = snprintf(buf, len, "%" PRIu32, static_cast<uint32_t>(e.GetLine()));
+ if (!(res < 0 || static_cast<size_t>(res) == len)) {
+ line = string(buf);
+ }
+
+ memset(buf, 0, len);
+- res = snprintf(buf, len, "%"PRIu32, static_cast<uint32_t>(e.GetLinePos()));
++ res = snprintf(buf, len, "%" PRIu32, static_cast<uint32_t>(e.GetLinePos()));
+ if (!(res < 0 || static_cast<size_t>(res) == len)) {
+ pos = string(buf);
+ }