2002-06-25 Jeff Johnston <jjohnstn@redhat.com>

* libc/sys/linux/sethostname.c: New file.
        * libc/sys/linux/Makefile.am: Add sethostname.c support.
        * libc/sys/linux/Makefile.in: Regenerated.
This commit is contained in:
Jeff Johnston 2002-06-25 18:05:31 +00:00
parent 6331b65843
commit ffddf61ea7
4 changed files with 39 additions and 17 deletions

View File

@ -1,3 +1,9 @@
2002-06-25 Jeff Johnston <jjohnstn@redhat.com>
* libc/sys/linux/sethostname.c: New file.
* libc/sys/linux/Makefile.am: Add sethostname.c support.
* libc/sys/linux/Makefile.in: Regenerated.
2002-06-24 Thomas Fitzsimmons <fitzsim@redhat.com>
* libc/search/db_local.h: New file.

View File

@ -49,6 +49,7 @@ LIB_SOURCES = \
sched.c \
select.c \
seteuid.c \
sethostname.c \
shm_open.c \
shm_unlink.c \
sig.c \
@ -79,19 +80,22 @@ SIGNAL_H = /usr/src/$(shell ls /usr/src/ | grep ^linux | head -n 1)/include/asm/
liblinux_la_LDFLAGS = -Xcompiler -nostdlib
add_objs =
if USE_LIBTOOL
noinst_LTLIBRARIES = liblinux.la
liblinux_la_SOURCES = $(LIB_SOURCES)
liblinux_la_LIBADD = $(LINUX_MACH_LIB)
liblinux_la_LIBADD = $(LINUX_MACH_LIB) $(add_objs)
liblinux_la_DEPENDENCIES = $(LINUX_MACH_LIB) $(add_objs)
noinst_DATA = objectlist.awk.in
else
noinst_LIBRARIES = lib.a
lib_a_SOURCES = $(LIB_SOURCES)
lib_a_LIBADD = $(LINUX_MACH_LIB)
lib_a_DEPENDENCIES = $(LINUX_MACH_LIB)
lib_a_LIBADD = $(LINUX_MACH_LIB) $(add_objs)
lib_a_DEPENDENCIES = $(LINUX_MACH_LIB) $(add_objs)
noinst_DATA =
lib.a: $(LINUX_MACH_LIB) $(lib_a_OBJECTS)
lib.a: $(LINUX_MACH_LIB) $(lib_a_OBJECTS) $(add_objs)
rm -f $@
rm -rf tmp
mkdir tmp

View File

@ -146,6 +146,7 @@ LIB_SOURCES = \
sched.c \
select.c \
seteuid.c \
sethostname.c \
shm_open.c \
shm_unlink.c \
sig.c \
@ -177,15 +178,18 @@ SIGNAL_H = /usr/src/$(shell ls /usr/src/ | grep ^linux | head -n 1)/include/asm/
liblinux_la_LDFLAGS = -Xcompiler -nostdlib
add_objs =
@USE_LIBTOOL_TRUE@noinst_LTLIBRARIES = @USE_LIBTOOL_TRUE@liblinux.la
@USE_LIBTOOL_TRUE@liblinux_la_SOURCES = @USE_LIBTOOL_TRUE@$(LIB_SOURCES)
@USE_LIBTOOL_TRUE@liblinux_la_LIBADD = @USE_LIBTOOL_TRUE@$(LINUX_MACH_LIB)
@USE_LIBTOOL_TRUE@liblinux_la_LIBADD = @USE_LIBTOOL_TRUE@$(LINUX_MACH_LIB) $(add_objs)
@USE_LIBTOOL_TRUE@liblinux_la_DEPENDENCIES = @USE_LIBTOOL_TRUE@$(LINUX_MACH_LIB) $(add_objs)
@USE_LIBTOOL_TRUE@noinst_DATA = @USE_LIBTOOL_TRUE@objectlist.awk.in
@USE_LIBTOOL_FALSE@noinst_DATA =
@USE_LIBTOOL_FALSE@noinst_LIBRARIES = @USE_LIBTOOL_FALSE@lib.a
@USE_LIBTOOL_FALSE@lib_a_SOURCES = @USE_LIBTOOL_FALSE@$(LIB_SOURCES)
@USE_LIBTOOL_FALSE@lib_a_LIBADD = @USE_LIBTOOL_FALSE@$(LINUX_MACH_LIB)
@USE_LIBTOOL_FALSE@lib_a_DEPENDENCIES = @USE_LIBTOOL_FALSE@$(LINUX_MACH_LIB)
@USE_LIBTOOL_FALSE@lib_a_LIBADD = @USE_LIBTOOL_FALSE@$(LINUX_MACH_LIB) $(add_objs)
@USE_LIBTOOL_FALSE@lib_a_DEPENDENCIES = @USE_LIBTOOL_FALSE@$(LINUX_MACH_LIB) $(add_objs)
AM_CFLAGS = -I $(srcdir)/../../stdio
ACLOCAL_AMFLAGS = -I ../../..
@ -216,9 +220,9 @@ LIBS = @LIBS@
@USE_LIBTOOL_FALSE@pwrite64.$(OBJEXT) raise.$(OBJEXT) \
@USE_LIBTOOL_FALSE@realpath.$(OBJEXT) rename.$(OBJEXT) \
@USE_LIBTOOL_FALSE@resource.$(OBJEXT) sched.$(OBJEXT) select.$(OBJEXT) \
@USE_LIBTOOL_FALSE@seteuid.$(OBJEXT) shm_open.$(OBJEXT) \
@USE_LIBTOOL_FALSE@shm_unlink.$(OBJEXT) sig.$(OBJEXT) \
@USE_LIBTOOL_FALSE@sigaction.$(OBJEXT) sigqueue.$(OBJEXT) \
@USE_LIBTOOL_FALSE@seteuid.$(OBJEXT) sethostname.$(OBJEXT) \
@USE_LIBTOOL_FALSE@shm_open.$(OBJEXT) shm_unlink.$(OBJEXT) \
@USE_LIBTOOL_FALSE@sig.$(OBJEXT) sigaction.$(OBJEXT) sigqueue.$(OBJEXT) \
@USE_LIBTOOL_FALSE@signal.$(OBJEXT) siglongjmp.$(OBJEXT) \
@USE_LIBTOOL_FALSE@sigset.$(OBJEXT) sigwait.$(OBJEXT) socket.$(OBJEXT) \
@USE_LIBTOOL_FALSE@sleep.$(OBJEXT) stack.$(OBJEXT) strsignal.$(OBJEXT) \
@ -228,7 +232,6 @@ LIBS = @LIBS@
@USE_LIBTOOL_FALSE@usleep.$(OBJEXT) wait.$(OBJEXT)
LTLIBRARIES = $(noinst_LTLIBRARIES)
@USE_LIBTOOL_TRUE@liblinux_la_DEPENDENCIES =
@USE_LIBTOOL_TRUE@liblinux_la_OBJECTS = brk.lo cfspeed.lo flockfile.lo \
@USE_LIBTOOL_TRUE@ftok.lo funlockfile.lo getdate.lo getdate_err.lo \
@USE_LIBTOOL_TRUE@gethostname.lo getoptlong.lo getreent.lo ids.lo \
@ -238,11 +241,12 @@ LTLIBRARIES = $(noinst_LTLIBRARIES)
@USE_LIBTOOL_TRUE@ntp_gettime.lo pread.lo pread64.lo process.lo \
@USE_LIBTOOL_TRUE@psignal.lo pwrite.lo pwrite64.lo raise.lo realpath.lo \
@USE_LIBTOOL_TRUE@rename.lo resource.lo sched.lo select.lo seteuid.lo \
@USE_LIBTOOL_TRUE@shm_open.lo shm_unlink.lo sig.lo sigaction.lo \
@USE_LIBTOOL_TRUE@sigqueue.lo signal.lo siglongjmp.lo sigset.lo \
@USE_LIBTOOL_TRUE@sigwait.lo socket.lo sleep.lo stack.lo strsignal.lo \
@USE_LIBTOOL_TRUE@sysconf.lo sysctl.lo systat.lo system.lo tcdrain.lo \
@USE_LIBTOOL_TRUE@tcsendbrk.lo termios.lo time.lo usleep.lo wait.lo
@USE_LIBTOOL_TRUE@sethostname.lo shm_open.lo shm_unlink.lo sig.lo \
@USE_LIBTOOL_TRUE@sigaction.lo sigqueue.lo signal.lo siglongjmp.lo \
@USE_LIBTOOL_TRUE@sigset.lo sigwait.lo socket.lo sleep.lo stack.lo \
@USE_LIBTOOL_TRUE@strsignal.lo sysconf.lo sysctl.lo systat.lo system.lo \
@USE_LIBTOOL_TRUE@tcdrain.lo tcsendbrk.lo termios.lo time.lo usleep.lo \
@USE_LIBTOOL_TRUE@wait.lo
CFLAGS = @CFLAGS@
COMPILE = $(CC) $(DEFS) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS)
LTCOMPILE = $(LIBTOOL) --mode=compile $(CC) $(DEFS) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS)
@ -581,7 +585,7 @@ clean-generic maintainer-clean-generic clean mostlyclean distclean \
maintainer-clean
@USE_LIBTOOL_FALSE@lib.a: $(LINUX_MACH_LIB) $(lib_a_OBJECTS)
@USE_LIBTOOL_FALSE@lib.a: $(LINUX_MACH_LIB) $(lib_a_OBJECTS) $(add_objs)
@USE_LIBTOOL_FALSE@ rm -f $@
@USE_LIBTOOL_FALSE@ rm -rf tmp
@USE_LIBTOOL_FALSE@ mkdir tmp

View File

@ -0,0 +1,8 @@
/* libc/sys/linux/sethostname.c - Set host name */
/* Copyright 2002, Red Hat Inc. */
#include <unistd.h>
#include <machine/syscall.h>
_syscall2(int,sethostname,const char *,name,size_t,len);