? ,,

亚洲午夜精品视频_国产黄大片_网站av_99亚洲伊人久久精品影院红桃_91av入口_永久免费av片在线观看全网站

聯(lián)系我們

給我們留言

聯(lián)系我們

地址:福建省晉江市青陽街道洪山路國際工業(yè)設(shè)計(jì)園納金網(wǎng)

郵箱:info@narkii.com

電話:0595-82682267

(周一到周五, 周六周日休息)

當(dāng)前位置:主頁 > 3D教程 > 圖文教程

UE4 Project.Build.cs配置示例(UE4引用libuv靜態(tài)鏈接庫

來源: 52vr | 責(zé)任編輯:傳說的落葉 | 發(fā)布時(shí)間: 2019-06-06 08:27 | 瀏覽量:

[UE4]Project.Build.cs配置示例(UE4引用libuv靜態(tài)鏈接庫)

 

這個(gè)例子演示了如何鏈接libuv靜態(tài)庫相關(guān)的配置。

libuv版本是v1.8

 
  1. // Fill out your copyright notice in the Description page of Project Settings.  
  2.   
  3. using System.IO;  
  4. using UnrealBuildTool;  
  5.   
  6. public class HuaiKXSrv : ModuleRules  
  7. {  
  8.     private string ModulePath  
  9.     {  
  10.         get { return Path.GetDirectoryName(RulesCompiler.GetModuleFilename(this.GetType().Name)); }  
  11.     }  
  12.   
  13.     private string ThirdPartyPath  
  14.     {  
  15.         get { return Path.GetFullPath(Path.Combine(ModulePath, "../../ThirdParty/")); }  
  16.     }  
  17.   
  18.   
  19.     public HuaiKXSrv(TargetInfo Target)  
  20.     {  
  21.         PublicDependencyModuleNames.AddRange(new string[] { "Core""CoreUObject""Engine""InputCore" });  
  22.   
  23.         PrivateDependencyModuleNames.AddRange(new string[] {  });  
  24.   
  25.         // Uncomment if you are using Slate UI  
  26.         // PrivateDependencyModuleNames.AddRange(new string[] { "Slate", "SlateCore" });  
  27.   
  28.         // Uncomment if you are using online features  
  29.         // PrivateDependencyModuleNames.Add("OnlineSubsystem");  
  30.         // if ((Target.Platform == UnrealTargetPlatform.Win32) || (Target.Platform == UnrealTargetPlatform.Win64))  
  31.         // {  
  32.         //      if (UEBuildConfiguration.bCompileSteamOSS == true)  
  33.         //      {  
  34.         //          DynamicallyLoadedModuleNames.Add("OnlineSubsystemSteam");  
  35.         //      }  
  36.         // }  
  37.   
  38.         AddDefines(Target);  
  39.   
  40.         LoadLibuv(Target);  
  41.     }  
  42.   
  43.     public void AddDefines(TargetInfo Target)  
  44.     {  
  45.         if ((Target.Platform == UnrealTargetPlatform.Win32) || (Target.Platform == UnrealTargetPlatform.Win64))  
  46.         {  
  47.             Definitions.Add("_IS_WINDOWS_");  
  48.         }  
  49.         else  
  50.         {  
  51.             Definitions.Add("_IS_LINUX_");  
  52.         }  
  53.     }  
  54.   
  55.     //鏈接libuv  
  56.     public bool LoadLibuv(TargetInfo Target)  
  57.     {  
  58.         bool isLibrarySupported = false;  
  59.   
  60.         //libuv需要的系統(tǒng)lib  
  61.         PublicAdditionalLibraries.Add("IPHLPAPI.lib");  
  62.         PublicAdditionalLibraries.Add("Psapi.lib");  
  63.         PublicAdditionalLibraries.Add("userenv.lib");  
  64.         PublicAdditionalLibraries.Add("msvcrtd.lib");  
  65.   
  66.         if (Target.Configuration == UnrealTargetConfiguration.Debug || Target.Configuration == UnrealTargetConfiguration.DebugGame)  
  67.         {  
  68.             if ((Target.Platform == UnrealTargetPlatform.Win64) || (Target.Platform == UnrealTargetPlatform.Win32))  
  69.             {  
  70.                 isLibrarySupported = true;  
  71.   
  72.                 string PlatformString = (Target.Platform == UnrealTargetPlatform.Win64) ? "D.x64" : "D.x86";  
  73.                 string LibrariesPath = Path.Combine(ThirdPartyPath, "Libuv""Libraries");  
  74.   
  75.                 string LibuvLibPath = Path.Combine(LibrariesPath, "libuv" + PlatformString + ".lib");  
  76.                 PublicAdditionalLibraries.Add(LibuvLibPath);  
  77.                 System.Console.WriteLine("#### Set Debug Libuv Libraries ####:" + LibuvLibPath);  
  78.             }  
  79.         }  
  80.         else if (Target.Configuration == UnrealTargetConfiguration.Shipping || Target.Configuration == UnrealTargetConfiguration.Development)  
  81.         {  
  82.             if ((Target.Platform == UnrealTargetPlatform.Win64) || (Target.Platform == UnrealTargetPlatform.Win32))  
  83.             {  
  84.                 isLibrarySupported = true;  
  85.   
  86.                 string PlatformString = (Target.Platform == UnrealTargetPlatform.Win64) ? "x64" : "x86";  
  87.                 string LibrariesPath = Path.Combine(ThirdPartyPath, "Libuv""Libraries");  
  88.   
  89.                 string LibuvLibPath = Path.Combine(LibrariesPath, "libuv." + PlatformString + ".lib");  
  90.                 PublicAdditionalLibraries.Add(LibuvLibPath);  
  91.                 System.Console.WriteLine("#### Set Shipping Libuv Libraries ####:" + LibuvLibPath);  
  92.             }  
  93.         }  
  94.   
  95.         if (isLibrarySupported)  
  96.         {  
  97.             System.Console.WriteLine("#### Set Libuv Includes ####:" + Path.Combine(ThirdPartyPath, "Libuv""Includes"));  
  98.             // Include path  
  99.             PublicIncludePaths.Add(Path.Combine(ThirdPartyPath, "Libuv""Includes"));  
  100.         }  
  101.   
  102.         //Definitions.Add(string.Format("WITH_BOBS_MAGIC_BINDING={0}", isLibrarySupported ? 1 : 0));  
  103.   
  104.         return isLibrarySupported;  
  105.     }  
  106. }  

 


相關(guān)文章
網(wǎng)友評論

您需要登錄后才可以發(fā)帖 登錄 | 立即注冊

關(guān)閉

全部評論:0條

推薦
熱門
主站蜘蛛池模板: 午夜亚洲福利 | 日本免费人成黄页网观看视频 | 久久久久国产精品 | 一本久久知道综合久久 | 久久精品爱 | 香蕉精品在线 | aaaa级片 | 作爱视频在线免费观看 | 91极品视频在线观看 | 天天摸天天添 | 国产中文99视频在线观看 | 伊人干综合 | 少妇性l交大片 | 老汉影视永久免费视频 | 亚洲免费三级电影 | 一本大道加勒比久久 | 国产视频不卡 | 1717she精品永久免费视频 | 亚洲中文字幕无码中文字在线 | 韩国精品欧美一区二区三区 | www.亚洲欧美 | 亚洲熟妇色xxxxx欧美老妇y | 18处破外女出血在线 | 久久96精品国产 | 免费看美女的网站 | 精品国产午夜久久久久九九 | 中文字幕亚洲欧美日韩2019 | 自拍偷拍片 | 国产一码二码免费观看 | 中文字幕欧美日韩久久 | 91网站免费看 | 妞干网这里只有精品 | 国产亚洲无线码一区二区 | 免费精品一区二区三区第35 | 免费观看欧美成人禁片 | 四虎网站网址 | 天天搞天天色 | 97超级碰碰人妻中文字幕 | 欧美视屏在线观看 | 亚洲国产视频网 | 国产福利一区二区三区 |