[Asterisk-code-review] Remove #include <sys/cdefs.h> (asterisk[16])

Sean Bright asteriskteam at digium.com
Tue May 5 07:56:14 CDT 2020


Hello Jaco Kroon,

I'd like you to do a code review. Please visit

    https://gerrit.asterisk.org/c/asterisk/+/14340

to review the following change.


Change subject: Remove #include <sys/cdefs.h>
......................................................................

Remove #include <sys/cdefs.h>

These are not provided by standards, and as a result causes failure to
compile on musl.

https://wiki.musl-libc.org/faq.html#Q:-When-compiling-something-against-musl,-I-get-error-messages-about-%3Ccode%3Esys/cdefs.h%3C/code%3E

Change-Id: I6a357cefd106c72cfecafd898638f6b5692c2e05
---
M main/ast_expr2.c
M main/ast_expr2.y
M utils/db1-ast/include/db.h
3 files changed, 0 insertions(+), 3 deletions(-)



  git pull ssh://gerrit.asterisk.org:29418/asterisk refs/changes/40/14340/1

diff --git a/main/ast_expr2.c b/main/ast_expr2.c
index b7b45da..5b8f6e8 100644
--- a/main/ast_expr2.c
+++ b/main/ast_expr2.c
@@ -94,7 +94,6 @@
 #define ASTMM_LIBC ASTMM_REDIRECT
 #include "asterisk.h"
 
-#include <sys/cdefs.h>
 #include <sys/types.h>
 #include <stdio.h>
 
diff --git a/main/ast_expr2.y b/main/ast_expr2.y
index 144df57..b0b257d 100644
--- a/main/ast_expr2.y
+++ b/main/ast_expr2.y
@@ -15,7 +15,6 @@
 #define ASTMM_LIBC ASTMM_REDIRECT
 #include "asterisk.h"
 
-#include <sys/cdefs.h>
 #include <sys/types.h>
 #include <stdio.h>
 
diff --git a/utils/db1-ast/include/db.h b/utils/db1-ast/include/db.h
index 23b9b95..30f73e2 100644
--- a/utils/db1-ast/include/db.h
+++ b/utils/db1-ast/include/db.h
@@ -37,7 +37,6 @@
 #define	_DB_H 1
 
 #include <sys/types.h>
-#include <sys/cdefs.h>
 
 #include <limits.h>
 

-- 
To view, visit https://gerrit.asterisk.org/c/asterisk/+/14340
To unsubscribe, or for help writing mail filters, visit https://gerrit.asterisk.org/settings

Gerrit-Project: asterisk
Gerrit-Branch: 16
Gerrit-Change-Id: I6a357cefd106c72cfecafd898638f6b5692c2e05
Gerrit-Change-Number: 14340
Gerrit-PatchSet: 1
Gerrit-Owner: Sean Bright <sean.bright at gmail.com>
Gerrit-Reviewer: Jaco Kroon <jaco at uls.co.za>
Gerrit-MessageType: newchange
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.digium.com/pipermail/asterisk-code-review/attachments/20200505/18a7cd2a/attachment-0001.html>


More information about the asterisk-code-review mailing list