Move ARM access.c from machine to sys
The implementation of the POSIX access() function is nothing machine specific like memcpy(), etc. Move it back to the system domain. This avoids problems due to the include search order of the Newlib/GCC build which picks up machine includes before system includes. Signed-off-by: Sebastian Huber <sebastian.huber@embedded-brains.de>
This commit is contained in:
parent
0008601042
commit
2693c1db69
|
@ -8,7 +8,7 @@ AM_CCASFLAGS = $(INCLUDES)
|
||||||
|
|
||||||
noinst_LIBRARIES = lib.a
|
noinst_LIBRARIES = lib.a
|
||||||
|
|
||||||
lib_a_SOURCES = setjmp.S access.c strcmp.S strcpy.c \
|
lib_a_SOURCES = setjmp.S strcmp.S strcpy.c \
|
||||||
aeabi_memcpy.c aeabi_memcpy-armv7a.S \
|
aeabi_memcpy.c aeabi_memcpy-armv7a.S \
|
||||||
aeabi_memmove.c aeabi_memmove-soft.S \
|
aeabi_memmove.c aeabi_memmove-soft.S \
|
||||||
aeabi_memset.c aeabi_memset-soft.S aeabi_memclr.c
|
aeabi_memset.c aeabi_memset-soft.S aeabi_memclr.c
|
||||||
|
|
|
@ -69,9 +69,8 @@ LIBRARIES = $(noinst_LIBRARIES)
|
||||||
ARFLAGS = cru
|
ARFLAGS = cru
|
||||||
lib_a_AR = $(AR) $(ARFLAGS)
|
lib_a_AR = $(AR) $(ARFLAGS)
|
||||||
lib_a_LIBADD =
|
lib_a_LIBADD =
|
||||||
am_lib_a_OBJECTS = lib_a-setjmp.$(OBJEXT) lib_a-access.$(OBJEXT) \
|
am_lib_a_OBJECTS = lib_a-setjmp.$(OBJEXT) lib_a-strcmp.$(OBJEXT) \
|
||||||
lib_a-strcmp.$(OBJEXT) lib_a-strcpy.$(OBJEXT) \
|
lib_a-strcpy.$(OBJEXT) lib_a-aeabi_memcpy.$(OBJEXT) \
|
||||||
lib_a-aeabi_memcpy.$(OBJEXT) \
|
|
||||||
lib_a-aeabi_memcpy-armv7a.$(OBJEXT) \
|
lib_a-aeabi_memcpy-armv7a.$(OBJEXT) \
|
||||||
lib_a-aeabi_memmove.$(OBJEXT) \
|
lib_a-aeabi_memmove.$(OBJEXT) \
|
||||||
lib_a-aeabi_memmove-soft.$(OBJEXT) \
|
lib_a-aeabi_memmove-soft.$(OBJEXT) \
|
||||||
|
@ -206,7 +205,7 @@ AUTOMAKE_OPTIONS = cygnus
|
||||||
INCLUDES = $(NEWLIB_CFLAGS) $(CROSS_CFLAGS) $(TARGET_CFLAGS)
|
INCLUDES = $(NEWLIB_CFLAGS) $(CROSS_CFLAGS) $(TARGET_CFLAGS)
|
||||||
AM_CCASFLAGS = $(INCLUDES)
|
AM_CCASFLAGS = $(INCLUDES)
|
||||||
noinst_LIBRARIES = lib.a
|
noinst_LIBRARIES = lib.a
|
||||||
lib_a_SOURCES = setjmp.S access.c strcmp.S strcpy.c aeabi_memcpy.c \
|
lib_a_SOURCES = setjmp.S strcmp.S strcpy.c aeabi_memcpy.c \
|
||||||
aeabi_memcpy-armv7a.S aeabi_memmove.c aeabi_memmove-soft.S \
|
aeabi_memcpy-armv7a.S aeabi_memmove.c aeabi_memmove-soft.S \
|
||||||
aeabi_memset.c aeabi_memset-soft.S aeabi_memclr.c \
|
aeabi_memset.c aeabi_memset-soft.S aeabi_memclr.c \
|
||||||
memchr-stub.c memchr.S memcpy-stub.c memcpy.S strlen-stub.c \
|
memchr-stub.c memchr.S memcpy-stub.c memcpy.S strlen-stub.c \
|
||||||
|
@ -338,12 +337,6 @@ lib_a-strlen.obj: strlen.S
|
||||||
.c.obj:
|
.c.obj:
|
||||||
$(COMPILE) -c `$(CYGPATH_W) '$<'`
|
$(COMPILE) -c `$(CYGPATH_W) '$<'`
|
||||||
|
|
||||||
lib_a-access.o: access.c
|
|
||||||
$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lib_a_CFLAGS) $(CFLAGS) -c -o lib_a-access.o `test -f 'access.c' || echo '$(srcdir)/'`access.c
|
|
||||||
|
|
||||||
lib_a-access.obj: access.c
|
|
||||||
$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lib_a_CFLAGS) $(CFLAGS) -c -o lib_a-access.obj `if test -f 'access.c'; then $(CYGPATH_W) 'access.c'; else $(CYGPATH_W) '$(srcdir)/access.c'; fi`
|
|
||||||
|
|
||||||
lib_a-strcpy.o: strcpy.c
|
lib_a-strcpy.o: strcpy.c
|
||||||
$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lib_a_CFLAGS) $(CFLAGS) -c -o lib_a-strcpy.o `test -f 'strcpy.c' || echo '$(srcdir)/'`strcpy.c
|
$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lib_a_CFLAGS) $(CFLAGS) -c -o lib_a-strcpy.o `test -f 'strcpy.c' || echo '$(srcdir)/'`strcpy.c
|
||||||
|
|
||||||
|
|
|
@ -14,7 +14,7 @@ else
|
||||||
extra_objs =
|
extra_objs =
|
||||||
endif
|
endif
|
||||||
|
|
||||||
lib_a_SOURCES = aeabi_atexit.c
|
lib_a_SOURCES = access.c aeabi_atexit.c
|
||||||
lib_a_LIBADD = $(extra_objs)
|
lib_a_LIBADD = $(extra_objs)
|
||||||
EXTRA_lib_a_SOURCES = trap.S syscalls.c libcfunc.c
|
EXTRA_lib_a_SOURCES = trap.S syscalls.c libcfunc.c
|
||||||
lib_a_DEPENDENCIES = $(extra_objs)
|
lib_a_DEPENDENCIES = $(extra_objs)
|
||||||
|
|
|
@ -70,7 +70,7 @@ ARFLAGS = cru
|
||||||
lib_a_AR = $(AR) $(ARFLAGS)
|
lib_a_AR = $(AR) $(ARFLAGS)
|
||||||
@MAY_SUPPLY_SYSCALLS_TRUE@am__DEPENDENCIES_1 = $(lpfx)libcfunc.o \
|
@MAY_SUPPLY_SYSCALLS_TRUE@am__DEPENDENCIES_1 = $(lpfx)libcfunc.o \
|
||||||
@MAY_SUPPLY_SYSCALLS_TRUE@ $(lpfx)trap.o $(lpfx)syscalls.o
|
@MAY_SUPPLY_SYSCALLS_TRUE@ $(lpfx)trap.o $(lpfx)syscalls.o
|
||||||
am_lib_a_OBJECTS = lib_a-aeabi_atexit.$(OBJEXT)
|
am_lib_a_OBJECTS = lib_a-access.$(OBJEXT) lib_a-aeabi_atexit.$(OBJEXT)
|
||||||
lib_a_OBJECTS = $(am_lib_a_OBJECTS)
|
lib_a_OBJECTS = $(am_lib_a_OBJECTS)
|
||||||
DEFAULT_INCLUDES = -I.@am__isrc@
|
DEFAULT_INCLUDES = -I.@am__isrc@
|
||||||
depcomp =
|
depcomp =
|
||||||
|
@ -198,7 +198,7 @@ AM_CCASFLAGS = $(INCLUDES)
|
||||||
noinst_LIBRARIES = lib.a
|
noinst_LIBRARIES = lib.a
|
||||||
@MAY_SUPPLY_SYSCALLS_FALSE@extra_objs =
|
@MAY_SUPPLY_SYSCALLS_FALSE@extra_objs =
|
||||||
@MAY_SUPPLY_SYSCALLS_TRUE@extra_objs = $(lpfx)libcfunc.o $(lpfx)trap.o $(lpfx)syscalls.o
|
@MAY_SUPPLY_SYSCALLS_TRUE@extra_objs = $(lpfx)libcfunc.o $(lpfx)trap.o $(lpfx)syscalls.o
|
||||||
lib_a_SOURCES = aeabi_atexit.c
|
lib_a_SOURCES = access.c aeabi_atexit.c
|
||||||
lib_a_LIBADD = $(extra_objs)
|
lib_a_LIBADD = $(extra_objs)
|
||||||
EXTRA_lib_a_SOURCES = trap.S syscalls.c libcfunc.c
|
EXTRA_lib_a_SOURCES = trap.S syscalls.c libcfunc.c
|
||||||
lib_a_DEPENDENCIES = $(extra_objs)
|
lib_a_DEPENDENCIES = $(extra_objs)
|
||||||
|
@ -276,6 +276,12 @@ lib_a-trap.obj: trap.S
|
||||||
.c.obj:
|
.c.obj:
|
||||||
$(COMPILE) -c `$(CYGPATH_W) '$<'`
|
$(COMPILE) -c `$(CYGPATH_W) '$<'`
|
||||||
|
|
||||||
|
lib_a-access.o: access.c
|
||||||
|
$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lib_a_CFLAGS) $(CFLAGS) -c -o lib_a-access.o `test -f 'access.c' || echo '$(srcdir)/'`access.c
|
||||||
|
|
||||||
|
lib_a-access.obj: access.c
|
||||||
|
$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lib_a_CFLAGS) $(CFLAGS) -c -o lib_a-access.obj `if test -f 'access.c'; then $(CYGPATH_W) 'access.c'; else $(CYGPATH_W) '$(srcdir)/access.c'; fi`
|
||||||
|
|
||||||
lib_a-aeabi_atexit.o: aeabi_atexit.c
|
lib_a-aeabi_atexit.o: aeabi_atexit.c
|
||||||
$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lib_a_CFLAGS) $(CFLAGS) -c -o lib_a-aeabi_atexit.o `test -f 'aeabi_atexit.c' || echo '$(srcdir)/'`aeabi_atexit.c
|
$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lib_a_CFLAGS) $(CFLAGS) -c -o lib_a-aeabi_atexit.o `test -f 'aeabi_atexit.c' || echo '$(srcdir)/'`aeabi_atexit.c
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue