Update of /cvsroot/winbash/winbash/lib/tilde
In directory usw-pr-cvs1:/tmp/cvs-serv6262/lib/tilde
Modified Files:
Makefile tilde.c
Log Message:
Major realignment to 1.14.7
Index: Makefile
===================================================================
RCS file: /cvsroot/winbash/winbash/lib/tilde/Makefile,v
retrieving revision 1.1.1.1
retrieving revision 1.2
diff -u -d -r1.1.1.1 -r1.2
--- Makefile 9 Mar 2002 03:39:13 -0000 1.1.1.1
+++ Makefile 11 Mar 2002 14:32:16 -0000 1.2
@@ -14,7 +14,9 @@
# Please note that the values for INCLUDES, CC, AR, RM, CP,
# RANLIB, and selfdir are passed in from ../Makefile, and do
# not need to be defined here.
-RM = rm
+RM = rm -f
+MV = mv
+CP = cp
srcdir = .
VPATH = .:$(srcdir)
@@ -59,7 +61,7 @@
all: $(LIBRARY_NAME)
$(LIBRARY_NAME): $(OBJECTS)
- $(RM) -f $@
+ $(RM) $@
$(AR) cq $@ $(OBJECTS)
-[ -n "$(RANLIB)" ] && $(RANLIB) $@
@@ -81,8 +83,10 @@
-[ -n "$(RANLIB)" ] && $(RANLIB) -t $(bindir)/$(LIBRARY_NAME)
clean:
- $(RM) -f $(OBJECTS) $(LIBRARY_NAME)
- -(cd doc; $(MAKE) $(MFLAGS) clean)
+ $(RM) $(OBJECTS) $(LIBRARY_NAME)
+ -(cd doc && $(MAKE) $(MFLAGS) $@)
+
+maintainer-clean realclean mostlyclean distclean: clean
######################################################################
Index: tilde.c
===================================================================
RCS file: /cvsroot/winbash/winbash/lib/tilde/tilde.c,v
retrieving revision 1.2
retrieving revision 1.3
diff -u -d -r1.2 -r1.3
--- tilde.c 9 Mar 2002 16:05:44 -0000 1.2
+++ tilde.c 11 Mar 2002 14:32:16 -0000 1.3
@@ -251,15 +251,15 @@
else
{
char *username;
- struct passwd *user_entry;
- int i;
+ struct passwd *user_entry;
+ int i;
- username = xmalloc (strlen (dirname));
- for (i = 1; dirname[i] && dirname[i] != '/'; i++)
- username[i - 1] = dirname[i];
+ username = xmalloc (strlen (dirname));
+ for (i = 1; dirname[i] && dirname[i] != '/'; i++)
+ username[i - 1] = dirname[i];
username[i - 1] = '\0';
- if ((user_entry = getpwnam (username)) == 0)
+ if ((user_entry = getpwnam (username)) == 0)
{
/* If the calling program has a special syntax for
expanding tildes, and we couldn't find a standard
@@ -293,7 +293,7 @@
dirname = temp_name;
}
endpwent ();
- free (username);
+ free (username);
}
}
return (dirname);
|