Gentoo Logo
Gentoo Spaceship




Note: Due to technical difficulties, the Archives are currently not up to date. GMANE provides an alternative service for most mailing lists.
c.f. bug 424647
List Archive: gentoo-commits
Navigation:
Lists: gentoo-commits: < Prev By Thread Next > < Prev By Date Next >
Headers:
To: gentoo-commits@g.o
From: "Mike Frysinger" <vapier@g.o>
Subject: proj/sandbox:master commit in: /, libsbutil/, libsandbox/
Date: Sat, 23 Jun 2012 21:25:26 +0000 (UTC)
commit:     2995c5954980f84b0e4a5501dbdde92ec57293ca
Author:     Mike Frysinger <vapier <AT> gentoo <DOT> org>
AuthorDate: Wed Mar  7 16:00:02 2012 +0000
Commit:     Mike Frysinger <vapier <AT> gentoo <DOT> org>
CommitDate: Sat Jun 23 21:23:10 2012 +0000
URL:        http://git.overlays.gentoo.org/gitweb/?p=proj/sandbox.git;a=commit;h=2995c595

libsandbox: create more defines for gcc attributes

Signed-off-by: Mike Frysinger <vapier <AT> gentoo.org>

---
 libsandbox/libsandbox.h |    4 ++--
 libsbutil/sbutil.h      |    8 ++++----
 localdecls.h            |    2 ++
 3 files changed, 8 insertions(+), 6 deletions(-)

diff --git a/libsandbox/libsandbox.h b/libsandbox/libsandbox.h
index 0324b5b..3177253 100644
--- a/libsandbox/libsandbox.h
+++ b/libsandbox/libsandbox.h
@@ -63,9 +63,9 @@ extern void sb_unlock(void);
 
 void trace_main(const char *filename, char *const argv[]);
 
-__attribute__((__format__(__printf__, 1, 2))) void sb_eqawarn(const char *format, ...);
+__printf(1, 2) void sb_eqawarn(const char *format, ...);
 void sb_dump_backtrace(void);
-__attribute__((noreturn)) void sb_abort(void);
+__noreturn void sb_abort(void);
 
 /* glibc modified realpath() function */
 char *erealpath(const char *, char *);

diff --git a/libsbutil/sbutil.h b/libsbutil/sbutil.h
index ad9ce25..f45402e 100644
--- a/libsbutil/sbutil.h
+++ b/libsbutil/sbutil.h
@@ -96,10 +96,10 @@ size_t sb_write(int fd, const void *buf, size_t count);
 int sb_close(int fd);
 
 /* Reliable output */
-__attribute__((__format__(__printf__, 1, 2))) void sb_printf(const char *format, ...);
-__attribute__((__format__(__printf__, 2, 3))) void sb_fdprintf(int fd, const char *format, ...);
-__attribute__((__format__(__printf__, 2, 0))) void sb_vfdprintf(int fd, const char *format, va_list args);
-__attribute__((__format__(__printf__, 3, 4))) void sb_efunc(const char *color, const char *hilight, const char *format, ...);
+__printf(1, 2) void sb_printf(const char *format, ...);
+__printf(2, 3) void sb_fdprintf(int fd, const char *format, ...);
+__printf(2, 0) void sb_vfdprintf(int fd, const char *format, va_list args);
+__printf(3, 4) void sb_efunc(const char *color, const char *hilight, const char *format, ...);
 #define sb_fprintf(fp, ...) sb_fdprintf(fileno(fp), __VA_ARGS__)
 #define sb_vfprintf(fp, ...) sb_vfdprintf(fileno(fp), __VA_ARGS__)
 

diff --git a/localdecls.h b/localdecls.h
index 674e848..eef7295 100644
--- a/localdecls.h
+++ b/localdecls.h
@@ -119,5 +119,7 @@ typedef struct user_regs_struct trace_regs;
 
 #define likely(x)   __builtin_expect(!!(x), 1)
 #define unlikely(x) __builtin_expect(!!(x), 0)
+#define __noreturn __attribute__((noreturn))
+#define __printf(x, y) __attribute__((__format__(__printf__, x, y)))
 
 #endif


Navigation:
Lists: gentoo-commits: < Prev By Thread Next > < Prev By Date Next >
Previous by thread:
proj/sandbox:master commit in: src/, libsbutil/, etc/, tests/
Next by thread:
gentoo-x86 commit in app-office/calligra/files: calligra-2.4.2-marble.patch
Previous by date:
proj/sandbox:master commit in: src/, libsbutil/, etc/, tests/
Next by date:
proj/sandbox:master commit in: tests/


Updated Jun 26, 2012

Summary: Archive of the gentoo-commits mailing list.

Donate to support our development efforts.

Copyright 2001-2013 Gentoo Foundation, Inc. Questions, Comments? Contact us.