no engine anymore
This commit is contained in:
@@ -1,30 +1,62 @@
|
||||
#ifndef HELPER_H
|
||||
#define HELPER_H
|
||||
|
||||
#include "apktool.h"
|
||||
#include "tier1/utlstring.h"
|
||||
#include "target.h"
|
||||
|
||||
#define FPC_TEMPORAL_DIRNAME ".fpc"
|
||||
|
||||
class CProject
|
||||
|
||||
struct BaseProject_t
|
||||
{
|
||||
public:
|
||||
Target_t m_target = Target_t::DefaultTarget();
|
||||
CUtlString m_szName;
|
||||
unsigned int GenerateProjectHash( void );
|
||||
};
|
||||
|
||||
interface IFileSystem2
|
||||
|
||||
struct CPUProject_t : public BaseProject_t
|
||||
{
|
||||
public:
|
||||
static char *OwnDirectory();
|
||||
static char *BuildDirectory();
|
||||
static void MakeDirectory( const char *psz );
|
||||
static void CopyFile( const char *szDestination, const char *szOrigin );
|
||||
static void CopyDirectory( const char *szDestination, const char *szOrigin );
|
||||
static bool ShouldRecompile( const char *szSource, const char *szOutput );
|
||||
Target_t m_target = Target_t::DefaultTarget();
|
||||
|
||||
};
|
||||
|
||||
|
||||
struct ShaderProject_t : public BaseProject_t
|
||||
{
|
||||
public:
|
||||
EShaderTarget m_eTarget;
|
||||
};
|
||||
|
||||
//-----------------------------------------------------------------------------
|
||||
// File system.
|
||||
//-----------------------------------------------------------------------------
|
||||
|
||||
#define FILE_SYSTEM_2_INTERFACE_NAME "FileSystem2_001"
|
||||
|
||||
abstract_class IFileSystem2
|
||||
{
|
||||
public:
|
||||
// Returns a directory of fpc executable
|
||||
virtual char *OwnDirectory() = 0;
|
||||
|
||||
// Returns directory of build.cpp
|
||||
virtual char *BuildDirectory() = 0;
|
||||
|
||||
virtual void MakeDirectory( const char *psz ) = 0;
|
||||
virtual void CopyFile( const char *szDestination, const char *szOrigin ) = 0;
|
||||
virtual void CopyDirectory( const char *szDestination, const char *szOrigin ) = 0;
|
||||
virtual bool ShouldRecompile( const char *szSource, const char *szOutput ) = 0;
|
||||
};
|
||||
|
||||
extern IFileSystem2 *filesystem2;
|
||||
|
||||
|
||||
//-----------------------------------------------------------------------------
|
||||
// Build stage.
|
||||
//-----------------------------------------------------------------------------
|
||||
class CBuildStage
|
||||
{
|
||||
public:
|
||||
@@ -33,8 +65,10 @@ public:
|
||||
int(*m_pMainFn)();
|
||||
};
|
||||
|
||||
#define DECLARE_BUILD_STAGE(sz, fn) \
|
||||
CBuildStage __##sz##_build_stage(#sz, fn);
|
||||
#define DECLARE_BUILD_STAGE(sz) \
|
||||
int __build_stage_##sz(); \
|
||||
CBuildStage __##sz##_build_stage(#sz, __build_stage_##sz); \
|
||||
int __build_stage_##sz()
|
||||
|
||||
CUtlVector<CBuildStage*>& BuildStages();
|
||||
|
||||
|
||||
Reference in New Issue
Block a user