Commit Graph

137 Commits

Author SHA1 Message Date
Alibek Omarov 1855fab80b filesystem: fix Platform_GetNativeObject macro definition 2023-06-06 17:46:38 +03:00
Alibek Omarov 02ce80981c filesystem: update optional funcs interface, add platform-specific GetNativeObject call 2023-06-05 20:30:18 +03:00
Alibek Omarov 8caa2d142f scripts: sailfish: initial SailfishOS support 2023-06-02 05:37:13 +03:00
Alibek Omarov 81c752da2b filesystem: wad: static-ize WAD functions 2023-05-27 20:51:00 +03:00
Alibek Omarov fd2ad447a8 filesystem: zip: static-ize ZIP functions 2023-05-27 20:49:06 +03:00
Alibek Omarov 18d55c1de2 filesystem: zip: adapt to new interface 2023-05-27 20:48:48 +03:00
Alibek Omarov d0d09c878f filesystem: wad: adapt to new interface 2023-05-27 20:47:49 +03:00
Alibek Omarov e791d44dd8 filesystem: properly support compressed archives in FS_LoadFile 2023-05-27 20:46:48 +03:00
Alibek Omarov 152f6d154c filesystem: remove unused argument from FS_CheckNastyPath 2023-05-27 20:22:12 +03:00
Alibek Omarov 9cd9744407 filesystem: fix Windows build 2023-05-27 19:40:44 +03:00
Alibek Omarov f13c285287 filesystem: verbose error printing in FS_SetCurrentDirectory, move error reporting from engine 2023-05-26 22:29:34 +03:00
Alibek Omarov cca7744f1c filesystem: make some calls from API safe to use without initialize 2023-05-26 18:31:00 +03:00
Alibek Omarov 31ae22961b filesystem: add base test case to call ShutdownStdio without calling Init prior 2023-05-26 18:30:13 +03:00
Alibek Omarov d0127e5e14 filesystem: fix FS_GetDiskPath, it was broken since implementing caseinsensitive emulation, oops
Anyway, FS_GetFullDiskPath is a proper safe version that lacks this bug
2023-05-14 08:21:17 +03:00
Alibek Omarov 5a7b68fcc1 filesystem: add new export FS_GetFullDiskPath, similar to FS_GetDiskPath, but generates full path to the file, including searchpath 2023-05-02 08:52:54 +03:00
Alibek Omarov e2540bd446 filesystem: turn unused caseinsensitive argument in InitStdio into a reserved argument (set to true by default) 2023-04-30 10:14:02 +03:00
Alibek Omarov 07fd4f37ef engine: remove unused -caseinsensitive command line argument 2023-04-30 10:14:02 +03:00
Alibek Omarov 71a3cedba8 filesystem: add size argument to COM_Default/ReplaceExtension calls 2023-04-26 05:20:45 +03:00
Alibek Omarov 1603b8028c filesystem: add size argument to COM_FileBase calls 2023-04-26 05:20:45 +03:00
Alibek Omarov b16fa8eddc public: remove Q_strcat and Q_strcpy, and patch the code that uses it 2023-04-26 05:20:45 +03:00
Alibek Omarov 096ee34f67 public: remove Q_vsprintf, replace by proper Q_vsnprintf proper calls
Fixes weird off by one error caused by glibc updates? I didn't tracked
what causes it exactly but replacing it seems to work. Anyway, we should
remove all 99999 hacks in libpublic.
2023-04-23 18:19:28 +03:00
Alibek Omarov 0d5d30398b filesystem: VFileSystem009: refactoring 2023-04-18 04:50:47 +03:00
Alibek Omarov eb0686fca1 filesystem: fix wrong data type for character in Gets and Ungetc 2023-04-18 04:47:55 +03:00
Alibek Omarov 558ded6d6a filesystem: tests: interface: use correct type for module on Win32 2023-04-15 04:58:29 +03:00
Alibek Omarov c157b7def3 filesystem: tests: interface: various fixes
* correctly check success variable value in CreateInterface
* get rid of C language quirks because this file is C++
* check that globals were filled
2023-04-15 04:08:12 +03:00
Alibek Omarov de88aec958 filesystem: restore DarkPlaces contributors copyrights lost in filesystem_stdio
* Add Xash3D FWGS contributors copyrights
2023-04-15 02:39:38 +03:00
Alibek Omarov 46e2ccd2bf filesystem: wscript: check interface test before everything else
It makes sense since we're using sequential execution here anyway
2023-04-13 20:07:58 +03:00
Alibek Omarov d86ab19351 wscript: refactoring, replace --enable-fs-tests with --enable-tests
* Run filesystem tests in sequential order, to avoid tests being run
before filesystem_stdio DLL is linked
* Include new interface test in filesystem
2023-04-13 18:40:27 +03:00
Alibek Omarov db40d58208 filesystem: add test for probing all interfaces 2023-04-13 18:39:21 +03:00
Alibek Omarov 127bd89b44 filesystem: remove unused watch.c file, added by mistake from inotify branch 2023-03-27 03:56:57 +03:00
Alibek Omarov e673fe9a02 filesystem: only create readwrite directories if they look like a gamedirectory in rodir 2023-03-25 03:27:32 +03:00
Andrey Akhmichin 34160151a4 filesystem: replace va function calls. 2023-03-11 16:28:54 +03:00
fgsfds 577add56f1 filesystem: fs is non case sensitive on nswitch and psvita 2023-03-11 07:09:18 +03:00
fgsfds 7424b29e56 engine: initial psvita build support 2023-03-11 07:09:14 +03:00
Alibek Omarov 3c27384b6b filesystem: speedup fs_ext_path case in FS_FindFile 2023-02-13 06:49:52 +03:00
Alibek Omarov 1e8c26a527 filesystem: wad: fix loading WADs by absolute paths 2023-02-13 06:49:29 +03:00
Alibek Omarov e95161aa14 filesystem: fix ClearSearchPath 2023-02-12 17:09:53 +03:00
Alibek Omarov 9cb867a7d4 filesystem: wad: print errno if wad can't be opened 2023-02-05 02:42:35 +03:00
Alibek Omarov 9c0c1a802c filesystem: fix strict order of loading archives 2023-01-15 13:12:39 +03:00
Alibek Omarov eb0459a045 engine: strip Intel suffixes from server library name, but only on special platforms
Remove same code from filesystem, it's not what filesystem should do
2023-01-10 04:51:34 +03:00
Alibek Omarov 34eb258cae filesystem: dir: remove PATH_SEPARATOR, fix return value when directory is caseinsensitive 2023-01-04 22:34:45 +03:00
Alibek Omarov b4c0ccbede filesystem: fix _wstat usage under Windows, remove PATH_SEPARATOR usage, fix listdirectory 2023-01-04 22:33:59 +03:00
Alibek Omarov 15846a8ea8 filesystem: use POSIX funcs for Windows too, where possible, apply wide char conversion for Sys functions 2023-01-04 18:10:33 +03:00
Alibek Omarov e694081626 filesystem: dir: guarantee file existense in FS_FixFileCase for caseinsensitive directories 2023-01-04 18:09:00 +03:00
Alibek Omarov cb9605430d filesystem: bump FS_API_VERSION (removed unused argument from SysFileExists) 2023-01-04 18:07:18 +03:00
Alibek Omarov 409edf5a70 filesystem: zip: use stdint types, use enum for errors 2023-01-04 17:15:40 +03:00
Alibek Omarov 03a3fb83b6 filesystem: write extended fields to gameinfo.txt, as this function is used to write game info when using rodir 2023-01-03 07:34:05 +03:00
Alibek Omarov e5763e2e9a filesystem: dir: check dir casesensitivity after dir entries list was properly initialized 2023-01-03 01:15:28 +03:00
Alibek Omarov 42a3c7b059 filesystem: dir: fix dir entry cache init in case of directory was empty previously 2023-01-03 00:24:57 +03:00
Alibek Omarov 339711c3c7 filesystem: dir: check casefold directory flag 2022-12-27 02:31:46 +03:00
Alibek Omarov 2febe632c5 filesystem: add caseinsensitive emulation test 2022-12-27 02:31:46 +03:00
Alibek Omarov c454e37064 filesystem: allow to init with NULL overrides 2022-12-27 02:31:46 +03:00
Alibek Omarov fe1aba3561 filesystem: apply caseinsensitivity to file creation
Replace fs_writedir with fs_writepath, exposing current writeable searchpath.
Fix caseinsensitive FS_Search
Remove unused argument from listdirectory()
Minor optimizations and refactoring
2022-12-27 02:31:46 +03:00
Alibek Omarov b36ebc294f filesystem: dir: exit from loop immediately if directory is caseinsensitive 2022-12-27 02:31:46 +03:00
Alibek Omarov 3d71e5d111 filesystem: dir: fix merging existing cache with new directory entries 2022-12-27 02:31:46 +03:00
Alibek Omarov ac59f25375 DO NOT MERGE filesystem: add naive FixFileCase 2022-12-27 02:31:46 +03:00
Alibek Omarov 3393e2d95c filesystem: implement directory entries caching, to avoid excessive directory listing syscalls to emulate case-insensitive filesystems
* simplify game directory initialization code
2022-12-27 02:31:46 +03:00
Alibek Omarov 18e68f1ab3
filesystem: fix missing cast 2022-12-20 16:34:23 +03:00
Alibek Omarov ee218f36e0 filesystem: pak: no need to free files ptr anymore 2022-12-17 00:25:20 +03:00
Alibek Omarov 9397301a73 filesystem: remove excessive filename field from archive structs, use common in searchpath_t. Small optimizations for PAK 2022-12-15 04:06:38 +03:00
Alibek Omarov f1ec612819 filesystem: hungry 2022-12-15 01:06:20 +03:00
Alibek Omarov 08f834cd82 filesystem: make all archive searchpath functions private 2022-12-15 00:59:52 +03:00
Alibek Omarov 48c17d08d9 filesystem: dir: move searchpath initialization to dir.c, make all DIR functions static 2022-12-15 00:52:09 +03:00
Alibek Omarov 934d9ba69a filesystem: fix FS_GetDiskPath 2022-12-12 06:54:42 +03:00
Alibek Omarov eb36fe0155 filesystem: fill searchpath DIR functions only if file was found in direct path 2022-12-05 03:22:07 +03:00
Alibek Omarov 9381a40506 filesystem: check only DLLs for encryption 2022-12-05 03:22:07 +03:00
Andrey Akhmichin 0c4f35e2d0 filesystem: simplify strings operations. 2022-12-04 22:08:06 +03:00
Alibek Omarov 6477f1656e filesystem: simplify string operation 2022-12-04 05:26:22 +03:00
SNMetamorph a2971ce939 filesystem: fixed uninitialized pointers in FS_FindFile when fs_ext_path enabled 2022-11-26 02:45:18 +03:00
Velaron 43c6175918 filesystem: dir.c: safer string operations 2022-11-24 03:19:21 +03:00
Velaron fcd741e2b8 filesystem: fix FS_FixFileCase behavior 2022-11-24 03:19:15 +03:00
Velaron 89807250e5 filesystem: dir.c: optimize string operations 2022-11-24 03:19:10 +03:00
Velaron 24f7db19d8 filesystem: switch file operations to an interface 2022-11-24 03:19:05 +03:00
Alibek Omarov b1ee27a3f3 filesystem: add new token internal_vgui_support to mark client dlls that have internal VGUI implementation(to support other UI systems) 2022-11-12 16:35:18 +03:00
Alibek Omarov adb8ec1da8 filesystem: try to normalize linux gamedll path for liblist.gam 2022-11-10 11:58:44 +03:00
Bien Pham 816337a7bb filesystem: set root directory as static
Counter-Strike uses COM_ExpandFileName to get
full path to filesystem_stdio. When reading liblist.gam,
the engine will clear the search path and the root search path
will be cleared. Set it as static so it will be excluded from clearing.
2022-11-02 18:07:25 +06:00
Alibek Omarov 234c843f60 filesystem: integrate inotify for file changes 2022-09-10 22:55:07 +03:00
Alibek Omarov 0ed9391969 filesystem: wscript: add dummy filesystem_includes target that only exposes public filesystem_stdio include paths 2022-09-10 22:52:52 +03:00
Alibek Omarov fce8afabfb filesystem: allow acquiring C interface through CreateInterface export 2022-08-25 20:33:16 +03:00
Alibek Omarov 0d449370e0 filesystem: fixes for GCC 3 2022-08-06 20:33:01 +03:00
Alibek Omarov 10ad1c3b38 filesystem: use correct flushing function for file descriptors on Win32 2022-08-06 20:19:42 +03:00
Alibek Omarov 33cbead4a4 filesystem: wscript: fix library name on Android 2022-08-06 20:17:41 +03:00
Alibek Omarov b7b9c611cf filesystem: wscript: disable RTTI and exceptions(useful on Android), we don't need it here. Link as C++ library. 2022-08-01 14:06:00 +03:00
SNMetamorph fd7dba74cd filesystem: fixed build for Windows 2022-08-01 12:54:26 +03:00
Alibek Omarov 55a29e6e6b filesystem: implement VFileSystem009 interface 2022-07-28 18:56:02 +03:00
Alibek Omarov 56d7c05b51 filesystem: generated VFileSystem009 from pdwtags output, removed unneeded in C++ this first argument 2022-07-28 18:56:02 +03:00
Alibek Omarov 5e4fc64430 filesystem: introduce new module, based on engine filesystem.
The goal is to share filesystem code between engine and
utilities and provide C++ VFileSystem interface in the future
2022-07-28 18:56:02 +03:00