Hi,
On Mon, Oct 09, 2017 at 10:17:43AM +0100, Edd Barrett wrote:
> On Sun, Oct 08, 2017 at 08:50:54PM +0200, Matthias Kilian wrote:
> > ps: I think edd@ mentioned that the next texlive release will be
> > C++-11-ready, so there's no point in upstreaming the fix.
>
> Yes hopefully.
>
> I have an updated TL 2017 base in openbsd-wip in case you wanted to
> check that all is well. I'm still working on the texmf, but you should
> be able to check the compile stage of base works OK.
>
> Hoping to get TL 2017 in shortly after 6.2.
Well, my remark about texlive 2017 was only about wether to send
the patch upstream or not. openbsd-wip won't help here.
So, until texlive 2017 happens, can i just commit the C++11 diff
below or not? Could someone *please* test it on sparc64?
If not, we have to stick with a very old print/poppler.
Index: Makefile
===================================================================
RCS file: /cvs/ports/print/texlive/base/Makefile,v
retrieving revision 1.92
diff -u -p -r1.92 Makefile
--- Makefile 24 Aug 2017 09:45:23 -0000 1.92
+++ Makefile 8 Oct 2017 18:41:58 -0000
@@ -6,7 +6,7 @@ COMMENT = base binaries for TeXLive typ
DISTNAME = texlive-${DIST_V}b-source
PKGNAME = texlive_base-${V}
WRKDIST = ${WRKDIR}/texlive-${DIST_V}-source
-REVISION = 2
+REVISION = 3
DISTFILES = ${DISTNAME}${EXTRACT_SUFX} \
texlive-${DIST_V}-extra${EXTRACT_SUFX}
@@ -47,7 +47,7 @@ LIB_DEPENDS = converters/libiconv \
MODULES = textproc/intltool perl
# c++-11 required for poppler
-COMPILER = gcc
+COMPILER = base-clang ports-gcc
# Never set SEPARATE_BUILD
CONFIGURE_STYLE = gnu
@@ -55,6 +55,8 @@ CONFIGURE_STYLE = gnu
CPPFLAGS = -I${X11BASE}/include \
-I${LOCALBASE}/include \
-I${LOCALBASE}/include/poppler
+
+CXXFLAGS += -std=c++11
LDFLAGS = -L${LOCALBASE}/lib \
-L${X11BASE}/lib
Index: patches/patch-texk_web2c_luatexdir_image_pdftoepdf_w
===================================================================
RCS file: patches/patch-texk_web2c_luatexdir_image_pdftoepdf_w
diff -N patches/patch-texk_web2c_luatexdir_image_pdftoepdf_w
--- /dev/null 1 Jan 1970 00:00:00 -0000
+++ patches/patch-texk_web2c_luatexdir_image_pdftoepdf_w 8 Oct 2017
18:41:58 -0000
@@ -0,0 +1,25 @@
+$OpenBSD$
+
+Let it build with -std=c++11.
+
+found by sthen@ at
+https://github.com/termux/termux-packages/blob/master/packages/texlive-bin/c%2B%2B11.patch
+
+
+Index: texk/web2c/luatexdir/image/pdftoepdf.w
+--- texk/web2c/luatexdir/image/pdftoepdf.w.orig
++++ texk/web2c/luatexdir/image/pdftoepdf.w
+@@ -71,7 +71,12 @@ static char *get_file_checksum(const char *a, file_err
+ ck = (char *) malloc(PDF_CHECKSUM_SIZE);
+ if (ck == NULL)
+ formatted_error("pdf inclusion","out of memory while processing
'%s'", a);
+- snprintf(ck, PDF_CHECKSUM_SIZE, "%" PRIu64 "_%" PRIu64, (uint64_t)
size,(uint64_t) mtime);
++ snprintf(ck, PDF_CHECKSUM_SIZE, "%"
++ PRIu64
++ "_%"
++ PRIu64,
++ (uint64_t) size,
++ (uint64_t) mtime);
+ } else {
+ switch (fe) {
+ case FE_FAIL: