Enable the DOS filesystem. This allows reading from various DOS filesystems

(FAT12/16/32, VFAT).

Make a private copy of strcasecmp, as the "real" one uses the system ctype
header, which introduces locale poisoning.
This commit is contained in:
Mike Smith 1998-10-06 19:23:57 +00:00
parent a0ab71761c
commit 40fd46f77d
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=40005
3 changed files with 9 additions and 10 deletions

View file

@ -1,4 +1,4 @@
# $Id: Makefile,v 1.4 1998/09/26 01:42:39 msmith Exp $
# $Id: Makefile,v 1.5 1998/10/04 08:10:29 msmith Exp $
#
# Originally from $NetBSD: Makefile,v 1.21 1997/10/26 22:08:38 lukem Exp $
#
@ -24,19 +24,21 @@ SRCS+= __main.c bcd.c bswap.c environment.c getopt.c gets.c globals.c \
pager.c printf.c strdup.c strerror.c strtol.c random.c sbrk.c \
twiddle.c zalloc.c zalloc_malloc.c
# private (pruned) versions of libc string functions
SRCS+= strcasecmp.c
# string functions from libc
.PATH: ${.CURDIR}/../libc/string
.if ${MACHINE_ARCH} == "i386"
SRCS+= bcmp.c bcopy.c bzero.c ffs.c index.c memccpy.c memchr.c memcmp.c \
memcpy.c memmove.c memset.c rindex.c strcasecmp.c strcat.c strchr.c \
memcpy.c memmove.c memset.c rindex.c strcat.c strchr.c \
strcmp.c strcpy.c strcspn.c strlen.c strncat.c strncmp.c strncpy.c \
strpbrk.c strrchr.c strsep.c strspn.c strstr.c strtok.c swab.c
.endif
.if ${MACHINE_ARCH} == "alpha"
.PATH: ${.CURDIR}/../libc/alpha/string
SRCS+= bcmp.c bcopy.S bzero.S ffs.S index.c memccpy.c memchr.c memcmp.c \
memcpy.S memmove.S memset.c rindex.c strcasecmp.c strcat.c strchr.c \
memcpy.S memmove.S memset.c rindex.c strcat.c strchr.c \
strcmp.c strcpy.c strcspn.c strlen.c \
strncat.c strncmp.c strncpy.c strpbrk.c strrchr.c strsep.c \
strspn.c strstr.c strtok.c swab.c
@ -107,8 +109,7 @@ SRCS+= bootp.c rarp.c bootparam.c
# boot filesystems
SRCS+= ufs.c nfs.c cd9660.c tftp.c zipfs.c
SRCS+= netif.c nfs.c
# needs "open directory" support
#SRCS+= dosfs.c
SRCS+= dosfs.c
beforeinstall:
${INSTALL} -C -o ${BINOWN} -g ${BINGRP} -m 444 ${.CURDIR}/stand.h \

View file

@ -39,7 +39,7 @@
#include "dosfs.h"
static int dos_open(char *path, struct open_file *fd);
static int dos_open(const char *path, struct open_file *fd);
static int dos_close(struct open_file *fd);
static int dos_read(struct open_file *fd, void *buf, size_t size, size_t *resid);
static off_t dos_seek(struct open_file *fd, off_t offset, int whence);
@ -185,7 +185,7 @@ dosunmount(DOS_FS *fs)
* Open DOS file
*/
static int
dos_open(char *path, struct open_file *fd)
dos_open(const char *path, struct open_file *fd)
{
DOS_DE *de;
DOS_FILE *f;

View file

@ -23,7 +23,7 @@
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
* SUCH DAMAGE.
*
* $Id: stand.h,v 1.5 1998/09/26 01:42:39 msmith Exp $
* $Id: stand.h,v 1.6 1998/09/26 10:48:50 dfr Exp $
* From $NetBSD: stand.h,v 1.22 1997/06/26 19:17:40 drochner Exp $
*/
@ -119,9 +119,7 @@ extern struct fs_ops tftp_fsops;
extern struct fs_ops nfs_fsops;
extern struct fs_ops cd9660_fsops;
extern struct fs_ops zipfs_fsops;
#ifdef notyet
extern struct fs_ops dosfs_fsops;
#endif
/* where values for lseek(2) */
#define SEEK_SET 0 /* set file offset to offset */