Step-by-step: How to build EmulationStation on Windows
-
@Nismo No. That one should build fine on Windows.
-
@fieldofcows Thanks again.
-
@fieldofcows I'm having the same issues someone else is having with the following:
5>c:\src\emulationstation\es-gamedata\src\GameDataList.h(11): fatal error C1083: Cannot open include file: 'sqlite3.h': No such file or directory (compiling source file C:\src\EmulationStation\es-gamedata\src\GameData.cpp) 5>c:\src\emulationstation\es-gamedata\src\GameDataList.h(11): fatal error C1083: Cannot open include file: 'sqlite3.h': No such file or directory (compiling source file C:\src\EmulationStation\es-gamedata\src\GameDataList.cpp) 5>c:\src\emulationstation\es-gamedata\src\GameDataList.h(11): fatal error C1083: Cannot open include file: 'sqlite3.h': No such file or directory (compiling source file C:\src\EmulationStation\es-gamedata\src\GameDataFolder.cpp) 5>c:\src\emulationstation\es-gamedata\src\GameDataTags.h(11): fatal error C1083: Cannot open include file: 'sqlite3.h': No such file or directory (compiling source file C:\src\EmulationStation\es-gamedata\src\GameDataItem.cpp) 5>c:\src\emulationstation\es-gamedata\src\GameDataList.h(11): fatal error C1083: Cannot open include file: 'sqlite3.h': No such file or directory (compiling source file C:\src\EmulationStation\es-gamedata\src\GameDataTags.cpp) ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ 4>C:\src\EmulationStation\es-core\src\platform.cpp(87): error C3861: 'open': identifier not found 4>C:\src\EmulationStation\es-core\src\platform.cpp(89): error C3861: 'close': identifier not found ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ 4>C:\src\EmulationStation\es-core\src\Util.cpp(105): error C2440: 'initializing': cannot convert from 'const boost::filesystem::path::value_type *' to 'std::basic_string<char,std::char_traits<char>,std::allocator<char>>' 4> C:\src\EmulationStation\es-core\src\Util.cpp(105): note: No constructor could take the source type, or constructor overload resolution was ambiguous 4>C:\src\EmulationStation\es-core\src\Util.cpp(106): error C2440: 'initializing': cannot convert from 'const boost::filesystem::path::value_type *' to 'std::basic_string<char,std::char_traits<char>,std::allocator<char>>' 4> C:\src\EmulationStation\es-core\src\Util.cpp(106): note: No constructor could take the source type, or constructor overload resolution was ambiguous
Now the open()/close() issue you state would be fixed in your fork but I'm using your fork. Not sure about the sqlite and initializing issues.
I'm not sure if this is related, but when building a few of the libraries, VS stated a few projects were skipped.
-
@trigger_death My 'master' branch is not the one to use anymore. It should be tracking the RetroPie branch but I think I've committed some stuff there by mistake. I generally do not use that one anymore.
I took a backup of the branch from the point where I was working on the video preview with Nismo and named it 'old_master'. You find it here: https://github.com/fieldofcows/EmulationStation/commits/old_master. This might be a good starting point if you want a Windows build. You can switch to it like this:
git clone https://github.com/fieldofcows/EmulationStation.git EmulationStation cd EmulationStation git checkout old_master
I've got a few features to sort out and try to get merged back to retropie. When this is done I'll create a Windows build branch and keep it up to date with my latest developments.
-
@fieldofcows Thanks it works. :D
But about the Windows branch, does that mean there's currently separate branches for building on Windows and Linux systems? Because I was hoping to use this to debug before spending multiple hours building on my Pi.
-
@fieldofcows I'm very happy to know that we can have an up to date windows branch.
Thank you very much.
@trigger_death If the branchs are up to date I don't think you could have any problem.
-
@trigger_death said in Step-by-step: How to build EmulationStation on Windows:
But about the Windows branch, does that mean there's currently separate branches for building on Windows and Linux systems?
That particular branch builds on Windows, Linux and Raspberry pi without problems.
There is a simple fix that needs to be applied to the retropie ES which would allow it to build on Windows. I'll see if I can suggest a PR to get it included in the retropie fork. Although this is a RPi version, I don't see any harm in including this fix.
-
@fieldofcows I hope this isn't going too off topic but: Although you say it's well documented, I actually find this guide for Windows to be much more understandable than any of the other guides for Linux or the Raspberry Pi. However, I can't seem to find any guides on how to build & install EmulationStation on RetroPie. Do you have insight into that? It's not mentioned anywhere to where the output should be as well as how to setup the libraries.
Edit: Nevermind, I've figured out how to do it and layed it out here.
-
This PR, which was merged in recently, broke my builds of ES under windows.
Basically, what happened is that PugiXML is now an git submodule, which is much easier to maintain. However, when you rebase your view, it is not automatically included.
You need to performgit submodule update --init
in order to make that happen.
Easy enough, but it took me a while to figure it out.
@BuZz: will we do the same for nanosvg?
-
@Zigurana sorry, should have mentioned that. I probably need to update the readme too.
If nanosvg is managed on git, we could.
-
I'm having trouble with the final Cmake step. It can't find the boost libraries. I've used the retroPie branch and the fix_debug_and_win_builds. I was using visual studio 2017 but when I switched to 2015 I still got the same error from boost.
CMake Error at C:/Program Files/CMake/share/cmake-3.8/Modules/FindBoost.cmake:1813 (message): Unable to find the requested Boost libraries. Boost version: 1.61.0 Boost include path: C:/src/lib/boost_1_61_0 Could not find the following Boost libraries: boost_system boost_date_time boost_locale No Boost libraries were found. You may need to set BOOST_LIBRARYDIR to the directory containing Boost libraries or BOOST_ROOT to the location of Boost. Call Stack (most recent call first): CMakeLists.txt:49 (find_package) -- Configuring incomplete, errors occurred!
Thanks
-
Have you installed it manually? Use the boost installer.
-
@Nismo I didn't install it manually. I used the installer you and the tutorial mentioned. I have a boost_1_61_0\lib32-msvc-14.0 directory with date_time, system and locale files in it.
-
Can you send to me a folder list inside C:/src/lib/boost_1_61_0????
-
@Nismo Here you go.
-
Have you installed C-Make or it's a portable one?
I'm uploading my working lib folder for you, but it will take a few minutes.
-
@Nismo I installed Cmake. It's version 3.8. I appreciate it.
-
A few minutes remaining for upload complete, then you can rename your C:/src/lib folder to C:/src/lib_old and try with mine...
-
-
@Nismo Still doesn't work. Tried VS 2017 command prompt, failed, deleted everything in build directory and tried VS 2015. I did notice before the boost errors that it couldn't find PkgConfig. Here's my full output from running the 2015 command prompt with your lib being the active one.
C:\src\EmulationStation\build>cmake -g "Visual Studio 14 2015 x86" .. -DEIGEN3_INCLUDE_DIR=%ES_LIB_DIR%\eigen -DFREETYPE_INCLUDE_DIRS=%ES_LIB_DIR%\freetype-2.7\include -DFREETYPE_LIBRARY=%ES_LIB_DIR%\freetype-2.7\objs\vc2010\Win32\freetype27.lib -DFreeImage_INCLUDE_DIR=%ES_LIB_DIR%\FreeImage\Source -DFreeImage_LIBRARY=%ES_LIB_DIR%\FreeImage\Dist\x32\FreeImage.lib -DSDL2_INCLUDE_DIR=%ES_LIB_DIR%\SDL2-2.0.5\include -DSDL2_LIBRARY=%ES_LIB_DIR%\SDL2-2.0.5\build\Release\SDL2.lib;%ES_LIB_DIR%\SDL2-2.0.5\build\Release\SDL2main.lib;Imm32.lib;version.lib -DBOOST_ROOT=%ES_LIB_DIR%\boost_1_61_0 -DBoost_LIBRARY_DIR=%ES_LIB_DIR%\boost_1_61_0\lib32-msvc-14.0 -DCURL_INCLUDE_DIR=%ES_LIB_DIR%\curl-7.50.3\include -DCURL_LIBRARY=%ES_LIB_DIR%\curl-7.50.3\builds\libcurl-vc14-x86-release-dll-ipv6-sspi-winssl\lib\libcurl.lib -DVLC_INCLUDE_DIR=%ES_LIB_DIR%\libvlc-2.2.2\include -DVLC_LIBRARIES=%ES_LIB_DIR%\libvlc-2.2.2\lib\msvc\libvlc.lib;%ES_LIB_DIR%\libvlc-2.2.2\lib\msvc\libvlccore.lib -DVLC_VERSION=1.0.0 -- Building for: Visual Studio 15 2017 -- The C compiler identification is MSVC 19.10.25019.0 -- The CXX compiler identification is MSVC 19.10.25019.0 -- Check for working C compiler: C:/Program Files (x86)/Microsoft Visual Studio/2017/Community/VC/Tools/MSVC/14.10.25017/bin/HostX86/x86/cl.exe -- Check for working C compiler: C:/Program Files (x86)/Microsoft Visual Studio/2017/Community/VC/Tools/MSVC/14.10.25017/bin/HostX86/x86/cl.exe -- works -- Detecting C compiler ABI info -- Detecting C compiler ABI info - done -- Check for working CXX compiler: C:/Program Files (x86)/Microsoft Visual Studio/2017/Community/VC/Tools/MSVC/14.10.25017/bin/HostX86/x86/cl.exe -- Check for working CXX compiler: C:/Program Files (x86)/Microsoft Visual Studio/2017/Community/VC/Tools/MSVC/14.10.25017/bin/HostX86/x86/cl.exe -- works -- Detecting CXX compiler ABI info -- Detecting CXX compiler ABI info - done -- Detecting CXX compile features -- Detecting CXX compile features - done Looking for bcm_host.h bcm_host.h not found Looking for libMali.so libMali.so not found -- Found OpenGL: opengl32 -- Found Freetype: c:\src\lib\freetype-2.7\objs\vc2010\Win32\freetype27.lib -- Looking for FreeImage... -- Could NOT find PkgConfig (missing: PKG_CONFIG_EXECUTABLE) -- Found FreeImage: c:\src\lib\FreeImage\Dist\x32\FreeImage.lib -- Looking for pthread.h -- Looking for pthread.h - not found -- Found Threads: TRUE -- Found SDL2: c:\src\lib\SDL2-2.0.5\build\Release\SDL2.lib;c:\src\lib\SDL2-2.0.5\build\Release\SDL2main.lib;Imm32.lib;version.lib CMake Error at C:/Program Files/CMake/share/cmake-3.8/Modules/FindBoost.cmake:1813 (message): Unable to find the requested Boost libraries. Boost version: 1.61.0 Boost include path: C:/src/lib/boost_1_61_0 Could not find the following Boost libraries: boost_system boost_date_time boost_locale No Boost libraries were found. You may need to set BOOST_LIBRARYDIR to the directory containing Boost libraries or BOOST_ROOT to the location of Boost. Call Stack (most recent call first): CMakeLists.txt:52 (find_package) -- Found CURL: C:/src/lib/curl-7.50.3/builds/libcurl-vc14-x86-release-dll-ipv6-sspi-winssl/lib/libcurl.lib (found version "7.50.3") -- VLC library found -- Configuring incomplete, errors occurred! See also "C:/src/EmulationStation/build/CMakeFiles/CMakeOutput.log". See also "C:/src/EmulationStation/build/CMakeFiles/CMakeError.log".
Contributions to the project are always appreciated, so if you would like to support us with a donation you can do so here.
Hosting provided by Mythic-Beasts. See the Hosting Information page for more information.