您的位置:首页 > 编程语言

教程(转+自汉化):如何在Win下编译MPC-BE源代码官方版.

2016-10-07 12:24 465 查看
轻教程。

Part A:准备Visual Studio和DirectX SDK环境。

安装Visual Studio 2015 Pro到你的电脑。

下载地址:http://www.itellyou.cn/

安装DirecX SDK(June 2010)到你的电脑。

下载地址:https://go.microsoft.com/fwlink/?LinkID=71193

Part B:准备GCC环境

注意:*如果您在其他目录下安装MSYS / MinGW的包,你将不得不使用该路径在下面的步骤。

1.下载并解压MSYS_MinGW-w64_GCC_610_x86-x64.7z到 C:/MSYS

http://mpc-be.org/MSYS/MSYS_MinGW-w64_GCC_610_x86-x64.7z

2.添加以下环境变量(在系统属性 - >高级 - >环境变量):
Variable    Value

MSYS        C:\MSYS

MINGW32     C:\MSYS\mingw

MINGW64     C:\MSYS\mingw

YASM        C:\MSYS\bin


3.找到C:\MSYS\etc\目录,创建文件名为“fstab”的文件,在文件中添加

C:\MSYS\mingw \mingw

注意:中间是的空格按TAB键。

Part C:下载并编译MPCBE

下载MPCBE源码:

svn://mpc-next.ru/mpc-be/trunk

https://sourceforge.net/projects/mpcbe/

编译MPCBE源码:

首先在编译前请先执行trunk文件夹中的 update_gcc.bat

这是必要做复制文件和libgcc.a的libmingwex.a,在文件夹“LIB”和“lib64下”

然后,你可以尝试直接运行build.bat直接进行编译,也可以用VS2015逐个编译:

打开解决方案文件:C:\ MPC-be\ MPC-be.sln

   更改该解决方案的配置,以“Release”(在工具栏中)。

5.按确定保存更改并关闭属性窗口。

6.按F7来构建解决方案。

7.你现在有在C MPC-be.exe:\ MPC-be\ BIN \ MPC-be_x86

8.打开解决方案文件C:\ MPC-be\ mpciconlib.sln

9.按F7来构建解决方案。

10.你现在有mpciconlib.dll在C:\ MPC-be\ BIN \ MPC-be_x86

11.打开解决方案文件C:\ MPC-be\ mpcresources.sln

    在Visual Studio中去Build->Batch Build->Press Select All->Press Build

12.你现在有mpcresources.XX.dll在C:\ MPC-be\ BIN \ MPC-be_x86 \lang

如果你在编译的过程中出现缺少第三方库的情况,可以手动进行添加它们。

(1)Little-CMS

下载地址:https://github.com/mm2/Little-CMS

放置路径:(…)\mpc-hc-develop\src\thirdparty\lcms2\library\

(2)LAVFilters

下载地址:https://github.com/mpc-hc/LAVFilters/tree/d863428ee7619737da78331107ffe95da7560849

放置路径:(…)\mpc-hc-develop\src\thirdparty\LAVFilters\src\

(6)FFmpeg

下载地址:https://github.com/mpc-hc/FFmpeg/tree/c054258b9d776172cf0859e5f3f7bc3b45d95085

放置路径:(…)\mpc-hc-develop\src\thirdparty\LAVFilters\src\ffmpeg\

(7)libbluray

下载地址:https://github.com/tourettes/libbluray

放置路径:(…)\mpc-hc-develop\src\thirdparty\LAVFilters\src\libbluray\

(3)freetype2

下载地址:https://github.com/tourettes/freetype2

放置路径:(…)\mpc-hc-develop\src\thirdparty\LAVFilters\src\libbluray\3rd_party\freetype2\

(9)qsdecoder

下载地址:https://github.com/jeeb/qsdecoder

放置路径:(…)\mpc-hc-develop\src\thirdparty\LAVFilters\src\qsdecoder\

(10)dcadec

下载地址:https://github.com/foo86/dcadec/tree/2a9186e34ce557d3af1a20f5b558d1e6687708b9

放置路径:(…)\mpc-hc-develop\src\thirdparty\LAVFilters\src\thirdparty\dcadec\

(4)MediaInfoLib

下载地址:https://github.com/MediaArea/MediaInfoLib

放置路径:(…)\mpc-hc-develop\src\thirdparty\MediaInfo\library\

(5)rarfilesource

下载地址:https://github.com/mpc-hc/rarfilesource

放置路径:(…)\mpc-hc-develop\src\thirdparty\RARFileSource\library\

(8)ZenLib

下载地址:https://github.com/MediaArea/ZenLib

放置路径:(…)\mpc-hc-develop\src\thirdparty\ZenLib\library\

请将 mpc-hc-develop 自动脑补为 MPC-BE

参考资料:

https://trac.mpc-hc.org/wiki/How_to_compile_the_MPC

http://blog.sina.com.cn/s/blog_7155fb1a0102vom7.html

http://blog.csdn.net/leixiaohua1020/article/details/11750505

@本地磁盘姬 整理

ohayou.moeres.org

微博@萌萌的本地磁盘w

2016年09月15日
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签: