From 591c02acb039ccabadaca2afb1eb0f5aa2f43103 Mon Sep 17 00:00:00 2001 From: janwas Date: Fri, 7 May 2004 01:27:05 +0000 Subject: [PATCH] no message This was SVN commit r218. --- source/lib/res/vfs.cpp | 10 +++++----- source/lib/res/vfs.h | 2 +- source/linux/readme.txt | 10 +++++----- source/linux/sys/time.h | 20 +++++++++++++++++++ source/{ => workspaces}/update-workspaces.bat | 0 5 files changed, 31 insertions(+), 11 deletions(-) create mode 100755 source/linux/sys/time.h rename source/{ => workspaces}/update-workspaces.bat (100%) diff --git a/source/lib/res/vfs.cpp b/source/lib/res/vfs.cpp index 9045b970ba..9ddc3742b2 100755 --- a/source/lib/res/vfs.cpp +++ b/source/lib/res/vfs.cpp @@ -80,7 +80,7 @@ /////////////////////////////////////////////////////////////////////////////// // path types: -// p_* : portable +// portable (/ as directory separator; no ':' or '\\') // v_* : VFS // f_* : no path at all, filename only @@ -90,7 +90,7 @@ static int path_append(char* dst, const char* path, const char* path2) const size_t path_len = strlen(path); const size_t path2_len = strlen(path2); - if(path_len+path2_len+1 > PATH_MAX) + if(path_len+path2_len+1 > VFS_MAX_PATH) return -1; char* p = dst; @@ -168,7 +168,7 @@ ok: } -#define CHECK_PATH(p_path) CHECK_ERR(path_validate(__LINE__, p_path)) +#define CHECK_PATH(path) CHECK_ERR(path_validate(__LINE__, path)) /////////////////////////////////////////////////////////////////////////////// @@ -248,9 +248,9 @@ static int loc_free_all() // wrapper on top of new + ctor to emphasize that // the caller must not free the Loc pointer. // (if they do, VFS entries point to freed memory => disaster) -static Loc* loc_create(const Handle ha, const char* const p_path, const uint pri) +static Loc* loc_create(const Handle ha, const char* const path, const uint pri) { - return new Loc(ha, p_path, pri); + return new Loc(ha, path, pri); } diff --git a/source/lib/res/vfs.h b/source/lib/res/vfs.h index 713f8b5522..cac9c75eed 100755 --- a/source/lib/res/vfs.h +++ b/source/lib/res/vfs.h @@ -21,7 +21,7 @@ #define __VFS_H__ #include "h_mgr.h" -#include "posix.h" +#include "posix.h" // struct stat #define VFS_MAX_PATH 256 // includes trailing '\0' diff --git a/source/linux/readme.txt b/source/linux/readme.txt index c0e75b5cc4..207c3ac5d7 100755 --- a/source/linux/readme.txt +++ b/source/linux/readme.txt @@ -1,7 +1,7 @@ Linux build instructions The Linux build is, so far, a bit hackish. Things might not work on another -system than mine, but it should work. The source/linux/ folder contains some +system than mine, but it should work. The source/gcc/ folder contains some header files that exist to override and bug-fix some system headers. If you have trouble with them, try renaming the offending header, and see if it does you any good ;-) @@ -9,7 +9,7 @@ you any good ;-) What do I need? - Xerces-C++ installed and in standard include path -- glext.h - you can put it in source/linux/GL/ if you don't have access to the +- glext.h - you can put it in source/gcc/GL/ if you don't have access to the system include path - The Makefile is made for GCC 3.x.x - GCC 2.x might work, but it's not likely @@ -17,11 +17,11 @@ Where are built things put? The linux makefile follows the general directory layout of the VS workspaces: -source/linux/: makefile, system header overrides +source/gcc/: makefile, system header overrides binaries/: The built binaries - called "prometheus" -source/linux/deps/: Automatically generated dependency information for all +source/gcc/deps/: Automatically generated dependency information for all source files -source/linux/o/: Object files +source/gcc/o/: Object files Makefile Targets: diff --git a/source/linux/sys/time.h b/source/linux/sys/time.h new file mode 100755 index 0000000000..e9937af039 --- /dev/null +++ b/source/linux/sys/time.h @@ -0,0 +1,20 @@ +#ifndef _bug_time_H +#define _bug_time_H + +#include "/usr/include/sys/time.h" + +#define __need_time_t +#include + +#ifndef __timespec_defined +#define __timespec_defined 1 +struct timespec { + __time_t tv_sec; + long int tv_nsec; +}; +#endif + +typedef __time_t time_t; +typedef __clockid_t clockid_t; + +#endif diff --git a/source/update-workspaces.bat b/source/workspaces/update-workspaces.bat similarity index 100% rename from source/update-workspaces.bat rename to source/workspaces/update-workspaces.bat