summaryrefslogtreecommitdiff
path: root/dln.c
diff options
context:
space:
mode:
authormatz <matz@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>1999-04-09 18:04:08 +0000
committermatz <matz@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>1999-04-09 18:04:08 +0000
commit32e799db485107ba9d47fb4fb4cd44c9d6f57b8a (patch)
treee33fd45f76d7f31959c1e5298902588de716657c /dln.c
parent35247a52ef719584a59ae9c518523f0ee825c8e3 (diff)
*** empty log message ***
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_3@414 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'dln.c')
-rw-r--r--dln.c11
1 files changed, 7 insertions, 4 deletions
diff --git a/dln.c b/dln.c
index 936dc7a..76e0785 100644
--- a/dln.c
+++ b/dln.c
@@ -1585,7 +1585,7 @@ dln_find_1(fname, path, exe_flag)
if (strncmp("./", fname, 2) == 0 || strncmp("../", fname, 3) == 0)
return fname;
if (exe_flag && strchr(fname, '/')) return fname;
-#if defined(MSDOS) || defined(NT) || defined(__human68k__)
+#if defined(MSDOS) || defined(NT) || defined(__human68k__) || defined(__EMX__)
if (fname[0] == '\\') return fname;
if (strlen(fname) > 2 && fname[1] == ':') return fname;
if (strncmp(".\\", fname, 2) == 0 || strncmp("..\\", fname, 3) == 0)
@@ -1617,7 +1617,7 @@ dln_find_1(fname, path, exe_flag)
*/
if (*dp == '~' && (l == 1 ||
-#if defined(MSDOS) || defined(NT) || defined(__human68k__)
+#if defined(MSDOS) || defined(NT) || defined(__human68k__) || defined(__EMX__)
dp[1] == '\\' ||
#endif
dp[1] == '/')) {
@@ -1671,7 +1671,7 @@ dln_find_1(fname, path, exe_flag)
if (eaccess(mac_fullpath, X_OK) == 0) return mac_fullpath;
}
#endif
-#if defined(MSDOS) || defined(NT) || defined(__human68k__)
+#if defined(MSDOS) || defined(NT) || defined(__human68k__) || defined(__EMX__)
if (exe_flag) {
static const char *extension[] = {
#if defined(MSDOS)
@@ -1680,7 +1680,10 @@ dln_find_1(fname, path, exe_flag)
".btm", ".sh", ".ksh", ".pl", ".sed",
#endif
#else
+#if defined(__EMX__)
+ ".exe", ".com", ".cmd", ".bat",
".r", ".R", ".x", ".X", ".bat", ".BAT",
+#endif /*__EMX__*/
#endif
(char *) NULL
};
@@ -1703,7 +1706,7 @@ dln_find_1(fname, path, exe_flag)
#endif
}
}
-#endif /* MSDOS or NT or __human68k__ */
+#endif /* MSDOS or NT or __human68k__ or __EMX__ */
/* if not, and no other alternatives, life is bleak */
if (*ep == '\0') {
return NULL;