From fe412875fc366ec390eed1a337a0dfbddfcc7dd7 Mon Sep 17 00:00:00 2001 From: Tim Kientzle Date: Mon, 6 Oct 2008 18:39:07 -0400 Subject: [PATCH] Fix bsdtar building on platforms that already have an older libarchive installed. SVN-Revision: 218 --- tar/bsdtar_platform.h | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/tar/bsdtar_platform.h b/tar/bsdtar_platform.h index ccb9d3c02..a1c96bfe9 100644 --- a/tar/bsdtar_platform.h +++ b/tar/bsdtar_platform.h @@ -147,4 +147,14 @@ #endif #endif +/* How to mark functions that don't return. */ +/* This facilitates use of some newer static code analysis tools. */ +#undef __LA_DEAD +#if defined(__GNUC__) && (__GNUC__ > 2 || \ + (__GNUC__ == 2 && __GNUC_MINOR__ >= 5)) +#define __LA_DEAD __attribute__((__noreturn__)) +#else +#define __LA_DEAD +#endif + #endif /* !BSDTAR_PLATFORM_H_INCLUDED */ -- 2.47.3