mirror of
https://gitlab.rtems.org/rtems/rtos/rtems.git
synced 2026-09-02 05:26:30 +08:00
posix/src/exec*: Remove all variants already in Newlib
The RTEMS build of Newlib includes implementations of all exec*() variants. They rely on the _execve() support method. RTEMS already had this and it returned ENOSYS. There is no functional change. closes #2537.
This commit is contained in:
@@ -61,9 +61,7 @@ libposix_a_SOURCES += src/aio_cancel.c src/aio_error.c src/aio_fsync.c \
|
||||
src/aio_read.c src/aio_return.c src/aio_suspend.c src/aio_write.c \
|
||||
src/lio_listio.c src/aio_misc.c
|
||||
|
||||
## ENOSYS_C_FILES
|
||||
libposix_a_SOURCES += src/_execve.c src/execl.c src/execle.c src/execlp.c \
|
||||
src/execv.c src/execve.c src/execvp.c
|
||||
libposix_a_SOURCES += src/_execve.c
|
||||
endif
|
||||
|
||||
libposix_a_SOURCES += src/fork.c src/vfork.c
|
||||
|
||||
@@ -1,12 +1,16 @@
|
||||
/**
|
||||
* @file
|
||||
*
|
||||
* @brief execve()
|
||||
* @brief _execve()
|
||||
* @ingroup POSIXAPI
|
||||
*
|
||||
* The Newlib C Library contains all of the exec*() variants and assumes
|
||||
* the underlying OS support provides _execve(). This single method
|
||||
* ensures that all exec*() variants return ENOSYS.
|
||||
*/
|
||||
|
||||
/*
|
||||
* COPYRIGHT (c) 1989-2013.
|
||||
* COPYRIGHT (c) 1989-2013,2016.
|
||||
* On-Line Applications Research Corporation (OAR).
|
||||
*
|
||||
* The license and distribution terms for this file may be
|
||||
|
||||
@@ -1,37 +0,0 @@
|
||||
/**
|
||||
* @file
|
||||
*
|
||||
* @brief Process will get Executed and then Terminated by execl
|
||||
* @ingroup POSIXAPI
|
||||
*/
|
||||
|
||||
/*
|
||||
* execl() - POSIX 1003.1b 3.1.2
|
||||
*
|
||||
* COPYRIGHT (c) 1989-2007.
|
||||
* On-Line Applications Research Corporation (OAR).
|
||||
*
|
||||
* The license and distribution terms for this file may be
|
||||
* found in the file LICENSE in this distribution or at
|
||||
* http://www.rtems.org/license/LICENSE.
|
||||
*/
|
||||
|
||||
#if HAVE_CONFIG_H
|
||||
#include "config.h"
|
||||
#endif
|
||||
|
||||
#ifndef HAVE_EXECL
|
||||
|
||||
#include <errno.h>
|
||||
#include <rtems/seterr.h>
|
||||
|
||||
int execl(
|
||||
const char *path,
|
||||
const char *arg,
|
||||
...
|
||||
)
|
||||
{
|
||||
rtems_set_errno_and_return_minus_one( ENOSYS );
|
||||
}
|
||||
|
||||
#endif
|
||||
@@ -1,35 +0,0 @@
|
||||
/**
|
||||
* @file
|
||||
*
|
||||
* @brief Execute a File
|
||||
* @ingroup POSIXAPI
|
||||
*/
|
||||
|
||||
/*
|
||||
* COPYRIGHT (c) 1989-2007.
|
||||
* On-Line Applications Research Corporation (OAR).
|
||||
*
|
||||
* The license and distribution terms for this file may be
|
||||
* found in the file LICENSE in this distribution or at
|
||||
* http://www.rtems.org/license/LICENSE.
|
||||
*/
|
||||
|
||||
#if HAVE_CONFIG_H
|
||||
#include "config.h"
|
||||
#endif
|
||||
|
||||
#ifndef HAVE_EXECLE
|
||||
|
||||
#include <errno.h>
|
||||
#include <rtems/seterr.h>
|
||||
|
||||
int execle(
|
||||
const char *path,
|
||||
char const *arg,
|
||||
...
|
||||
)
|
||||
{
|
||||
rtems_set_errno_and_return_minus_one( ENOSYS );
|
||||
}
|
||||
|
||||
#endif
|
||||
@@ -1,35 +0,0 @@
|
||||
/**
|
||||
* @file
|
||||
*
|
||||
* @brief execlp()
|
||||
* @ingroup POSIXAPI
|
||||
*/
|
||||
|
||||
/*
|
||||
* COPYRIGHT (c) 1989-2007.
|
||||
* On-Line Applications Research Corporation (OAR).
|
||||
*
|
||||
* The license and distribution terms for this file may be
|
||||
* found in the file LICENSE in this distribution or at
|
||||
* http://www.rtems.org/license/LICENSE.
|
||||
*/
|
||||
|
||||
#if HAVE_CONFIG_H
|
||||
#include "config.h"
|
||||
#endif
|
||||
|
||||
#ifndef HAVE_EXECLP
|
||||
|
||||
#include <errno.h>
|
||||
#include <rtems/seterr.h>
|
||||
|
||||
int execlp(
|
||||
const char *file,
|
||||
const char *arg,
|
||||
...
|
||||
)
|
||||
{
|
||||
rtems_set_errno_and_return_minus_one( ENOSYS );
|
||||
}
|
||||
|
||||
#endif
|
||||
@@ -1,36 +0,0 @@
|
||||
/**
|
||||
* @file
|
||||
*
|
||||
* @brief Inoperable implementation of execv for POSIX threads
|
||||
* @ingroup POSIXAPI
|
||||
*/
|
||||
|
||||
/*
|
||||
* execv() - POSIX 1003.1b 3.1.2
|
||||
*
|
||||
* COPYRIGHT (c) 1989-2007.
|
||||
* On-Line Applications Research Corporation (OAR).
|
||||
*
|
||||
* The license and distribution terms for this file may be
|
||||
* found in the file LICENSE in this distribution or at
|
||||
* http://www.rtems.org/license/LICENSE.
|
||||
*/
|
||||
|
||||
#if HAVE_CONFIG_H
|
||||
#include "config.h"
|
||||
#endif
|
||||
|
||||
#ifndef HAVE_EXECV
|
||||
|
||||
#include <errno.h>
|
||||
#include <rtems/seterr.h>
|
||||
|
||||
int execv(
|
||||
const char *file,
|
||||
char *const argv[]
|
||||
)
|
||||
{
|
||||
rtems_set_errno_and_return_minus_one( ENOSYS );
|
||||
}
|
||||
|
||||
#endif
|
||||
@@ -1,38 +0,0 @@
|
||||
/**
|
||||
* @file
|
||||
*
|
||||
* @brief Execute a Program
|
||||
* @ingroup POSIXAPI
|
||||
*/
|
||||
|
||||
/*
|
||||
* COPYRIGHT (c) 1989-2007.
|
||||
* On-Line Applications Research Corporation (OAR).
|
||||
*
|
||||
* The license and distribution terms for this file may be
|
||||
* found in the file LICENSE in this distribution or at
|
||||
* http://www.rtems.org/license/LICENSE.
|
||||
*/
|
||||
|
||||
#if HAVE_CONFIG_H
|
||||
#include "config.h"
|
||||
#endif
|
||||
|
||||
#ifndef HAVE_EXECVE
|
||||
|
||||
#include <errno.h>
|
||||
#include <rtems/seterr.h>
|
||||
|
||||
/**
|
||||
* POSIX 1003.1b 3.1.2
|
||||
*/
|
||||
int execve(
|
||||
const char *path,
|
||||
char *const argv[],
|
||||
char *const envp[]
|
||||
)
|
||||
{
|
||||
rtems_set_errno_and_return_minus_one( ENOSYS );
|
||||
}
|
||||
|
||||
#endif
|
||||
@@ -1,34 +0,0 @@
|
||||
/**
|
||||
* @file
|
||||
*
|
||||
* @brief execvp() - POSIX 1003.1b 3.1.2
|
||||
* @ingroup POSIX_KEY Key
|
||||
*/
|
||||
|
||||
/*
|
||||
* COPYRIGHT (c) 1989-2007.
|
||||
* On-Line Applications Research Corporation (OAR).
|
||||
*
|
||||
* The license and distribution terms for this file may be
|
||||
* found in the file LICENSE in this distribution or at
|
||||
* http://www.rtems.org/license/LICENSE.
|
||||
*/
|
||||
|
||||
#if HAVE_CONFIG_H
|
||||
#include "config.h"
|
||||
#endif
|
||||
|
||||
#ifndef HAVE_EXECVP
|
||||
|
||||
#include <errno.h>
|
||||
#include <rtems/seterr.h>
|
||||
|
||||
int execvp(
|
||||
const char *path,
|
||||
char *const argv[]
|
||||
)
|
||||
{
|
||||
rtems_set_errno_and_return_minus_one( ENOSYS );
|
||||
}
|
||||
|
||||
#endif
|
||||
Reference in New Issue
Block a user