introduces ios support? still needs metal
This commit is contained in:
@@ -29,8 +29,6 @@ CUtlVector<CUtlString> engine_CompiledFiles = {
|
||||
/* rendering */
|
||||
"engine/vk_videosdl.cpp",
|
||||
"engine/vk_video.cpp",
|
||||
"engine/vk_mesh.cpp",
|
||||
"engine/vk_postprocessing.cpp",
|
||||
|
||||
/* io */
|
||||
"engine/input.cpp",
|
||||
@@ -40,11 +38,14 @@ CUtlVector<CUtlString> engine_CompiledFiles = {
|
||||
CUtlVector<CUtlString> engine_Libraries = {
|
||||
"c",
|
||||
"SDL3",
|
||||
"vulkan",
|
||||
};
|
||||
|
||||
int engine_build()
|
||||
{
|
||||
if (Target_t::DefaultTarget().kernel == TARGET_KERNEL_DARWIN)
|
||||
engine_Libraries.AppendTail("MoltenVK");
|
||||
if (Target_t::DefaultTarget().kernel == TARGET_KERNEL_LINUX)
|
||||
engine_Libraries.AppendTail("vulkan");
|
||||
CCProject compileProject = {};
|
||||
CLDProject ldProject = {};
|
||||
|
||||
@@ -53,19 +54,27 @@ int engine_build()
|
||||
compileProject.includeDirectories = all_IncludeDirectories;
|
||||
compileProject.bFPIC = true;
|
||||
ldProject = compileProject.Compile();
|
||||
ldProject.linkType = ELINK_DYNAMIC_LIBRARY;
|
||||
ldProject.libraries = engine_Libraries;
|
||||
ldProject.objects.AppendTail((CObject){tier1_lib});
|
||||
ldProject.objects.AppendTail((CObject){rapier_lib});
|
||||
if (bStaticBuild)
|
||||
ldProject.linkType = ELINK_STATIC_LIBRARY;
|
||||
else
|
||||
{
|
||||
ldProject.objects.AppendTail((CObject){tier1_lib});
|
||||
ldProject.objects.AppendTail((CObject){rapier_lib});
|
||||
ldProject.linkType = ELINK_DYNAMIC_LIBRARY;
|
||||
}
|
||||
|
||||
CUtlString outputProject = ldProject.Link();
|
||||
|
||||
if (!bStaticBuild)
|
||||
{
|
||||
IFileSystem2::MakeDirectory(CUtlString("%s/bin",szOutputDir.GetString()));
|
||||
IFileSystem2::CopyFile(CUtlString("%s/bin", szOutputDir.GetString()), outputProject);
|
||||
} else {
|
||||
engine_lib = outputProject;
|
||||
}
|
||||
|
||||
|
||||
const char *szGameName = ICommandLine::ParamValue("-game");
|
||||
if (szGameName == NULL)
|
||||
szGameName = "funnygame";
|
||||
IFileSystem2::MakeDirectory(CUtlString("build/%s/game/bin",szGameName));
|
||||
IFileSystem2::CopyFile(CUtlString("build/%s/game/bin",szGameName), outputProject);
|
||||
|
||||
|
||||
return 0;
|
||||
|
||||
Reference in New Issue
Block a user