Commit Graph
100 Commits
Author SHA1 Message Date
James Turner fca64343ae Attempting to fix Windows include issues.
Only handle PackageRef by reference in the header file, so we don’t
create calls to the copy constructor and/or destructor. If this doesn’t
work will need to create a stub implementation file.
2016-11-14 07:52:15 +01:00
James Turner 042a2659f6 Disable Codecvt for now, libstdc++ is problematic.
Need to research which libstdc++ versions implement codecvt.
2016-11-14 07:45:23 +01:00
James Turner fe54af405c Zlib is a public, not private include in Simgear.
Should fix Windows compilation as reported by Alan Teeder on the list.
2016-11-14 07:31:54 +01:00
James Turner ab70090a0a Finally fix bogus terrasync download numbers.
(Staying a hotel with sufficiently slow wi-fi to debug this!)
2016-11-13 22:18:32 +01:00
James Turner ee02750e95 Enforce VS2013/2015 requirement on Windows. 2016-11-13 14:57:39 +00:00
James Turner f55007394e Make more includes target-specific. 2016-11-13 14:57:21 +00:00
James Turner 60a9e8fb7e Implement UTF-8 conversion using codecvt 2016-11-13 14:56:52 +00:00
James Turner 7f8455f731 Multi-thumbnail support in packages.
Allow multiple thumbnails per variant / package, including
tagging with types so we can require certain thumbnails in the future.
2016-11-13 14:56:31 +00:00
James Turner 6ae86fc4ca Fix a warning. 2016-11-13 12:02:12 +00:00
James Turner ab1d4e651e Bugfix: avoid bogus download size on start
Missed a default init of the HTTP repo download content size, so until
the request response header was received, this could report a very
large value.
2016-11-07 15:49:07 +01:00
James Turner 5cd250e452 Packages: notify delegate of uninstalls. 2016-11-06 21:58:01 +01:00
James Turner 2dcff4bb8e Ensure build include location is used first.
Otherwise PREFIX_PATH headers might be found first, but these could be
from an older SimGear version.
2016-11-06 21:57:30 +01:00
James Turner 604a9ff614 Hopefully fix Win32 linkage. 2016-11-02 22:57:39 +00:00
James Turner a09630bcca Cmake export fixes.
Should hopefully fix importing in FlightGear
2016-11-02 13:59:43 +00:00
James Turner b44c70b3f4 Simplify isnan detection with C++11 library. 2016-10-30 22:49:38 +00:00
James Turner e4cddb100e Drastically simplify compiler.h 2016-10-30 22:49:11 +00:00
James Turner 51e7d95bf2 Require CMake 3.0, enable C++11
Let’s see what this breaks.
2016-10-24 22:52:51 +02:00
James Turner 202571386b Exported package fix.
https://sourceforge.net/p/flightgear/codetickets/1892/
2016-10-20 20:26:51 +01:00
James Turner dd52b6af50 Remove some archaic code. 2016-10-09 11:08:17 +02:00
James Turner 7b2507cb19 Config changes to warn on older tools.
Warn on to-be-deprecated versions of Cmake, Visual Studio and GCC
2016-09-28 17:20:51 -05:00
James Turner 2e19aaaff9 Remove multi-arch workaround in CMake
Since we now require 2.8.11, we can rely on this bug being fixed.
2016-09-27 20:43:03 -05:00
James Turner 6854598b79 Initial pieces for full OBJ support.
Needs testing by aircraft developers, this is just the first piece.
2016-09-27 20:41:31 -05:00
James Turner 87590cafb2 Fix terrasync behaviour when net is down. 2016-09-07 22:49:03 +01:00
James Turner 9b997ea1f7 Only reopen the streams if AllocConsole succeeds.
Avoid a crash with FGRun when OSG tries to use the console.
2016-09-02 00:05:13 +01:00
James Turner d7d59b08a2 Copy-from-install support in TerraSync
Allows repositories to be initialised based on data in the install.
This avoids duplicate downloading of the Model and Airport data,
and the starting scenery.

Requires a corresponding FlightGear change to be functional.
2016-08-18 16:21:31 +01:00
James Turner 6b82b78c7c Warn when OSG is not in UTF-8 mode.
This will become an error in the near future.
2016-08-15 22:38:00 +01:00
James Turner 8201301064 Improve Windows linkage.
When using a patched OSG, avoid /FORCE:MULTIPLE work-around.
2016-08-15 22:38:00 +01:00
James Turner 899778b354 Fix inverted logic in any-bindings test. 2016-08-08 16:59:06 +01:00
James Turner a31d1342d5 Simplify Aeonwave/OpenAL logic in Cmake slightly 2016-08-06 14:40:14 +01:00
James Turner 5ea01039f9 Improve pick-callback enabled testing. 2016-07-31 22:21:03 +01:00
James Turner 8b8dbeb00d Quiet a log message 2016-07-31 22:21:03 +01:00
James Turner 93226fc500 Change location used for path tests
Jenkins seems to dislike non-Latin-1 characters inside the build
tree on Linux, so use a location inside /tmp instead.
2016-07-15 17:57:32 +01:00
James Turner 31ba9dfa70 Further SGPath API usage cleanups. 2016-07-15 16:33:52 +01:00
James Turner 19df18fefb Use wide-string APIs on Windows.
SGPath and simgear::Dir use ‘w’ versions of POSIX APIs on Windows,
and convert UTF-8 SGPath to wide-strings as part of this.

Includes improved unit-tests for this code, with some very basic
tests of creating and iterating files with Unicode characters in
their names.

No user-visible changes should result from this, on any platform; in
particular wide-string support is still incomplete so FlightGear will
not yet work with arbitrary Unicode paths on Windows.
2016-07-15 09:50:44 +01:00
James Turner a5a4bf6d41 Another HLA/SGPath fix 2016-07-04 09:31:34 +01:00
James Turner 9812315d96 realpath returns a path, not a string. 2016-07-04 09:04:46 +01:00
James Turner c40044feeb Fix HLAFederate for readXML API change 2016-07-04 07:20:23 +01:00
James Turner a636da6959 SGPath in easyXML API 2016-07-03 23:41:07 +01:00
James Turner ca84d2046a Fix sg_gzofstream path type (now SGPath) 2016-07-03 23:05:42 +01:00
James Turner c037a0e461 Windows string conversion for SGPath 2016-07-03 22:56:04 +01:00
James Turner cf18d4eaaf SGPath can convert to std::wstring 2016-07-02 09:34:27 +01:00
James Turner 32735428bb More SGPath APIs 2016-07-01 17:14:34 +01:00
James Turner b862cf7e54 Fix repository test. 2016-07-01 09:02:52 +01:00
James Turner f21eac8473 Building with clean SGPath API 2016-06-30 16:17:52 +01:00
James Turner 38c8931950 Fix debug runtime assert 2016-06-29 16:26:42 +01:00
James Turner cfe1c0933f Further SG stream APIs 2016-06-27 12:29:23 -05:00
James Turner a3b3280123 iostream overloads taking an SGPath 2016-06-25 16:30:24 +01:00
James Turner 8cfe5a2e08 Native SGPath API on SGInterpTable
- string-based version will be removed in the future.
2016-06-23 15:21:26 +01:00
James Turner bd896096cc Changing SGPath APIs, using SGPath in more places.
Change most places we control (i.e not helper libs) to use SGPath
to represent a path, instead of using std::string. Extend SGPath
API to explicitly expose the path in either UTF-8 or the
system 8-bit encoding.
2016-06-22 17:15:32 +01:00
James Turner 855ff5a8b0 Fix Linux compilation of untar.hxx 2016-06-16 04:46:37 -05:00
James Turner e695505e62 Tests for un-tar code. 2016-06-15 22:27:01 +01:00
James Turner f824cf85a4 Fix Untar namespacing. 2016-06-14 15:13:58 +01:00
James Turner fb8b60b6fe Export untar header
Needed for scenery installation helper.
2016-06-14 15:12:20 +01:00
James Turner 516d76d41b VS215 tweaks, warning fixes 2016-06-09 20:38:01 +01:00
James Turner daa10503e6 Fixes to Windows console interaction.
Thanks To Jasin Colegrove for helping me understand the issues here!
2016-06-09 15:11:44 +01:00
James Turner c762dbe864 Fix dependency on ‘version’ file. 2016-06-09 11:03:35 +01:00
James Turner 37c551bae7 Fix for HTTP/curl waiting on update
This improves responsiveness of TerraSync with small files and general
throughout dramatically.
2016-06-08 15:43:59 +01:00
James Turner 0ccf3e1629 Threadsafe terrasync state updates/reading. 2016-06-08 15:27:47 +01:00
James Turner 5ba9004853 More repository test tweaks for Jenkins. 2016-06-07 11:24:01 +01:00
James Turner cb80af0ebe Improving channel lifetime in HTTP-based tests.
Previously, closed channels were not cleaned up, which looks to be
the caused of the test failures on Jenkins.
2016-06-06 17:26:50 +01:00
James Turner 1492de4391 Fix a leak / potential crash 2016-06-06 11:36:47 +01:00
James Turner fad905e7e0 Increase test timeout value.
- investigating failing tests on Jenkins
2016-06-03 15:26:48 +01:00
James Turner fb1b1b9c5e Fix uninitialized var 2016-06-03 08:44:25 -05:00
James Turner b7b304ecfb Fix a warning with GCC 2016-06-03 08:40:55 -05:00
James Turner 8690e4617f CMake tweaks for MSVC detection 2016-06-03 12:19:21 +01:00
James Turner a6bed69d19 Fix user-after-free in HTTP repo code 2016-06-02 23:53:15 +01:00
James Turner 100e327684 More permissive catalog version checks
- support wildcard prefixes on FlightGear versions
- drop catalog version equality check
2016-06-01 22:46:17 +01:00
James Turner 729c9e3faa More VS2015 fixes 2016-06-01 22:36:36 +01:00
James Turner be4ebddb60 Fix for VS2015 compilation 2016-05-31 13:41:28 +01:00
James Turner 34e804b784 Fix VS2015 compilation 2016-05-31 13:40:32 +01:00
James Turner 75b2ef9372 Fix VS2015 compilation 2016-05-31 13:40:00 +01:00
James Turner 1ae9e74539 More libCurl version guards. 2016-05-30 13:02:25 +01:00
James Turner 980ae3115c Whitespace fixes. 2016-05-30 13:02:24 +01:00
James Turner 5ca9a06273 FreeBSD fixes from Ganael LAPLANCHE 2016-05-30 13:02:24 +01:00
James Turner 1b0289b11f HTTP: Always use absolute paths for hashes
Ensure we only compute / retrieve hashes for absolute paths. Fixes
duplicate paths in repository hash cache.
2016-05-26 23:36:03 +01:00
James Turner 00f4248137 Partial update support for HTTP repos.
Not used yet, we set full-update mode on repositories for the
moment. Pending Terrasync change will enable partial mode.
2016-05-26 23:35:11 +01:00
James Turner 8211f1c482 Allow updating a Catalog URL explicitly.
Needed for fallback Catalog URL support.
2016-05-26 17:38:02 +01:00
James Turner 43ebde9914 Expose pending count from terrasync
Total and expose HTTP pending download value as a new
property under terrasync-root.
2016-05-26 17:38:02 +01:00
James Turner 7d59dd977f AbstractRepository interface removed. 2016-05-26 17:38:02 +01:00
James Turner 3e2f37418a Remove SVN sync code. 2016-05-26 17:38:02 +01:00
James Turner 9d2df12ab8 Remove old terraysnc backend methods.
Only in-process HTTP access is supported now, SVN and rsync
and removed. This is to allow changes for better use of the
HTTP API.
2016-05-26 17:38:02 +01:00
James Turner 49bd96c55d Guard usage of CURLMOPT_MAX_TOTAL_CONNECTIONS
Check the Curl patch version to avoid breaking on older
sustems.
2016-05-25 20:08:40 +01:00
James Turner 5fdc756a64 Fix missing <cstdint> on non-Mac 2016-05-24 08:16:40 +01:00
James Turner 871b418242 Initial Tar package support.
Needs proper testing, but basic unit-test passes.
2016-05-23 22:23:16 +01:00
James Turner 6285a409ed Fix a crash with mismatch package versions. 2016-05-18 19:02:41 +01:00
James Turner 9818a123ca Fix removal of directories. 2016-05-18 10:50:57 +01:00
James Turner 9dda5a4e31 Fix platform check for strerror_r on Mac 2016-05-10 20:47:25 +02:00
James Turner 616826ab69 Remove non-CURL HTTP option. 2016-05-07 10:11:40 +01:00
James Turner 6e4da15a58 Use SGBinaryFile in a couple more places.
Most importantly, when computing a hash from the on-disk
state.
2016-05-07 10:03:48 +01:00
James Turner 1fe8931129 Packages: fix extract dir cleanup on success.
Don’t leave extract_xxxxxxx dirs in the Aircraft tree after successfully
extract the contents to the final location.
2016-05-04 22:22:34 +01:00
James Turner d39b055ed1 Avoid unlink of an open file.
Works on Unix, not so great on Windows it turns out. Thanks to Jasin
and Geoff for figuring this out in the end.
2016-05-04 22:13:15 +01:00
James Turner 46ed4b2f79 Catalog refresh / package updating test. 2016-04-20 11:58:35 +02:00
James Turner 8582676100 Catalog removal test
- verifies installed packages are removed also.
2016-04-19 13:56:07 +02:00
James Turner 32181a3956 Expand package-system unit-tests.
More to come, but this covers the absolute basics now.
2016-04-19 13:50:37 +02:00
James Turner c17324b5ea Fixes for HTTP cancellation.
(Forgot to stage these from previous commit)
2016-04-14 09:42:04 +01:00
James Turner a3f1bb546f HTTP request cancellation
- replaces abort() with something more structured.
2016-04-14 09:16:36 +01:00
James Turner 177c5ec709 Guard against disabling a not-yet-active catalog. 2016-03-30 17:09:51 +01:00
James Turner 2e1f01a86a Use ref-ptr in canvas adapter getImage
Adjusted while investigating missing tooltip texture with recent
OSG versions.
2016-03-26 19:55:37 +00:00
James Turner 27baafab0d Packages: handle catalog versions better
When a catalog version is stale, disable it but don’t remove it,
and still try to refresh it. This should give much better behaviour
when the FG version changes, should behave as users expect.
2016-03-25 23:04:45 +00:00
James Turner 8ddcef9142 Fix HTTP unit-test 2016-03-25 13:28:24 +00:00