Subject: FVWM: basename compilation error

From: "Michael Kirby" <[email-masked]>
Date: Thu, 16 Nov 1995 08:22:57 PST

in compiling pl39 on solaris2.4 I get an unknown symbol "basename" in 
fvwm.c

Its in the usage statement.  Apparently something new between 38 and 
39 (I checked).  Not sure where the basename library call is supposed 
to be.  Is that part of the standard C library?

Mike Kirby
[email-masked]
--
To unsubscribe from the list, send "unsubscribe fvwm" in the body of a
message to [email-masked].
To report problems, send mail to [email-masked].

---

From: Gregory Margo <[email-masked]>
Date: Thu, 16 Nov 1995 15:17:35 -0800 (PST)

Michael Kirby said:
> Not sure where the basename library call is supposed 

basename() is not part of ANSI C, but is present in some libc's.
Here is a substitute:

#include <string.h>
char *
basename(char *path)
{
	char	*c = strrchr(path, '/');

	if (c) return(c+1);
	return(path);
}

+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Gregory H. Margo                 No free speech restrictions on the Internet!
[email-masked]
--
To unsubscribe from the list, send "unsubscribe fvwm" in the body of a
message to [email-masked].
To report problems, send mail to [email-masked].

---

From: "Ronald S. Chong" <[email-masked]>
Date: Thu, 16 Nov 1995 19:14:05 -0500 (EST)

> in compiling pl39 on solaris2.4 I get an unknown symbol "basename" in 

i just downloaded it also and got the same error.  i commented out the
line and it works.  basename is apparently both a unix command that
returns the last item in a pathname.

/r/

-- 
+----------------------------------------------------------------------------+
 Ronald S. Chong -- [email-masked]
 http://ai.eecs.umich.edu/people/rchong/index.html
+----------------------------------------------------------------------------+
--
To unsubscribe from the list, send "unsubscribe fvwm" in the body of a
message to [email-masked].
To report problems, send mail to [email-masked].