fix: implicit declaration of function 'syscall' in apps/shell

Merge pull request  from uhamc/fix-apps-shell-build
This commit is contained in:
openharmony_ci 2021-10-26 06:43:57 +00:00 committed by Gitee
commit 23c4f2b81b
4 changed files with 5 additions and 3 deletions
apps

View File

@ -30,7 +30,7 @@
include $(LITEOSTOPDIR)/config.mk
# common flags config
BASE_OPTS := -D_FORTIFY_SOURCE=2 -D_GNU_SOURCE
BASE_OPTS := -D_FORTIFY_SOURCE=2 -D_XOPEN_SOURCE=700
ASFLAGS :=
CFLAGS := $(LITEOS_COPTS) $(BASE_OPTS) -fPIE

View File

@ -29,9 +29,7 @@
* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
#ifndef _GNU_SOURCE
#define _GNU_SOURCE
#endif
#include "unistd.h"
#include "shcmd.h"

View File

@ -29,6 +29,8 @@
* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
#define _GNU_SOURCE
#include "show.h"
#include "shmsg.h"
#include "shcmd.h"

View File

@ -29,6 +29,8 @@
* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
#define _GNU_SOURCE
#include "stdlib.h"
#include "stdio.h"
#include "unistd.h"