Windows build still not finished

git-svn-id: https://openmw.svn.sourceforge.net/svnroot/openmw/trunk@37 ea6a568a-9f4f-0410-981a-c910a81bb256
actorid
nkorslund 17 years ago
parent fc621518cb
commit 53ae52c7c9

@ -26,8 +26,7 @@ Dependencies needed to build OpenMW:
OGRE 1.4.9 (3d engine)
OpenAL (3d sound system)
libavcodec,
libavformat (For MP3 playback)
FFmpeg (For MP3 playback)
Mingw (C++ compiler)
gdc 4.1.3 (mingw) (D compiler)
@ -36,15 +35,18 @@ versions might work. OGRE, OpenAL and OIS are complex libraries with
their own set of dependencies. I recommend downloading prebuild SDKs
instead of building them from source.
libavcodec and libavformat are part of the FFmpeg package, which is
part of the 'mplayer' project. Note that some of the codecs might be
patented in your country.
FFmpeg package contains the necessary libraries libavcodec and
libavformat. You will most likely have to build it from source. This
can be done either with Mingw32/Msys or with Cygwin. See below for
instructions. Note that some of the codecs included with FFmpeg might
be patented in your country.
You can find the libraries here:
OGRE: http://ogre3d.org (See "Getting Ogre" in README-win32.txt for details)
OIS: Comes with the Ogre SDK
OpenAL: http://openal.org/
FFmpeg: http://ffmpeg.mplayerhq.hu/
Mingw http://sourceforge.net/projects/mingw/
gdc http://sourceforge.net/projects/gdcwin/
@ -65,11 +67,17 @@ Open a command line. Set up your PATH to include Mingw and gdc
(eg. "set PATH=%PATH%;c:\mingw\bin"). Make sure the commands g++ and
gdc work (should output "no input files".)
The build script expects to find the Ogre and Audiere SDKs in the
The build script expects to find the Ogre and FFmpeg SDKs in the
parent directory. An example directory structure is:
c:\openmw\Ogre - Ogre SDK
c:\openmw\openmw - OpenMW source
c:\openmw\ffmpeg - FFmpeg
You must compile FFmpeg from source, since at the time of writing
there are no prebuilt SDKs available. The source must be built with
Mingw as well (not Cygwin!) The following configure flags should work:
./configure --enable-shared --disable--ffserver --disable-ffplay
Building

@ -2,18 +2,21 @@
rem See COMPILE-win32.txt for instructions.
rem This file assumes it can find Ogre in ..\ogro
rem TODO: Not updated to OpenAL
rem This file assumes it can find Ogre in ..\ogre and that ffmpeg
rem has been downloaded and compiled in ..\ffmpeg
echo Compiling C++ files
g++ -c sound\cpp_audiere.cpp -I..\audiere\include
g++ -c sound\cpp_avcodec.cpp -I..\ffmpeg
g++ -c ogre\cpp_ogre.cpp -I..\ogre\include
copy ..\ogre\bin\debug\ogremain_d.dll .
copy ..\ogre\bin\debug\ois_d.dll .
copy ..\ogre\bin\debug\cg.dll .
copy ..\audiere\bin\audiere.dll .
copy ..\ffmpeg\libavcodec\cygavcodec-51.dll cygavcodec.dll
copy ..\ffmpeg\libavformat\cygavformat-52.dll cygavformat.dll
copy ..\ffmpeg\libavdevice\cygavdevice-52.dll cygavdevice.dll
copy ..\ffmpeg\libavutil\cygavutil-49.dll cygavutil.dll
copy \windows\system32\d3dx9_30.dll d3dx9d_30.dll
echo Compiling main program (openmw.exe)
gdc -Wall -g openmw.d bsa\*.d core\*.d esm\*.d input\*.d nif\*.d ogre\*.d scene\*.d sound\*.d util\*.d cpp_ogre.o monster\util\*.d ogremain_d.dll OIS_d.dll -lstdc++ -o openmw.exe
gdc -Wall -g openmw.d bsa\*.d core\*.d esm\*.d input\*.d nif\*.d ogre\*.d scene\*.d sound\*.d util\*.d cpp_ogre.o cpp_avcodec.o monster\util\*.d cygavcodec.dll cygavformat.dll cygavdevice.dll cygavutil.dll openal32.dll ogremain_d.dll OIS_d.dll -lstdc++ -o openmw.exe

@ -1,6 +1,6 @@
module sound.al;
extern(System):
extern(C):
//Defines
const int AL_NONE = 0;

@ -1,6 +1,6 @@
module sound.alc;
extern(System):
extern(C):
//Definitions
const int ALC_FALSE = 0;

@ -24,8 +24,13 @@
#include <stdio.h>
extern "C" { // the headers don't do this..
#ifdef WIN32
#include <libavcodec/avcodec.h>
#include <libavformat/avformat.h>
#else
#include <ffmpeg/avcodec.h>
#include <ffmpeg/avformat.h>
#endif
}
#include <vector>

Loading…
Cancel
Save