Fri Aug 9 13:09:32 2019 UTC ()
Pullup ticket #6013 - requested by bacon
devel/subversion: build fix

Revisions pulled up:
- devel/subversion/distinfo                                     1.113
- devel/subversion/patches/patch-configure                      1.5
- devel/subversion/patches/patch-subversion_bindings_swig_python_libsvn_swig_py_swigutil_py.c 1.1

---
   Module Name:    pkgsrc
   Committed By:   markd
   Date:           Wed Jul  3 10:42:54 UTC 2019

   Modified Files:
           pkgsrc/devel/subversion: distinfo
           pkgsrc/devel/subversion/patches: patch-configure
   Added Files:
           pkgsrc/devel/subversion/patches:
               patch-subversion_bindings_swig_python_libsvn_swig_py_swigutil_py.c

   Log Message:
   subversion: more reliable fix for APR 1.7.0

   From: Stefan Sperling <stsp%apache.org@localhost>
   Date: Fri, 12 Apr 2019 09:27:33 +0000
   Subject: [PATCH] Get rid of apr_int64_t format string check in swig py
    configure.

   This check relied on APR implementation details and broke with APR 1.7.0.
   Rather than trying to guess a perfect format string to use, just use the
   largest possible format and cast the argument accordingly.

   Should fix build against APR 1.7.0 and later.

   Suggested by: brane

   * build/ac-macros/swig.m4: Remove code related to SVN_APR_INT64_T_PYCFMT.

   * subversion/bindings/swig/python/libsvn_swig_py/swigutil_py.c
     (svn_swig_py_client_blame_receiver_func): Stop relying on the
      SVN_APR_INT64_T_PYCFMT constant from configure. Use "L" and
      acast to PY_LONG_LONG instead.


(bsiegert)
diff -r1.112 -r1.112.2.1 pkgsrc/devel/subversion/distinfo
diff -r1.4 -r1.4.2.1 pkgsrc/devel/subversion/patches/patch-configure
diff -r0 -r1.1.2.2 pkgsrc/devel/subversion/patches/patch-subversion_bindings_swig_python_libsvn_swig_py_swigutil_py.c

cvs diff -r1.112 -r1.112.2.1 pkgsrc/devel/subversion/distinfo (expand / switch to unified diff)

--- pkgsrc/devel/subversion/distinfo 2019/05/27 16:10:08 1.112
+++ pkgsrc/devel/subversion/distinfo 2019/08/09 13:09:32 1.112.2.1
@@ -1,10 +1,11 @@ @@ -1,10 +1,11 @@
1$NetBSD: distinfo,v 1.112 2019/05/27 16:10:08 ryoon Exp $ 1$NetBSD: distinfo,v 1.112.2.1 2019/08/09 13:09:32 bsiegert Exp $
2 2
3SHA1 (subversion-1.12.0.tar.bz2) = 2dfecac56f18951182dbee4a4f14d27f27ebcdb7 3SHA1 (subversion-1.12.0.tar.bz2) = 2dfecac56f18951182dbee4a4f14d27f27ebcdb7
4RMD160 (subversion-1.12.0.tar.bz2) = cd06e97d3e109796c3370cb7633081805ee4d957 4RMD160 (subversion-1.12.0.tar.bz2) = cd06e97d3e109796c3370cb7633081805ee4d957
5SHA512 (subversion-1.12.0.tar.bz2) = 87a00b23bdac63124fa00642e2ac7e6f7818b092bc6422cabdeb2ca8fbc8c481fb8c1e4fbd86aac94e8e1fc099fa163aa0609aca23265ceb96ef4ebe78a64c13 5SHA512 (subversion-1.12.0.tar.bz2) = 87a00b23bdac63124fa00642e2ac7e6f7818b092bc6422cabdeb2ca8fbc8c481fb8c1e4fbd86aac94e8e1fc099fa163aa0609aca23265ceb96ef4ebe78a64c13
6Size (subversion-1.12.0.tar.bz2) = 8504473 bytes 6Size (subversion-1.12.0.tar.bz2) = 8504473 bytes
7SHA1 (patch-Makefile.in) = 2df6c733d563c0bc7e0d1b4b6e6e00f82ea8c176 7SHA1 (patch-Makefile.in) = 2df6c733d563c0bc7e0d1b4b6e6e00f82ea8c176
8SHA1 (patch-configure) = d0454b65964c6d37753e0b674c2e30205df193a1 8SHA1 (patch-configure) = 3a0650395111c400c9bf0418cd31510e7179f454
9SHA1 (patch-subversion_bindings_swig_perl_native_Makefile.PL.in) = 3fadde312693f2a304cd7e348c66cbd373c57854 9SHA1 (patch-subversion_bindings_swig_perl_native_Makefile.PL.in) = 3fadde312693f2a304cd7e348c66cbd373c57854
 10SHA1 (patch-subversion_bindings_swig_python_libsvn_swig_py_swigutil_py.c) = ed75c4d2fbc911a97bc47e78eaebc5b61078332b
10SHA1 (patch-tools_dev_benchmarks_large__dirs_create__bigdir.sh) = ff19087ff4d348fdcf904eb52406f6b717fe444a 11SHA1 (patch-tools_dev_benchmarks_large__dirs_create__bigdir.sh) = ff19087ff4d348fdcf904eb52406f6b717fe444a

cvs diff -r1.4 -r1.4.2.1 pkgsrc/devel/subversion/patches/patch-configure (expand / switch to unified diff)

--- pkgsrc/devel/subversion/patches/patch-configure 2019/05/27 16:10:08 1.4
+++ pkgsrc/devel/subversion/patches/patch-configure 2019/08/09 13:09:32 1.4.2.1
@@ -1,78 +1,278 @@ @@ -1,78 +1,278 @@
1$NetBSD: patch-configure,v 1.4 2019/05/27 16:10:08 ryoon Exp $ 1$NetBSD: patch-configure,v 1.4.2.1 2019/08/09 13:09:32 bsiegert Exp $
2 2
3* Fix build with devel/apr-1.7.0 3* Fix build with devel/apr-1.7.0
4 4
5--- configure.orig 2019-04-11 13:21:28.000000000 +0000 5--- configure.orig 2019-04-11 13:21:28.000000000 +0000
6+++ configure 6+++ configure
7@@ -24344,7 +24344,7 @@ else 7@@ -24329,67 +24329,6 @@ $as_echo "$ac_cv_python_libs" >&6; }
8 MaTcHtHiS APR_INT64_T_FMT EnDeNd 8 fi
9 _ACEOF 9 `"
10 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | 10
 11- SVN_PYCFMT_SAVE_CPPFLAGS="$CPPFLAGS"
 12- CPPFLAGS="$CPPFLAGS $SVN_APR_INCLUDES"
 13- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for apr_int64_t Python/C API format string" >&5
 14-$as_echo_n "checking for apr_int64_t Python/C API format string... " >&6; }
 15-if ${svn_cv_pycfmt_apr_int64_t+:} false; then :
 16- $as_echo_n "(cached) " >&6
 17-else
 18-
 19- if test "x$svn_cv_pycfmt_apr_int64_t" = "x"; then
 20- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
 21-/* end confdefs.h. */
 22-#include <apr.h>
 23- MaTcHtHiS APR_INT64_T_FMT EnDeNd
 24-_ACEOF
 25-if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
11- $EGREP "MaTcHtHiS +\"lld\" +EnDeNd" >/dev/null 2>&1; then : 26- $EGREP "MaTcHtHiS +\"lld\" +EnDeNd" >/dev/null 2>&1; then :
12+ $EGREP "MaTcHtHiS +\"ll(\" *\")?d\" +EnDeNd" >/dev/null 2>&1; then : 27- svn_cv_pycfmt_apr_int64_t="L"
13 svn_cv_pycfmt_apr_int64_t="L" 28-fi
14 fi 29-rm -f conftest*
15 rm -f conftest* 30-
16@@ -24358,7 +24358,7 @@ r 31- fi
17 MaTcHtHiS APR_INT64_T_FMT EnDeNd 32- if test "x$svn_cv_pycfmt_apr_int64_t" = "x"; then
18 _ACEOF 33- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | 34-/* end confdefs.h. */
 35-r
 36- #include <apr.h>
 37- MaTcHtHiS APR_INT64_T_FMT EnDeNd
 38-_ACEOF
 39-if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
20- $EGREP "MaTcHtHiS +\"ld\" +EnDeNd" >/dev/null 2>&1; then : 40- $EGREP "MaTcHtHiS +\"ld\" +EnDeNd" >/dev/null 2>&1; then :
21+ $EGREP "MaTcHtHiS +\"l(\" *\")?d\" +EnDeNd" >/dev/null 2>&1; then : 41- svn_cv_pycfmt_apr_int64_t="l"
22 svn_cv_pycfmt_apr_int64_t="l" 42-fi
23 fi 43-rm -f conftest*
24 rm -f conftest* 44-
25@@ -24859,7 +24859,7 @@ else 45- fi
26 MaTcHtHiS APR_INT64_T_FMT EnDeNd 46- if test "x$svn_cv_pycfmt_apr_int64_t" = "x"; then
27 _ACEOF 47- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
28 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | 48-/* end confdefs.h. */
 49-#include <apr.h>
 50- MaTcHtHiS APR_INT64_T_FMT EnDeNd
 51-_ACEOF
 52-if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
 53- $EGREP "MaTcHtHiS +\"d\" +EnDeNd" >/dev/null 2>&1; then :
 54- svn_cv_pycfmt_apr_int64_t="i"
 55-fi
 56-rm -f conftest*
 57-
 58- fi
 59-
 60-fi
 61-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $svn_cv_pycfmt_apr_int64_t" >&5
 62-$as_echo "$svn_cv_pycfmt_apr_int64_t" >&6; }
 63- CPPFLAGS="$SVN_PYCFMT_SAVE_CPPFLAGS"
 64- if test "x$svn_cv_pycfmt_apr_int64_t" = "x"; then
 65- as_fn_error $? "failed to recognize APR_INT64_T_FMT on this platform" "$LINENO" 5
 66- fi
 67-
 68-cat >>confdefs.h <<_ACEOF
 69-#define SVN_APR_INT64_T_PYCFMT "$svn_cv_pycfmt_apr_int64_t"
 70-_ACEOF
 71-
 72 fi
 73
 74 if test "$PERL" != "none"; then
 75@@ -24844,67 +24783,6 @@ $as_echo "$ac_cv_python_libs" >&6; }
 76 fi
 77 `"
 78
 79- SVN_PYCFMT_SAVE_CPPFLAGS="$CPPFLAGS"
 80- CPPFLAGS="$CPPFLAGS $SVN_APR_INCLUDES"
 81- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for apr_int64_t Python/C API format string" >&5
 82-$as_echo_n "checking for apr_int64_t Python/C API format string... " >&6; }
 83-if ${svn_cv_pycfmt_apr_int64_t+:} false; then :
 84- $as_echo_n "(cached) " >&6
 85-else
 86-
 87- if test "x$svn_cv_pycfmt_apr_int64_t" = "x"; then
 88- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
 89-/* end confdefs.h. */
 90-#include <apr.h>
 91- MaTcHtHiS APR_INT64_T_FMT EnDeNd
 92-_ACEOF
 93-if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
29- $EGREP "MaTcHtHiS +\"lld\" +EnDeNd" >/dev/null 2>&1; then : 94- $EGREP "MaTcHtHiS +\"lld\" +EnDeNd" >/dev/null 2>&1; then :
30+ $EGREP "MaTcHtHiS +\"ll(\" *\")?d\" +EnDeNd" >/dev/null 2>&1; then : 95- svn_cv_pycfmt_apr_int64_t="L"
31 svn_cv_pycfmt_apr_int64_t="L" 96-fi
32 fi 97-rm -f conftest*
33 rm -f conftest* 98-
34@@ -24873,7 +24873,7 @@ r 99- fi
35 MaTcHtHiS APR_INT64_T_FMT EnDeNd 100- if test "x$svn_cv_pycfmt_apr_int64_t" = "x"; then
36 _ACEOF 101- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
37 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | 102-/* end confdefs.h. */
 103-r
 104- #include <apr.h>
 105- MaTcHtHiS APR_INT64_T_FMT EnDeNd
 106-_ACEOF
 107-if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
38- $EGREP "MaTcHtHiS +\"ld\" +EnDeNd" >/dev/null 2>&1; then : 108- $EGREP "MaTcHtHiS +\"ld\" +EnDeNd" >/dev/null 2>&1; then :
39+ $EGREP "MaTcHtHiS +\"l(\" *\")?d\" +EnDeNd" >/dev/null 2>&1; then : 109- svn_cv_pycfmt_apr_int64_t="l"
40 svn_cv_pycfmt_apr_int64_t="l" 110-fi
41 fi 111-rm -f conftest*
42 rm -f conftest* 112-
43@@ -25374,7 +25374,7 @@ else 113- fi
44 MaTcHtHiS APR_INT64_T_FMT EnDeNd 114- if test "x$svn_cv_pycfmt_apr_int64_t" = "x"; then
45 _ACEOF 115- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
46 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | 116-/* end confdefs.h. */
 117-#include <apr.h>
 118- MaTcHtHiS APR_INT64_T_FMT EnDeNd
 119-_ACEOF
 120-if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
 121- $EGREP "MaTcHtHiS +\"d\" +EnDeNd" >/dev/null 2>&1; then :
 122- svn_cv_pycfmt_apr_int64_t="i"
 123-fi
 124-rm -f conftest*
 125-
 126- fi
 127-
 128-fi
 129-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $svn_cv_pycfmt_apr_int64_t" >&5
 130-$as_echo "$svn_cv_pycfmt_apr_int64_t" >&6; }
 131- CPPFLAGS="$SVN_PYCFMT_SAVE_CPPFLAGS"
 132- if test "x$svn_cv_pycfmt_apr_int64_t" = "x"; then
 133- as_fn_error $? "failed to recognize APR_INT64_T_FMT on this platform" "$LINENO" 5
 134- fi
 135-
 136-cat >>confdefs.h <<_ACEOF
 137-#define SVN_APR_INT64_T_PYCFMT "$svn_cv_pycfmt_apr_int64_t"
 138-_ACEOF
 139-
 140 fi
 141
 142 if test "$PERL" != "none"; then
 143@@ -25359,67 +25237,6 @@ $as_echo "$ac_cv_python_libs" >&6; }
 144 fi
 145 `"
 146
 147- SVN_PYCFMT_SAVE_CPPFLAGS="$CPPFLAGS"
 148- CPPFLAGS="$CPPFLAGS $SVN_APR_INCLUDES"
 149- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for apr_int64_t Python/C API format string" >&5
 150-$as_echo_n "checking for apr_int64_t Python/C API format string... " >&6; }
 151-if ${svn_cv_pycfmt_apr_int64_t+:} false; then :
 152- $as_echo_n "(cached) " >&6
 153-else
 154-
 155- if test "x$svn_cv_pycfmt_apr_int64_t" = "x"; then
 156- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
 157-/* end confdefs.h. */
 158-#include <apr.h>
 159- MaTcHtHiS APR_INT64_T_FMT EnDeNd
 160-_ACEOF
 161-if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
47- $EGREP "MaTcHtHiS +\"lld\" +EnDeNd" >/dev/null 2>&1; then : 162- $EGREP "MaTcHtHiS +\"lld\" +EnDeNd" >/dev/null 2>&1; then :
48+ $EGREP "MaTcHtHiS +\"ll(\" *\")?d\" +EnDeNd" >/dev/null 2>&1; then : 163- svn_cv_pycfmt_apr_int64_t="L"
49 svn_cv_pycfmt_apr_int64_t="L" 164-fi
50 fi 165-rm -f conftest*
51 rm -f conftest* 166-
52@@ -25388,7 +25388,7 @@ r 167- fi
53 MaTcHtHiS APR_INT64_T_FMT EnDeNd 168- if test "x$svn_cv_pycfmt_apr_int64_t" = "x"; then
54 _ACEOF 169- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
55 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | 170-/* end confdefs.h. */
 171-r
 172- #include <apr.h>
 173- MaTcHtHiS APR_INT64_T_FMT EnDeNd
 174-_ACEOF
 175-if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
56- $EGREP "MaTcHtHiS +\"ld\" +EnDeNd" >/dev/null 2>&1; then : 176- $EGREP "MaTcHtHiS +\"ld\" +EnDeNd" >/dev/null 2>&1; then :
57+ $EGREP "MaTcHtHiS +\"l(\" *\")?d\" +EnDeNd" >/dev/null 2>&1; then : 177- svn_cv_pycfmt_apr_int64_t="l"
58 svn_cv_pycfmt_apr_int64_t="l" 178-fi
59 fi 179-rm -f conftest*
60 rm -f conftest* 180-
61@@ -25892,7 +25892,7 @@ else 181- fi
62 MaTcHtHiS APR_INT64_T_FMT EnDeNd 182- if test "x$svn_cv_pycfmt_apr_int64_t" = "x"; then
63 _ACEOF 183- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
64 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | 184-/* end confdefs.h. */
 185-#include <apr.h>
 186- MaTcHtHiS APR_INT64_T_FMT EnDeNd
 187-_ACEOF
 188-if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
 189- $EGREP "MaTcHtHiS +\"d\" +EnDeNd" >/dev/null 2>&1; then :
 190- svn_cv_pycfmt_apr_int64_t="i"
 191-fi
 192-rm -f conftest*
 193-
 194- fi
 195-
 196-fi
 197-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $svn_cv_pycfmt_apr_int64_t" >&5
 198-$as_echo "$svn_cv_pycfmt_apr_int64_t" >&6; }
 199- CPPFLAGS="$SVN_PYCFMT_SAVE_CPPFLAGS"
 200- if test "x$svn_cv_pycfmt_apr_int64_t" = "x"; then
 201- as_fn_error $? "failed to recognize APR_INT64_T_FMT on this platform" "$LINENO" 5
 202- fi
 203-
 204-cat >>confdefs.h <<_ACEOF
 205-#define SVN_APR_INT64_T_PYCFMT "$svn_cv_pycfmt_apr_int64_t"
 206-_ACEOF
 207-
 208 fi
 209
 210 if test "$PERL" != "none"; then
 211@@ -25877,67 +25694,6 @@ $as_echo "$ac_cv_python_libs" >&6; }
 212 fi
 213 `"
 214
 215- SVN_PYCFMT_SAVE_CPPFLAGS="$CPPFLAGS"
 216- CPPFLAGS="$CPPFLAGS $SVN_APR_INCLUDES"
 217- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for apr_int64_t Python/C API format string" >&5
 218-$as_echo_n "checking for apr_int64_t Python/C API format string... " >&6; }
 219-if ${svn_cv_pycfmt_apr_int64_t+:} false; then :
 220- $as_echo_n "(cached) " >&6
 221-else
 222-
 223- if test "x$svn_cv_pycfmt_apr_int64_t" = "x"; then
 224- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
 225-/* end confdefs.h. */
 226-#include <apr.h>
 227- MaTcHtHiS APR_INT64_T_FMT EnDeNd
 228-_ACEOF
 229-if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
65- $EGREP "MaTcHtHiS +\"lld\" +EnDeNd" >/dev/null 2>&1; then : 230- $EGREP "MaTcHtHiS +\"lld\" +EnDeNd" >/dev/null 2>&1; then :
66+ $EGREP "MaTcHtHiS +\"ll(\" *\")?d\" +EnDeNd" >/dev/null 2>&1; then : 231- svn_cv_pycfmt_apr_int64_t="L"
67 svn_cv_pycfmt_apr_int64_t="L" 232-fi
68 fi 233-rm -f conftest*
69 rm -f conftest* 234-
70@@ -25906,7 +25906,7 @@ r 235- fi
71 MaTcHtHiS APR_INT64_T_FMT EnDeNd 236- if test "x$svn_cv_pycfmt_apr_int64_t" = "x"; then
72 _ACEOF 237- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
73 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | 238-/* end confdefs.h. */
 239-r
 240- #include <apr.h>
 241- MaTcHtHiS APR_INT64_T_FMT EnDeNd
 242-_ACEOF
 243-if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
74- $EGREP "MaTcHtHiS +\"ld\" +EnDeNd" >/dev/null 2>&1; then : 244- $EGREP "MaTcHtHiS +\"ld\" +EnDeNd" >/dev/null 2>&1; then :
75+ $EGREP "MaTcHtHiS +\"l(\" *\")?d\" +EnDeNd" >/dev/null 2>&1; then : 245- svn_cv_pycfmt_apr_int64_t="l"
76 svn_cv_pycfmt_apr_int64_t="l" 246-fi
77 fi 247-rm -f conftest*
78 rm -f conftest* 248-
 249- fi
 250- if test "x$svn_cv_pycfmt_apr_int64_t" = "x"; then
 251- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
 252-/* end confdefs.h. */
 253-#include <apr.h>
 254- MaTcHtHiS APR_INT64_T_FMT EnDeNd
 255-_ACEOF
 256-if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
 257- $EGREP "MaTcHtHiS +\"d\" +EnDeNd" >/dev/null 2>&1; then :
 258- svn_cv_pycfmt_apr_int64_t="i"
 259-fi
 260-rm -f conftest*
 261-
 262- fi
 263-
 264-fi
 265-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $svn_cv_pycfmt_apr_int64_t" >&5
 266-$as_echo "$svn_cv_pycfmt_apr_int64_t" >&6; }
 267- CPPFLAGS="$SVN_PYCFMT_SAVE_CPPFLAGS"
 268- if test "x$svn_cv_pycfmt_apr_int64_t" = "x"; then
 269- as_fn_error $? "failed to recognize APR_INT64_T_FMT on this platform" "$LINENO" 5
 270- fi
 271-
 272-cat >>confdefs.h <<_ACEOF
 273-#define SVN_APR_INT64_T_PYCFMT "$svn_cv_pycfmt_apr_int64_t"
 274-_ACEOF
 275-
 276 fi
 277
 278 if test "$PERL" != "none"; then

File Added: pkgsrc/devel/subversion/patches/Attic/patch-subversion_bindings_swig_python_libsvn_swig_py_swigutil_py.c
$NetBSD: patch-subversion_bindings_swig_python_libsvn_swig_py_swigutil_py.c,v 1.1.2.2 2019/08/09 13:09:32 bsiegert Exp $

From: Stefan Sperling <stsp@apache.org>
Date: Fri, 12 Apr 2019 09:27:33 +0000
Subject: [PATCH] Get rid of apr_int64_t format string check in swig py
 configure.

This check relied on APR implementation details and broke with APR 1.7.0.
Rather than trying to guess a perfect format string to use, just use the
largest possible format and cast the argument accordingly.

Should fix build against APR 1.7.0 and later.

Suggested by: brane

* build/ac-macros/swig.m4: Remove code related to SVN_APR_INT64_T_PYCFMT.

* subversion/bindings/swig/python/libsvn_swig_py/swigutil_py.c
  (svn_swig_py_client_blame_receiver_func): Stop relying on the
   SVN_APR_INT64_T_PYCFMT constant from configure. Use "L" and
   acast to PY_LONG_LONG instead.

--- subversion/bindings/swig/python/libsvn_swig_py/swigutil_py.c.orig	2018-12-12 13:57:17.000000000 +0000
+++ subversion/bindings/swig/python/libsvn_swig_py/swigutil_py.c
@@ -46,7 +46,7 @@
 #include "svn_mergeinfo.h"
 #include "svn_types.h"
 
-#include "svn_private_config.h" /* for SVN_APR_INT64_T_PYCFMT */
+#include "svn_private_config.h"
 
 #include "swig_python_external_runtime.swg"
 #include "swigutil_py.h"
@@ -3394,10 +3394,9 @@ svn_error_t *svn_swig_py_client_blame_re
   svn_swig_py_acquire_py_lock();
 
   if ((result = PyObject_CallFunction(receiver,
-                                      (char *)
-                                      (SVN_APR_INT64_T_PYCFMT "lsssO&"),
-                                      line_no, revision, author, date, line,
-                                      make_ob_pool, pool)) == NULL)
+                                      (char *)"LlsssO&",
+                                      (PY_LONG_LONG)line_no, revision, author,
+                                      date, line, make_ob_pool, pool)) == NULL)
     {
       err = callback_exception_error();
     }