第三方静态库的使用

1. 工程根目录下创建文件夹“ThirdParty”,然后在此文件夹下创建“includes”和“libs”文件夹

2. 拷贝静态库的头文件和库文件到上面的文件夹下

3. 修改工程的build.cs文件,增加下面代码

    1)在类中

         private string ThirdPartyPath
         {
              get { return Path.GetFullPath(Path.Combine(ModuleDirectory, "../../ThirdParty/")); }

         }

    2)在类的构造函数中

        PublicIncludePaths.Add(Path.Combine(ThirdPartyPath, "includes"));

        PublicAdditionalLibraries.Add(Path.Combine(ThirdPartyPath, "libs", "GraphicsPixel.lib"));

猜你喜欢

转载自blog.csdn.net/sukhoi27smk/article/details/79507025