Date: Mon, 19 Feb 2024 16:44:53 GMT From: Andrew Turner <andrew@FreeBSD.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org Subject: git: 892cc8813aff - stable/13 - sys/sys: Check for __ASSEMBLER__ in elf_common.h Message-ID: <202402191644.41JGirll094144@gitrepo.freebsd.org>
next in thread | raw e-mail | index | archive | help
The branch stable/13 has been updated by andrew: URL: https://cgit.FreeBSD.org/src/commit/?id=892cc8813aff01429614a27192061d013e8f52c4 commit 892cc8813aff01429614a27192061d013e8f52c4 Author: Andrew Turner <andrew@FreeBSD.org> AuthorDate: 2023-10-12 09:45:43 +0000 Commit: Andrew Turner <andrew@FreeBSD.org> CommitDate: 2024-02-19 12:40:43 +0000 sys/sys: Check for __ASSEMBLER__ in elf_common.h When preprocessing assembly files with clang or gcc the __ASSEMBLER__ macro is defined. Check for this as an alternative to LOCORE in elf_common.h so it can be included by .S files. Reviewed by: imp Sponsored by: Arm Ltd Differential Revision: https://reviews.freebsd.org/D42224 (cherry picked from commit f39010b1393d471f1c59195acde5d95cdb66847c) --- sys/sys/elf_common.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/sys/sys/elf_common.h b/sys/sys/elf_common.h index 2bb7e458314c..4af241bb085c 100644 --- a/sys/sys/elf_common.h +++ b/sys/sys/elf_common.h @@ -44,7 +44,7 @@ * not include the padding. */ -#ifndef LOCORE +#if !defined(LOCORE) && !defined(__ASSEMBLER__) typedef struct { u_int32_t n_namesz; /* Length of name. */ u_int32_t n_descsz; /* Length of descriptor. */ @@ -112,7 +112,7 @@ typedef Elf_Note Elf_Nhdr; * The header for GNU-style hash sections. */ -#ifndef LOCORE +#if !defined(LOCORE) && !defined(__ASSEMBLER__) typedef struct { u_int32_t gh_nbuckets; /* Number of hash buckets. */ u_int32_t gh_symndx; /* First visible symbol in .dynsym. */
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?202402191644.41JGirll094144>