1
0
Fork 0

Merge branch 'next' of gitorious.org:fg/flightgear into next

This commit is contained in:
Torsten Dreyer 2011-01-07 09:07:56 +01:00
commit 5cdfe3d7a5
22 changed files with 253 additions and 92 deletions

View file

@ -8,6 +8,11 @@ include (CPack)
project(FlightGear) project(FlightGear)
set(CMAKE_DEBUG_POSTFIX "d" CACHE STRING "add a postfix, usually d on windows")
set(CMAKE_RELEASE_POSTFIX "" CACHE STRING "add a postfix, usually empty on windows")
set(CMAKE_RELWITHDEBINFO_POSTFIX "rd" CACHE STRING "add a postfix, usually empty on windows")
set(CMAKE_MINSIZEREL_POSTFIX "s" CACHE STRING "add a postfix, usually empty on windows")
# read 'version' file into a variable (stripping any newlines or spaces) # read 'version' file into a variable (stripping any newlines or spaces)
file(READ version versionFile) file(READ version versionFile)
string(STRIP ${versionFile} FLIGHTGEAR_VERSION) string(STRIP ${versionFile} FLIGHTGEAR_VERSION)
@ -48,6 +53,7 @@ option(ENABLE_UIUC_MODEL "Set to ON to build FlightGear with UIUCModel FDM" ON)
option(ENABLE_LARCSIM "Set to ON to build FlightGear with LaRCsim FDM" ON) option(ENABLE_LARCSIM "Set to ON to build FlightGear with LaRCsim FDM" ON)
option(ENABLE_YASIM "Set to ON to build FlightGear with YASIM FDM" ON) option(ENABLE_YASIM "Set to ON to build FlightGear with YASIM FDM" ON)
option(ENABLE_JSBSIM "Set to ON to build FlightGear with JSBSim FDM" ON) option(ENABLE_JSBSIM "Set to ON to build FlightGear with JSBSim FDM" ON)
option(ENABLE_FGADMIN "Set to ON to build FlightGear with FGADMIN" ON)
option(EVENT_INPUT "Set to ON to build FlightGear with event-based Input support" OFF) option(EVENT_INPUT "Set to ON to build FlightGear with event-based Input support" OFF)
set(MSVC_3RDPARTY_DIR NOT_FOUND CACHE PATH "Location where the third-party dependencies are extracted") set(MSVC_3RDPARTY_DIR NOT_FOUND CACHE PATH "Location where the third-party dependencies are extracted")
@ -94,8 +100,12 @@ find_package(OpenAL REQUIRED)
find_package(ALUT REQUIRED) find_package(ALUT REQUIRED)
find_package(OpenSceneGraph 2.8.2 REQUIRED osgText osgSim osgDB osgParticle osgFX osgUtil osgViewer osgGA) find_package(OpenSceneGraph 2.8.2 REQUIRED osgText osgSim osgDB osgParticle osgFX osgUtil osgViewer osgGA)
if(ENABLE_FGADMIN)
find_package(FLTK)
endif(ENABLE_FGADMIN)
find_package(PLIB REQUIRED puaux pu js fnt) find_package(PLIB REQUIRED puaux pu js fnt)
find_package(SimGear 2.0.0 REQUIRED) find_package(SimGear 2.2.0 REQUIRED)
check_include_file(unistd.h HAVE_UNISTD_H) check_include_file(unistd.h HAVE_UNISTD_H)
check_include_file(sys/time.h HAVE_SYS_TIME_H) check_include_file(sys/time.h HAVE_SYS_TIME_H)
@ -157,6 +167,7 @@ if(WIN32)
endif(MSVC) endif(MSVC)
set(NOMINMAX 1) set(NOMINMAX 1)
set( WINSOCK_LIBRARY "ws2_32.lib" )
endif(WIN32) endif(WIN32)
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} ${WARNING_FLAGS} ${MSVC_FLAGS} -D_REENTRANT") set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} ${WARNING_FLAGS} ${MSVC_FLAGS} -D_REENTRANT")

View file

@ -77,7 +77,7 @@
OutputFile="$(OutDir)\fgfs.exe" OutputFile="$(OutDir)\fgfs.exe"
LinkIncremental="2" LinkIncremental="2"
SuppressStartupBanner="true" SuppressStartupBanner="true"
AdditionalLibraryDirectories="..\..\..\..\install\msvc90\OpenSceneGraph\lib;..\..\..\..\3rdParty\lib;..\..\..\..\boost_1_44_0\lib" AdditionalLibraryDirectories="..\..\..\..\install\msvc90\OpenSceneGraph\lib;..\..\..\..\3rdParty\lib"
IgnoreDefaultLibraryNames="" IgnoreDefaultLibraryNames=""
GenerateDebugInformation="true" GenerateDebugInformation="true"
SubSystem="1" SubSystem="1"
@ -165,7 +165,7 @@
OutputFile="$(OutDir)\fgfs.exe" OutputFile="$(OutDir)\fgfs.exe"
LinkIncremental="2" LinkIncremental="2"
SuppressStartupBanner="true" SuppressStartupBanner="true"
AdditionalLibraryDirectories="..\..\..\..\install\msvc90-64\OpenSceneGraph\lib;..\..\..\..\3rdParty.x64\lib;..\..\..\..\boost_1_44_0\lib64" AdditionalLibraryDirectories="..\..\..\..\install\msvc90-64\OpenSceneGraph\lib;..\..\..\..\3rdParty.x64\lib"
IgnoreDefaultLibraryNames="" IgnoreDefaultLibraryNames=""
GenerateDebugInformation="true" GenerateDebugInformation="true"
SubSystem="1" SubSystem="1"
@ -253,7 +253,7 @@
OutputFile="$(OutDir)\fgfs.exe" OutputFile="$(OutDir)\fgfs.exe"
LinkIncremental="1" LinkIncremental="1"
SuppressStartupBanner="true" SuppressStartupBanner="true"
AdditionalLibraryDirectories="..\..\..\..\install\msvc90\OpenSceneGraph\lib;..\..\..\..\3rdParty\lib;..\..\..\..\boost_1_44_0\lib" AdditionalLibraryDirectories="..\..\..\..\install\msvc90\OpenSceneGraph\lib;..\..\..\..\3rdParty\lib"
IgnoreDefaultLibraryNames="" IgnoreDefaultLibraryNames=""
GenerateDebugInformation="true" GenerateDebugInformation="true"
SubSystem="1" SubSystem="1"
@ -340,7 +340,7 @@
OutputFile="$(OutDir)\fgfs.exe" OutputFile="$(OutDir)\fgfs.exe"
LinkIncremental="1" LinkIncremental="1"
SuppressStartupBanner="true" SuppressStartupBanner="true"
AdditionalLibraryDirectories="..\..\..\..\install\msvc90-64\OpenSceneGraph\lib;..\..\..\..\3rdParty.x64\lib;..\..\..\..\boost_1_44_0\lib64" AdditionalLibraryDirectories="..\..\..\..\install\msvc90-64\OpenSceneGraph\lib;..\..\..\..\3rdParty.x64\lib"
IgnoreDefaultLibraryNames="" IgnoreDefaultLibraryNames=""
GenerateDebugInformation="true" GenerateDebugInformation="true"
SubSystem="1" SubSystem="1"

View file

@ -46,7 +46,7 @@
Name="VCCLCompilerTool" Name="VCCLCompilerTool"
Optimization="0" Optimization="0"
AdditionalIncludeDirectories="..\..\..\src;..\..\..\..\SimGear;..\..\..\..\install\msvc90\OpenSceneGraph\include;..\..\..\..\3rdParty\include" AdditionalIncludeDirectories="..\..\..\src;..\..\..\..\SimGear;..\..\..\..\install\msvc90\OpenSceneGraph\include;..\..\..\..\3rdParty\include"
PreprocessorDefinitions="WIN32;_DEBUG;_CONSOLE;NOMINMAX;_CRT_SECURE_NO_WARNINGS;_CRT_NONSTDC_NO_WARNINGS" PreprocessorDefinitions="WIN32;_DEBUG;_CONSOLE;NOMINMAX;_CRT_SECURE_NO_WARNINGS;_CRT_NONSTDC_NO_WARNINGS;HAVE_WINDOWS_H"
MinimalRebuild="true" MinimalRebuild="true"
BasicRuntimeChecks="3" BasicRuntimeChecks="3"
RuntimeLibrary="3" RuntimeLibrary="3"
@ -126,7 +126,7 @@
Name="VCCLCompilerTool" Name="VCCLCompilerTool"
Optimization="0" Optimization="0"
AdditionalIncludeDirectories="..\..\..\src;..\..\..\..\SimGear;..\..\..\..\install\msvc90-64\OpenSceneGraph\include;..\..\..\..\3rdParty.x64\include" AdditionalIncludeDirectories="..\..\..\src;..\..\..\..\SimGear;..\..\..\..\install\msvc90-64\OpenSceneGraph\include;..\..\..\..\3rdParty.x64\include"
PreprocessorDefinitions="WIN32;_DEBUG;_CONSOLE;NOMINMAX;_CRT_SECURE_NO_WARNINGS;_CRT_NONSTDC_NO_WARNINGS" PreprocessorDefinitions="WIN32;_DEBUG;_CONSOLE;NOMINMAX;_CRT_SECURE_NO_WARNINGS;_CRT_NONSTDC_NO_WARNINGS;HAVE_WINDOWS_H"
MinimalRebuild="true" MinimalRebuild="true"
BasicRuntimeChecks="3" BasicRuntimeChecks="3"
RuntimeLibrary="3" RuntimeLibrary="3"
@ -204,7 +204,7 @@
<Tool <Tool
Name="VCCLCompilerTool" Name="VCCLCompilerTool"
AdditionalIncludeDirectories="..\..\..\src;..\..\..\..\SimGear;..\..\..\..\install\msvc90\OpenSceneGraph\include;..\..\..\..\3rdParty\include" AdditionalIncludeDirectories="..\..\..\src;..\..\..\..\SimGear;..\..\..\..\install\msvc90\OpenSceneGraph\include;..\..\..\..\3rdParty\include"
PreprocessorDefinitions="WIN32;NDEBUG;_CONSOLE;NOMINMAX;_CRT_SECURE_NO_WARNINGS;_CRT_NONSTDC_NO_WARNINGS" PreprocessorDefinitions="WIN32;NDEBUG;_CONSOLE;NOMINMAX;_CRT_SECURE_NO_WARNINGS;_CRT_NONSTDC_NO_WARNINGS;HAVE_WINDOWS_H"
RuntimeLibrary="2" RuntimeLibrary="2"
UsePrecompiledHeader="0" UsePrecompiledHeader="0"
WarningLevel="3" WarningLevel="3"
@ -282,7 +282,7 @@
<Tool <Tool
Name="VCCLCompilerTool" Name="VCCLCompilerTool"
AdditionalIncludeDirectories="..\..\..\src;..\..\..\..\SimGear;..\..\..\..\install\msvc90-64\OpenSceneGraph\include;..\..\..\..\3rdParty\include" AdditionalIncludeDirectories="..\..\..\src;..\..\..\..\SimGear;..\..\..\..\install\msvc90-64\OpenSceneGraph\include;..\..\..\..\3rdParty\include"
PreprocessorDefinitions="WIN32;NDEBUG;_CONSOLE;NOMINMAX;_CRT_SECURE_NO_WARNINGS;_CRT_NONSTDC_NO_WARNINGS" PreprocessorDefinitions="WIN32;NDEBUG;_CONSOLE;NOMINMAX;_CRT_SECURE_NO_WARNINGS;_CRT_NONSTDC_NO_WARNINGS;HAVE_WINDOWS_H"
RuntimeLibrary="2" RuntimeLibrary="2"
UsePrecompiledHeader="0" UsePrecompiledHeader="0"
WarningLevel="3" WarningLevel="3"

View file

@ -45,7 +45,7 @@
Name="VCCLCompilerTool" Name="VCCLCompilerTool"
Optimization="0" Optimization="0"
AdditionalIncludeDirectories="..\..\..\src;..\..\..\..\SimGear;..\..\..\..\install\msvc90\OpenSceneGraph\include;..\..\..\..\3rdParty\include" AdditionalIncludeDirectories="..\..\..\src;..\..\..\..\SimGear;..\..\..\..\install\msvc90\OpenSceneGraph\include;..\..\..\..\3rdParty\include"
PreprocessorDefinitions="WIN32;_DEBUG;_CONSOLE;NOMINMAX;_CRT_SECURE_NO_WARNINGS;_CRT_NONSTDC_NO_WARNINGS" PreprocessorDefinitions="WIN32;_DEBUG;_CONSOLE;NOMINMAX;_CRT_SECURE_NO_WARNINGS;_CRT_NONSTDC_NO_WARNINGS;HAVE_WINDOWS_H"
MinimalRebuild="true" MinimalRebuild="true"
BasicRuntimeChecks="3" BasicRuntimeChecks="3"
RuntimeLibrary="3" RuntimeLibrary="3"
@ -126,7 +126,7 @@
Name="VCCLCompilerTool" Name="VCCLCompilerTool"
Optimization="0" Optimization="0"
AdditionalIncludeDirectories="..\..\..\src;..\..\..\..\SimGear;..\..\..\..\install\msvc90-64\OpenSceneGraph\include;..\..\..\..\3rdParty.x64\include" AdditionalIncludeDirectories="..\..\..\src;..\..\..\..\SimGear;..\..\..\..\install\msvc90-64\OpenSceneGraph\include;..\..\..\..\3rdParty.x64\include"
PreprocessorDefinitions="WIN32;_DEBUG;_CONSOLE;NOMINMAX;_CRT_SECURE_NO_WARNINGS;_CRT_NONSTDC_NO_WARNINGS" PreprocessorDefinitions="WIN32;_DEBUG;_CONSOLE;NOMINMAX;_CRT_SECURE_NO_WARNINGS;_CRT_NONSTDC_NO_WARNINGS;HAVE_WINDOWS_H"
MinimalRebuild="true" MinimalRebuild="true"
BasicRuntimeChecks="3" BasicRuntimeChecks="3"
RuntimeLibrary="3" RuntimeLibrary="3"
@ -205,7 +205,7 @@
<Tool <Tool
Name="VCCLCompilerTool" Name="VCCLCompilerTool"
AdditionalIncludeDirectories="..\..\..\src;..\..\..\..\SimGear;..\..\..\..\install\msvc90\OpenSceneGraph\include;..\..\..\..\3rdParty\include" AdditionalIncludeDirectories="..\..\..\src;..\..\..\..\SimGear;..\..\..\..\install\msvc90\OpenSceneGraph\include;..\..\..\..\3rdParty\include"
PreprocessorDefinitions="WIN32;NDEBUG;_CONSOLE;NOMINMAX;_CRT_SECURE_NO_WARNINGS;_CRT_NONSTDC_NO_WARNINGS" PreprocessorDefinitions="WIN32;NDEBUG;_CONSOLE;NOMINMAX;_CRT_SECURE_NO_WARNINGS;_CRT_NONSTDC_NO_WARNINGS;HAVE_WINDOWS_H"
RuntimeLibrary="2" RuntimeLibrary="2"
RuntimeTypeInfo="true" RuntimeTypeInfo="true"
UsePrecompiledHeader="0" UsePrecompiledHeader="0"
@ -284,7 +284,7 @@
<Tool <Tool
Name="VCCLCompilerTool" Name="VCCLCompilerTool"
AdditionalIncludeDirectories="..\..\..\src;..\..\..\..\SimGear;..\..\..\..\install\msvc90-64\OpenSceneGraph\include;..\..\..\..\3rdParty.x64\include" AdditionalIncludeDirectories="..\..\..\src;..\..\..\..\SimGear;..\..\..\..\install\msvc90-64\OpenSceneGraph\include;..\..\..\..\3rdParty.x64\include"
PreprocessorDefinitions="WIN32;NDEBUG;_CONSOLE;NOMINMAX;_CRT_SECURE_NO_WARNINGS;_CRT_NONSTDC_NO_WARNINGS" PreprocessorDefinitions="WIN32;NDEBUG;_CONSOLE;NOMINMAX;_CRT_SECURE_NO_WARNINGS;_CRT_NONSTDC_NO_WARNINGS;HAVE_WINDOWS_H"
RuntimeLibrary="2" RuntimeLibrary="2"
RuntimeTypeInfo="true" RuntimeTypeInfo="true"
UsePrecompiledHeader="0" UsePrecompiledHeader="0"

View file

@ -45,7 +45,7 @@
Name="VCCLCompilerTool" Name="VCCLCompilerTool"
Optimization="0" Optimization="0"
AdditionalIncludeDirectories="..\..\..\src;..\..\..\..\SimGear;..\..\..\..\install\msvc90\OpenSceneGraph\include;..\..\..\..\3rdParty\include;..\..\..\..\boost_1_44_0" AdditionalIncludeDirectories="..\..\..\src;..\..\..\..\SimGear;..\..\..\..\install\msvc90\OpenSceneGraph\include;..\..\..\..\3rdParty\include;..\..\..\..\boost_1_44_0"
PreprocessorDefinitions="WIN32;_DEBUG;_CONSOLE;NOMINMAX;_CRT_SECURE_NO_WARNINGS;_CRT_NONSTDC_NO_WARNINGS" PreprocessorDefinitions="WIN32;_DEBUG;_CONSOLE;NOMINMAX;_CRT_SECURE_NO_WARNINGS;_CRT_NONSTDC_NO_WARNINGS;HAVE_WINDOWS_H"
MinimalRebuild="true" MinimalRebuild="true"
BasicRuntimeChecks="3" BasicRuntimeChecks="3"
RuntimeLibrary="3" RuntimeLibrary="3"
@ -126,7 +126,7 @@
Name="VCCLCompilerTool" Name="VCCLCompilerTool"
Optimization="0" Optimization="0"
AdditionalIncludeDirectories="..\..\..\src;..\..\..\..\SimGear;..\..\..\..\install\msvc90-64\OpenSceneGraph\include;..\..\..\..\3rdParty.x64\include;..\..\..\..\boost_1_44_0" AdditionalIncludeDirectories="..\..\..\src;..\..\..\..\SimGear;..\..\..\..\install\msvc90-64\OpenSceneGraph\include;..\..\..\..\3rdParty.x64\include;..\..\..\..\boost_1_44_0"
PreprocessorDefinitions="WIN32;_DEBUG;_CONSOLE;NOMINMAX;_CRT_SECURE_NO_WARNINGS;_CRT_NONSTDC_NO_WARNINGS" PreprocessorDefinitions="WIN32;_DEBUG;_CONSOLE;NOMINMAX;_CRT_SECURE_NO_WARNINGS;_CRT_NONSTDC_NO_WARNINGS;HAVE_WINDOWS_H"
MinimalRebuild="true" MinimalRebuild="true"
BasicRuntimeChecks="3" BasicRuntimeChecks="3"
RuntimeLibrary="3" RuntimeLibrary="3"
@ -205,7 +205,7 @@
<Tool <Tool
Name="VCCLCompilerTool" Name="VCCLCompilerTool"
AdditionalIncludeDirectories="..\..\..\src;..\..\..\..\SimGear;..\..\..\..\install\msvc90\OpenSceneGraph\include;..\..\..\..\3rdParty\include;..\..\..\..\boost_1_44_0" AdditionalIncludeDirectories="..\..\..\src;..\..\..\..\SimGear;..\..\..\..\install\msvc90\OpenSceneGraph\include;..\..\..\..\3rdParty\include;..\..\..\..\boost_1_44_0"
PreprocessorDefinitions="WIN32;NDEBUG;_CONSOLE;NOMINMAX;_CRT_SECURE_NO_WARNINGS;_CRT_NONSTDC_NO_WARNINGS" PreprocessorDefinitions="WIN32;NDEBUG;_CONSOLE;NOMINMAX;_CRT_SECURE_NO_WARNINGS;_CRT_NONSTDC_NO_WARNINGS;HAVE_WINDOWS_H"
RuntimeLibrary="2" RuntimeLibrary="2"
RuntimeTypeInfo="true" RuntimeTypeInfo="true"
UsePrecompiledHeader="0" UsePrecompiledHeader="0"
@ -284,7 +284,7 @@
<Tool <Tool
Name="VCCLCompilerTool" Name="VCCLCompilerTool"
AdditionalIncludeDirectories="..\..\..\src;..\..\..\..\SimGear;..\..\..\..\install\msvc90-64\OpenSceneGraph\include;..\..\..\..\3rdParty.x64\include;..\..\..\..\boost_1_44_0" AdditionalIncludeDirectories="..\..\..\src;..\..\..\..\SimGear;..\..\..\..\install\msvc90-64\OpenSceneGraph\include;..\..\..\..\3rdParty.x64\include;..\..\..\..\boost_1_44_0"
PreprocessorDefinitions="WIN32;NDEBUG;_CONSOLE;NOMINMAX;_CRT_SECURE_NO_WARNINGS;_CRT_NONSTDC_NO_WARNINGS" PreprocessorDefinitions="WIN32;NDEBUG;_CONSOLE;NOMINMAX;_CRT_SECURE_NO_WARNINGS;_CRT_NONSTDC_NO_WARNINGS;HAVE_WINDOWS_H"
RuntimeLibrary="2" RuntimeLibrary="2"
RuntimeTypeInfo="true" RuntimeTypeInfo="true"
UsePrecompiledHeader="0" UsePrecompiledHeader="0"

View file

@ -68,7 +68,7 @@
Name="VCLinkerTool" Name="VCLinkerTool"
AdditionalDependencies="opengl32.lib osgd.lib osgDBd.lib osgViewerd.lib osgGAd.lib openthreadsd.lib osgParticled.lib osgUtild.lib osgTextd.lib ul_d.lib sg_d.lib zlibd.lib" AdditionalDependencies="opengl32.lib osgd.lib osgDBd.lib osgViewerd.lib osgGAd.lib openthreadsd.lib osgParticled.lib osgUtild.lib osgTextd.lib ul_d.lib sg_d.lib zlibd.lib"
LinkIncremental="2" LinkIncremental="2"
AdditionalLibraryDirectories="..\..\..\..\install\msvc90\OpenSceneGraph\lib;..\..\..\..\3rdParty\lib;..\..\..\..\boost_1_44_0\lib" AdditionalLibraryDirectories="..\..\..\..\install\msvc90\OpenSceneGraph\lib;..\..\..\..\3rdParty\lib"
GenerateDebugInformation="true" GenerateDebugInformation="true"
ProgramDatabaseFile="$(OutDir)/fgviewer.pdb" ProgramDatabaseFile="$(OutDir)/fgviewer.pdb"
SubSystem="1" SubSystem="1"
@ -149,7 +149,7 @@
Name="VCLinkerTool" Name="VCLinkerTool"
AdditionalDependencies="opengl32.lib osgd.lib osgDBd.lib osgViewerd.lib osgGAd.lib openthreadsd.lib osgParticled.lib osgUtild.lib osgTextd.lib ul_d.lib sg_d.lib zlibd.lib" AdditionalDependencies="opengl32.lib osgd.lib osgDBd.lib osgViewerd.lib osgGAd.lib openthreadsd.lib osgParticled.lib osgUtild.lib osgTextd.lib ul_d.lib sg_d.lib zlibd.lib"
LinkIncremental="2" LinkIncremental="2"
AdditionalLibraryDirectories="..\..\..\..\install\msvc90-64\OpenSceneGraph\lib;..\..\..\..\3rdParty.x64\lib;..\..\..\..\boost_1_44_0\lib64" AdditionalLibraryDirectories="..\..\..\..\install\msvc90-64\OpenSceneGraph\lib;..\..\..\..\3rdParty.x64\lib"
GenerateDebugInformation="true" GenerateDebugInformation="true"
ProgramDatabaseFile="$(OutDir)/fgviewer.pdb" ProgramDatabaseFile="$(OutDir)/fgviewer.pdb"
SubSystem="1" SubSystem="1"
@ -226,7 +226,7 @@
Name="VCLinkerTool" Name="VCLinkerTool"
AdditionalDependencies="opengl32.lib osg.lib osgDB.lib osgViewer.lib osgGA.lib openthreads.lib osgParticle.lib osgUtil.lib osgText.lib ul.lib sg.lib zlib.lib" AdditionalDependencies="opengl32.lib osg.lib osgDB.lib osgViewer.lib osgGA.lib openthreads.lib osgParticle.lib osgUtil.lib osgText.lib ul.lib sg.lib zlib.lib"
LinkIncremental="1" LinkIncremental="1"
AdditionalLibraryDirectories="..\..\..\..\install\msvc90\OpenSceneGraph\lib;..\..\..\..\3rdParty\lib;..\..\..\..\boost_1_44_0\lib" AdditionalLibraryDirectories="..\..\..\..\install\msvc90\OpenSceneGraph\lib;..\..\..\..\3rdParty\lib"
GenerateDebugInformation="true" GenerateDebugInformation="true"
SubSystem="1" SubSystem="1"
OptimizeReferences="2" OptimizeReferences="2"
@ -305,7 +305,7 @@
Name="VCLinkerTool" Name="VCLinkerTool"
AdditionalDependencies="opengl32.lib osg.lib osgDB.lib osgViewer.lib osgGA.lib openthreads.lib osgParticle.lib osgUtil.lib osgText.lib ul.lib sg.lib zlib.lib" AdditionalDependencies="opengl32.lib osg.lib osgDB.lib osgViewer.lib osgGA.lib openthreads.lib osgParticle.lib osgUtil.lib osgText.lib ul.lib sg.lib zlib.lib"
LinkIncremental="1" LinkIncremental="1"
AdditionalLibraryDirectories="..\..\..\..\install\msvc90-64\OpenSceneGraph\lib;..\..\..\..\3rdParty.x64\lib;..\..\..\..\boost_1_44_0\lib64" AdditionalLibraryDirectories="..\..\..\..\install\msvc90-64\OpenSceneGraph\lib;..\..\..\..\3rdParty.x64\lib"
GenerateDebugInformation="true" GenerateDebugInformation="true"
SubSystem="1" SubSystem="1"
OptimizeReferences="2" OptimizeReferences="2"

View file

@ -151,6 +151,7 @@ void FGATIS::Update(double dt) {
// If !_prev_display, the radio had been detuned for a while and our // If !_prev_display, the radio had been detuned for a while and our
// "transmission" variable was lost when we were de-instantiated. // "transmission" variable was lost when we were de-instantiated.
int rslt = GenTransmission(!_prev_display, attention); int rslt = GenTransmission(!_prev_display, attention);
TreeOut(msg_OK);
if (rslt || volume != old_volume) { if (rslt || volume != old_volume) {
//cout << "ATIS calling ATC::render volume: " << volume << endl; //cout << "ATIS calling ATC::render volume: " << volume << endl;
Render(transmission, volume, refname, true); Render(transmission, volume, refname, true);
@ -207,6 +208,28 @@ const int minute(60); // measured in seconds
const int ATIS_interval(60*minute); const int ATIS_interval(60*minute);
#endif #endif
// FIXME: This is heuristic. It gets the right answer for
// more than 90% of the world's airports, which is a lot
// better than nothing ... but it's not 100%.
// We know "most" of the world uses millibars,
// but the US, Canada and *some* other places use inches of mercury,
// but (a) we have not implemented a reliable method of
// ascertaining which airports are in the US, let alone
// (b) ascertaining which other places use inches.
//
int Apt_US_CA(const string id) {
// Assume all IDs have length 3 or 4.
// No counterexamples have been seen.
if (id.length() == 4) {
if (id.substr(0,1) == "K") return 1;
if (id.substr(0,2) == "CY") return 1;
}
for (string::const_iterator ptr = id.begin(); ptr != id.end(); ptr++) {
if (isdigit(*ptr)) return 1;
}
return 0;
}
// Generate the actual broadcast ATIS transmission. // Generate the actual broadcast ATIS transmission.
// Regen means regenerate the /current/ transmission. // Regen means regenerate the /current/ transmission.
// Special means generate a new transmission, with a new sequence. // Special means generate a new transmission, with a new sequence.
@ -238,7 +261,9 @@ int FGATIS::GenTransmission(const int regen, const int special) {
transmission = ""; transmission = "";
if (ident.substr(0,2) == "EG") { int US_CA = Apt_US_CA(ident);
if (!US_CA) {
// UK CAA radiotelephony manual indicates ATIS transmissions start // UK CAA radiotelephony manual indicates ATIS transmissions start
// with "This is ..." // with "This is ..."
transmission += This_is + " "; transmission += This_is + " ";
@ -338,15 +363,25 @@ int FGATIS::GenTransmission(const int regen, const int special) {
snprintf(buf, bs, "/environment/clouds/layer[%i]/elevation-ft", layer); snprintf(buf, bs, "/environment/clouds/layer[%i]/elevation-ft", layer);
double ceiling = int(fgGetDouble(buf) - _geod.getElevationFt()); double ceiling = int(fgGetDouble(buf) - _geod.getElevationFt());
if (ceiling > 12000) continue; if (ceiling > 12000) continue;
if (coverage == scattered) {
if (!did_some) transmission += " " + Sky_condition + ": "; // BEWARE: At the present time, the environment system has no
// way (so far as I know) to represent a "thin broken" or
// "thin overcast" layer. If/when such things are implemented
// in the environment system, code will have to be written here
// to handle them.
// First, do the prefix if any:
if (coverage == scattered || coverage == few) {
if (!did_some) {
transmission += " " + Sky_condition + ": ";
did_some++; did_some++;
}
} else /* must be a ceiling */ if (!did_ceiling) { } else /* must be a ceiling */ if (!did_ceiling) {
transmission += " " + Ceiling + ": "; transmission += " " + Ceiling + ": ";
did_ceiling++; did_ceiling++;
did_some++; did_some++;
} else { } else {
transmission += " "; transmission += " "; // no prefix required
} }
int cig00 = int(SGMiscd::round(ceiling/100)); // hundreds of feet int cig00 = int(SGMiscd::round(ceiling/100)); // hundreds of feet
if (cig00) { if (cig00) {
@ -368,6 +403,7 @@ int FGATIS::GenTransmission(const int regen, const int special) {
} }
transmission += coverage + BRK; transmission += coverage + BRK;
} }
if (!did_some) transmission += " " + Sky + " " + clear + BRK;
transmission += Temperature + ": "; transmission += Temperature + ": ";
double Tsl = fgGetDouble("/environment/temperature-sea-level-degc"); double Tsl = fgGetDouble("/environment/temperature-sea-level-degc");
@ -377,7 +413,7 @@ int FGATIS::GenTransmission(const int regen, const int special) {
} }
snprintf(buf, bs, "%i", abs(temp)); snprintf(buf, bs, "%i", abs(temp));
transmission += ConvertNumToSpokenDigits(buf); transmission += ConvertNumToSpokenDigits(buf);
transmission += " " + Celsius; if (US_CA) transmission += " " + Celsius;
transmission += " " + dewpoint + " "; transmission += " " + dewpoint + " ";
double dpsl = fgGetDouble("/environment/dewpoint-sea-level-degc"); double dpsl = fgGetDouble("/environment/dewpoint-sea-level-degc");
temp = int(SGMiscd::round(FGAtmo().fake_dp_vs_a_us(dpsl, _geod.getElevationFt()))); temp = int(SGMiscd::round(FGAtmo().fake_dp_vs_a_us(dpsl, _geod.getElevationFt())));
@ -386,7 +422,8 @@ int FGATIS::GenTransmission(const int regen, const int special) {
} }
snprintf(buf, bs, "%i", abs(temp)); snprintf(buf, bs, "%i", abs(temp));
transmission += ConvertNumToSpokenDigits(buf); transmission += ConvertNumToSpokenDigits(buf);
transmission += " " + Celsius + BRK; if (US_CA) transmission += " " + Celsius;
transmission += BRK;
transmission += Visibility + ": "; transmission += Visibility + ": ";
double visibility = fgGetDouble("/environment/config/boundary/entry[0]/visibility-m"); double visibility = fgGetDouble("/environment/config/boundary/entry[0]/visibility-m");
@ -409,7 +446,6 @@ int FGATIS::GenTransmission(const int regen, const int special) {
} }
transmission += BRK; transmission += BRK;
transmission += Altimeter + ": ";
double myQNH; double myQNH;
double Psl = fgGetDouble("/environment/pressure-sea-level-inhg"); double Psl = fgGetDouble("/environment/pressure-sea-level-inhg");
{ {
@ -424,17 +460,21 @@ int FGATIS::GenTransmission(const int regen, const int special) {
#endif #endif
myQNH = FGAtmo().QNH(_geod.getElevationM(), press); myQNH = FGAtmo().QNH(_geod.getElevationM(), press);
} }
if(ident.substr(0,2) == "EG" && fgGetBool("/sim/atc/use-millibars")) {
// Convert to millibars for the UK! // Convert to millibars for most of the world (not US, not CA)
if((!US_CA) && fgGetBool("/sim/atc/use-millibars")) {
transmission += QNH + ": ";
myQNH /= mbar; myQNH /= mbar;
if (myQNH > 1000) myQNH -= 1000; // drop high digit if (myQNH > 1000) myQNH -= 1000; // drop high digit
snprintf(buf, bs, "%03.0f", myQNH); snprintf(buf, bs, "%03.0f", myQNH);
transmission += ConvertNumToSpokenDigits(buf) + " " + millibars + BRK;
} else { } else {
myQNH /= inHg; transmission += Altimeter + ": ";
myQNH *= 100.; // shift two decimal places double asetting = myQNH / inHg; // use inches of mercury
snprintf(buf, bs, "%04.0f", myQNH); asetting *= 100.; // shift two decimal places
} snprintf(buf, bs, "%04.0f", asetting);
transmission += ConvertNumToSpokenDigits(buf) + BRK; transmission += ConvertNumToSpokenDigits(buf) + BRK;
}
if (_type == ATIS /* as opposed to AWOS */) { if (_type == ATIS /* as opposed to AWOS */) {
const FGAirport* apt = fgFindAirportID(ident); const FGAirport* apt = fgFindAirportID(ident);
@ -456,27 +496,8 @@ int FGATIS::GenTransmission(const int regen, const int special) {
transmission += phonetic_seq_string; transmission += phonetic_seq_string;
transmission += "... " + BRK + PAUSE + PAUSE; transmission += "... " + BRK + PAUSE + PAUSE;
} }
#ifdef ATIS_TEST transmission_readable = transmission;
cout << "**** ATIS active on:"; // Take the previous readable string and munge it to
#endif
for (map<string,int>::iterator act = active_on.begin(); act != active_on.end(); act++){
string prop = "/instrumentation/" + act->first + "/atis";
globals->get_props()->setStringValue(prop.c_str(),
("<pre>\n" + transmission + "</pre>\n").c_str());
#ifdef ATIS_TEST
cout << " " << prop;
#endif
}
#ifdef ATIS_TEST
cout << " ****" << endl;
cout << transmission << endl;
// Note that even if we aren't outputting the transmission
// on stdout, you can still see it by pointing a web browser
// at the property tree. The second comm radio is:
// http://localhost:5400/instrumentation/comm[1]
#endif
// Take the previous English-looking string and munge it to
// be relatively-more acceptable to the primitive tts system. // be relatively-more acceptable to the primitive tts system.
// Note that : ; and . are among the token-delimeters recognized // Note that : ; and . are among the token-delimeters recognized
// by the tts system. // by the tts system.
@ -487,3 +508,27 @@ int FGATIS::GenTransmission(const int regen, const int special) {
} }
return 1; return 1;
} }
// Put the transmission into the property tree,
// possibly in multiple places if multiple radios
// are tuned to the same ATIS.
// You can see it by pointing a web browser
// at the property tree. The second comm radio is:
// http://localhost:5400/instrumentation/comm[1]
//
// (Also, if in debug mode, dump it to the console.)
void FGATIS::TreeOut(int msg_OK){
for (map<string,int>::iterator act = active_on.begin();
act != active_on.end();
act++){
string prop = "/instrumentation/" + act->first + "/atis";
globals->get_props()->setStringValue(prop.c_str(),
("<pre>\n" + transmission_readable + "</pre>\n").c_str());
#ifdef ATIS_TEST
if (msg_OK) cout << "**** ATIS active on: " << prop << endl;
#endif
}
#ifdef ATIS_TEST
if (msg_OK) cout << transmission_readable << endl;
#endif
}

View file

@ -39,9 +39,14 @@ typedef std::map<std::string,std::string> MSS;
class FGATIS : public FGATC { class FGATIS : public FGATC {
//atc_type type; //atc_type type;
std::string transmission; // The actual ATIS transmission
// This is not stored in default.atis but is generated // The actual ATIS transmission
// from the prevailing conditions when required. // This is generated from the prevailing conditions when required.
// This is the version with markup, suitable for voice synthesis:
std::string transmission;
// Same as above, but in a form more readable as text.
std::string transmission_readable;
// for failure modeling // for failure modeling
std::string trans_ident; // transmitted ident std::string trans_ident; // transmitted ident
@ -82,8 +87,12 @@ class FGATIS : public FGATC {
std::string refname; // Holds the refname of a transmission in progress std::string refname; // Holds the refname of a transmission in progress
int GenTransmission(const int regen, // Generate the ATIS transmission text:
const int special); // Generate the transmission string int GenTransmission(const int regen, const int special);
// Put the text into the property tree
// (and in debug mode, print it on the console):
void TreeOut(int msgOK);
friend std::istream& operator>> ( std::istream&, FGATIS& ); friend std::istream& operator>> ( std::istream&, FGATIS& );
}; };

View file

@ -3,6 +3,9 @@
#include <string> #include <string>
// NOTE: This file serves as a database.
// It is read by some utility programs that synthesize
// the library of spoken words.
#define Q(word) const std::string word(#word); #define Q(word) const std::string word(#word);
@ -41,6 +44,7 @@ Q(broken)
Q(overcast) Q(overcast)
Q(thin) Q(thin)
Q(Sky_condition) Q(Sky_condition)
Q(Sky)
Q(Ceiling) Q(Ceiling)
Q(minus) Q(minus)
Q(dewpoint) Q(dewpoint)
@ -51,6 +55,8 @@ Q(one_half)
Q(three_quarters) Q(three_quarters)
Q(one_and_one_half) Q(one_and_one_half)
Q(Altimeter) Q(Altimeter)
Q(QNH)
Q(millibars)
Q(Landing_and_departing_runway) Q(Landing_and_departing_runway)
Q(On_initial_contact_advise_you_have_information) Q(On_initial_contact_advise_you_have_information)
Q(This_is) Q(This_is)

View file

@ -1,3 +1,7 @@
// NOTE: This file serves as a database.
// It is read by some utility programs that synthesize
// the library of spoken words.
REMAP(Intl, International) REMAP(Intl, International)
REMAP(Rgnl, Regional) REMAP(Rgnl, Regional)
REMAP(Co, County) REMAP(Co, County)

View file

@ -1,3 +1,7 @@
add_subdirectory(TerraSync) add_subdirectory(TerraSync)
add_subdirectory(fgviewer) add_subdirectory(fgviewer)
add_subdirectory(GPSsmooth)
if (FLTK_FOUND)
add_subdirectory(fgadmin)
endif (FLTK_FOUND)

View file

@ -0,0 +1,48 @@
add_executable(GPSsmooth gps.cxx gps_main.cxx)
add_executable(MIDGsmooth MIDG-II.cxx MIDG_main.cxx)
add_executable(UGsmooth UGear.cxx UGear_command.cxx UGear_main.cxx UGear_telnet.cxx)
target_link_libraries(GPSsmooth
${SIMGEAR_DEBUG_LIBRARY}
${SIMGEAR_IO_LIBRARY}
${SIMGEAR_MISC_LIBRARY}
${SIMGEAR_STRUCTURE_LIBRARY}
${SIMGEAR_TIMING_LIBRARY}
${PLIB_SG_LIBRARY}
${PLIB_UL_LIBRARY}
${ZLIB_LIBRARIES}
${WINMM_LIBRARY}
${WINSOCK_LIBRARY}
${ZLIB_LIBRARIES}
)
target_link_libraries(MIDGsmooth
${SIMGEAR_DEBUG_LIBRARY}
${SIMGEAR_IO_LIBRARY}
${SIMGEAR_MATH_LIBRARY}
${SIMGEAR_SERIAL_LIBRARY}
${SIMGEAR_STRUCTURE_LIBRARY}
${SIMGEAR_TIMING_LIBRARY}
${PLIB_SG_LIBRARY}
${PLIB_UL_LIBRARY}
${WINMM_LIBRARY}
${WINSOCK_LIBRARY}
)
target_link_libraries(UGsmooth
${SIMGEAR_DEBUG_LIBRARY}
${SIMGEAR_IO_LIBRARY}
${SIMGEAR_MATH_LIBRARY}
${SIMGEAR_MISC_LIBRARY}
${SIMGEAR_SERIAL_LIBRARY}
${SIMGEAR_STRUCTURE_LIBRARY}
${SIMGEAR_TIMING_LIBRARY}
${PLIB_SG_LIBRARY}
${PLIB_UL_LIBRARY}
${WINMM_LIBRARY}
${WINSOCK_LIBRARY}
${ZLIB_LIBRARIES}
)
install(TARGETS GPSsmooth MIDGsmooth UGsmooth RUNTIME DESTINATION bin)

View file

@ -2,16 +2,22 @@
# include <config.h> # include <config.h>
#endif #endif
#ifdef HAVE_WINDOWS_H
# include <windows.h>
#else
# include <netinet/in.h> // htonl() ntohl()
#endif
#include <iostream> #include <iostream>
#include <string> #include <string>
#include <plib/net.h>
#include <plib/sg.h> #include <plib/sg.h>
#include <simgear/constants.h> #include <simgear/constants.h>
#include <simgear/io/lowlevel.hxx> // endian tests #include <simgear/io/lowlevel.hxx> // endian tests
#include <simgear/io/sg_file.hxx> #include <simgear/io/sg_file.hxx>
#include <simgear/io/sg_serial.hxx> #include <simgear/io/sg_serial.hxx>
#include <simgear/io/raw_socket.hxx>
#include <simgear/math/sg_geodesy.hxx> #include <simgear/math/sg_geodesy.hxx>
#include <simgear/timing/timestamp.hxx> #include <simgear/timing/timestamp.hxx>
@ -27,7 +33,7 @@ using std::string;
// Network channels // Network channels
static netSocket fdm_sock, ctrls_sock; static simgear::Socket fdm_sock, ctrls_sock;
// midg data // midg data
MIDGTrack track; MIDGTrack track;
@ -394,7 +400,7 @@ int main( int argc, char **argv ) {
// Setup up outgoing network connections // Setup up outgoing network connections
netInit( &argc,argv ); // We must call this before any other net stuff simgear::Socket::initSockets(); // We must call this before any other net stuff
if ( ! fdm_sock.open( false ) ) { // open a UDP socket if ( ! fdm_sock.open( false ) ) { // open a UDP socket
cout << "error opening fdm output socket" << endl; cout << "error opening fdm output socket" << endl;

View file

@ -16,7 +16,7 @@ GPSsmooth_SOURCES = \
gps_main.cxx gps_main.cxx
GPSsmooth_LDADD = \ GPSsmooth_LDADD = \
$(GPSsmooth_PLIB_LIBS) -lsgtiming -lsgmisc -lsgdebug \ $(GPSsmooth_PLIB_LIBS) -lsgio -lsgtiming -lsgmisc -lsgdebug -lsgstructure \
$(joystick_LIBS) $(network_LIBS) $(base_LIBS) -lz $(joystick_LIBS) $(network_LIBS) $(base_LIBS) -lz
MIDGsmooth_SOURCES = \ MIDGsmooth_SOURCES = \
@ -37,7 +37,7 @@ UGsmooth_SOURCES = \
UGsmooth_LDADD = \ UGsmooth_LDADD = \
$(UGsmooth_PLIB_LIBS) -lsgio -lsgserial -lsgtiming \ $(UGsmooth_PLIB_LIBS) -lsgio -lsgserial -lsgtiming \
-lsgmath -lsgbucket -lsgmisc -lsgdebug \ -lsgmath -lsgbucket -lsgmisc -lsgdebug -lsgstructure \
$(joystick_LIBS) $(network_LIBS) $(base_LIBS) -lz $(joystick_LIBS) $(network_LIBS) $(base_LIBS) -lz
INCLUDES = -I$(top_srcdir)/src INCLUDES = -I$(top_srcdir)/src

View file

@ -2,6 +2,12 @@
# include <config.h> # include <config.h>
#endif #endif
#ifdef HAVE_WINDOWS_H
# include <windows.h>
#else
# include <netinet/in.h> // htonl() ntohl()
#endif
#ifndef _WIN32 #ifndef _WIN32
# include <strings.h> // for bzero() # include <strings.h> // for bzero()
#else #else
@ -10,12 +16,12 @@
#include <iostream> #include <iostream>
#include <string> #include <string>
#include <plib/net.h>
#include <plib/sg.h> #include <plib/sg.h>
#include <simgear/constants.h> #include <simgear/constants.h>
#include <simgear/io/lowlevel.hxx> // endian tests #include <simgear/io/lowlevel.hxx> // endian tests
#include <simgear/io/sg_file.hxx> #include <simgear/io/sg_file.hxx>
#include <simgear/io/raw_socket.hxx>
#include <simgear/serial/serial.hxx> #include <simgear/serial/serial.hxx>
#include <simgear/math/sg_geodesy.hxx> #include <simgear/math/sg_geodesy.hxx>
#include <simgear/timing/timestamp.hxx> #include <simgear/timing/timestamp.hxx>
@ -35,7 +41,7 @@ using std::string;
// Network channels // Network channels
static netSocket fdm_sock, ctrls_sock, opengc_sock; static simgear::Socket fdm_sock, ctrls_sock, opengc_sock;
// ugear data // ugear data
UGTrack track; UGTrack track;
@ -658,7 +664,7 @@ int main( int argc, char **argv ) {
// Setup up outgoing network connections // Setup up outgoing network connections
netInit( &argc,argv ); // We must call this before any other net stuff simgear::Socket::initSockets(); // We must call this before any other net stuff
if ( ! opengc_sock.open( false ) ) { // open a UDP socket if ( ! opengc_sock.open( false ) ) { // open a UDP socket
cout << "error opening opengc output socket" << endl; cout << "error opening opengc output socket" << endl;

View file

@ -23,14 +23,13 @@
// $Id$ // $Id$
#include <simgear/io/sg_netChat.hxx>
#include <simgear/structure/commands.hxx> #include <simgear/structure/commands.hxx>
#include <simgear/misc/strutils.hxx> #include <simgear/misc/strutils.hxx>
#include <simgear/math/SGMath.hxx> #include <simgear/math/SGMath.hxx>
#include <sstream> #include <sstream>
#include <plib/netChat.h>
#include "UGear_command.hxx" #include "UGear_command.hxx"
#include "UGear_telnet.hxx" #include "UGear_telnet.hxx"
@ -41,9 +40,9 @@ using std::ends;
* Props connection class. * Props connection class.
* This class represents a connection to props client. * This class represents a connection to props client.
*/ */
class PropsChannel : public netChat class PropsChannel : public simgear::NetChat
{ {
netBuffer buffer; simgear::NetBuffer buffer;
/** /**
* Current property node name. * Current property node name.
@ -188,9 +187,9 @@ UGTelnet::open()
return false; return false;
} }
netChannel::open(); simgear::NetChannel::open();
netChannel::bind( "", port ); simgear::NetChannel::bind( "", port );
netChannel::listen( 5 ); simgear::NetChannel::listen( 5 );
printf("Telnet server started on port %d\n", port ); printf("Telnet server started on port %d\n", port );
enabled = true; enabled = true;
@ -214,7 +213,7 @@ UGTelnet::close()
bool bool
UGTelnet::process() UGTelnet::process()
{ {
netChannel::poll(); simgear::NetChannel::poll();
return true; return true;
} }
@ -224,8 +223,8 @@ UGTelnet::process()
void void
UGTelnet::handleAccept() UGTelnet::handleAccept()
{ {
netAddress addr; simgear::IPAddress addr;
int handle = netChannel::accept( &addr ); int handle = simgear::NetChannel::accept( &addr );
printf("Telent server accepted connection from %s:%d\n", printf("Telent server accepted connection from %s:%d\n",
addr.getHost(), addr.getPort() ); addr.getHost(), addr.getPort() );
PropsChannel* channel = new PropsChannel(); PropsChannel* channel = new PropsChannel();

View file

@ -33,7 +33,7 @@
using std::string; using std::string;
using std::vector; using std::vector;
#include <plib/netChannel.h> #include <simgear/io/sg_netChannel.hxx>
/** /**
@ -41,7 +41,7 @@ using std::vector;
* This class provides a telnet-like server for remote access to * This class provides a telnet-like server for remote access to
* FlightGear properties. * FlightGear properties.
*/ */
class UGTelnet: netChannel class UGTelnet: simgear::NetChannel
{ {
private: private:

View file

@ -2,13 +2,19 @@
# include <config.h> # include <config.h>
#endif #endif
#ifdef HAVE_WINDOWS_H
# include <windows.h>
#else
# include <netinet/in.h> // htonl() ntohl()
#endif
#include <iostream> #include <iostream>
#include <string> #include <string>
#include <plib/net.h>
#include <plib/sg.h> #include <plib/sg.h>
#include <simgear/io/lowlevel.hxx> // endian tests #include <simgear/io/lowlevel.hxx> // endian tests
#include <simgear/io/raw_socket.hxx>
#include <simgear/timing/timestamp.hxx> #include <simgear/timing/timestamp.hxx>
#include <Network/net_ctrls.hxx> #include <Network/net_ctrls.hxx>
@ -23,7 +29,7 @@ using std::string;
// Network channels // Network channels
static netSocket fdm_sock, ctrls_sock; static simgear::Socket fdm_sock, ctrls_sock;
// gps data // gps data
GPSTrack track; GPSTrack track;
@ -369,7 +375,7 @@ int main( int argc, char **argv ) {
// Setup up outgoing network connections // Setup up outgoing network connections
netInit( &argc,argv ); // We must call this before any other net stuff simgear::Socket::initSockets(); // We must call this before any other net stuff
if ( ! fdm_sock.open( false ) ) { // open a UDP socket if ( ! fdm_sock.open( false ) ) { // open a UDP socket
cout << "error opening fdm output socket" << endl; cout << "error opening fdm output socket" << endl;

View file

@ -5,7 +5,8 @@ add_executable(terrasync terrasync.cxx)
target_link_libraries(terrasync target_link_libraries(terrasync
${SIMGEAR_LIBRARIES} ${SIMGEAR_LIBRARIES}
${ZLIB_LIBRARIES}) ${ZLIB_LIBRARIES}
${WINSOCK_LIBRARY})
if(HAVE_SVN_CLIENT) if(HAVE_SVN_CLIENT)
target_link_libraries(terrasync ${SVN_CLIENT_LIBRARIES}) target_link_libraries(terrasync ${SVN_CLIENT_LIBRARIES})

View file

@ -33,7 +33,11 @@
#include <time.h> #include <time.h>
#include <unistd.h> #include <unistd.h>
#elif defined(_MSC_VER) #elif defined(_MSC_VER)
#include <io.h> # include <io.h>
# ifndef HAVE_SVN_CLIENT_H
# include <time.h>
# include <process.h>
# endif
#endif #endif
#include <stdlib.h> // atoi() atof() abs() system() #include <stdlib.h> // atoi() atof() abs() system()

View file

@ -0,0 +1 @@
add_subdirectory(src)

View file

@ -0,0 +1,11 @@
add_executable(fgadmin fgadmin.cxx fgadmin_funcs.cxx main.cxx untarka.c)
target_link_libraries(fgadmin
${SIMGEAR_LIBRARIES}
${ZLIB_LIBRARIES}
${PLIB_LIBRARIES}
${FLTK_LIBRARIES}
)
install(TARGETS fgadmin RUNTIME DESTINATION bin)