aboutsummaryrefslogtreecommitdiffstats
path: root/mktable.c
diff options
context:
space:
mode:
authorFumitoshi UKAI <ukai@debian.or.jp>2003-03-12 18:27:03 +0000
committerFumitoshi UKAI <ukai@debian.or.jp>2003-03-12 18:27:03 +0000
commit33ddf9cdfc7ffa2ce662d85133c84f02db6b23c4 (patch)
tree67c85afac026064c37d3a214bab9a76a3293d7ae /mktable.c
parent* Makefile.in (distclean): added (diff)
downloadw3m-33ddf9cdfc7ffa2ce662d85133c84f02db6b23c4.tar.gz
w3m-33ddf9cdfc7ffa2ce662d85133c84f02db6b23c4.zip
[w3m-dev 03819] support cd build && ../configure
* Makefile.in: add VPATH add MV use $(top_srcdir), $<, $@ * acinclude.m4 (AC_W3M_VERSION): use $srcdir * configure.in (AC_W3M_VERSION): move * mktable.c (main): basename From: Fumitoshi UKAI <ukai@debian.or.jp>
Diffstat (limited to 'mktable.c')
-rw-r--r--mktable.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/mktable.c b/mktable.c
index 6e97643..d9cdf38 100644
--- a/mktable.c
+++ b/mktable.c
@@ -1,4 +1,4 @@
-/* $Id: mktable.c,v 1.11 2002/12/24 17:20:47 ukai Exp $ */
+/* $Id: mktable.c,v 1.12 2003/03/12 18:27:07 ukai Exp $ */
#include <stdio.h>
#include <stdlib.h>
#include "myctype.h"
@@ -48,7 +48,10 @@ main(int argc, char *argv[], char **envp)
fprintf(stderr, "Can't open %s\n", argv[2]);
exit(1);
}
- fbase = Strnew_charp(argv[2]);
+ p = argv[2];
+ if (strrchr(p, '/') != NULL)
+ p = strrchr(p, '/')+1;
+ fbase = Strnew_charp(p);
if (strchr(fbase->ptr, '.'))
while (Strlastchar(fbase) != '.')
Strshrink(fbase, 1);