URL
https://opencores.org/ocsvn/openrisc_me/openrisc_me/trunk
Subversion Repositories openrisc_me
Compare Revisions
- This comparison shows the changes necessary to convert path
/openrisc/trunk/gnu-src/newlib-1.17.0/newlib/libc/argz
- from Rev 148 to Rev 158
- ↔ Reverse comparison
Rev 148 → Rev 158
/argz_replace.c
0,0 → 1,88
/* Copyright (C) 2002 by Red Hat, Incorporated. All rights reserved. |
* |
* Permission to use, copy, modify, and distribute this software |
* is freely granted, provided that this notice is preserved. |
*/ |
|
#include <errno.h> |
#include <sys/types.h> |
#include <string.h> |
#include <stdlib.h> |
#include <argz.h> |
|
#include "buf_findstr.h" |
|
error_t |
_DEFUN (argz_replace, (argz, argz_len, str, with, replace_count), |
char **argz _AND |
size_t *argz_len _AND |
const char *str _AND |
const char *with _AND |
unsigned *replace_count) |
{ |
const int str_len = strlen(str); |
const int with_len = strlen(with); |
const int len_diff = with_len - str_len; |
|
char *buf_iter = *argz; |
size_t buf_len = *argz_len; |
char *last_iter = NULL; |
char *new_argz = NULL; |
size_t new_argz_len = 0; |
char *new_argz_iter = NULL; |
|
*replace_count = 0; |
new_argz_len = *argz_len; |
|
while(buf_len) |
{ |
if(_buf_findstr(str, &buf_iter, &buf_len)) |
{ |
*replace_count += 1; |
new_argz_len += len_diff; |
} |
} |
|
if (*replace_count) |
{ |
new_argz = (char *)malloc(new_argz_len); |
|
buf_iter = *argz; |
buf_len = *argz_len; |
last_iter = buf_iter; |
new_argz_iter = new_argz; |
|
while(buf_len) |
{ |
if (_buf_findstr(str, &buf_iter, &buf_len)) |
{ |
/* copy everything up to, but not including str, from old argz to |
new argz. */ |
memcpy(new_argz_iter, last_iter, buf_iter - last_iter - str_len); |
new_argz_iter += (buf_iter - last_iter - str_len); |
/* copy replacement string. */ |
memcpy(new_argz_iter, with, with_len); |
new_argz_iter += with_len; |
last_iter = buf_iter; |
} |
} |
/* copy everything after last occurrence of str. */ |
memcpy(new_argz_iter, last_iter, *argz + *argz_len - last_iter); |
|
/* reallocate argz, and copy over the new value. */ |
if(!(*argz = (char *)realloc(*argz, new_argz_len))) |
return ENOMEM; |
|
memcpy(*argz, new_argz, new_argz_len); |
*argz_len = new_argz_len; |
|
if (*argz_len == 0) |
{ |
free(*argz); |
*argz = NULL; |
} |
free(new_argz); |
} |
|
return 0; |
} |
argz_replace.c
Property changes :
Added: svn:eol-style
## -0,0 +1 ##
+native
\ No newline at end of property
Added: svn:keywords
## -0,0 +1 ##
+Id
\ No newline at end of property
Index: envz_remove.c
===================================================================
--- envz_remove.c (nonexistent)
+++ envz_remove.c (revision 158)
@@ -0,0 +1,37 @@
+/* Copyright (C) 2002 by Red Hat, Incorporated. All rights reserved.
+ *
+ * Permission to use, copy, modify, and distribute this software
+ * is freely granted, provided that this notice is preserved.
+ */
+
+#include
+#include
+#include
+#include
+#include
+#include
+
+void
+_DEFUN (envz_remove, (envz, envz_len, name),
+ char **envz _AND
+ size_t *envz_len _AND
+ const char *name)
+{
+ char *entry = NULL;
+ int len = 0;
+ entry = envz_entry (*envz, *envz_len, name);
+
+ if (entry)
+ {
+ len = strlen(entry) + 1;
+
+ /* Not the last entry. */
+ if (*envz + *envz_len != entry + len - 1)
+ {
+ memmove(entry, entry + len, *envz + *envz_len - entry - len);
+ }
+
+ *envz = (char *)realloc(*envz, *envz_len - len);
+ *envz_len -= len;
+ }
+}
envz_remove.c
Property changes :
Added: svn:eol-style
## -0,0 +1 ##
+native
\ No newline at end of property
Added: svn:keywords
## -0,0 +1 ##
+Id
\ No newline at end of property
Index: envz_merge.c
===================================================================
--- envz_merge.c (nonexistent)
+++ envz_merge.c (revision 158)
@@ -0,0 +1,61 @@
+/* Copyright (C) 2002 by Red Hat, Incorporated. All rights reserved.
+ *
+ * Permission to use, copy, modify, and distribute this software
+ * is freely granted, provided that this notice is preserved.
+ */
+
+#include
+#include
+#include
+#include
+#include
+#include
+
+error_t
+_DEFUN (envz_merge, (envz, envz_len, envz2, envz2_len, override),
+ char **envz _AND
+ size_t *envz_len _AND
+ const char *envz2 _AND
+ size_t envz2_len _AND
+ int override)
+{
+ char *entry = NULL;
+ char *name_str = NULL;
+ char *val_str = NULL;
+ char *name_iter = NULL;
+ int retval = 0;
+
+ while((entry = argz_next((char *)envz2, envz2_len, entry)) && !retval)
+ {
+ if (!override)
+ {
+ name_str = strdup (entry);
+ name_iter = strchr(name_str, '=');
+ if(name_iter)
+ *name_iter = '\0';
+
+ if(!envz_entry(*envz, *envz_len, name_str))
+ {
+ retval = argz_add(envz, envz_len, entry);
+ }
+ free(name_str);
+ }
+ else
+ {
+ name_str = strdup (entry);
+ name_iter = strchr(name_str, '=');
+ if(name_iter)
+ {
+ *name_iter = '\0';
+ val_str = name_iter + 1;
+ }
+ else
+ {
+ val_str = NULL;
+ }
+
+ retval = envz_add(envz, envz_len, name_str, val_str);
+ }
+ }
+ return retval;
+}
envz_merge.c
Property changes :
Added: svn:eol-style
## -0,0 +1 ##
+native
\ No newline at end of property
Added: svn:keywords
## -0,0 +1 ##
+Id
\ No newline at end of property
Index: Makefile.in
===================================================================
--- Makefile.in (nonexistent)
+++ Makefile.in (revision 158)
@@ -0,0 +1,664 @@
+# Makefile.in generated by automake 1.9.6 from Makefile.am.
+# @configure_input@
+
+# Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002,
+# 2003, 2004, 2005 Free Software Foundation, Inc.
+# This Makefile.in is free software; the Free Software Foundation
+# gives unlimited permission to copy and/or distribute it,
+# with or without modifications, as long as this notice is preserved.
+
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY, to the extent permitted by law; without
+# even the implied warranty of MERCHANTABILITY or FITNESS FOR A
+# PARTICULAR PURPOSE.
+
+@SET_MAKE@
+
+
+
+srcdir = @srcdir@
+top_srcdir = @top_srcdir@
+VPATH = @srcdir@
+pkgdatadir = $(datadir)/@PACKAGE@
+pkglibdir = $(libdir)/@PACKAGE@
+pkgincludedir = $(includedir)/@PACKAGE@
+top_builddir = ..
+am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd
+INSTALL = @INSTALL@
+install_sh_DATA = $(install_sh) -c -m 644
+install_sh_PROGRAM = $(install_sh) -c
+install_sh_SCRIPT = $(install_sh) -c
+INSTALL_HEADER = $(INSTALL_DATA)
+transform = $(program_transform_name)
+NORMAL_INSTALL = :
+PRE_INSTALL = :
+POST_INSTALL = :
+NORMAL_UNINSTALL = :
+PRE_UNINSTALL = :
+POST_UNINSTALL = :
+build_triplet = @build@
+host_triplet = @host@
+DIST_COMMON = $(srcdir)/../../Makefile.shared $(srcdir)/Makefile.in \
+ $(srcdir)/Makefile.am
+subdir = argz
+ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
+am__aclocal_m4_deps = $(top_srcdir)/../../libtool.m4 \
+ $(top_srcdir)/../../ltoptions.m4 \
+ $(top_srcdir)/../../ltsugar.m4 \
+ $(top_srcdir)/../../ltversion.m4 \
+ $(top_srcdir)/../../lt~obsolete.m4 \
+ $(top_srcdir)/../acinclude.m4 $(top_srcdir)/../confsubdir.m4 \
+ $(top_srcdir)/configure.in
+am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
+ $(ACLOCAL_M4)
+mkinstalldirs = $(SHELL) $(top_srcdir)/../../mkinstalldirs
+CONFIG_CLEAN_FILES =
+LIBRARIES = $(noinst_LIBRARIES)
+ARFLAGS = cru
+lib_a_AR = $(AR) $(ARFLAGS)
+lib_a_LIBADD =
+@ELIX_LEVEL_1_FALSE@am__objects_1 = lib_a-argz_add.$(OBJEXT) \
+@ELIX_LEVEL_1_FALSE@ lib_a-argz_add_sep.$(OBJEXT) \
+@ELIX_LEVEL_1_FALSE@ lib_a-argz_append.$(OBJEXT) \
+@ELIX_LEVEL_1_FALSE@ lib_a-argz_count.$(OBJEXT) \
+@ELIX_LEVEL_1_FALSE@ lib_a-argz_create.$(OBJEXT) \
+@ELIX_LEVEL_1_FALSE@ lib_a-argz_create_sep.$(OBJEXT) \
+@ELIX_LEVEL_1_FALSE@ lib_a-argz_delete.$(OBJEXT) \
+@ELIX_LEVEL_1_FALSE@ lib_a-argz_extract.$(OBJEXT) \
+@ELIX_LEVEL_1_FALSE@ lib_a-argz_insert.$(OBJEXT) \
+@ELIX_LEVEL_1_FALSE@ lib_a-argz_next.$(OBJEXT) \
+@ELIX_LEVEL_1_FALSE@ lib_a-argz_replace.$(OBJEXT) \
+@ELIX_LEVEL_1_FALSE@ lib_a-argz_stringify.$(OBJEXT) \
+@ELIX_LEVEL_1_FALSE@ lib_a-buf_findstr.$(OBJEXT) \
+@ELIX_LEVEL_1_FALSE@ lib_a-envz_entry.$(OBJEXT) \
+@ELIX_LEVEL_1_FALSE@ lib_a-envz_get.$(OBJEXT) \
+@ELIX_LEVEL_1_FALSE@ lib_a-envz_add.$(OBJEXT) \
+@ELIX_LEVEL_1_FALSE@ lib_a-envz_remove.$(OBJEXT) \
+@ELIX_LEVEL_1_FALSE@ lib_a-envz_merge.$(OBJEXT) \
+@ELIX_LEVEL_1_FALSE@ lib_a-envz_strip.$(OBJEXT)
+@USE_LIBTOOL_FALSE@am_lib_a_OBJECTS = lib_a-dummy.$(OBJEXT) \
+@USE_LIBTOOL_FALSE@ $(am__objects_1)
+lib_a_OBJECTS = $(am_lib_a_OBJECTS)
+LTLIBRARIES = $(noinst_LTLIBRARIES)
+libargz_la_LIBADD =
+@ELIX_LEVEL_1_FALSE@am__objects_2 = argz_add.lo argz_add_sep.lo \
+@ELIX_LEVEL_1_FALSE@ argz_append.lo argz_count.lo \
+@ELIX_LEVEL_1_FALSE@ argz_create.lo argz_create_sep.lo \
+@ELIX_LEVEL_1_FALSE@ argz_delete.lo argz_extract.lo \
+@ELIX_LEVEL_1_FALSE@ argz_insert.lo argz_next.lo \
+@ELIX_LEVEL_1_FALSE@ argz_replace.lo argz_stringify.lo \
+@ELIX_LEVEL_1_FALSE@ buf_findstr.lo envz_entry.lo envz_get.lo \
+@ELIX_LEVEL_1_FALSE@ envz_add.lo envz_remove.lo envz_merge.lo \
+@ELIX_LEVEL_1_FALSE@ envz_strip.lo
+@USE_LIBTOOL_TRUE@am_libargz_la_OBJECTS = dummy.lo $(am__objects_2)
+libargz_la_OBJECTS = $(am_libargz_la_OBJECTS)
+@USE_LIBTOOL_TRUE@am_libargz_la_rpath =
+DEFAULT_INCLUDES = -I. -I$(srcdir)
+depcomp =
+am__depfiles_maybe =
+COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \
+ $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS)
+LTCOMPILE = $(LIBTOOL) --tag=CC --mode=compile $(CC) $(DEFS) \
+ $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) \
+ $(AM_CFLAGS) $(CFLAGS)
+CCLD = $(CC)
+LINK = $(LIBTOOL) --tag=CC --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \
+ $(AM_LDFLAGS) $(LDFLAGS) -o $@
+SOURCES = $(lib_a_SOURCES) $(libargz_la_SOURCES)
+DATA = $(noinst_DATA)
+ETAGS = etags
+CTAGS = ctags
+ACLOCAL = @ACLOCAL@
+AMDEP_FALSE = @AMDEP_FALSE@
+AMDEP_TRUE = @AMDEP_TRUE@
+AMTAR = @AMTAR@
+AR = @AR@
+AS = @AS@
+AUTOCONF = @AUTOCONF@
+AUTOHEADER = @AUTOHEADER@
+AUTOMAKE = @AUTOMAKE@
+AWK = @AWK@
+CC = @CC@
+CCAS = @CCAS@
+CCASFLAGS = @CCASFLAGS@
+CCDEPMODE = @CCDEPMODE@
+CFLAGS = @CFLAGS@
+CPP = @CPP@
+CPPFLAGS = @CPPFLAGS@
+CRT0 = @CRT0@
+CYGPATH_W = @CYGPATH_W@
+DEFS = @DEFS@
+DEPDIR = @DEPDIR@
+DLLTOOL = @DLLTOOL@
+DSYMUTIL = @DSYMUTIL@
+DUMPBIN = @DUMPBIN@
+ECHO_C = @ECHO_C@
+ECHO_N = @ECHO_N@
+ECHO_T = @ECHO_T@
+EGREP = @EGREP@
+ELIX_LEVEL_0_FALSE = @ELIX_LEVEL_0_FALSE@
+ELIX_LEVEL_0_TRUE = @ELIX_LEVEL_0_TRUE@
+ELIX_LEVEL_1_FALSE = @ELIX_LEVEL_1_FALSE@
+ELIX_LEVEL_1_TRUE = @ELIX_LEVEL_1_TRUE@
+ELIX_LEVEL_2_FALSE = @ELIX_LEVEL_2_FALSE@
+ELIX_LEVEL_2_TRUE = @ELIX_LEVEL_2_TRUE@
+ELIX_LEVEL_3_FALSE = @ELIX_LEVEL_3_FALSE@
+ELIX_LEVEL_3_TRUE = @ELIX_LEVEL_3_TRUE@
+ELIX_LEVEL_4_FALSE = @ELIX_LEVEL_4_FALSE@
+ELIX_LEVEL_4_TRUE = @ELIX_LEVEL_4_TRUE@
+ENABLE_NEWLIB_ICONV_FALSE = @ENABLE_NEWLIB_ICONV_FALSE@
+ENABLE_NEWLIB_ICONV_TRUE = @ENABLE_NEWLIB_ICONV_TRUE@
+EXEEXT = @EXEEXT@
+FGREP = @FGREP@
+GREP = @GREP@
+HAVE_POSIX_DIR_FALSE = @HAVE_POSIX_DIR_FALSE@
+HAVE_POSIX_DIR_TRUE = @HAVE_POSIX_DIR_TRUE@
+HAVE_SIGNAL_DIR_FALSE = @HAVE_SIGNAL_DIR_FALSE@
+HAVE_SIGNAL_DIR_TRUE = @HAVE_SIGNAL_DIR_TRUE@
+HAVE_STDIO64_DIR_FALSE = @HAVE_STDIO64_DIR_FALSE@
+HAVE_STDIO64_DIR_TRUE = @HAVE_STDIO64_DIR_TRUE@
+HAVE_STDIO_DIR_FALSE = @HAVE_STDIO_DIR_FALSE@
+HAVE_STDIO_DIR_TRUE = @HAVE_STDIO_DIR_TRUE@
+HAVE_SYSCALL_DIR_FALSE = @HAVE_SYSCALL_DIR_FALSE@
+HAVE_SYSCALL_DIR_TRUE = @HAVE_SYSCALL_DIR_TRUE@
+HAVE_UNIX_DIR_FALSE = @HAVE_UNIX_DIR_FALSE@
+HAVE_UNIX_DIR_TRUE = @HAVE_UNIX_DIR_TRUE@
+INSTALL_DATA = @INSTALL_DATA@
+INSTALL_PROGRAM = @INSTALL_PROGRAM@
+INSTALL_SCRIPT = @INSTALL_SCRIPT@
+INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@
+LD = @LD@
+LDFLAGS = @LDFLAGS@
+LIBC_EXTRA_DEF = @LIBC_EXTRA_DEF@
+LIBC_EXTRA_LIB = @LIBC_EXTRA_LIB@
+LIBC_MACHINE_LIB = @LIBC_MACHINE_LIB@
+LIBC_POSIX_LIB = @LIBC_POSIX_LIB@
+LIBC_SIGNAL_DEF = @LIBC_SIGNAL_DEF@
+LIBC_SIGNAL_LIB = @LIBC_SIGNAL_LIB@
+LIBC_STDIO64_DEF = @LIBC_STDIO64_DEF@
+LIBC_STDIO64_LIB = @LIBC_STDIO64_LIB@
+LIBC_STDIO_DEF = @LIBC_STDIO_DEF@
+LIBC_STDIO_LIB = @LIBC_STDIO_LIB@
+LIBC_SYSCALL_LIB = @LIBC_SYSCALL_LIB@
+LIBC_SYS_LIB = @LIBC_SYS_LIB@
+LIBC_UNIX_LIB = @LIBC_UNIX_LIB@
+LIBOBJS = @LIBOBJS@
+LIBS = @LIBS@
+LIBTOOL = @LIBTOOL@
+LIPO = @LIPO@
+LN_S = @LN_S@
+LTLIBOBJS = @LTLIBOBJS@
+MAINT = @MAINT@
+MAINTAINER_MODE_FALSE = @MAINTAINER_MODE_FALSE@
+MAINTAINER_MODE_TRUE = @MAINTAINER_MODE_TRUE@
+MAKEINFO = @MAKEINFO@
+MAY_SUPPLY_SYSCALLS_FALSE = @MAY_SUPPLY_SYSCALLS_FALSE@
+MAY_SUPPLY_SYSCALLS_TRUE = @MAY_SUPPLY_SYSCALLS_TRUE@
+NEWLIB_CFLAGS = @NEWLIB_CFLAGS@
+NM = @NM@
+NMEDIT = @NMEDIT@
+OBJDUMP = @OBJDUMP@
+OBJEXT = @OBJEXT@
+OTOOL = @OTOOL@
+OTOOL64 = @OTOOL64@
+PACKAGE = @PACKAGE@
+PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@
+PACKAGE_NAME = @PACKAGE_NAME@
+PACKAGE_STRING = @PACKAGE_STRING@
+PACKAGE_TARNAME = @PACKAGE_TARNAME@
+PACKAGE_VERSION = @PACKAGE_VERSION@
+PATH_SEPARATOR = @PATH_SEPARATOR@
+RANLIB = @RANLIB@
+READELF = @READELF@
+SED = @SED@
+SET_MAKE = @SET_MAKE@
+SHELL = @SHELL@
+STRIP = @STRIP@
+USE_LIBTOOL_FALSE = @USE_LIBTOOL_FALSE@
+USE_LIBTOOL_TRUE = @USE_LIBTOOL_TRUE@
+VERSION = @VERSION@
+ac_ct_AR = @ac_ct_AR@
+ac_ct_AS = @ac_ct_AS@
+ac_ct_CC = @ac_ct_CC@
+ac_ct_DLLTOOL = @ac_ct_DLLTOOL@
+ac_ct_DSYMUTIL = @ac_ct_DSYMUTIL@
+ac_ct_DUMPBIN = @ac_ct_DUMPBIN@
+ac_ct_LIPO = @ac_ct_LIPO@
+ac_ct_NMEDIT = @ac_ct_NMEDIT@
+ac_ct_OBJDUMP = @ac_ct_OBJDUMP@
+ac_ct_OTOOL = @ac_ct_OTOOL@
+ac_ct_OTOOL64 = @ac_ct_OTOOL64@
+ac_ct_RANLIB = @ac_ct_RANLIB@
+ac_ct_READELF = @ac_ct_READELF@
+ac_ct_STRIP = @ac_ct_STRIP@
+aext = @aext@
+am__fastdepCC_FALSE = @am__fastdepCC_FALSE@
+am__fastdepCC_TRUE = @am__fastdepCC_TRUE@
+am__include = @am__include@
+am__leading_dot = @am__leading_dot@
+am__quote = @am__quote@
+am__tar = @am__tar@
+am__untar = @am__untar@
+bindir = @bindir@
+build = @build@
+build_alias = @build_alias@
+build_cpu = @build_cpu@
+build_os = @build_os@
+build_vendor = @build_vendor@
+datadir = @datadir@
+exec_prefix = @exec_prefix@
+extra_dir = @extra_dir@
+host = @host@
+host_alias = @host_alias@
+host_cpu = @host_cpu@
+host_os = @host_os@
+host_vendor = @host_vendor@
+includedir = @includedir@
+infodir = @infodir@
+install_sh = @install_sh@
+libdir = @libdir@
+libexecdir = @libexecdir@
+libm_machine_dir = @libm_machine_dir@
+localstatedir = @localstatedir@
+lpfx = @lpfx@
+lt_ECHO = @lt_ECHO@
+machine_dir = @machine_dir@
+mandir = @mandir@
+mkdir_p = @mkdir_p@
+newlib_basedir = @newlib_basedir@
+oext = @oext@
+oldincludedir = @oldincludedir@
+prefix = @prefix@
+program_transform_name = @program_transform_name@
+sbindir = @sbindir@
+sharedstatedir = @sharedstatedir@
+subdirs = @subdirs@
+sys_dir = @sys_dir@
+sysconfdir = @sysconfdir@
+target_alias = @target_alias@
+AUTOMAKE_OPTIONS = cygnus
+INCLUDES = $(NEWLIB_CFLAGS) $(CROSS_CFLAGS) $(TARGET_CFLAGS)
+@ELIX_LEVEL_1_FALSE@ELIX_SOURCES = \
+@ELIX_LEVEL_1_FALSE@ argz_add.c \
+@ELIX_LEVEL_1_FALSE@ argz_add_sep.c \
+@ELIX_LEVEL_1_FALSE@ argz_append.c \
+@ELIX_LEVEL_1_FALSE@ argz_count.c \
+@ELIX_LEVEL_1_FALSE@ argz_create.c \
+@ELIX_LEVEL_1_FALSE@ argz_create_sep.c \
+@ELIX_LEVEL_1_FALSE@ argz_delete.c \
+@ELIX_LEVEL_1_FALSE@ argz_extract.c \
+@ELIX_LEVEL_1_FALSE@ argz_insert.c \
+@ELIX_LEVEL_1_FALSE@ argz_next.c \
+@ELIX_LEVEL_1_FALSE@ argz_replace.c \
+@ELIX_LEVEL_1_FALSE@ argz_stringify.c \
+@ELIX_LEVEL_1_FALSE@ buf_findstr.c \
+@ELIX_LEVEL_1_FALSE@ envz_entry.c \
+@ELIX_LEVEL_1_FALSE@ envz_get.c \
+@ELIX_LEVEL_1_FALSE@ envz_add.c \
+@ELIX_LEVEL_1_FALSE@ envz_remove.c \
+@ELIX_LEVEL_1_FALSE@ envz_merge.c \
+@ELIX_LEVEL_1_FALSE@ envz_strip.c
+
+@ELIX_LEVEL_1_TRUE@ELIX_SOURCES =
+libargz_la_LDFLAGS = -Xcompiler -nostdlib
+@USE_LIBTOOL_TRUE@noinst_LTLIBRARIES = libargz.la
+@USE_LIBTOOL_TRUE@libargz_la_SOURCES = dummy.c $(ELIX_SOURCES)
+@USE_LIBTOOL_FALSE@noinst_DATA =
+@USE_LIBTOOL_TRUE@noinst_DATA = objectlist.awk.in
+@USE_LIBTOOL_FALSE@noinst_LIBRARIES = lib.a
+@USE_LIBTOOL_FALSE@lib_a_SOURCES = dummy.c $(ELIX_SOURCES)
+@USE_LIBTOOL_FALSE@lib_a_CFLAGS = $(AM_CFLAGS)
+SUFFIXES = .def
+CHEWOUT_FILES =
+CHEW = ../../doc/makedoc -f $(srcdir)/../../doc/doc.str
+TARGETDOC = ../tmp.texi
+CLEANFILES = $(CHEWOUT_FILES) *.ref
+all: all-am
+
+.SUFFIXES:
+.SUFFIXES: .def .c .lo .o .obj
+$(srcdir)/Makefile.in: @MAINTAINER_MODE_TRUE@ $(srcdir)/Makefile.am $(srcdir)/../../Makefile.shared $(am__configure_deps)
+ @for dep in $?; do \
+ case '$(am__configure_deps)' in \
+ *$$dep*) \
+ cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh \
+ && exit 0; \
+ exit 1;; \
+ esac; \
+ done; \
+ echo ' cd $(top_srcdir) && $(AUTOMAKE) --cygnus argz/Makefile'; \
+ cd $(top_srcdir) && \
+ $(AUTOMAKE) --cygnus argz/Makefile
+.PRECIOUS: Makefile
+Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
+ @case '$?' in \
+ *config.status*) \
+ cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \
+ *) \
+ echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe)'; \
+ cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe);; \
+ esac;
+
+$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES)
+ cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
+
+$(top_srcdir)/configure: @MAINTAINER_MODE_TRUE@ $(am__configure_deps)
+ cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
+$(ACLOCAL_M4): @MAINTAINER_MODE_TRUE@ $(am__aclocal_m4_deps)
+ cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
+
+clean-noinstLIBRARIES:
+ -test -z "$(noinst_LIBRARIES)" || rm -f $(noinst_LIBRARIES)
+lib.a: $(lib_a_OBJECTS) $(lib_a_DEPENDENCIES)
+ -rm -f lib.a
+ $(lib_a_AR) lib.a $(lib_a_OBJECTS) $(lib_a_LIBADD)
+ $(RANLIB) lib.a
+
+clean-noinstLTLIBRARIES:
+ -test -z "$(noinst_LTLIBRARIES)" || rm -f $(noinst_LTLIBRARIES)
+ @list='$(noinst_LTLIBRARIES)'; for p in $$list; do \
+ dir="`echo $$p | sed -e 's|/[^/]*$$||'`"; \
+ test "$$dir" != "$$p" || dir=.; \
+ echo "rm -f \"$${dir}/so_locations\""; \
+ rm -f "$${dir}/so_locations"; \
+ done
+libargz.la: $(libargz_la_OBJECTS) $(libargz_la_DEPENDENCIES)
+ $(LINK) $(am_libargz_la_rpath) $(libargz_la_LDFLAGS) $(libargz_la_OBJECTS) $(libargz_la_LIBADD) $(LIBS)
+
+mostlyclean-compile:
+ -rm -f *.$(OBJEXT)
+
+distclean-compile:
+ -rm -f *.tab.c
+
+.c.o:
+ $(COMPILE) -c $<
+
+.c.obj:
+ $(COMPILE) -c `$(CYGPATH_W) '$<'`
+
+.c.lo:
+ $(LTCOMPILE) -c -o $@ $<
+
+lib_a-dummy.o: dummy.c
+ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lib_a_CFLAGS) $(CFLAGS) -c -o lib_a-dummy.o `test -f 'dummy.c' || echo '$(srcdir)/'`dummy.c
+
+lib_a-dummy.obj: dummy.c
+ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lib_a_CFLAGS) $(CFLAGS) -c -o lib_a-dummy.obj `if test -f 'dummy.c'; then $(CYGPATH_W) 'dummy.c'; else $(CYGPATH_W) '$(srcdir)/dummy.c'; fi`
+
+lib_a-argz_add.o: argz_add.c
+ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lib_a_CFLAGS) $(CFLAGS) -c -o lib_a-argz_add.o `test -f 'argz_add.c' || echo '$(srcdir)/'`argz_add.c
+
+lib_a-argz_add.obj: argz_add.c
+ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lib_a_CFLAGS) $(CFLAGS) -c -o lib_a-argz_add.obj `if test -f 'argz_add.c'; then $(CYGPATH_W) 'argz_add.c'; else $(CYGPATH_W) '$(srcdir)/argz_add.c'; fi`
+
+lib_a-argz_add_sep.o: argz_add_sep.c
+ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lib_a_CFLAGS) $(CFLAGS) -c -o lib_a-argz_add_sep.o `test -f 'argz_add_sep.c' || echo '$(srcdir)/'`argz_add_sep.c
+
+lib_a-argz_add_sep.obj: argz_add_sep.c
+ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lib_a_CFLAGS) $(CFLAGS) -c -o lib_a-argz_add_sep.obj `if test -f 'argz_add_sep.c'; then $(CYGPATH_W) 'argz_add_sep.c'; else $(CYGPATH_W) '$(srcdir)/argz_add_sep.c'; fi`
+
+lib_a-argz_append.o: argz_append.c
+ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lib_a_CFLAGS) $(CFLAGS) -c -o lib_a-argz_append.o `test -f 'argz_append.c' || echo '$(srcdir)/'`argz_append.c
+
+lib_a-argz_append.obj: argz_append.c
+ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lib_a_CFLAGS) $(CFLAGS) -c -o lib_a-argz_append.obj `if test -f 'argz_append.c'; then $(CYGPATH_W) 'argz_append.c'; else $(CYGPATH_W) '$(srcdir)/argz_append.c'; fi`
+
+lib_a-argz_count.o: argz_count.c
+ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lib_a_CFLAGS) $(CFLAGS) -c -o lib_a-argz_count.o `test -f 'argz_count.c' || echo '$(srcdir)/'`argz_count.c
+
+lib_a-argz_count.obj: argz_count.c
+ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lib_a_CFLAGS) $(CFLAGS) -c -o lib_a-argz_count.obj `if test -f 'argz_count.c'; then $(CYGPATH_W) 'argz_count.c'; else $(CYGPATH_W) '$(srcdir)/argz_count.c'; fi`
+
+lib_a-argz_create.o: argz_create.c
+ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lib_a_CFLAGS) $(CFLAGS) -c -o lib_a-argz_create.o `test -f 'argz_create.c' || echo '$(srcdir)/'`argz_create.c
+
+lib_a-argz_create.obj: argz_create.c
+ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lib_a_CFLAGS) $(CFLAGS) -c -o lib_a-argz_create.obj `if test -f 'argz_create.c'; then $(CYGPATH_W) 'argz_create.c'; else $(CYGPATH_W) '$(srcdir)/argz_create.c'; fi`
+
+lib_a-argz_create_sep.o: argz_create_sep.c
+ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lib_a_CFLAGS) $(CFLAGS) -c -o lib_a-argz_create_sep.o `test -f 'argz_create_sep.c' || echo '$(srcdir)/'`argz_create_sep.c
+
+lib_a-argz_create_sep.obj: argz_create_sep.c
+ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lib_a_CFLAGS) $(CFLAGS) -c -o lib_a-argz_create_sep.obj `if test -f 'argz_create_sep.c'; then $(CYGPATH_W) 'argz_create_sep.c'; else $(CYGPATH_W) '$(srcdir)/argz_create_sep.c'; fi`
+
+lib_a-argz_delete.o: argz_delete.c
+ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lib_a_CFLAGS) $(CFLAGS) -c -o lib_a-argz_delete.o `test -f 'argz_delete.c' || echo '$(srcdir)/'`argz_delete.c
+
+lib_a-argz_delete.obj: argz_delete.c
+ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lib_a_CFLAGS) $(CFLAGS) -c -o lib_a-argz_delete.obj `if test -f 'argz_delete.c'; then $(CYGPATH_W) 'argz_delete.c'; else $(CYGPATH_W) '$(srcdir)/argz_delete.c'; fi`
+
+lib_a-argz_extract.o: argz_extract.c
+ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lib_a_CFLAGS) $(CFLAGS) -c -o lib_a-argz_extract.o `test -f 'argz_extract.c' || echo '$(srcdir)/'`argz_extract.c
+
+lib_a-argz_extract.obj: argz_extract.c
+ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lib_a_CFLAGS) $(CFLAGS) -c -o lib_a-argz_extract.obj `if test -f 'argz_extract.c'; then $(CYGPATH_W) 'argz_extract.c'; else $(CYGPATH_W) '$(srcdir)/argz_extract.c'; fi`
+
+lib_a-argz_insert.o: argz_insert.c
+ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lib_a_CFLAGS) $(CFLAGS) -c -o lib_a-argz_insert.o `test -f 'argz_insert.c' || echo '$(srcdir)/'`argz_insert.c
+
+lib_a-argz_insert.obj: argz_insert.c
+ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lib_a_CFLAGS) $(CFLAGS) -c -o lib_a-argz_insert.obj `if test -f 'argz_insert.c'; then $(CYGPATH_W) 'argz_insert.c'; else $(CYGPATH_W) '$(srcdir)/argz_insert.c'; fi`
+
+lib_a-argz_next.o: argz_next.c
+ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lib_a_CFLAGS) $(CFLAGS) -c -o lib_a-argz_next.o `test -f 'argz_next.c' || echo '$(srcdir)/'`argz_next.c
+
+lib_a-argz_next.obj: argz_next.c
+ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lib_a_CFLAGS) $(CFLAGS) -c -o lib_a-argz_next.obj `if test -f 'argz_next.c'; then $(CYGPATH_W) 'argz_next.c'; else $(CYGPATH_W) '$(srcdir)/argz_next.c'; fi`
+
+lib_a-argz_replace.o: argz_replace.c
+ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lib_a_CFLAGS) $(CFLAGS) -c -o lib_a-argz_replace.o `test -f 'argz_replace.c' || echo '$(srcdir)/'`argz_replace.c
+
+lib_a-argz_replace.obj: argz_replace.c
+ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lib_a_CFLAGS) $(CFLAGS) -c -o lib_a-argz_replace.obj `if test -f 'argz_replace.c'; then $(CYGPATH_W) 'argz_replace.c'; else $(CYGPATH_W) '$(srcdir)/argz_replace.c'; fi`
+
+lib_a-argz_stringify.o: argz_stringify.c
+ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lib_a_CFLAGS) $(CFLAGS) -c -o lib_a-argz_stringify.o `test -f 'argz_stringify.c' || echo '$(srcdir)/'`argz_stringify.c
+
+lib_a-argz_stringify.obj: argz_stringify.c
+ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lib_a_CFLAGS) $(CFLAGS) -c -o lib_a-argz_stringify.obj `if test -f 'argz_stringify.c'; then $(CYGPATH_W) 'argz_stringify.c'; else $(CYGPATH_W) '$(srcdir)/argz_stringify.c'; fi`
+
+lib_a-buf_findstr.o: buf_findstr.c
+ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lib_a_CFLAGS) $(CFLAGS) -c -o lib_a-buf_findstr.o `test -f 'buf_findstr.c' || echo '$(srcdir)/'`buf_findstr.c
+
+lib_a-buf_findstr.obj: buf_findstr.c
+ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lib_a_CFLAGS) $(CFLAGS) -c -o lib_a-buf_findstr.obj `if test -f 'buf_findstr.c'; then $(CYGPATH_W) 'buf_findstr.c'; else $(CYGPATH_W) '$(srcdir)/buf_findstr.c'; fi`
+
+lib_a-envz_entry.o: envz_entry.c
+ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lib_a_CFLAGS) $(CFLAGS) -c -o lib_a-envz_entry.o `test -f 'envz_entry.c' || echo '$(srcdir)/'`envz_entry.c
+
+lib_a-envz_entry.obj: envz_entry.c
+ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lib_a_CFLAGS) $(CFLAGS) -c -o lib_a-envz_entry.obj `if test -f 'envz_entry.c'; then $(CYGPATH_W) 'envz_entry.c'; else $(CYGPATH_W) '$(srcdir)/envz_entry.c'; fi`
+
+lib_a-envz_get.o: envz_get.c
+ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lib_a_CFLAGS) $(CFLAGS) -c -o lib_a-envz_get.o `test -f 'envz_get.c' || echo '$(srcdir)/'`envz_get.c
+
+lib_a-envz_get.obj: envz_get.c
+ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lib_a_CFLAGS) $(CFLAGS) -c -o lib_a-envz_get.obj `if test -f 'envz_get.c'; then $(CYGPATH_W) 'envz_get.c'; else $(CYGPATH_W) '$(srcdir)/envz_get.c'; fi`
+
+lib_a-envz_add.o: envz_add.c
+ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lib_a_CFLAGS) $(CFLAGS) -c -o lib_a-envz_add.o `test -f 'envz_add.c' || echo '$(srcdir)/'`envz_add.c
+
+lib_a-envz_add.obj: envz_add.c
+ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lib_a_CFLAGS) $(CFLAGS) -c -o lib_a-envz_add.obj `if test -f 'envz_add.c'; then $(CYGPATH_W) 'envz_add.c'; else $(CYGPATH_W) '$(srcdir)/envz_add.c'; fi`
+
+lib_a-envz_remove.o: envz_remove.c
+ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lib_a_CFLAGS) $(CFLAGS) -c -o lib_a-envz_remove.o `test -f 'envz_remove.c' || echo '$(srcdir)/'`envz_remove.c
+
+lib_a-envz_remove.obj: envz_remove.c
+ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lib_a_CFLAGS) $(CFLAGS) -c -o lib_a-envz_remove.obj `if test -f 'envz_remove.c'; then $(CYGPATH_W) 'envz_remove.c'; else $(CYGPATH_W) '$(srcdir)/envz_remove.c'; fi`
+
+lib_a-envz_merge.o: envz_merge.c
+ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lib_a_CFLAGS) $(CFLAGS) -c -o lib_a-envz_merge.o `test -f 'envz_merge.c' || echo '$(srcdir)/'`envz_merge.c
+
+lib_a-envz_merge.obj: envz_merge.c
+ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lib_a_CFLAGS) $(CFLAGS) -c -o lib_a-envz_merge.obj `if test -f 'envz_merge.c'; then $(CYGPATH_W) 'envz_merge.c'; else $(CYGPATH_W) '$(srcdir)/envz_merge.c'; fi`
+
+lib_a-envz_strip.o: envz_strip.c
+ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lib_a_CFLAGS) $(CFLAGS) -c -o lib_a-envz_strip.o `test -f 'envz_strip.c' || echo '$(srcdir)/'`envz_strip.c
+
+lib_a-envz_strip.obj: envz_strip.c
+ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lib_a_CFLAGS) $(CFLAGS) -c -o lib_a-envz_strip.obj `if test -f 'envz_strip.c'; then $(CYGPATH_W) 'envz_strip.c'; else $(CYGPATH_W) '$(srcdir)/envz_strip.c'; fi`
+
+mostlyclean-libtool:
+ -rm -f *.lo
+
+clean-libtool:
+ -rm -rf .libs _libs
+
+distclean-libtool:
+ -rm -f libtool
+uninstall-info-am:
+
+ID: $(HEADERS) $(SOURCES) $(LISP) $(TAGS_FILES)
+ list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \
+ unique=`for i in $$list; do \
+ if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
+ done | \
+ $(AWK) ' { files[$$0] = 1; } \
+ END { for (i in files) print i; }'`; \
+ mkid -fID $$unique
+tags: TAGS
+
+TAGS: $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) \
+ $(TAGS_FILES) $(LISP)
+ tags=; \
+ here=`pwd`; \
+ list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \
+ unique=`for i in $$list; do \
+ if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
+ done | \
+ $(AWK) ' { files[$$0] = 1; } \
+ END { for (i in files) print i; }'`; \
+ if test -z "$(ETAGS_ARGS)$$tags$$unique"; then :; else \
+ test -n "$$unique" || unique=$$empty_fix; \
+ $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
+ $$tags $$unique; \
+ fi
+ctags: CTAGS
+CTAGS: $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) \
+ $(TAGS_FILES) $(LISP)
+ tags=; \
+ here=`pwd`; \
+ list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \
+ unique=`for i in $$list; do \
+ if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
+ done | \
+ $(AWK) ' { files[$$0] = 1; } \
+ END { for (i in files) print i; }'`; \
+ test -z "$(CTAGS_ARGS)$$tags$$unique" \
+ || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \
+ $$tags $$unique
+
+GTAGS:
+ here=`$(am__cd) $(top_builddir) && pwd` \
+ && cd $(top_srcdir) \
+ && gtags -i $(GTAGS_ARGS) $$here
+
+distclean-tags:
+ -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
+check-am:
+check: check-am
+all-am: Makefile $(LIBRARIES) $(LTLIBRARIES) $(DATA)
+installdirs:
+install: install-am
+install-exec: install-exec-am
+install-data: install-data-am
+uninstall: uninstall-am
+
+install-am: all-am
+ @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am
+
+installcheck: installcheck-am
+install-strip:
+ $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
+ install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
+ `test -z '$(STRIP)' || \
+ echo "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'"` install
+mostlyclean-generic:
+
+clean-generic:
+ -test -z "$(CLEANFILES)" || rm -f $(CLEANFILES)
+
+distclean-generic:
+ -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES)
+
+maintainer-clean-generic:
+ @echo "This command is intended for maintainers to use"
+ @echo "it deletes files that may require special tools to rebuild."
+clean: clean-am
+
+clean-am: clean-generic clean-libtool clean-noinstLIBRARIES \
+ clean-noinstLTLIBRARIES mostlyclean-am
+
+distclean: distclean-am
+ -rm -f Makefile
+distclean-am: clean-am distclean-compile distclean-generic \
+ distclean-libtool distclean-tags
+
+dvi: dvi-am
+
+dvi-am:
+
+html: html-am
+
+info: info-am
+
+info-am:
+
+install-data-am:
+
+install-exec-am:
+
+install-info: install-info-am
+
+install-man:
+
+installcheck-am:
+
+maintainer-clean: maintainer-clean-am
+ -rm -f Makefile
+maintainer-clean-am: distclean-am maintainer-clean-generic
+
+mostlyclean: mostlyclean-am
+
+mostlyclean-am: mostlyclean-compile mostlyclean-generic \
+ mostlyclean-libtool
+
+pdf: pdf-am
+
+pdf-am:
+
+ps: ps-am
+
+ps-am:
+
+uninstall-am:
+
+.PHONY: CTAGS GTAGS all all-am check check-am clean clean-generic \
+ clean-libtool clean-noinstLIBRARIES clean-noinstLTLIBRARIES \
+ ctags distclean distclean-compile distclean-generic \
+ distclean-libtool distclean-tags dvi dvi-am html html-am info \
+ info-am install install-am install-data install-data-am \
+ install-exec install-exec-am install-info install-info-am \
+ install-man install-strip installcheck installcheck-am \
+ installdirs maintainer-clean maintainer-clean-generic \
+ mostlyclean mostlyclean-compile mostlyclean-generic \
+ mostlyclean-libtool pdf pdf-am ps ps-am tags uninstall \
+ uninstall-am uninstall-info-am
+
+
+.c.def:
+ $(CHEW) < $< > $*.def 2> $*.ref
+ touch stmp-def
+
+doc: $(CHEWOUT_FILES)
+objectlist.awk.in: $(noinst_LTLIBRARIES)
+ -rm -f objectlist.awk.in
+ for i in `ls *.lo` ; \
+ do \
+ echo $$i `pwd`/$$i >> objectlist.awk.in ; \
+ done
+# Tell versions [3.59,3.63) of GNU make to not export all variables.
+# Otherwise a system limit (for SysV at least) may be exceeded.
+.NOEXPORT:
Index: argz_next.c
===================================================================
--- argz_next.c (nonexistent)
+++ argz_next.c (revision 158)
@@ -0,0 +1,37 @@
+/* Copyright (C) 2002 by Red Hat, Incorporated. All rights reserved.
+ *
+ * Permission to use, copy, modify, and distribute this software
+ * is freely granted, provided that this notice is preserved.
+ */
+
+#include
+#include
+#include
+#include
+#include
+
+char *
+_DEFUN (argz_next, (argz, argz_len, entry),
+ char *argz _AND
+ size_t argz_len _AND
+ const char *entry)
+{
+ if (entry)
+ {
+ while(*entry != '\0')
+ entry++;
+ entry++;
+
+ if (entry >= argz + argz_len)
+ return NULL;
+ else
+ return (char *) entry;
+ }
+ else
+ {
+ if (argz_len > 0)
+ return (char *) argz;
+ else
+ return NULL;
+ }
+}
argz_next.c
Property changes :
Added: svn:eol-style
## -0,0 +1 ##
+native
\ No newline at end of property
Added: svn:keywords
## -0,0 +1 ##
+Id
\ No newline at end of property
Index: argz_stringify.c
===================================================================
--- argz_stringify.c (nonexistent)
+++ argz_stringify.c (revision 158)
@@ -0,0 +1,27 @@
+/* Copyright (C) 2002 by Red Hat, Incorporated. All rights reserved.
+ *
+ * Permission to use, copy, modify, and distribute this software
+ * is freely granted, provided that this notice is preserved.
+ */
+
+#include <_ansi.h>
+#include
+#include
+#include
+
+void
+_DEFUN (argz_stringify, (argz, argz_len, sep),
+ char *argz _AND
+ size_t argz_len _AND
+ int sep)
+{
+ size_t i;
+
+ /* len includes trailing \0, which we don't want to replace. */
+ if (argz_len > 1)
+ for (i = 0; i < argz_len - 1; i++)
+ {
+ if (argz[i] == '\0')
+ argz[i] = sep;
+ }
+}
argz_stringify.c
Property changes :
Added: svn:eol-style
## -0,0 +1 ##
+native
\ No newline at end of property
Added: svn:keywords
## -0,0 +1 ##
+Id
\ No newline at end of property
Index: envz_entry.c
===================================================================
--- envz_entry.c (nonexistent)
+++ envz_entry.c (revision 158)
@@ -0,0 +1,46 @@
+/* Copyright (C) 2002 by Red Hat, Incorporated. All rights reserved.
+ *
+ * Permission to use, copy, modify, and distribute this software
+ * is freely granted, provided that this notice is preserved.
+ */
+
+#include
+#include
+#include
+#include
+#include
+
+#include "buf_findstr.h"
+
+char *
+_DEFUN (envz_entry, (envz, envz_len, name),
+ const char *envz _AND
+ size_t envz_len _AND
+ const char *name)
+{
+ char *buf_ptr = (char *)envz;
+ size_t buf_len = envz_len;
+
+ while(buf_len)
+ {
+ if (_buf_findstr(name, &buf_ptr, &buf_len))
+ {
+ if (buf_ptr)
+ {
+ if (*buf_ptr == '=' || *buf_ptr == '\0')
+ {
+ buf_ptr--;
+
+ /* Move buf_ptr back to start of entry. */
+ while(*buf_ptr != '\0' && buf_ptr != envz) buf_ptr--;
+
+ if(*buf_ptr == '\0')
+ buf_ptr++;
+
+ return (char *)buf_ptr;
+ }
+ }
+ }
+ }
+ return 0;
+}
envz_entry.c
Property changes :
Added: svn:eol-style
## -0,0 +1 ##
+native
\ No newline at end of property
Added: svn:keywords
## -0,0 +1 ##
+Id
\ No newline at end of property
Index: envz_strip.c
===================================================================
--- envz_strip.c (nonexistent)
+++ envz_strip.c (revision 158)
@@ -0,0 +1,42 @@
+/* Copyright (C) 2002 by Red Hat, Incorporated. All rights reserved.
+ *
+ * Permission to use, copy, modify, and distribute this software
+ * is freely granted, provided that this notice is preserved.
+ */
+
+#include
+#include
+#include
+#include
+#include
+#include
+
+void
+_DEFUN (envz_strip, (envz, envz_len),
+ char **envz _AND
+ size_t *envz_len)
+{
+ char *entry = 0;
+ int len = 0;
+ int null_found = 0;
+
+ while((entry = argz_next(*envz, *envz_len, entry)))
+ {
+ if(!strchr(entry, '='))
+ {
+ null_found = 1;
+ len = strlen(entry) + 1;
+ /* Make sure this is not the last entry in envz. If it is, it
+ will be chopped off by the realloc anyway.*/
+ if(*envz + *envz_len != entry + len - 1)
+ {
+ memmove(entry, entry + len, *envz + *envz_len - entry - len);
+ }
+ *envz_len -= len;
+ }
+ }
+ if(null_found)
+ {
+ *envz = (char *)realloc(*envz, *envz_len);
+ }
+}
envz_strip.c
Property changes :
Added: svn:eol-style
## -0,0 +1 ##
+native
\ No newline at end of property
Added: svn:keywords
## -0,0 +1 ##
+Id
\ No newline at end of property
Index: buf_findstr.c
===================================================================
--- buf_findstr.c (nonexistent)
+++ buf_findstr.c (revision 158)
@@ -0,0 +1,44 @@
+/* Copyright (C) 2002 by Red Hat, Incorporated. All rights reserved.
+ *
+ * Permission to use, copy, modify, and distribute this software
+ * is freely granted, provided that this notice is preserved.
+ */
+
+#include
+#include
+#include
+#include
+
+#include "buf_findstr.h"
+
+/* Find string str in buffer buf of length buf_len. Point buf to character after string,
+ or set it to NULL if end of buffer is reached. Return 1 if found, 0 if not. */
+int
+_buf_findstr(const char *str, char **buf, size_t *buf_len)
+{
+ int i = 0;
+ int j = 0;
+
+ for (i = 0; i < *buf_len; i++)
+ {
+ if (str[0] == (*buf)[i])
+ {
+ j = i;
+ while (str[j - i] && (str[j - i] == (*buf)[j])) j++;
+ if(str[j - i] == '\0')
+ {
+ *buf += j;
+ *buf_len -= j;
+ return 1;
+ }
+ }
+ }
+
+ if (i == *buf_len)
+ {
+ *buf += *buf_len;
+ *buf_len = 0;
+ }
+
+ return 0;
+}
buf_findstr.c
Property changes :
Added: svn:eol-style
## -0,0 +1 ##
+native
\ No newline at end of property
Added: svn:keywords
## -0,0 +1 ##
+Id
\ No newline at end of property
Index: buf_findstr.h
===================================================================
--- buf_findstr.h (nonexistent)
+++ buf_findstr.h (revision 158)
@@ -0,0 +1,12 @@
+/* Copyright (C) 2002 by Red Hat, Incorporated. All rights reserved.
+ *
+ * Permission to use, copy, modify, and distribute this software
+ * is freely granted, provided that this notice is preserved.
+ */
+
+#include
+
+/* Find string str in buffer buf of length buf_len. Point buf to
+ character after string, or set it to NULL if end of buffer is
+ reached. Return 1 if found, 0 if not. */
+int _buf_findstr(const char *str, char **buf, size_t *buf_len);
buf_findstr.h
Property changes :
Added: svn:eol-style
## -0,0 +1 ##
+native
\ No newline at end of property
Added: svn:keywords
## -0,0 +1 ##
+Id
\ No newline at end of property
Index: argz_add.c
===================================================================
--- argz_add.c (nonexistent)
+++ argz_add.c (revision 158)
@@ -0,0 +1,33 @@
+/* Copyright (C) 2002 by Red Hat, Incorporated. All rights reserved.
+ *
+ * Permission to use, copy, modify, and distribute this software
+ * is freely granted, provided that this notice is preserved.
+ */
+
+#include
+#include
+#include
+#include
+#include
+
+error_t
+_DEFUN (argz_add, (argz, argz_len, str),
+ char **argz _AND
+ size_t *argz_len _AND
+ const char *str)
+{
+ int len_to_add = 0;
+ size_t last = *argz_len;
+
+ if (str == NULL)
+ return 0;
+
+ len_to_add = strlen(str) + 1;
+ *argz_len += len_to_add;
+
+ if(!(*argz = (char *)realloc(*argz, *argz_len)))
+ return ENOMEM;
+
+ memcpy(*argz + last, str, len_to_add);
+ return 0;
+}
argz_add.c
Property changes :
Added: svn:eol-style
## -0,0 +1 ##
+native
\ No newline at end of property
Added: svn:keywords
## -0,0 +1 ##
+Id
\ No newline at end of property
Index: argz_count.c
===================================================================
--- argz_count.c (nonexistent)
+++ argz_count.c (revision 158)
@@ -0,0 +1,26 @@
+/* Copyright (C) 2002 by Red Hat, Incorporated. All rights reserved.
+ *
+ * Permission to use, copy, modify, and distribute this software
+ * is freely granted, provided that this notice is preserved.
+ */
+
+#include <_ansi.h>
+#include
+#include
+#include
+
+size_t
+_DEFUN (argz_count, (argz, argz_len),
+ const char *argz _AND
+ size_t argz_len)
+{
+ int i;
+ size_t count = 0;
+
+ for (i = 0; i < argz_len; i++)
+ {
+ if (argz[i] == '\0')
+ count++;
+ }
+ return count;
+}
argz_count.c
Property changes :
Added: svn:eol-style
## -0,0 +1 ##
+native
\ No newline at end of property
Added: svn:keywords
## -0,0 +1 ##
+Id
\ No newline at end of property
Index: envz_get.c
===================================================================
--- envz_get.c (nonexistent)
+++ envz_get.c (revision 158)
@@ -0,0 +1,43 @@
+/* Copyright (C) 2002 by Red Hat, Incorporated. All rights reserved.
+ *
+ * Permission to use, copy, modify, and distribute this software
+ * is freely granted, provided that this notice is preserved.
+ */
+
+#include
+#include
+#include
+#include
+#include
+
+#include "buf_findstr.h"
+
+char *
+_DEFUN (envz_get, (envz, envz_len, name),
+ const char *envz _AND
+ size_t envz_len _AND
+ const char *name)
+{
+ char *buf_ptr = (char *)envz;
+ size_t buf_len = envz_len;
+
+ while(buf_len)
+ {
+ if (_buf_findstr(name, &buf_ptr, &buf_len))
+ {
+ if (*buf_ptr == '=')
+ {
+ buf_ptr++;
+ return (char *)buf_ptr;
+ }
+ else
+ {
+ if (*buf_ptr == '\0')
+ /* NULL entry. */
+ return NULL;
+ }
+ }
+ }
+ /* No matching entries found. */
+ return NULL;
+}
envz_get.c
Property changes :
Added: svn:eol-style
## -0,0 +1 ##
+native
\ No newline at end of property
Added: svn:keywords
## -0,0 +1 ##
+Id
\ No newline at end of property
Index: argz_add_sep.c
===================================================================
--- argz_add_sep.c (nonexistent)
+++ argz_add_sep.c (revision 158)
@@ -0,0 +1,36 @@
+/* Copyright (C) 2002 by Red Hat, Incorporated. All rights reserved.
+ *
+ * Permission to use, copy, modify, and distribute this software
+ * is freely granted, provided that this notice is preserved.
+ */
+
+#include
+#include
+#include
+#include
+#include
+
+error_t
+_DEFUN (argz_add_sep, (argz, argz_len, str, sep),
+ char **argz _AND
+ size_t *argz_len _AND
+ const char *str _AND
+ int sep)
+{
+ char *str_argz = 0;
+ size_t str_argz_len = 0;
+ size_t last = *argz_len;
+
+ argz_create_sep (str, sep, &str_argz, &str_argz_len);
+
+ if (str_argz_len)
+ {
+ *argz_len += str_argz_len;
+
+ if(!(*argz = (char *)realloc(*argz, *argz_len)))
+ return ENOMEM;
+
+ memcpy(*argz + last, str_argz, str_argz_len);
+ }
+ return 0;
+}
argz_add_sep.c
Property changes :
Added: svn:eol-style
## -0,0 +1 ##
+native
\ No newline at end of property
Added: svn:keywords
## -0,0 +1 ##
+Id
\ No newline at end of property
Index: argz_delete.c
===================================================================
--- argz_delete.c (nonexistent)
+++ argz_delete.c (revision 158)
@@ -0,0 +1,41 @@
+/* Copyright (C) 2002 by Red Hat, Incorporated. All rights reserved.
+ *
+ * Permission to use, copy, modify, and distribute this software
+ * is freely granted, provided that this notice is preserved.
+ */
+
+#include
+#include
+#include
+#include
+#include
+
+error_t
+_DEFUN (argz_delete, (argz, argz_len, entry),
+ char **argz _AND
+ size_t *argz_len _AND
+ char *entry)
+{
+ int len = 0;
+ char *moveto = entry;
+
+ if (entry)
+ {
+ len = strlen(entry) + 1;
+ entry += len;
+
+ memmove(moveto, entry, *argz + *argz_len - entry);
+
+ *argz_len -= len;
+
+ if(!(*argz = (char *)realloc(*argz, *argz_len)))
+ return ENOMEM;
+
+ if (*argz_len <= 0)
+ {
+ free(*argz);
+ *argz = NULL;
+ }
+ }
+ return 0;
+}
argz_delete.c
Property changes :
Added: svn:eol-style
## -0,0 +1 ##
+native
\ No newline at end of property
Added: svn:keywords
## -0,0 +1 ##
+Id
\ No newline at end of property
Index: argz_create.c
===================================================================
--- argz_create.c (nonexistent)
+++ argz_create.c (revision 158)
@@ -0,0 +1,50 @@
+/* Copyright (C) 2002 by Red Hat, Incorporated. All rights reserved.
+ *
+ * Permission to use, copy, modify, and distribute this software
+ * is freely granted, provided that this notice is preserved.
+ */
+
+#include
+#include
+#include
+#include
+#include
+
+error_t
+_DEFUN (argz_create, (argv, argz, argz_len),
+ char *const argv[] _AND
+ char **argz _AND
+ size_t *argz_len)
+{
+ int argc = 0;
+ int i = 0;
+ int len = 0;
+ char *iter;
+
+ *argz_len = 0;
+
+ if (*argv == NULL)
+ {
+ *argz = NULL;
+ return 0;
+ }
+
+ while (argv[argc])
+ {
+ *argz_len += (strlen(argv[argc]) + 1);
+ argc++;
+ }
+
+ /* There are argc strings to copy into argz. */
+ if(!(*argz = (char *)malloc(*argz_len)))
+ return ENOMEM;
+
+ iter = *argz;
+ for(i = 0; i < argc; i++)
+ {
+ len = strlen(argv[i]) + 1;
+ memcpy(iter, argv[i], len);
+ iter += len;
+ }
+ return 0;
+}
argz_create.c
Property changes :
Added: svn:eol-style
## -0,0 +1 ##
+native
\ No newline at end of property
Added: svn:keywords
## -0,0 +1 ##
+Id
\ No newline at end of property
Index: argz_insert.c
===================================================================
--- argz_insert.c (nonexistent)
+++ argz_insert.c (revision 158)
@@ -0,0 +1,48 @@
+/* Copyright (C) 2002, 2005 by Red Hat, Incorporated. All rights reserved.
+ *
+ * Permission to use, copy, modify, and distribute this software
+ * is freely granted, provided that this notice is preserved.
+ */
+
+#include
+#include
+#include
+#include
+#include
+#define __need_ptrdiff_t
+#include
+
+error_t
+_DEFUN (argz_insert, (argz, argz_len, before, entry),
+ char **argz _AND
+ size_t *argz_len _AND
+ char *before _AND
+ const char *entry)
+{
+ int len = 0;
+ ptrdiff_t delta;
+
+ if (before == NULL)
+ return argz_add(argz, argz_len, entry);
+
+ if (before < *argz || before >= *argz + *argz_len)
+ return EINVAL;
+
+ while (before != *argz && before[-1])
+ before--;
+
+ /* delta will always be non-negative, and < *argz_len */
+ delta = before - *argz;
+
+ len = strlen(entry) + 1;
+
+ if(!(*argz = (char *)realloc(*argz, *argz_len + len)))
+ return ENOMEM;
+
+ memmove(*argz + delta + len, *argz + delta, *argz_len - delta);
+ memcpy(*argz + delta, entry, len);
+
+ *argz_len += len;
+
+ return 0;
+}
argz_insert.c
Property changes :
Added: svn:eol-style
## -0,0 +1 ##
+native
\ No newline at end of property
Added: svn:keywords
## -0,0 +1 ##
+Id
\ No newline at end of property
Index: Makefile.am
===================================================================
--- Makefile.am (nonexistent)
+++ Makefile.am (revision 158)
@@ -0,0 +1,62 @@
+## Process this file with automake to generate Makefile.in
+
+AUTOMAKE_OPTIONS = cygnus
+
+INCLUDES = $(NEWLIB_CFLAGS) $(CROSS_CFLAGS) $(TARGET_CFLAGS)
+
+## All functions in this directory are EL/IX level 2 and above
+if ELIX_LEVEL_1
+ELIX_SOURCES =
+else
+ELIX_SOURCES = \
+ argz_add.c \
+ argz_add_sep.c \
+ argz_append.c \
+ argz_count.c \
+ argz_create.c \
+ argz_create_sep.c \
+ argz_delete.c \
+ argz_extract.c \
+ argz_insert.c \
+ argz_next.c \
+ argz_replace.c \
+ argz_stringify.c \
+ buf_findstr.c \
+ envz_entry.c \
+ envz_get.c \
+ envz_add.c \
+ envz_remove.c \
+ envz_merge.c \
+ envz_strip.c
+endif
+
+libargz_la_LDFLAGS = -Xcompiler -nostdlib
+
+if USE_LIBTOOL
+noinst_LTLIBRARIES = libargz.la
+libargz_la_SOURCES = dummy.c $(ELIX_SOURCES)
+noinst_DATA = objectlist.awk.in
+else
+noinst_LIBRARIES = lib.a
+lib_a_SOURCES = dummy.c $(ELIX_SOURCES)
+lib_a_CFLAGS = $(AM_CFLAGS)
+noinst_DATA =
+endif # USE_LIBTOOL
+
+SUFFIXES = .def
+
+CHEWOUT_FILES =
+
+CHEW = ../../doc/makedoc -f $(srcdir)/../../doc/doc.str
+
+.c.def:
+ $(CHEW) < $< > $*.def 2> $*.ref
+ touch stmp-def
+
+TARGETDOC = ../tmp.texi
+
+doc: $(CHEWOUT_FILES)
+
+CLEANFILES = $(CHEWOUT_FILES) *.ref
+
+include $(srcdir)/../../Makefile.shared
Makefile.am
Property changes :
Added: svn:eol-style
## -0,0 +1 ##
+native
\ No newline at end of property
Added: svn:keywords
## -0,0 +1 ##
+Id
\ No newline at end of property
Index: argz_append.c
===================================================================
--- argz_append.c (nonexistent)
+++ argz_append.c (revision 158)
@@ -0,0 +1,32 @@
+/* Copyright (C) 2002 by Red Hat, Incorporated. All rights reserved.
+ *
+ * Permission to use, copy, modify, and distribute this software
+ * is freely granted, provided that this notice is preserved.
+ */
+
+#include
+#include
+#include
+#include
+#include
+
+error_t
+_DEFUN (argz_append, (argz, argz_len, buf, buf_len),
+ char **argz _AND
+ size_t *argz_len _AND
+ const char *buf _AND
+ size_t buf_len)
+{
+ if (buf_len)
+ {
+ size_t last = *argz_len;
+
+ *argz_len += buf_len;
+
+ if(!(*argz = (char *)realloc(*argz, *argz_len)))
+ return ENOMEM;
+
+ memcpy(*argz + last, buf, buf_len);
+ }
+ return 0;
+}
argz_append.c
Property changes :
Added: svn:eol-style
## -0,0 +1 ##
+native
\ No newline at end of property
Added: svn:keywords
## -0,0 +1 ##
+Id
\ No newline at end of property
Index: envz_add.c
===================================================================
--- envz_add.c (nonexistent)
+++ envz_add.c (revision 158)
@@ -0,0 +1,47 @@
+/* Copyright (C) 2002 by Red Hat, Incorporated. All rights reserved.
+ *
+ * Permission to use, copy, modify, and distribute this software
+ * is freely granted, provided that this notice is preserved.
+ */
+
+#include
+#include
+#include
+#include
+#include
+#include
+
+error_t
+_DEFUN (envz_add, (envz, envz_len, name, value),
+ char **envz _AND
+ size_t *envz_len _AND
+ const char *name _AND
+ const char *value)
+{
+ char *concat = NULL;
+ int name_len = 0;
+ int val_len = 0;
+ int retval = 0;
+
+ envz_remove(envz, envz_len, name);
+
+ if (value)
+ {
+ name_len = strlen(name);
+ val_len = strlen(value);
+ if(!(concat = (char *) malloc(name_len + val_len + 2)))
+ return ENOMEM;
+
+ memcpy(concat, name, name_len);
+ concat[name_len] = '=';
+ memcpy(concat + name_len + 1, value, val_len + 1);
+
+ retval = argz_add(envz, envz_len, concat);
+ free(concat);
+ }
+ else
+ {
+ retval = argz_add(envz, envz_len, name);
+ }
+ return retval;
+}
envz_add.c
Property changes :
Added: svn:eol-style
## -0,0 +1 ##
+native
\ No newline at end of property
Added: svn:keywords
## -0,0 +1 ##
+Id
\ No newline at end of property
Index: dummy.c
===================================================================
--- dummy.c (nonexistent)
+++ dummy.c (revision 158)
@@ -0,0 +1 @@
+/* empty stub to allow objectlist.awk.in to be created */
dummy.c
Property changes :
Added: svn:eol-style
## -0,0 +1 ##
+native
\ No newline at end of property
Added: svn:keywords
## -0,0 +1 ##
+Id
\ No newline at end of property
Index: argz_extract.c
===================================================================
--- argz_extract.c (nonexistent)
+++ argz_extract.c (revision 158)
@@ -0,0 +1,32 @@
+/* Copyright (C) 2002 by Red Hat, Incorporated. All rights reserved.
+ *
+ * Permission to use, copy, modify, and distribute this software
+ * is freely granted, provided that this notice is preserved.
+ */
+
+#include
+#include
+#include
+
+void
+_DEFUN (argz_extract, (argz, argz_len, argv),
+ char *argz _AND
+ size_t argz_len _AND
+ char **argv)
+{
+ size_t i = 0;
+ int j = 0;
+ const size_t count = argz_count(argz, argz_len);
+
+ if (argz_len > 1)
+ for (i = argz_len - 2; i > 0; i--)
+ {
+ if (argz[i] == '\0')
+ {
+ j++;
+ argv[count - j] = &argz[i + 1];
+ }
+ }
+ argv[0] = &argz[0];
+ argv[count] = NULL;
+}
argz_extract.c
Property changes :
Added: svn:eol-style
## -0,0 +1 ##
+native
\ No newline at end of property
Added: svn:keywords
## -0,0 +1 ##
+Id
\ No newline at end of property
Index: argz_create_sep.c
===================================================================
--- argz_create_sep.c (nonexistent)
+++ argz_create_sep.c (revision 158)
@@ -0,0 +1,69 @@
+/* Copyright (C) 2002 by Red Hat, Incorporated. All rights reserved.
+ *
+ * Permission to use, copy, modify, and distribute this software
+ * is freely granted, provided that this notice is preserved.
+ */
+
+#include
+#include
+#include
+#include
+#include
+
+error_t
+_DEFUN (argz_create_sep, (string, sep, argz, argz_len),
+ const char *string _AND
+ int sep _AND
+ char **argz _AND
+ size_t *argz_len)
+{
+ int len = 0;
+ int i = 0;
+ int num_strings = 0;
+ char delim[2];
+ char *running = 0;
+ char *old_running = 0;
+ char *token = 0;
+ char *iter = 0;
+
+ *argz_len = 0;
+
+ if (!string || string[0] == '\0')
+ {
+ *argz= NULL;
+ return 0;
+ }
+
+ delim[0] = sep;
+ delim[1] = '\0';
+
+ running = strdup(string);
+ old_running = running;
+
+ while ((token = strsep(&running, delim)))
+ {
+ len = strlen(token);
+ *argz_len += (len + 1);
+ num_strings++;
+ }
+
+ if(!(*argz = (char *)malloc(*argz_len)))
+ return ENOMEM;
+
+ free(old_running);
+
+ running = strdup(string);
+ old_running = running;
+
+ iter = *argz;
+ for (i = 0; i < num_strings; i++)
+ {
+ token = strsep(&running, delim);
+ len = strlen(token) + 1;
+ memcpy(iter, token, len);
+ iter += len;
+ }
+
+ free(old_running);
+ return 0;
+}
argz_create_sep.c
Property changes :
Added: svn:eol-style
## -0,0 +1 ##
+native
\ No newline at end of property
Added: svn:keywords
## -0,0 +1 ##
+Id
\ No newline at end of property