On 21-Mar-2023 04:31, Bram Moolenaar wrote:
Patch 9.0.1418
Problem:    The included xdiff code is a bit outdated.
Solution:   Sync with the latest git xdiff code. (Yee Cheng Chin,
             closes #12181)
Files:      src/xdiff/README.txt, src/xdiff/xdiff.h, src/xdiff/xdiffi.c,
             src/xdiff/xdiffi.h, src/xdiff/xemit.c, src/xdiff/xhistogram.c,
             src/xdiff/xmacros.h, src/xdiff/xpatience.c, src/xdiff/xprepare.c,
             src/xdiff/xutils.c, src/xdiff/xutils.h



After this patch, my HPUX build fails with this error:
<snip>
    cc -c -I. -Iproto -DHAVE_CONFIG_H     -O2       -D_REENTRANT -o objects/xdiffi.o xdiff/xdiffi.c
cc: "xdiff/xdiffi.c", line 340: error 1588: "SIZE_MAX" undefined.
cc: "xdiff/xdiffi.c", line 340: error 1552: First expression of ?: must be arithmetic.
*** Error exit code 1

Stop.
*** Error exit code 1
</snip>

The attached patch fixes it.

Cheers
John

--
--
You received this message from the "vim_dev" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

--- You received this message because you are subscribed to the Google Groups "vim_dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/vim_dev/a5832fbb-6393-c4c5-33d0-7e45904a5aee%40internode.on.net.
--- xmacros.h.orig      2023-03-21 05:55:55.215756200 +1100
+++ xmacros.h   2023-03-22 05:46:58.549399200 +1100
@@ -23,8 +23,11 @@
 #if !defined(XMACROS_H)
 #define XMACROS_H
 
-
-
+#ifdef __hpux
+#ifndef SIZE_MAX
+#define SIZE_MAX ((size_t)(-1))
+#endif
+#endif
 
 #define XDL_MIN(a, b) ((a) < (b) ? (a): (b))
 #define XDL_MAX(a, b) ((a) > (b) ? (a): (b))

Raspunde prin e-mail lui