Renamed libc filename, disabled debug and reenabled lfn in FAT
authorJohn Hodge <[email protected]>
Wed, 14 Apr 2010 10:26:13 +0000 (18:26 +0800)
committerJohn Hodge <[email protected]>
Wed, 14 Apr 2010 10:26:13 +0000 (18:26 +0800)
Kernel/Makefile.BuildNum
Modules/Filesystems/FAT/fat.c
Usermode/Libraries/libc.so_src/Makefile

index 1dbbbac..789b571 100644 (file)
@@ -1 +1 @@
-BUILD_NUM = 1830
+BUILD_NUM = 1837
index 2504526..93911de 100644 (file)
@@ -3,7 +3,7 @@
  * FAT12/16/32 Driver Version (Incl LFN)\r
  * \r
  * NOTE: This driver will only support _reading_ long file names, not\r
- * writing. I don't even know why i'm adding write-support. FAT sucks.\r
+ * writing. I don't even know why I'm adding write-support. FAT sucks.\r
  * \r
  * Known Bugs:\r
  * - LFN Is buggy in FAT_ReadDir\r
  * \todo Implement changing of the parent directory when a file is written to\r
  * \todo Implement file creation / deletion\r
  */\r
-#define DEBUG  1\r
+#define DEBUG  0\r
 #define VERBOSE        1\r
 \r
 #define CACHE_FAT      1       //!< Caches the FAT in memory\r
-#define USE_LFN                0       //!< Enables the use of Long File Names\r
+#define USE_LFN                1       //!< Enables the use of Long File Names\r
 #define        SUPPORT_WRITE   0\r
 \r
 #include <acess.h>\r
@@ -1130,10 +1130,13 @@ char *FAT_ReadDir(tVFS_Node *Node, int ID)
        // Check for empty entry\r
        if( (Uint8)fileinfo[a].name[0] == 0xE5 ) {\r
                LOG("Empty Entry");\r
-               //LEAVE('p', VFS_SKIP);\r
-               //return VFS_SKIP;      // Skip\r
+               #if 0   // Stop on empty entry?\r
                LEAVE('n');\r
-               return NULL;    // Skip\r
+               return NULL;    // Stop\r
+               #else\r
+               LEAVE('p', VFS_SKIP);\r
+               return VFS_SKIP;        // Skip\r
+               #endif\r
        }\r
        \r
        #if USE_LFN\r
@@ -1262,6 +1265,8 @@ tVFS_Node *FAT_FindDir(tVFS_Node *Node, char *Name)
                {\r
                        // Remove LFN if it does not apply\r
                        if(lfnId != i)  lfn[0] = '\0';\r
+               #else\r
+               if(fileinfo[i&0xF].attrib == ATTR_LFN)  continue;\r
                #endif\r
                        // Get Real Filename\r
                        FAT_int_ProperFilename(tmpName, fileinfo[i&0xF].name);\r
index 1e3fc46..a12ff45 100644 (file)
@@ -6,22 +6,22 @@
 CPPFLAGS += \r
 CFLAGS   += \r
 ASFLAGS  +=\r
-LDFLAGS  += -soname libc.so.1 -Map map.txt -lgcc\r
+LDFLAGS  += -soname libc.so -Map map.txt -lgcc\r
 \r
 OBJ = stub.o heap.o stdlib.o env.o fileIO.o string.o\r
 DEPFILES := $(OBJ:%.o=%.d)\r
 # signals.o\r
-BIN = ../libc.so.1\r
+BIN = ../libc.so\r
 \r
 .PHONY:        all clean install\r
 \r
 all: $(BIN)\r
 \r
 clean:\r
-       $(RM) $(BIN) ../libc.so $(OBJ) $(DEPFILES) libc.so.1.dsm libc.so.1.dmp map.txt\r
+       $(RM) $(BIN) $(OBJ) $(DEPFILES) libc.so.dsm libc.so.dmp map.txt\r
 \r
 install: $(BIN)\r
-       $(xCP) ../libc.so.1 $(DISTROOT)/Libs/\r
+       $(xCP) $(BIN) $(DISTROOT)/Libs/\r
 \r
 # Core C Library\r
 $(BIN): $(OBJ)\r
@@ -29,7 +29,6 @@ $(BIN): $(OBJ)
        @$(LD) $(LDFLAGS) $(OBJ) -o $@\r
        @$(OBJDUMP) -d $@ > libc.so.1.dsm\r
        @$(OBJDUMP) -x -r -R $@ > libc.so.1.dmp\r
-       cp ../libc.so.1 ../libc.so\r
 \r
 # C Runtime 0\r
 ../crt0.o: crt0.asm\r

UCC git Repository :: git.ucc.asn.au