Board index FlightGear Support Compiling

Optimized FG release builds?  Topic is solved

Building FlightGear from source, and in the need for help?

Re: Optimized FG release builds?

Postby wlbragg » Fri Nov 28, 2014 4:18 am

I'm trying a different approach and am 'oh so close to a 64bit build.
My last hurdle is to clear up the error
Code: Select all
cannot open include file 'windows.h'

I get it in both command line download_and_compile script and VS2010 IDE superbuild.

I'm think it's related to what I had to do to get 64bit build on my system.
It involved installing the 7.1 SDK.

I tried all the solutions I could find online (they all suggested adding "additional includes" in the IDE) but they aren't working for multiple reasons, no such thing as "additional include" in 2010 and I think the way superbuild and command line d_and_c works is it is reverting settings on the fly because of cmake?.
I think the solution has to do with adding the sdk include path to the property sheet created by cmake?

The IDE looks like it has the paths set correctly, I guess that is why I suspect property sheets.
Code: Select all
$(WindowsSdkDir)\include
$(VCInstallDir)include

But I know next to nothing about the subject so I am a fish out of water in setting up this environment.

Any suggestion, help would be greatly appreciated.
Kansas(2-27-15)/Ohio/Midwest scenery development.
KEQA (2-27-15), 3AU, KRCP Airport Layout
Intel i5 3570K AMDRX480
User avatar
wlbragg
 
Posts: 5769
Joined: Sat Aug 25, 2012 11:31 pm
Location: Kansas (Tornado Alley), USA
Callsign: WC2020
Version: next
OS: Win10/Linux/AMDRX480

Re: Optimized FG release builds?

Postby wlbragg » Fri Nov 28, 2014 11:25 am

I think I found it

Had to add a property group
Code: Select all
<PropertyGroup>
      <IncludePath>C:\Program Files (x86)\Microsoft SDKs\Windows\v7.1A\Include;$(IncludePath)</IncludePath>
      <LibraryPath>C:\Program Files (x86)\Microsoft SDKs\Windows\v7.1A\Lib\winv6.3\x64;$(LibraryPath)</LibraryPath>
   </PropertyGroup>

in %home%\AppData\Local\Microsoft\MSBuild\v4.0.\Cpp.x64.user.props which is used for 64 bit builds

per answer 2

Note: I had to exclude the "ExecutablePath". I think because rc.exe is named RC.Exe in the SDK?

At least it's compiling... :D
Kansas(2-27-15)/Ohio/Midwest scenery development.
KEQA (2-27-15), 3AU, KRCP Airport Layout
Intel i5 3570K AMDRX480
User avatar
wlbragg
 
Posts: 5769
Joined: Sat Aug 25, 2012 11:31 pm
Location: Kansas (Tornado Alley), USA
Callsign: WC2020
Version: next
OS: Win10/Linux/AMDRX480

Re: Optimized FG release builds?  

Postby wlbragg » Fri Nov 28, 2014 6:21 pm

Ecstatic! :D
Finally I have 64bit compiler working with the superbuild.
Not without having to do a few unconventional tweaks (as in not documented here in the FG forums).

First, adding the 7.1 SDK to get the 64bit compilers is a joke. Really long story short, there is an order that you have to install VC 2010, 7.1 SDK, SPK1 and 7.1 SDK Update. But that didn't work as advertised on my system. I had to install some of them more than once to get everything working. I know it sounds crazy, and it is.

Then once I got x64 working, the superbuild failed to find windows.h, that required the fix in a previous post in this thread (add SDK7.1 include in a property group).

Then the infamous "Cannot open include file: 'freetype.h'" error popped up. My system required an escape semicolon in CMakeLists.txt, (see OSG Superbuild freetype Error), in the 32bit environment. But that didn't fix this new issue. I had to add another include in the property group.
So now my property group looks like this
Code: Select all
<?xml version="1.0" encoding="utf-8"?>
<Project DefaultTargets="Build" ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
   <PropertyGroup>
      <IncludePath>C:\Program Files (x86)\Microsoft SDKs\Windows\v7.1A\Include;D:\FlightGear\fgbuildmeta\metabuild\3rdParty.x64\include\freetype;$(IncludePath)</IncludePath>
   </PropertyGroup>
</Project>


That's it. Now it works and the good new for me is my custom scenery works just fine with the 64bit build. I guess 32bit can't handle the load.
Kansas(2-27-15)/Ohio/Midwest scenery development.
KEQA (2-27-15), 3AU, KRCP Airport Layout
Intel i5 3570K AMDRX480
User avatar
wlbragg
 
Posts: 5769
Joined: Sat Aug 25, 2012 11:31 pm
Location: Kansas (Tornado Alley), USA
Callsign: WC2020
Version: next
OS: Win10/Linux/AMDRX480

Previous

Return to Compiling

Who is online

Users browsing this forum: No registered users and 1 guest