logo

oasis

Own branch of Oasis Linux (upstream: <https://git.sr.ht/~mcf/oasis/>) git clone https://anongit.hacktivis.me/git/oasis.git
commit: 954bdd9cc75e346cee07c3d3d2d834c68f3c1e6d
parent cb6514b21e253a6be7a310377e200be3e2bc04e4
Author: Michael Forney <mforney@mforney.org>
Date:   Tue, 30 Jun 2020 15:48:03 -0700

nasm: Update to 2.15.01

Diffstat:

Mpkg/nasm/.gitignore2+-
Mpkg/nasm/config.h233++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++-------------
Mpkg/nasm/gen.lua14++++++++------
Mpkg/nasm/patch/0001-Remove-date-from-version-info-to-make-build-reproduc.patch24++++++++++++------------
Mpkg/nasm/sha2562+-
Mpkg/nasm/url2+-
Mpkg/nasm/ver2+-
Aprobe/HAVE___BUILTIN_CHOOSE_EXPR3+++
Mprobe/gen.lua1+
9 files changed, 224 insertions(+), 59 deletions(-)

diff --git a/pkg/nasm/.gitignore b/pkg/nasm/.gitignore @@ -1,2 +1,2 @@ -/nasm-2.14.02.tar.gz +/nasm-2.15.01.tar.gz /src diff --git a/pkg/nasm/config.h b/pkg/nasm/config.h @@ -1,39 +1,40 @@ /* #undef ABORT_ON_PANIC */ /* #undef AC_APPLE_UNIVERSAL_BUILD */ -/* #undef CFLAG_FDATA_SECTIONS */ -/* #undef CFLAG_FFUNCTION_SECTIONS */ -/* #undef CFLAG_FGNU89_INLINE */ -/* #undef CFLAG_FLTO */ -#define CFLAG_FNO_COMMON 1 -/* #undef CFLAG_FNO_OMIT_FRAME_POINTER */ -/* #undef CFLAG_FSANITIZE_ADDRESS */ -/* #undef CFLAG_FSANITIZE_UNDEFINED */ -#define CFLAG_FVISIBILITY_HIDDEN 1 -#define CFLAG_FWRAPV 1 -/* #undef CFLAG_GGDB3 */ -#define CFLAG_PEDANTIC 1 -#define CFLAG_U_STRICT_ANSI 1 -#define CFLAG_W 1 -#define CFLAG_WALL 1 -#define CFLAG_WC90_C99_COMPAT 1 -/* #undef CFLAG_WERROR */ -#define CFLAG_WERROR_ATTRIBUTES 1 -#define CFLAG_WERROR_COMMENT 1 -#define CFLAG_WERROR_IMPLICIT 1 -#define CFLAG_WERROR_MISSING_BRACES 1 -#define CFLAG_WERROR_MISSING_DECLARATIONS 1 -#define CFLAG_WERROR_MISSING_PROTOTYPES 1 -#define CFLAG_WERROR_POINTER_ARITH 1 -#define CFLAG_WERROR_RETURN_TYPE 1 -/* #undef CFLAG_WERROR_STRICT_PROTOTYPES */ -#define CFLAG_WERROR_TRIGRAPHS 1 -/* #undef CFLAG_WERROR_UNKNOWN_WARNING_OPTION */ -#define CFLAG_WERROR_VLA 1 -#define CFLAG_WLONG_LONG 1 -/* #undef CFLAG_WL_GC_SECTIONS */ -/* #undef CFLAG_WPEDANTIC_MS_FORMAT */ -#define CFLAG_WSHIFT_NEGATIVE_VALUE 1 -#define CFLAG_WSTRINGOP_TRUNCATION 1 +#define CFLAGS_FDATA_SECTIONS 1 +#define CFLAGS_FFUNCTION_SECTIONS 1 +/* #undef CFLAGS_FGNU89_INLINE */ +/* #undef CFLAGS_FLTO */ +#define CFLAGS_FNO_COMMON 1 +/* #undef CFLAGS_FNO_OMIT_FRAME_POINTER */ +/* #undef CFLAGS_FSANITIZE_ADDRESS */ +/* #undef CFLAGS_FSANITIZE_UNDEFINED */ +#define CFLAGS_FVISIBILITY_HIDDEN 1 +#define CFLAGS_FWRAPV 1 +/* #undef CFLAGS_GGDB3 */ +/* #undef CFLAGS_O0 */ +#define CFLAGS_PEDANTIC 1 +/* #undef CFLAGS_PG */ +#define CFLAGS_U_STRICT_ANSI 1 +#define CFLAGS_W 1 +#define CFLAGS_WALL 1 +#define CFLAGS_WC90_C99_COMPAT 1 +/* #undef CFLAGS_WERROR */ +#define CFLAGS_WERROR_ATTRIBUTES 1 +#define CFLAGS_WERROR_COMMENT 1 +#define CFLAGS_WERROR_IMPLICIT 1 +#define CFLAGS_WERROR_MISSING_BRACES 1 +#define CFLAGS_WERROR_MISSING_DECLARATIONS 1 +#define CFLAGS_WERROR_MISSING_PROTOTYPES 1 +#define CFLAGS_WERROR_POINTER_ARITH 1 +#define CFLAGS_WERROR_RETURN_TYPE 1 +/* #undef CFLAGS_WERROR_STRICT_PROTOTYPES */ +#define CFLAGS_WERROR_TRIGRAPHS 1 +/* #undef CFLAGS_WERROR_UNKNOWN_WARNING_OPTION */ +#define CFLAGS_WERROR_VLA 1 +#define CFLAGS_WLONG_LONG 1 +/* #undef CFLAGS_WPEDANTIC_MS_FORMAT */ +#define CFLAGS_WSHIFT_NEGATIVE_VALUE 1 +#define CFLAGS_WSTRINGOP_TRUNCATION 1 #define HAVE_ACCESS 1 /* #undef HAVE_CANONICALIZE_FILE_NAME */ /* #undef HAVE_CPU_TO_LE16 */ @@ -54,18 +55,30 @@ #define HAVE_FSEEKO 1 #define HAVE_FSTAT 1 #define HAVE_FTRUNCATE 1 -#define HAVE_FUNC_ATTRIBUTE_ALLOC_SIZE 1 +#define HAVE_FUNC_ATTRIBUTE1_ALLOC_SIZE 1 +/* #undef HAVE_FUNC_ATTRIBUTE2_ALLOC_SIZE */ +#define HAVE_FUNC_ATTRIBUTE3_FORMAT 1 #define HAVE_FUNC_ATTRIBUTE_COLD 1 #define HAVE_FUNC_ATTRIBUTE_CONST 1 #define HAVE_FUNC_ATTRIBUTE_ERROR 1 -#define HAVE_FUNC_ATTRIBUTE_FORMAT 1 #define HAVE_FUNC_ATTRIBUTE_MALLOC 1 #define HAVE_FUNC_ATTRIBUTE_NORETURN 1 #define HAVE_FUNC_ATTRIBUTE_PURE 1 #define HAVE_FUNC_ATTRIBUTE_RETURNS_NONNULL 1 #define HAVE_FUNC_ATTRIBUTE_SENTINEL 1 +#define HAVE_FUNC_PTR_ATTRIBUTE1_ALLOC_SIZE 1 +/* #undef HAVE_FUNC_PTR_ATTRIBUTE2_ALLOC_SIZE */ +#define HAVE_FUNC_PTR_ATTRIBUTE3_FORMAT 1 +/* #undef HAVE_FUNC_PTR_ATTRIBUTE_COLD */ +#define HAVE_FUNC_PTR_ATTRIBUTE_CONST 1 +/* #undef HAVE_FUNC_PTR_ATTRIBUTE_MALLOC */ +#define HAVE_FUNC_PTR_ATTRIBUTE_NORETURN 1 +/* #undef HAVE_FUNC_PTR_ATTRIBUTE_PURE */ +#define HAVE_FUNC_PTR_ATTRIBUTE_RETURNS_NONNULL 1 +#define HAVE_FUNC_PTR_ATTRIBUTE_SENTINEL 1 #define HAVE_GETGID 1 #define HAVE_GETPAGESIZE 1 +#define HAVE_GETRLIMIT 1 #define HAVE_GETUID 1 #define HAVE_HTOLE16 1 #define HAVE_HTOLE32 1 @@ -73,8 +86,11 @@ /* #undef HAVE_INTRIN_H */ #define HAVE_INTTYPES_H 1 /* #undef HAVE_IO_H */ +#define HAVE_ISASCII 1 +#define HAVE_ISCNTRL 1 /* #undef HAVE_MACHINE_ENDIAN_H */ #define HAVE_MEMORY_H 1 +#define HAVE_MEMPCPY 1 #define HAVE_MMAP 1 #define HAVE_PATHCONF 1 #define HAVE_REALPATH 1 @@ -101,8 +117,10 @@ /* #undef HAVE_SYS_ENDIAN_H */ #define HAVE_SYS_MMAN_H 1 #define HAVE_SYS_PARAM_H 1 +#define HAVE_SYS_RESOURCE_H 1 #define HAVE_SYS_STAT_H 1 #define HAVE_SYS_TYPES_H 1 +/* #undef HAVE_S_ISREG */ #define HAVE_UINTPTR_T 1 #define HAVE_UNISTD_H 1 #define HAVE_VSNPRINTF 1 @@ -115,7 +133,6 @@ /* #undef HAVE__BYTESWAP_USHORT */ /* #undef HAVE__CHSIZE */ /* #undef HAVE__CHSIZE_S */ -/* #undef HAVE__FILELENGTHI64 */ /* #undef HAVE__FILENO */ /* #undef HAVE__FSEEKI64 */ /* #undef HAVE__FSTATI64 */ @@ -129,6 +146,7 @@ #define HAVE___BUILTIN_BSWAP16 1 #define HAVE___BUILTIN_BSWAP32 1 #define HAVE___BUILTIN_BSWAP64 1 +/* probe HAVE___BUILTIN_CHOOSE_EXPR */ /* probe HAVE___BUILTIN_CLZ */ #define HAVE___BUILTIN_CLZL 1 #define HAVE___BUILTIN_CLZLL 1 @@ -137,6 +155,7 @@ /* #undef HAVE___CPU_TO_LE16 */ /* #undef HAVE___CPU_TO_LE32 */ /* #undef HAVE___CPU_TO_LE64 */ +#define LDFLAGS_WL_GC_SECTIONS 1 #define PACKAGE_BUGREPORT "" #define PACKAGE_NAME "" #define PACKAGE_STRING "" @@ -181,3 +200,143 @@ #endif /* #undef size_t */ /* #undef uintptr_t */ +#ifndef noreturn_func +# ifdef HAVE_FUNC_ATTRIBUTE_NORETURN +# define noreturn_func __attribute__((noreturn)) +# else +# define noreturn_func +# endif +#endif +#ifndef alloc_size_func2_ptr +# ifdef HAVE_FUNC_PTR_ATTRIBUTE2_ALLOC_SIZE +# define alloc_size_func2_ptr(x1,x2) __attribute__((alloc_size(x1,x2))) +# else +# define alloc_size_func2_ptr(x1,x2) +# endif +#endif +#ifndef end_with_null +# ifdef HAVE_FUNC_ATTRIBUTE_SENTINEL +# define end_with_null __attribute__((sentinel)) +# else +# define end_with_null +# endif +#endif +#ifndef end_with_null_ptr +# ifdef HAVE_FUNC_PTR_ATTRIBUTE_SENTINEL +# define end_with_null_ptr __attribute__((sentinel)) +# else +# define end_with_null_ptr +# endif +#endif +#ifndef format_func3 +# ifdef HAVE_FUNC_ATTRIBUTE3_FORMAT +# define format_func3(x1,x2,x3) __attribute__((format(x1,x2,x3))) +# else +# define format_func3(x1,x2,x3) +# endif +#endif +#ifndef format_func3_ptr +# ifdef HAVE_FUNC_PTR_ATTRIBUTE3_FORMAT +# define format_func3_ptr(x1,x2,x3) __attribute__((format(x1,x2,x3))) +# else +# define format_func3_ptr(x1,x2,x3) +# endif +#endif +#ifndef const_func +# ifdef HAVE_FUNC_ATTRIBUTE_CONST +# define const_func __attribute__((const)) +# else +# define const_func +# endif +#endif +#ifndef const_func_ptr +# ifdef HAVE_FUNC_PTR_ATTRIBUTE_CONST +# define const_func_ptr __attribute__((const)) +# else +# define const_func_ptr +# endif +#endif +#ifndef pure_func +# ifdef HAVE_FUNC_ATTRIBUTE_PURE +# define pure_func __attribute__((pure)) +# else +# define pure_func +# endif +#endif +#ifndef pure_func_ptr +# ifdef HAVE_FUNC_PTR_ATTRIBUTE_PURE +# define pure_func_ptr __attribute__((pure)) +# else +# define pure_func_ptr +# endif +#endif +#ifndef unlikely_func +# ifdef HAVE_FUNC_ATTRIBUTE_COLD +# define unlikely_func __attribute__((cold)) +# else +# define unlikely_func +# endif +#endif +#ifndef noreturn_func_ptr +# ifdef HAVE_FUNC_PTR_ATTRIBUTE_NORETURN +# define noreturn_func_ptr __attribute__((noreturn)) +# else +# define noreturn_func_ptr +# endif +#endif +#ifndef unlikely_func_ptr +# ifdef HAVE_FUNC_PTR_ATTRIBUTE_COLD +# define unlikely_func_ptr __attribute__((cold)) +# else +# define unlikely_func_ptr +# endif +#endif +#ifndef never_null +# ifdef HAVE_FUNC_ATTRIBUTE_RETURNS_NONNULL +# define never_null __attribute__((returns_nonnull)) +# else +# define never_null +# endif +#endif +#ifndef never_null_ptr +# ifdef HAVE_FUNC_PTR_ATTRIBUTE_RETURNS_NONNULL +# define never_null_ptr __attribute__((returns_nonnull)) +# else +# define never_null_ptr +# endif +#endif +#ifndef malloc_func +# ifdef HAVE_FUNC_ATTRIBUTE_MALLOC +# define malloc_func __attribute__((malloc)) +# else +# define malloc_func +# endif +#endif +#ifndef malloc_func_ptr +# ifdef HAVE_FUNC_PTR_ATTRIBUTE_MALLOC +# define malloc_func_ptr __attribute__((malloc)) +# else +# define malloc_func_ptr +# endif +#endif +#ifndef alloc_size_func1 +# ifdef HAVE_FUNC_ATTRIBUTE1_ALLOC_SIZE +# define alloc_size_func1(x1) __attribute__((alloc_size(x1))) +# else +# define alloc_size_func1(x1) +# endif +#endif +#ifndef alloc_size_func1_ptr +# ifdef HAVE_FUNC_PTR_ATTRIBUTE1_ALLOC_SIZE +# define alloc_size_func1_ptr(x1) __attribute__((alloc_size(x1))) +# else +# define alloc_size_func1_ptr(x1) +# endif +#endif +#ifndef alloc_size_func2 +# ifdef HAVE_FUNC_ATTRIBUTE2_ALLOC_SIZE +# define alloc_size_func2(x1,x2) __attribute__((alloc_size(x1,x2))) +# else +# define alloc_size_func2(x1,x2) +# endif +#endif diff --git a/pkg/nasm/gen.lua b/pkg/nasm/gen.lua @@ -10,6 +10,7 @@ cflags{ } build('cat', '$outdir/config/config.h', { + '$builddir/probe/HAVE___BUILTIN_CHOOSE_EXPR', '$builddir/probe/HAVE___BUILTIN_CLZ', '$dir/config.h', }) @@ -20,11 +21,12 @@ lib('libnasm.a', [[ stdlib/(snprintf.c vsnprintf.c strlcpy.c strnlen.c strrchrnul.c) nasmlib/( ver.c - crc64.c malloc.c errfile.c - md5c.c string.c + alloc.c asprintf.c errfile.c + crc64.c md5c.c + string.c nctype.c file.c mmap.c ilog2.c realpath.c path.c - filename.c srcfile.c + filename.c rlimit.c zerobuf.c readnum.c bsi.c rbtree.c hashtbl.c raa.c saa.c @@ -38,8 +40,8 @@ lib('libnasm.a', [[ disp8.c iflag.c ) asm/( - error.c - float.c + error.c warnings.c + floats.c directiv.c directbl.c pragma.c assemble.c labels.c parser.c @@ -50,11 +52,11 @@ lib('libnasm.a', [[ segalloc.c preproc-nop.c rdstrnum.c + srcfile.c ) macros/macros.c output/( outform.c outlib.c legacy.c - strtbl.c nulldbg.c nullout.c outbin.c outaout.c outcoff.c outelf.c diff --git a/pkg/nasm/patch/0001-Remove-date-from-version-info-to-make-build-reproduc.patch b/pkg/nasm/patch/0001-Remove-date-from-version-info-to-make-build-reproduc.patch @@ -1,4 +1,4 @@ -From b5586408623a3b346ad9e5157d0b9a2ad6d78614 Mon Sep 17 00:00:00 2001 +From 62c2b6a0314a2c7123f9925a45b694d7119227f6 Mon Sep 17 00:00:00 2001 From: Val Lorentz <progval@progval.net> Date: Sun, 29 Jan 2017 17:39:54 -0800 Subject: [PATCH] Remove date from version info to make build reproducible @@ -12,10 +12,10 @@ Signed-off-by: Jordan Justen <jordan.l.justen@intel.com> 4 files changed, 4 insertions(+), 6 deletions(-) diff --git a/asm/nasm.c b/asm/nasm.c -index 1c5a5fc5..35c1e974 100644 +index 7c64569f..9659bf15 100644 --- a/asm/nasm.c +++ b/asm/nasm.c -@@ -871,8 +871,8 @@ static const struct textargs textopts[] = { +@@ -973,8 +973,8 @@ static const struct textargs textopts[] = { static void show_version(void) { @@ -27,10 +27,10 @@ index 1c5a5fc5..35c1e974 100644 } diff --git a/disasm/ndisasm.c b/disasm/ndisasm.c -index 2d0cf153..7383170c 100644 +index 01e0c557..7424b282 100644 --- a/disasm/ndisasm.c +++ b/disasm/ndisasm.c -@@ -118,8 +118,8 @@ int main(int argc, char **argv) +@@ -120,8 +120,8 @@ int main(int argc, char **argv) case 'r': case 'v': fprintf(stderr, @@ -42,19 +42,19 @@ index 2d0cf153..7383170c 100644 case 'u': /* -u for -b 32, -uu for -b 64 */ if (bits < 64) diff --git a/include/ver.h b/include/ver.h -index 62d9c52d..6c93fe15 100644 +index ab6e9784..4b26499c 100644 --- a/include/ver.h +++ b/include/ver.h -@@ -39,7 +39,6 @@ - #define NASM_VER_H +@@ -41,7 +41,6 @@ + #include "compiler.h" extern const char nasm_version[]; -extern const char nasm_date[]; extern const char nasm_compile_options[]; - extern const char nasm_comment[]; - extern const char nasm_signature[]; + + extern const char *nasm_comment(void); diff --git a/nasmlib/ver.c b/nasmlib/ver.c -index 98362e35..826ff159 100644 +index 9f80f79c..f711f332 100644 --- a/nasmlib/ver.c +++ b/nasmlib/ver.c @@ -36,7 +36,6 @@ @@ -66,5 +66,5 @@ index 98362e35..826ff159 100644 #ifdef DEBUG " with -DDEBUG" -- -2.22.0 +2.27.0 diff --git a/pkg/nasm/sha256 b/pkg/nasm/sha256 @@ -1 +1 @@ -b34bae344a3f2ed93b2ca7bf25f1ed3fb12da89eeda6096e3551fd66adeae9fc nasm-2.14.02.tar.gz +d98c3d0bf8aea524db0a63d8e93b241adcf94f6fb4cb3446fbc95ebd4fa430c3 nasm-2.15.01.tar.gz diff --git a/pkg/nasm/url b/pkg/nasm/url @@ -1 +1 @@ -url = "http://www.nasm.us/pub/nasm/releasebuilds/2.14.02/nasm-2.14.02.tar.gz" +url = "http://www.nasm.us/pub/nasm/releasebuilds/2.15.01/nasm-2.15.01.tar.gz" diff --git a/pkg/nasm/ver b/pkg/nasm/ver @@ -1 +1 @@ -2.14.02 r1 +2.15.01 r0 diff --git a/probe/HAVE___BUILTIN_CHOOSE_EXPR b/probe/HAVE___BUILTIN_CHOOSE_EXPR @@ -0,0 +1,3 @@ +int main(void) { + return __builtin_choose_expr(123, 1, 0); +} diff --git a/probe/gen.lua b/probe/gen.lua @@ -6,6 +6,7 @@ probe('HAVE_IMMINTRIN_H') probe('HAVE__MM_MOVEMASK_EPI8') probe('HAVE__THREAD_LOCAL') probe('HAVE___BUILTIN_ASSUME_ALIGNED') +probe('HAVE___BUILTIN_CHOOSE_EXPR') probe('HAVE___BUILTIN_CLZ') probe('HAVE___BUILTIN_CTZL') probe('HAVE___BUILTIN_POPCOUNT')