Build system almost done

This commit is contained in:
2025-06-02 19:56:18 +03:00
parent ade32c24a6
commit 3beb7aad3b
16 changed files with 191 additions and 77 deletions

View File

@@ -3,6 +3,8 @@
#include "tier0/platform.h"
#include "tier1/utlvector.h"
#include "tier1/utlstring.h"
#include "unistd.h"
#include "libgen.h"
unsigned int g_hashState = 102851263;
unsigned int CProject::GenerateProjectHash( void )
@@ -19,11 +21,19 @@ unsigned int CProject::GenerateProjectHash( void )
return hash;
};
static char path[1024];
static ssize_t pathSize = readlink("/proc/self/exe", path, sizeof(path) - 1);
static char* pathDir = dirname(path);
char *IFileSystem2::OwnDirectory()
{
return pathDir;
};
void IFileSystem2::MakeDirectory( const char *psz )
{
CUtlVector<CUtlString> args = {
"-p",
psz,
CUtlString(psz),
};
IRunner::Run("mkdir", args);
};