Commit Graph

521 Commits

Author SHA1 Message Date
marco
ffff774ff2 * fixes by lks of base.inc procptr types (one long->plong, three dword_ptr to ulong_ptr) fixes mantis #29023
git-svn-id: trunk@32456 -
2015-11-22 11:04:37 +00:00
marco
700a22f420 * revert accidentally committed part of executeprocess patch
git-svn-id: trunk@32334 -
2015-11-15 18:47:42 +00:00
marco
92960ff3ac * initial advanced records support for TSize..TRect and -F.
git-svn-id: trunk@32333 -
2015-11-15 18:34:19 +00:00
michael
aa7058e82d * Patch from Ondrej Pokorny to fix broken compilation after 32275
git-svn-id: trunk@32278 -
2015-11-09 07:36:01 +00:00
michael
fde42ca8ef * Type helpers, compatible to Delphi XE 8
git-svn-id: trunk@32262 -
2015-11-07 09:40:54 +00:00
marco
c402bffc69 * part of mantis 028134, cleanup of NORM_ constants
git-svn-id: trunk@30918 -
2015-05-26 17:44:09 +00:00
marco
076e43f799 * try to beautify image_delayload_descriptor a bit. But a 1:1 structure
is not possible I think (unless we forfeit the bitpack alternative)

git-svn-id: trunk@30279 -
2015-03-22 19:54:53 +00:00
marco
57212decc8 * ugly auto conversion IMAGE_IMPORT_DESCRIPTOR and _IMAGE_TLS_DIRECTORY64/32 fixed.
* IMAGE_EXPORT_DIRECTORY

(see comments mantis #27674 )

git-svn-id: trunk@30264 -
2015-03-20 14:01:28 +00:00
marco
882d42eb86 * change image_* macros to unsigned, half of bug #27674
git-svn-id: trunk@30256 -
2015-03-17 22:30:31 +00:00
marco
f79a8c1544 * IMAGE_FIRST_SECTION
git-svn-id: trunk@30185 -
2015-03-14 11:16:12 +00:00
marco
698a068da7 * Missing symbols from mantis #27657 except macro IMAGE_FIRST_SECTION
git-svn-id: trunk@30182 -
2015-03-13 20:08:29 +00:00
Tomas Hajny
dff7cb3c3c * added missing error constant
git-svn-id: trunk@29808 -
2015-02-23 11:19:50 +00:00
Tomas Hajny
b9f88aa80c * mapping of I/O error number 206 having different meaning in FPC to RTE 3
git-svn-id: trunk@29797 -
2015-02-22 22:25:44 +00:00
marco
8e2f8d7f3c * for wince use getprocessaddresa, mantis #27450
git-svn-id: trunk@29684 -
2015-02-13 10:23:05 +00:00
svenbarth
2d454dc8fa Move DynLibs support to System unit using a manager approach like for Threads, WideStrings, etc.. This is needed so that we can support features like "delayed" and loading of dynamic packages.
Each port that allows the usage of dynamic libraries should call InitSystemDynLibs during initialization of the System unit.
The DynLibs unit has been adjusted to be a forwarder for the functions that now reside in the System unit (for backwards compatiblity just in case). Additionally the unit will register the DynLibsManager if it doesn't reside in the System unit anyway.
Currently only the Windows targets (Win32, Win64 and WinCE) implement the DynLibsManager inside the System unit. For other systems using the LoadLibrary, etc. functions will lead to a run error/exception.
If a port wants to implement its own DynLibsManager then it needs to define DISABLE_NO_DYNLIBS_MANAGER. TLibHandle, NilHandle and optionally TOrdinalEntry (it's set to SizeUInt otherwise) should be defined in sysdlh.inc which needs to be enabled using the define FPC_SYSTEM_HAS_SYSDLH (because there are targets which have FEATURE_DYNLIBS enabled, but don't support them... e.g. powerpc-wii -.-).
The DynLibsManager contains methods for loading a library based on a RawByteString and based on a UnicodeString. BOTH should be implemented, but internally one can forward to the other.
The loading by ordinal *can* be be implemented. If it is set to Nil then the implementation of GetProcAddress(lib,ordinal) will return Nil.

+ new functions SetDynLibsManager and GetDynLibsManager to set and retrieve the current DynLibsManager
* provide interface of DynLibs unit in unit System

git-svn-id: trunk@29613 -
2015-02-03 20:00:00 +00:00
marco
43121ed5e1 * Fix for #27228
git-svn-id: trunk@29365 -
2015-01-01 00:27:18 +00:00
pierre
7bbb30ccd4 * Reset filerec mode field to fmClosed if the system call to open the file failed
git-svn-id: trunk@29132 -
2014-11-23 21:49:29 +00:00
pierre
90537e94a0 Call Errno2noutres if system call to close the handle fails in do_close for win and unix
git-svn-id: trunk@29095 -
2014-11-20 22:00:35 +00:00
pierre
260c6583cf Only set StdInputHandle, StdOutputHandle and StdErrorHandle once
git-svn-id: trunk@29094 -
2014-11-20 21:57:15 +00:00
marco
3fbcca0e77 * change ulargeinteger quadpart to unsinged, mantis #27023
git-svn-id: trunk@29059 -
2014-11-11 08:30:14 +00:00
marco
20833d4bc9 * change ContextTrackingMode field to boolean. Mantis #26892
git-svn-id: trunk@28883 -
2014-10-19 20:30:11 +00:00
marco
bcfe5eb146 * large image aware PE flag value. Fixes Delphi programs that set peflags with constant.
git-svn-id: trunk@28737 -
2014-10-04 11:14:56 +00:00
svenbarth
b79e7ce1f9 Implement GetCPUCount for Windows OSes. This is for all three Windows targets.
rtl/win/sysos.inc:
  + add definition of TSystemInfo structure
  + add import of GetSystemInfo
  + add implementation of GetCPUCount which returns value for number of processors retrieved by GetSystemInfo

git-svn-id: trunk@28643 -
2014-09-12 18:40:59 +00:00
marco
eb67f66e10 * add taglogfont out of compatibility, patch by Ocean, mantis #0026539
git-svn-id: trunk@28470 -
2014-08-19 17:45:23 +00:00
marco
a4a11cb149 * startupinfo was declared with lpTstr. splitted in the usual A/W/- variants
git-svn-id: trunk@28240 -
2014-07-19 22:22:49 +00:00
marco
0a0739b916 * improved winexec comment, updated copyright year and add minor comment to gettickcount64
Mantis #26238

git-svn-id: trunk@27834 -
2014-05-31 14:47:31 +00:00
michael
d5a88caecd * Do not display error message if NoErrMsg is set.
git-svn-id: trunk@27765 -
2014-05-11 10:19:04 +00:00
marco
959ea7f5bb * printer unit moved. Amiga unit also moved but it is not actively used.
git-svn-id: trunk@27351 -
2014-03-29 20:35:28 +00:00
nickysn
fb20791cbe * replaced all the remaining uses of nativeint in the rtl with either sizeint
or objpasint

git-svn-id: trunk@27237 -
2014-03-23 13:38:16 +00:00
sergei
e79e038f9c + Win32/Win64 SEH: STATUS_FLOAT_MULTIPLE_(FAULTS|TRAPS) need additional handling. Makes floating-point exceptions consistent between x87 and SSE.
git-svn-id: trunk@27177 -
2014-03-17 22:49:29 +00:00
nickysn
5242ed7864 * changed TResStrInitTable.Count and TWStrInitTablesTable.Count to nativeint
git-svn-id: trunk@26921 -
2014-03-02 13:27:59 +00:00
sergei
1f22c2de22 - Text i/o routines are not expected to return a value.
git-svn-id: trunk@26834 -
2014-02-22 13:42:41 +00:00
sergei
c83f4c5ddc * Windows targets: removed 'errno' threadvar, OS error codes can be passed directly to Errno2InOutRes().
git-svn-id: trunk@26815 -
2014-02-19 07:28:46 +00:00
sergei
489b23cecd * Made TStartupInfo type common for win32 and win64 and updated as suggested by Mantis #23074.
* Deprecated StartupInfo variable because it is not there for Delphi compatibility (Delphi apparently does not have such variable in interface of its System unit), and we don't have other reasons to export non-portable stuff.

git-svn-id: trunk@26810 -
2014-02-18 16:49:08 +00:00
sergei
5e762cc6ea * Second part of 64-bit Windows fixes and updates from Mantis #23074.
git-svn-id: trunk@26807 -
2014-02-18 09:26:47 +00:00
sergei
83deae45b8 * First part of 64-bit Windows fixes from Mantis #23074.
git-svn-id: trunk@26806 -
2014-02-18 02:10:35 +00:00
michael
f2d163cd38 * Fixed bug ID #23290 (FileSetDate on Dir)
git-svn-id: trunk@26682 -
2014-02-06 12:01:25 +00:00
Tomas Hajny
1a430d8110 * GetProcAddr added for OS/2, type of argument for ordinal target specific now
git-svn-id: trunk@26521 -
2014-01-19 21:15:26 +00:00
svenbarth
6273192ce1 + Add a new overload to DynLibs to allow loading by Ordinal only. This needs specific operating system support however and will return Nil (using a default implementation) if ordinals are not supported.
+ Implement overload for the three supported Windows targets.

git-svn-id: trunk@26457 -
2014-01-14 15:23:55 +00:00
marco
f09374a197 * winsock(and -2), sockets and gpm to rtl-extra.
git-svn-id: trunk@26426 -
2014-01-11 19:45:37 +00:00
marco
dea2c743d5 * Initial active version of
rtl-extra : objects matrix ucomplex
   rtl-objpas: convutil(s) dateutil(s) stdconvs variants varutils
   

git-svn-id: trunk@26398 -
2014-01-05 19:20:15 +00:00
Jonas Maebe
d1b2a5f362 * changed the initial value DefaultFileSystemCodePage from CP_ACP to CP_UTF8:
o since we always use UTF-16 for OS file API calls, this will only affect
     possible intermediate code page conversions inside RTL routines and hence
     prevent potential data loss. This was already the same for NativeNT and
     WinCE, which are in the same boat
   o DefaultRTLFileSystemCodePage, which specifies the code page used to return
     strings from single byte RTL routines, remains CP_ACP and hence nothing
     will change as far as programs using the RTL are concerned

git-svn-id: trunk@26377 -
2014-01-04 15:05:42 +00:00
marco
a001e12d04 * rtl-console initial version.
git-svn-id: trunk@26372 -
2014-01-03 22:19:02 +00:00
marco
ebe262762a * Clean out of $i textrec and filerec includes that are redundant now that cpstrrtl exposes
those records via system. 

git-svn-id: trunk@26356 -
2014-01-02 13:26:09 +00:00
sergei
179586f589 + SEH support for Win32. Enable by cycling with OPT=-dTEST_WIN32_SEH.
Although basic things work (no regressions in test suite, also with TEST_OPT=-O2), there are some secondary issues/TODOs:
- Exception frame around PASCALMAIN is not properly removed in DLLs
- No stack traces yet
- Stack overallocated in finalizer procedures, their entry/exit code needs cleanup
- Signals unit is probably completely broken.

git-svn-id: trunk@26225 -
2013-12-12 12:43:46 +00:00
marco
67c21b3a5e * fix for #25402 One argument of GetICMProfileW missed an indirection
git-svn-id: trunk@26202 -
2013-12-09 18:19:31 +00:00
sergei
04c0845189 * Moved more reusable exception handling code from seh64.inc to syswin.inc.
* sysutils.pp: Install ExceptObjProc and ExceptClsProc also on Win32.

git-svn-id: trunk@26181 -
2013-12-04 14:02:54 +00:00
marco
23ac05cfdd * fix for #22546
git-svn-id: trunk@26177 -
2013-12-03 23:24:48 +00:00
sergei
6a40ff730c * In preparation to support SEH on Win32, moved definitions that apply to Win32 from seh64.inc into syswin.inc.
git-svn-id: trunk@26153 -
2013-11-29 14:23:46 +00:00
nickysn
6cf2382760 + added the PFD_DIRECT3D_ACCELERATED and PFD_SUPPORT_COMPOSITION constants to
the windows unit

git-svn-id: trunk@25774 -
2013-10-14 11:59:24 +00:00