summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorwlemb <wlemb>2003-01-28 08:29:26 +0000
committerwlemb <wlemb>2003-01-28 08:29:26 +0000
commit61db599eb999f38f54c3e5f260b9d8437f393ae5 (patch)
tree5b358b7743007fa42948c5b3c264588cd0a2fd31
parent0354cdb0e9405e4087f496294a857111cb19d330 (diff)
downloadgroff-61db599eb999f38f54c3e5f260b9d8437f393ae5.tar.gz
* src/utils/indxbib/indxbib.cc (main) [__EMX__]: Check with
`access' before calling `unlink'. (do_file): Handle __EMX__. * src/include/nonposix.h: Handle __EMX__. * Makefile.in (SEP): New variable; set to @PATH_SEPARATOR@. (fontpath,tmacpath): Use it. * src/preproc/eqn/neqn.sh, src/roff/nroff/nroff.sh: Use @PATH_SEPARATOR@.
-rw-r--r--ChangeLog22
-rw-r--r--Makefile.in5
-rw-r--r--src/include/nonposix.h14
-rw-r--r--src/preproc/eqn/neqn.sh2
-rw-r--r--src/roff/nroff/nroff.sh2
-rw-r--r--src/utils/indxbib/indxbib.cc5
6 files changed, 35 insertions, 15 deletions
diff --git a/ChangeLog b/ChangeLog
index f54d467a..438ceaed 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,17 @@
+2003-01-26 Werner LEMBERG <wl@gnu.org>
+
+ * src/utils/indxbib/indxbib.cc (main) [__EMX__]: Check with
+ `access' before calling `unlink'.
+ (do_file): Handle __EMX__.
+
+ * src/include/nonposix.h: Handle __EMX__.
+
+ * Makefile.in (SEP): New variable; set to @PATH_SEPARATOR@.
+ (fontpath,tmacpath): Use it.
+
+ * src/preproc/eqn/neqn.sh, src/roff/nroff/nroff.sh: Use
+ @PATH_SEPARATOR@.
+
2003-01-27 Werner LEMBERG <wl@gnu.org>
* src/libs/libgroff/strcasecmp.c, src/libs/libgroff/strncasecmp.c:
@@ -7,10 +21,10 @@
* configure: Regenerated.
* src/include/config.hin: Regenerated.
- * src/include/lib.h [!HAVE_STRCASECMP]: Declare strcasecmp.
- Don't define strcasecmp as strcmp.
- [!HAVE_STRNCASECMP]: Declare strncasecmp.
- Dont define strncasecmp as strncmp.
+ * src/include/lib.h [!HAVE_STRCASECMP]: Declare `strcasecmp'.
+ Don't define `strcasecmp' as `strcmp'.
+ [!HAVE_STRNCASECMP]: Declare `strncasecmp'.
+ Dont define `strncasecmp' as `strncmp'.
* src/roff/groff/pipeline.c [!HAVE_STRCASECMP, !HAVE_STRNCASECMP]:
Removed.
diff --git a/Makefile.in b/Makefile.in
index 59c94208..690eca11 100644
--- a/Makefile.in
+++ b/Makefile.in
@@ -21,6 +21,7 @@ srcdir=@srcdir@
top_srcdir=@top_srcdir@
VPATH=@srcdir@
top_builddir=@groff_top_builddir@
+SEP=@PATH_SEPARATOR@
version=`cat $(top_srcdir)/VERSION`
# No additional number if revision is zero.
@@ -120,7 +121,7 @@ localfontdir=$(dataprogramdir)/site-font
legacyfontdir=/usr/lib/font
# `fontpath' says where to look for dev*/*.
-fontpath=$(localfontdir):$(fontdir):$(legacyfontdir)
+fontpath=$(localfontdir)$(SEP)$(fontdir)$(SEP)$(legacyfontdir)
# `tmacdir' says where to install macros.
tmacdir=$(datasubdir)/tmac
@@ -136,7 +137,7 @@ localtmacdir=$(dataprogramdir)/site-tmac
# directory will be always added.
# `troffrc' and `troffrc-end' (and `eqnrc') are searched neither in the
# current nor in the home directory.
-tmacpath=$(systemtmacdir):$(localtmacdir):$(tmacdir)
+tmacpath=$(systemtmacdir)$(SEP)$(localtmacdir)$(SEP)$(tmacdir)
# `sys_tmac_prefix' is prefix (if any) for system macro packages.
sys_tmac_prefix=@sys_tmac_prefix@
diff --git a/src/include/nonposix.h b/src/include/nonposix.h
index 86aa2e0e..88a1a214 100644
--- a/src/include/nonposix.h
+++ b/src/include/nonposix.h
@@ -1,4 +1,4 @@
-/* Copyright (C) 2000, 2001, 2002 Free Software Foundation, Inc.
+/* Copyright (C) 2000, 2001, 2002, 2003 Free Software Foundation, Inc.
Written by Eli Zaretskii (eliz@is.elta.co.il)
This file is part of groff.
@@ -26,7 +26,7 @@ Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
# endif
#endif
-#if defined(__MSDOS__) \
+#if defined(__MSDOS__) || defined(__EMX__) \
|| (defined(_WIN32) && !defined(_UWIN) && !defined(__CYGWIN__))
/* Binary I/O nuisances. Note: "setmode" is right for DJGPP and
@@ -60,9 +60,13 @@ Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
/* The system shell. Groff assumes a Unixy shell, but non-Posix
systems don't have standard places where it lives, and might not
have it installed to begin with. We want to give them some leeway. */
-# define BSHELL (system_shell_name())
-# define BSHELL_DASH_C (system_shell_dash_c())
-# define IS_BSHELL(s) (is_system_shell(s))
+# ifdef __EMX__
+# define getcwd(b,s) _getcwd2(b,s)
+# else
+# define BSHELL (system_shell_name())
+# define BSHELL_DASH_C (system_shell_dash_c())
+# define IS_BSHELL(s) (is_system_shell(s))
+# endif
/* The separator for directories in PATH and other environment
variables. */
diff --git a/src/preproc/eqn/neqn.sh b/src/preproc/eqn/neqn.sh
index 08346b05..1090b652 100644
--- a/src/preproc/eqn/neqn.sh
+++ b/src/preproc/eqn/neqn.sh
@@ -3,7 +3,7 @@
# GNU eqn with groff -Tascii|-Tlatin1|-Tutf8|-Tcp1047 is supported.
: ${GROFF_BIN_PATH=@BINDIR@}
-PATH=$GROFF_BIN_PATH:$PATH
+PATH=$GROFF_BIN_PATH@PATH_SEPARATOR@$PATH
export PATH
exec @g@eqn -Tascii ${1+"$@"}
diff --git a/src/roff/nroff/nroff.sh b/src/roff/nroff/nroff.sh
index 2d0628f0..03ff4666 100644
--- a/src/roff/nroff/nroff.sh
+++ b/src/roff/nroff/nroff.sh
@@ -86,6 +86,6 @@ done
: ${GROFF_BIN_PATH=@BINDIR@}
export GROFF_BIN_PATH
-PATH=$GROFF_BIN_PATH:$PATH groff -mtty-char $T $opts ${1+"$@"}
+PATH=$GROFF_BIN_PATH@PATH_SEPARATOR@$PATH groff -mtty-char $T $opts ${1+"$@"}
# eof
diff --git a/src/utils/indxbib/indxbib.cc b/src/utils/indxbib/indxbib.cc
index bd10772c..5c8651a4 100644
--- a/src/utils/indxbib/indxbib.cc
+++ b/src/utils/indxbib/indxbib.cc
@@ -287,7 +287,8 @@ int main(int argc, char **argv)
strcat(index_file, INDEX_SUFFIX);
#ifdef HAVE_RENAME
#ifdef __EMX__
- unlink(index_file);
+ if (access(index_file, R_OK) == 0)
+ unlink(index_file);
#endif /* __EMX__ */
if (rename(temp_index_file, index_file) < 0) {
#ifdef __MSDOS__
@@ -494,7 +495,7 @@ static int do_file(const char *filename)
else
ungetc(peek, fp);
}
-#if defined(__MSDOS__) || defined(_MSC_VER)
+#if defined(__MSDOS__) || defined(_MSC_VER) || defined(__EMX__)
else if (c == 0x1a) // ^Z means EOF in text files
break;
#endif