Hi, For precision, I'm resending this patch because I've got problems with [email protected] verifi <[email protected]>cation
Here is an update for devel/nasm to 3.02 Changelog: https://www.nasm.us/docs/3.02/nasmac.html patches/patch-include_compiler_h patch no longer necessary Tested on amd64 Index: Makefile =================================================================== RCS file: /cvs/ports/devel/nasm/Makefile,v diff -u -p -u -p -r1.55 Makefile --- Makefile 5 Mar 2026 12:11:43 -0000 1.55 +++ Makefile 30 Nov 2026 18:24:37 -0000 @@ -1,6 +1,6 @@ COMMENT= general-purpose multi-platform x86 assembler -VERSION= 3.01 +VERSION= 3.02 DISTNAME= nasm-${VERSION} CATEGORIES= devel lang SITES= ${HOMEPAGE}/pub/nasm/releasebuilds/${VERSION}/ Index: distinfo =================================================================== RCS file: /cvs/ports/devel/nasm/distinfo,v diff -u -p -u -p -r1.29 distinfo --- distinfo 5 Mar 2026 12:11:43 -0000 1.29 +++ distinfo 30 Nov 2026 18:24:37 -0000 @@ -1,2 +1,2 @@ -SHA256 (nasm-3.01.tar.xz) = tzJMvobnZ7ZfJvRn7YsSrYDhJOPMuJB2hVyY5Dqe3dQ= -SIZE (nasm-3.01.tar.xz) = 1499136 +SHA256 (nasm-3.02.tar.xz) = hzNuulO0rP6RdCSrXVANKwBU2fUUjTXCJzzPLPtxLw0= +SIZE (nasm-3.02.tar.xz) = 1531636 Index: patches/patch-include_compiler_h =================================================================== RCS file: patches/patch-include_compiler_h diff -N patches/patch-include_compiler_h --- patches/patch-include_compiler_h 5 Mar 2026 12:11:44 -0000 1.1 +++ /dev/null 1 Jan 1970 00:00:00 -0000 @@ -1,62 +0,0 @@ -- compiler.h: drop the stupid C++-style cast-to-bool hack - 44e89ba9b650b5e1533bca43682e167f51a3511f -- compiler.h: the test for "neither C++ nor C23" still wrong - 746e7c9efa37cec9a44d84a1e96b8c38f385cc1f - -Index: include/compiler.h ---- include/compiler.h.orig -+++ include/compiler.h -@@ -181,19 +181,10 @@ size_t strlcpy(char *, const char *, size_t); - char * pure_func strrchrnul(const char *, int); - #endif - --#if !defined(__cplusplus) || (__STDC_VERSION >= 202311L) - /* C++ and C23 have bool, false, and true as proper keywords */ -+#if !defined(__cplusplus) && (__STDC_VERSION__ < 202311L) - # ifdef HAVE_STDBOOL_H --/* If <stdbool.h> exists, include it explicitly to prevent it from -- begin included later, causing the "bool" macro to be defined. */ - # include <stdbool.h> --# ifdef bool --/* Force bool to be a typedef instead of a macro. What a "clever" hack -- this is... */ -- typedef bool /* The macro definition of bool */ --# undef bool -- bool; /* No longer the macro definition */ --# endif - # elif defined(HAVE___BOOL) - typedef _Bool bool; - # define false 0 -@@ -201,14 +192,10 @@ char * pure_func strrchrnul(const char *, int); - # else - /* This is a bit dangerous, because casting to this ersatz bool - will not produce the same result as the standard (bool) cast. -- Instead, use the bool() constructor-style macro defined below. */ -+ Instead, use the explicit construct !!x instead of relying on -+ implicit conversions or casts. */ - typedef enum bool { false, true } bool; - # endif --/* This amounts to a C++-style conversion cast to bool. This works -- because C ignores an argument-taking macro when used without an -- argument and because bool was redefined as a typedef if it previously -- was defined as a macro (see above.) */ --# define bool(x) ((bool)!!(x)) - #endif - - /* Create a NULL pointer of the same type as the address of -@@ -321,11 +308,11 @@ static inline void *mempset(void *dst, int c, size_t n - * less likely to be taken. - */ - #ifdef HAVE___BUILTIN_EXPECT --# define likely(x) __builtin_expect(bool(x), true) --# define unlikely(x) __builtin_expect(bool(x), false) -+# define likely(x) __builtin_expect(!!(x), true) -+# define unlikely(x) __builtin_expect(!!(x), false) - #else --# define likely(x) bool(x) --# define unlikely(x) bool(x) -+# define likely(x) (!!(x)) -+# define unlikely(x) (!!(x)) - #endif - - #ifdef HAVE___BUILTIN_PREFETCH
