now can package ipa, still problems with signing
This commit is contained in:
@@ -2,6 +2,7 @@
|
||||
#include "tier1/interface.h"
|
||||
#include "tier0/lib.h"
|
||||
#include "errno.h"
|
||||
#include "dirent.h"
|
||||
|
||||
class CLIBCFileHandle : public IFileHandle
|
||||
{
|
||||
@@ -11,6 +12,12 @@ public:
|
||||
|
||||
};
|
||||
|
||||
class CLIBCDirectoryHandle: public IDirectoryHandle
|
||||
{
|
||||
public:
|
||||
DIR *m_pDir;
|
||||
};
|
||||
|
||||
class CLIBCFileSystem : public IFileSystem
|
||||
{
|
||||
public:
|
||||
@@ -129,6 +136,30 @@ public:
|
||||
|
||||
return szData;
|
||||
};
|
||||
|
||||
virtual IDirectoryHandle *OpenDir( const char *szDirName ) override
|
||||
{
|
||||
CLIBCDirectoryHandle *pHandle = NULL;
|
||||
DIR *pDir = opendir(szDirName);
|
||||
if (pDir == NULL)
|
||||
return NULL;
|
||||
|
||||
pHandle = new CLIBCDirectoryHandle;
|
||||
pHandle->m_pDir = pDir;
|
||||
return pHandle;
|
||||
|
||||
};
|
||||
|
||||
virtual void CloseDir( IDirectoryHandle *pDir ) override
|
||||
{
|
||||
if (!pDir)
|
||||
return;
|
||||
CLIBCDirectoryHandle *pCDir = (CLIBCDirectoryHandle*)pDir;
|
||||
|
||||
closedir(pCDir->m_pDir);
|
||||
|
||||
delete (CLIBCDirectoryHandle*)pDir;
|
||||
};
|
||||
};
|
||||
|
||||
EXPOSE_INTERFACE(CLIBCFileSystem, IFileSystem, FILESYSTEM_INTERFACE_VERSION)
|
||||
|
||||
Reference in New Issue
Block a user