1
0
forked from 0ad/0ad
Commit Graph

4391 Commits

Author SHA1 Message Date
ec9b5c982e Replaced Windows SpiderMonkey library with a threadsafe build of version 1.6.
Fixed linking with wxWidgets.
Enabled RTTI for non-engine packages.
Fixed wxJS for Windows.
Fixed failure to load on Windows 2000 due to IsWow64Process import.
Fixed trivial warnings.

This was SVN commit r5155.
2007-06-09 02:40:48 +00:00
53bcba3368 Atlas: Updated wxJS to latest SVN version. Made the JS runtime have a greater lifetime than all the wx windows, to avoid garbage collection problems.
IGUIObject: Cache the JSObject*, to prevent some frequent allocation
while running GUI scripts.
JSInterface_IGUIObject: Fixed garbage collection issues.
JSInterface_IGUIObject, ScriptGlue: Changed to the JS_THREADSAFE form of
JS_GetClass.
Util: Avoid startup warnings on Linux caused by using unimplemented
cpu_* functions that aren't needed for anything important yet.
sysdep/unix: Changed to native line endings.

This was SVN commit r5154.
2007-06-08 22:56:01 +00:00
d416b6ac83 Removing old wxJavaScript
This was SVN commit r5153.
2007-06-08 22:15:11 +00:00
4fbaea3780 # fix for exceptions when not running in debugger
move exception-specific stuff into wseh. it now grabs the entry point
and wraps it in a __try block (but only for the main EXE).
this works around issues with the previous SEH registration code
(exceptions weren't caught in release mode when not running in debugger)

This was SVN commit r5151.
2007-06-08 17:44:24 +00:00
2405a98b58 fix for immediate exit in autobuilt EXE
(problem was the vc7 linker stripping out stuff that we needed)

This was SVN commit r5149.
2007-06-07 19:32:13 +00:00
163e294eb7 winit: section names should start with .
wposix: raise exception instead of quietly exiting
wstartup: add note on what needs to be done on vc7

This was SVN commit r5148.
2007-06-07 19:15:45 +00:00
914e5f7c2f Rename stdafx.h to precompiled.h
This was SVN commit r5146.
2007-06-05 18:35:05 +00:00
789ba49ca2 Oops, it crashes unless I include them this way around
This was SVN commit r5145.
2007-06-05 18:29:36 +00:00
4e83672579 # Added scripting support to the scenario editor UI
Added modified version of wxJavaScript.
Added Atlas script interface.
Rewrote the Map sidebar in JS.

This was SVN commit r5144.
2007-06-05 18:16:55 +00:00
0db787bf58 wsock: fix init problem (if getnameinfo et al were the first function called from winsock - as happens when using quickstart - ws2_32 wasn't loaded first)
This was SVN commit r5142.
2007-06-04 23:55:29 +00:00
d802b73d94 winit: rename register macros for more clarity
wdbg: cleanup, improve exception catcher (previously potentially failed
if __try block came in non-main thread). required since wstartup no
longer commandeers the entry point.
winit, wstartup: update documentation

This was SVN commit r5141.
2007-06-04 22:59:14 +00:00
92578ae553 # Some initial work on networking, fixing session setup, game startup, and command queueing.
- Fixed outdated / buggy networking code in the GUI scripts.
- Finished the API to CNetClient so that it's possible to start a CGame
from it.
- Some enhancements for debugging networking: Enabled updates while the
game is minimized/out-of-focus if it's in a network session. Also
reduced the turn length to something slightly more manageable but still
unplayable (1 sec versus 3 sec).
- Fixed a bug where IssueCommand used to access the order it creates
after queueing it, which is bad if the order gets deleted while being
queued (e.g. in CNetClient).

This was SVN commit r5139.
2007-06-04 07:41:05 +00:00
db189468a9 (update-workspace required)
found another means of doing startup/shutdown that doesn't require
hooking and allows init callbacks to use CRT functions (avoiding
problems similar to the recent rash of pre-libc bugs). also, callback
registration no longer needs ugly #pragma syntax.

remove 'Detours' (evil and no longer needed)

This was SVN commit r5137.
2007-06-04 00:00:57 +00:00
92cd6472da This was SVN commit r5136. 2007-06-03 22:50:44 +00:00
Alexander
05521b8c83 This was SVN commit r5135. 2007-06-03 22:20:29 +00:00
Alexander
523c5f78f5 Moved placement validation code to a separate function.
This was SVN commit r5134.
2007-06-03 21:56:21 +00:00
ecaf665d5a Separate JS_ShutDown from the normal ScriptingHost shutdown, because it's resetting non-thread-safe per-process state.
DllLoader: Report dlerror when dlopen fails.
AtlasObject: Avoid ICC warnings caused by 'const T' being equivalent to
'T' when 'T' is already const.

This was SVN commit r5133.
2007-06-03 15:37:26 +00:00
48ae626a31 fix warnings
This was SVN commit r5131.
2007-06-02 21:33:35 +00:00
c1d0a25b55 # Work around FAM problem on Linux
Avoid the hang caused by filling up FAM's event buffer when mounting
lots of directories

This was SVN commit r5130.
2007-06-02 17:04:05 +00:00
33c3a8ed97 Fix unbalanced #endif
This was SVN commit r5128.
2007-06-02 15:45:14 +00:00
c3de4710d3 Reverted update-workspaces.bat
This was SVN commit r5127.
2007-06-02 15:24:20 +00:00
cf89464e64 # autobuilder fix
detours is configured as a static lib, which would require using the
same compiler, but we have several in action.
fix: include a stripped down version of its code in the main source tree

This was SVN commit r5126.
2007-06-02 12:43:42 +00:00
6b6b6198f9 # Linux ICC compatibility.
Don't disable PCH in AtlasUI for non-GCC builds.
Prevented some excessive warnings ("implicitly-signed bit field of
length 1").
Removed (wcs|str)nlen functions on OS_UNIX, since they were already
removed from the .h.

This was SVN commit r5125.
2007-06-01 00:34:36 +00:00
d90975ee1e # Slightly improved Linux compatibility for Atlas.
Properly enabled PCH in GCC.
But wx 2.8 (with anonymous namespaces) and GCC <4.2 and PCH conflict, so
PCH is disabled when building AtlasUI on broken compiler versions.
Removed media player, because it's useless and makes building harder.
Removed unnecessary wx linking.

This was SVN commit r5122.
2007-05-31 01:47:17 +00:00
bd0d0c0026 # finalize WHRT implementation
cpu: avoid measuring cpu freq if possible
ia32: cleanup, fix #cores detection on AMD (they're incompatible,
*sigh*), add ia32_Generation
wcpu: remove IsThrottling code (clunky and not necessary - we rely on
ia32's feature bit detection instead)
counter: move whrt's counter create code here
qpc: update comment
tsc: finalize IsSafe implementation, remove per-thread stuff (since it
cannot be made to work)
whrt: cleanup, remove calibration code (no longer needed)

This was SVN commit r5121.
2007-05-31 00:11:38 +00:00
d778b22d61 Minor tidying of SVN log script
This was SVN commit r5120.
2007-05-30 17:14:07 +00:00
7c50888219 # Changed SVN log to show latest 10 entries
This was SVN commit r5119.
2007-05-30 17:01:14 +00:00
7c241ed22c manual build with new atlas overbrightening support.
also split aken driver into checked and free versions.

This was SVN commit r5118.
2007-05-29 22:55:23 +00:00
f35fe2f781 implement atlas feature request
(http://www.wildfiregames.com/forum/index.php?showtopic=11018)

This was SVN commit r5117.
2007-05-29 22:47:26 +00:00
cba876b246 bugfixes+cleanup
aken: clean up debug strings
mahaf: use checked/free version of aken depending on config. refactor to
eliminate goto.
hpet: avoid undefined unmap if HPET not found
whrt/*: make sure all counter class data is initialized
whrt: prefer QPC over PMT (it's much faster?!)
winit: add some instrumentation
wutil: win_exe_dir and win_sys_dir shouldn't end in slash. fixed.

This was SVN commit r5116.
2007-05-29 22:39:36 +00:00
fba692c8b5 # Fixed some warnings and potentially misleading code
* Removed ToJSVal<jsval> because it's treated as ToJSVal<long> and
causes minor confusion and/or compiler errors.
   Changed script interface functions to return either C++ types or a
jsval_t wrapper.
 * Replaced some C casts with static_cast to avoid significant confusion
and to cause compiler errors instead.
 * Removed some redundant argument-checking code. Simplified some
string-generating code.
 * Fixed some "dereferencing type-punned pointer will break
strict-aliasing rules" warnings (from `g++ -O3`).

This was SVN commit r5115.
2007-05-29 19:01:21 +00:00
5919fc7877 fixes, documentation and cleanup.
. allocators: add static_calloc. also: documention was duplicated in
header; merge it.
. wdir_watch: fix last remaining static object init issues
. add rationale and explanations to lib_errors, wsdl, qpc, whrt.
. cpu/ia32: remove throttling detection (hacky); will be taken care of
by tsc.
. ia32: expose vendor
. wdbg_sym: add its own critical section (safer, less contention)

This was SVN commit r5114.
2007-05-29 16:28:34 +00:00
6daf03b353 This was SVN commit r5113. 2007-05-29 03:49:48 +00:00
238252ec53 #Skins for Ekdromos detailed.
This was SVN commit r5112.
2007-05-29 03:08:41 +00:00
211999ac6a fixes to timer impls:
pmt: support ACPI 1.0 table name
qpc: just use wcpu_ClockFrequency, can't fail
tsc: do ia32_Init first

This was SVN commit r5111.
2007-05-28 16:50:08 +00:00
e57335cd63 init order fix: error reporter requires pageSize, so set that early in case other winit functions fail
This was SVN commit r5110.
2007-05-28 15:44:41 +00:00
b879e344f1 make sure winit shutdown actually happens during self-test (fixes leaks and possibly failure to unload driver)
revamp module init: no more atexit and "premain" init => no longer need
to call any wstartup init function. winit section names now use group
numbers instead of letters.

delay_load -> wdll_delay_load
dll_ver -> wdll_ver
add aken build environment
cleanup wsock.cpp, have it import its functions properly
wsdl: defend against GameSetup calling SDL_Quit twice.

This was SVN commit r5108.
2007-05-28 15:08:33 +00:00
7fe6c3d77f add detours library for API hooking.
(update aken driver while at it)

This was SVN commit r5107.
2007-05-28 15:01:29 +00:00
29610672f4 fix warnings
This was SVN commit r5106.
2007-05-28 14:25:07 +00:00
52ae284a7e new timer code (esp. HPET) now operational. TSC still disabled pending calibration code.
add update mechanism (needed to safely handle counter rollover) and
lock-free synchronization.

refactor:
. Counters now have Activate/Shutdown interface rather than throwing
exceptions from the ctor.
. whrt is responsible for caching frequency/resolution etc.
. fix counterBits handling

This was SVN commit r5105.
2007-05-28 09:25:38 +00:00
bc519cc671 prevent crash if lib_error association code is called before _cinit (happens if there's a problem with whrt init).
instead of std::map, use a linked list of static LibErrorAssociation
instances. (also simplifies the process of registering error
codes/descriptions)

module_init: remove warning (happens in normal operation)
win: add fixed InterlockedExchangePointer definition
mahaf: no longer warn if stopping the service failed because it wasn't
started

This was SVN commit r5104.
2007-05-28 09:20:55 +00:00
843d849931 This was SVN commit r5103. 2007-05-28 02:37:38 +00:00
c9f10be090 acpi and mahaf: now set ModuleInitState to error if something fails (prevents a subsequent init from returning true and allowing its dependent to continue and crash into a wall)
wtime: "implement" CLOCK_MONOTONIC (that's what the timer already did,
anyhow)

main: move early init to GameSetup!EarlyInit (fixes atlas problem with
timer)

This was SVN commit r5101.
2007-05-26 23:29:20 +00:00
2348f71aea mahaf: don't bring up a warning when starting the driver fails (expected case on non-admin accounts)
wcpu: detect values once during init (simplifies code a bit)

This was SVN commit r5100.
2007-05-26 22:42:08 +00:00
8f066e18ee Ignore non-standard mouse buttons, instead of crashing
This was SVN commit r5098.
2007-05-26 18:38:38 +00:00
f1e3c44d1b test_lockfree: eliminate GCC warning
lockfree: avoid mem leak caused by no longer necessary shutdown hack

This was SVN commit r5097.
2007-05-26 18:16:13 +00:00
4582c8f276 unbreak lockfree test, add sanity checks and timer init
lockfree: avoid potential race condition and add bounds check
whrt: sanity check
test_lockfree: fix by adding call to init/shutdown lockfree
timer: add proper init/shutdown
GameSetup: call lockfree and timer init/shutdown

This was SVN commit r5096.
2007-05-26 17:56:38 +00:00
349d9b9afe add whrt dir, remove winmm delayload and dsound dependency
(workspace must be updated)

This was SVN commit r5095.
2007-05-26 17:17:47 +00:00
2fee886a34 Linux compatibility
This was SVN commit r5094.
2007-05-26 17:10:28 +00:00
c45ef68a88 add work-in-progress WHRT (win high res timer). works well enough, but calibration is not yet complete nor is TSC usable.
cpu: accessor functions ensure what they return is valid. no longer
needs to call wtime_reset_impl (ugh). uses ModuleInitState.
ia32: add APIC ID accessor and prevent redundant init

This was SVN commit r5093.
2007-05-26 16:57:39 +00:00