Ogre 2.1 + Visual Studio 2017 - compilation errors Topic is solved

Discussion area about developing with Ogre-Next (2.1, 2.2 and beyond)


Post Reply
jcdentons
Gnoblar
Posts: 2
Joined: Fri Jan 19, 2018 1:33 pm

Ogre 2.1 + Visual Studio 2017 - compilation errors

Post by jcdentons »

Hi,

(Sorry for my poor english)
I have to use Ogre 2.1 under Windows and Visual Studio 2017.

For Win32, this was OK :
https://ogrecave.github.io/ogre/api/2.1 ... ntsWindows

except an error I encountered on Step "Building Ogre"> compile Release.
There is a C1001 problem with the C++ project FreeImage.
To solve this, the idea was, in Release Configuration, to disable "Optimization" in the "Properties > C/C++ > All options" for the project FreeImage.

To automate this, you can add, just before the step "Building Dependencies", this :
- Open PowerShell
- Go to the dependencies directory :
cd <ROOT_DIRECTORY>\ogre\Dependencies
- Execute this line :
(Get-Content .\build\src\FreeImage\FreeImage.vcxproj) | ForEach-Object { $_ -replace "<Optimization>MaxSpeed</Optimization>", "<Optimization>Disabled</Optimization>" } | Set-Content .\build\src\FreeImage\FreeImage.vcxproj

For x64, I have lots of problems with Samples and links with SDL2. If someone has encountered errors like that ...

J.C. Dentons
jcdentons
Gnoblar
Posts: 2
Joined: Fri Jan 19, 2018 1:33 pm

Re: Ogre 2.1 + Visual Studio 2017 - compilation errors

Post by jcdentons »

Finally It's OK -- I had a problem with a 32bits version of SDL2 installed. But I had to operate the same operation (FreeImage) that for Win32.
Post Reply