Hello all,
I am new to this forum and this is my first post. sort of exited to join the group. Although, i have been running into issues setting up my environment. Can someone please re-write this section of the setup. it is really difficult to understand and i am sure people are mostly guessing their way through this. Both the cmake and library parts are missing crucial and fundamental steps. We can't tell if it's actually needed to set some of these environment variables, the names of the files missing from OGRE, and which directories they need to be added. It just needs to be ordered by sequence of numbered steps with more explanations.
Libraries
Ogre: Choose OGRE v1.8 SDK for Visual Studio 2008 or 2010. Environment variable OGRE_HOME.
Boost: Boost lib used by OGRE but perhaps you should set it manually. In OGRE boost system, file_system, and program_options are missing, you should download the mt and mt-gd for vc90 and putt libs and dll in your OgreSDK_vc9_v1-7-1\boost_1_42\lib dir, they are in the boost-binaries\1.42.0 section in sourceforge download page. The boost source included in OGRE is missing filesystem and program_option, you should download them from boost sources and copy the directories in Ogre3D\boost_1_42\boost dir. Environment variable BOOST_ROOT.
Freetype: Freetype2, and set the environment variable FREETYPE_DIR to the <install_path>
OIS
OpenAL: OpenAL11CoreSDK, environment variable OPENALDIR.
Audiere: Environment variable AUDIERE_DIR.
QT. Environment variable QTDIR.
GNU C compiler Library
libsndfile
Once this is done, you're ready to get the source code.
Get the OpenMW Source code using GIT or Tortoise Git
Download and install all of these and make sure the environment (the system and Cmake) knows where they are. (Coming soon)
Running and using CMake
First, before opening Cmake, create a sibling directory called "OpenMW - build" next to the root "openmw" so that an out-of-source build can be done.
"<Cmake's Install Directory>\bin\cmake.exe" ..\openmw -G "Visual Studio 9 2008"
Then you should update include dirs of project to add OGRE (<path_to_ogre>\include and <path_to_ogre>\include\OGRE).
Then you should include the correct path to needed libs (OgreSDK\lib & boost\lib) if not done by the CMake script. This may require first setting the OGRE_HOME environment, e.g. set OGRE_HOME=C:\OgreSDK.
At this point, you've got an exe generated, it needed OGRE dll to be run, the lazy way is to copy the OpenMW in OgreSDK\bin\debug that contains all needed files (dll en .cfg). In the same directory than the .exe, you should have the data directory of the Morrowind game - or alternatively, on Windows Vista or Windows 7, you can create a symbolic link to the data directory:
C:\dev\omw\build>mklink /D data "c:\Program Files\Bethesda Softworks\Morrowind\Data Files"
symbolic link created for data <<===>> c:\Program Files\Bethesda Softworks\Morrowind\Data Files
Environment setup
Re: Environment setup
Hi there, I'm sure a developer will be helping you soon, I'm just a PR-guy, so I have no useful understanding of this.
Anyway, as a new member of the team, would you like to give a quick introduction of yourself, what you would prefer to do, your experience with coding languages, how much time you'll probably be spending on the project and as an extra, where you first heard of this project. It's very important to add how much time you'll probably spend on this project because we have had a lot of new (now supposed inactive) developers of whom we have heard nothing since about two weeks after they joined. It's always useful to keep things tidy around the workplace ).
So, this being said, a hearty welcome from me, and if the world doesn't end tomorrow, I hope you can do your thing here.
Ps. Could you make your introduction post in the new developers application thread please.
Anyway, as a new member of the team, would you like to give a quick introduction of yourself, what you would prefer to do, your experience with coding languages, how much time you'll probably be spending on the project and as an extra, where you first heard of this project. It's very important to add how much time you'll probably spend on this project because we have had a lot of new (now supposed inactive) developers of whom we have heard nothing since about two weeks after they joined. It's always useful to keep things tidy around the workplace ).
So, this being said, a hearty welcome from me, and if the world doesn't end tomorrow, I hope you can do your thing here.
Ps. Could you make your introduction post in the new developers application thread please.
Re: Environment setup
Can't really comment on the Windows stuff, since I am Linux only these days.
But this
But this
Is incorrect. We have the data switch for a reason (data= in the cfg file or --data in the command line options).C:\dev\omw\build>mklink /D data "c:\Program Files\Bethesda Softworks\Morrowind\Data Files"
symbolic link created for data <<===>> c:\Program Files\Bethesda Softworks\Morrowind\Data Files
Re: Environment setup
It probably has not been updated for very long as most of the steps seem to be inaccurate and confusing. I still can not get it to compile. i am hoping that someone who successfully got it to compile in Windows reads this post and helps out.
- lgromanowski
- Site Admin
- Posts: 1193
- Joined: 05 Aug 2011, 22:21
- Location: Wroclaw, Poland
- Contact:
Re: Environment setup
As far I remember there are at least two people which are using Windows for OpenMW compilation - jhooks and Ace (SWE). You could send them PM or msg on IRC channel (link is in the main menu - "#openmw").wanher wrote:It probably has not been updated for very long as most of the steps seem to be inaccurate and confusing. I still can not get it to compile. i am hoping that someone who successfully got it to compile in Windows reads this post and helps out.
Re: Environment setup
Right, been looking through the development environment setup and it does seem a bit messy.
I think a better version would be something along the lines of this:
Tools, install all of these first:
Now that everything you need is hopefully installed you can start by either using the GitHub application for windows or an install of the official git, the GitHub application will let you one-click clone the repository using the Clone in Windows button while with the normal git install you'll use the git bash or git gui.
Open your install of CMake (cmake-gui) from the start-menu and set the source directory to where you downloaded the openmw sources, set the build directory to some other folder where you want the Visual Studio project to live. <Source Directory>/Build is a nice place for this.
Press Configure and select which version of Visual Studio you installed from the drop-down list, CMake will fail to generate the solution at first and that okay.
Getting those solutions.
If you decided to go with ffmpeg instead of audiere then now is a good time to uncheck the USE_MPG123 checkbox and instead check USE_FFMPEG or USE_AUDIERE, don't worry if CMake leaves some MPG123 settings behind after switching.
Most of the dependencies should be found automatically but if some of them aren't then here are some hints on how to get CMake to find them properly:
I think a better version would be something along the lines of this:
Tools, install all of these first:
- Visual Studio 2008/2010 - normal or free express versions.
- Cmake - CMake v2.8 or later
- Git or GitHub for windows - The version control software, if using git itself then you want the latest download of the full installer for official Git for Windows
- Boost - General purpose C++ standard library, if you want to skip compiling the latest version yourself there is an automated installer here.
- OpenAL - Opensource Audio Library, does what it says on the tin. You want the file named OpenAL11CoreSDK.zip
- Audiere + libsndfile, or ffmpeg - Sound decoding, I'd recommend ffmpeg since it sees more development and there are windows builds of it here.
- OIS - Object Oriented Input System, also does what it says on the tin.
- QT - The QT UI framework, just download the latest (Do we support 5.0?) windows version of the libraries.
- MyGUI - Open source GUI framework, get the latest windows sources.
- Ogre - Object Oriented Graphics Rendering Engine, really does what it says on the tin too. Just download the latest SDK for windows.
- Bullet - Bullet Game Dynamics, a physics engine for use in games. (Download are here if you're having trouble finding them)
Now that everything you need is hopefully installed you can start by either using the GitHub application for windows or an install of the official git, the GitHub application will let you one-click clone the repository using the Clone in Windows button while with the normal git install you'll use the git bash or git gui.
Open your install of CMake (cmake-gui) from the start-menu and set the source directory to where you downloaded the openmw sources, set the build directory to some other folder where you want the Visual Studio project to live. <Source Directory>/Build is a nice place for this.
Press Configure and select which version of Visual Studio you installed from the drop-down list, CMake will fail to generate the solution at first and that okay.
Getting those solutions.
If you decided to go with ffmpeg instead of audiere then now is a good time to uncheck the USE_MPG123 checkbox and instead check USE_FFMPEG or USE_AUDIERE, don't worry if CMake leaves some MPG123 settings behind after switching.
Most of the dependencies should be found automatically but if some of them aren't then here are some hints on how to get CMake to find them properly:
- Boost - Create a new PATH entry named BOOST_ROOT and point it to your boost folder (Should contain another boost folder inside it), if it still can't find the boost libraries then you may want to set BOOST_STATIC to true.
- Ogre - If you got the Ogre SDK then try creating a PATH entry called OGRE_SDK and set it to where you installed the SDK, if you decided to build Ogre yourself then you want to create the PATH variables OGRE_SOURCE and OGRE_BUILD and set them to the source and build directory of your Ogre build.
- OIS - Just manually set all of the OIS_* variables, you can skip OIS_LIBRARY_FWK though. You want the INCLUDE_DIR to point to the includes folder in your OIS and the OIS_LIBRARY_* pointing to the debug and release builds of it.
- OpenAL - Again, just set the OPENAL_* variables to their correct values just like in OIS.
- Bullet - This too you want to set all of the missing variables (You may have to check the Advanced checkbox to see all of them), note that for Bullet the include directory is the src folder inside your bullet sources and the MATH library is named LinearMath.
- FFMPEG or Audiere - Again set all of the missing variables, for FFMPEG you don't need FFMPEG_CONFIG and the 'general' include path is for the include directory itself, the other include paths are for each of the sublibraries.
- MyGUI - Create a PATH entry named MYGUISDK pointing to where you set up your MyGUI sources and build.
Re: Environment setup
Feel free to upgrade the appropriate wiki's section ;)
Re: Environment setup
I might be a bit busy up until around february, so if anyone else feels like fixing the wiki up then that would be good.
Re: Environment setup
I will be updating the wiki right after the holidays are over and i get the project to compile on my machine. Thanks for these new instructions. As i go over the steps i will probably edit them if it's necessary. with holidays shopping and family visiting i may not have much time but definitely after.
Re: Environment setup
Something here is really weird. I have tried different settings and still, somehow cmake will not find boost. I doubt this is something wrong i am doing here . Did you run into this ? and how did you fix it ? ***See Output Below***
Looking for OGRE_RTShaderSystem...
Found OGRE_RTShaderSystem: optimized;C:/Users/Wanher/Documents/openwmlibsdeps/OgreSDK_vc10_v1-8-1/lib/release/OgreRTShaderSystem.lib;debug;C:/Users/Wanher/Documents/openwmlibsdeps/OgreSDK_vc10_v1-8-1/lib/debug/OgreRTShaderSystem_d.lib
Looking for MyGUI
CMake Error at C:/Program Files (x86)/CMake 2.8/share/cmake-2.8/Modules/FindBoost.cmake:1192 (message):
Unable to find the requested Boost libraries.
Boost version: 1.42.0
Boost include path: C:/Users/Wanher/Documents/openwmlibsdeps/boost_1_42_0
The following Boost libraries could not be found:
boost_system
boost_filesystem
boost_program_options
boost_thread
boost_wave
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:206 (find_package)
Looking for OIS...
OIS_PREFIX_PATH changed.
Could NOT find PkgConfig (missing: PKG_CONFIG_EXECUTABLE)
Found OIS: optimized;C:/Users/Wanher/Documents/openwmlibsdeps/OgreSDK_vc10_v1-8-1/lib/release/OIS.lib;debug;C:/Users/Wanher/Documents/openwmlibsdeps/OgreSDK_vc10_v1-8-1/lib/debug/OIS_d.lib
Found OpenAL: C:/Program Files (x86)/OpenAL 1.1 SDK/libs/Win32/OpenAL32.lib
CMake Error at C:/Program Files (x86)/CMake 2.8/share/cmake-2.8/Modules/FindPackageHandleStandardArgs.cmake:97 (message):
Could NOT find Bullet (missing: BULLET_DYNAMICS_LIBRARY
BULLET_COLLISION_LIBRARY BULLET_MATH_LIBRARY BULLET_SOFTBODY_LIBRARY
BULLET_INCLUDE_DIR)
Call Stack (most recent call first):
C:/Program Files (x86)/CMake 2.8/share/cmake-2.8/Modules/FindPackageHandleStandardArgs.cmake:291 (_FPHSA_FAILURE_MESSAGE)
cmake/FindBullet.cmake:68 (FIND_PACKAGE_HANDLE_STANDARD_ARGS)
CMakeLists.txt:209 (find_package)
Looking for OGRE_RTShaderSystem...
Found OGRE_RTShaderSystem: optimized;C:/Users/Wanher/Documents/openwmlibsdeps/OgreSDK_vc10_v1-8-1/lib/release/OgreRTShaderSystem.lib;debug;C:/Users/Wanher/Documents/openwmlibsdeps/OgreSDK_vc10_v1-8-1/lib/debug/OgreRTShaderSystem_d.lib
Looking for MyGUI
CMake Error at C:/Program Files (x86)/CMake 2.8/share/cmake-2.8/Modules/FindBoost.cmake:1192 (message):
Unable to find the requested Boost libraries.
Boost version: 1.42.0
Boost include path: C:/Users/Wanher/Documents/openwmlibsdeps/boost_1_42_0
The following Boost libraries could not be found:
boost_system
boost_filesystem
boost_program_options
boost_thread
boost_wave
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:206 (find_package)
Looking for OIS...
OIS_PREFIX_PATH changed.
Could NOT find PkgConfig (missing: PKG_CONFIG_EXECUTABLE)
Found OIS: optimized;C:/Users/Wanher/Documents/openwmlibsdeps/OgreSDK_vc10_v1-8-1/lib/release/OIS.lib;debug;C:/Users/Wanher/Documents/openwmlibsdeps/OgreSDK_vc10_v1-8-1/lib/debug/OIS_d.lib
Found OpenAL: C:/Program Files (x86)/OpenAL 1.1 SDK/libs/Win32/OpenAL32.lib
CMake Error at C:/Program Files (x86)/CMake 2.8/share/cmake-2.8/Modules/FindPackageHandleStandardArgs.cmake:97 (message):
Could NOT find Bullet (missing: BULLET_DYNAMICS_LIBRARY
BULLET_COLLISION_LIBRARY BULLET_MATH_LIBRARY BULLET_SOFTBODY_LIBRARY
BULLET_INCLUDE_DIR)
Call Stack (most recent call first):
C:/Program Files (x86)/CMake 2.8/share/cmake-2.8/Modules/FindPackageHandleStandardArgs.cmake:291 (_FPHSA_FAILURE_MESSAGE)
cmake/FindBullet.cmake:68 (FIND_PACKAGE_HANDLE_STANDARD_ARGS)
CMakeLists.txt:209 (find_package)