Commit Graph

13223 Commits

Author SHA1 Message Date
nickysn
aa3d13dd4a - removed the FPC_USE_GETDIRENTRIES_SYSCALL define and use_getdirentries_syscall
global variable, they are compatibility flags of a no longer supported OpenBSD version

git-svn-id: trunk@41790 -
2019-03-24 16:30:50 +00:00
nickysn
ede50a2c4f - get rid of the FPC_USE_GETDIRENTRIES_I49_SYSCALL define and the
use_openbsd_getdirentries_49 global variable - both are compatibility features
  for a no longer supported OpenBSD version

git-svn-id: trunk@41789 -
2019-03-24 16:12:30 +00:00
nickysn
9a18543324 * cleaned up most of the obsolete OpenBSD syscall numbers
git-svn-id: trunk@41783 -
2019-03-23 20:35:03 +00:00
nickysn
dab661cfc6 * switch syscall_nr_kill on OpenBSD to be using the 5.9+ syscall version
git-svn-id: trunk@41781 -
2019-03-23 04:23:15 +00:00
nickysn
41c753d7e7 * updated OpenBSD syscall numbers to version 6.4
git-svn-id: trunk@41780 -
2019-03-23 04:20:55 +00:00
nickysn
b32e54152a * updated OpenBSD syscall numbers to version 6.3
git-svn-id: trunk@41779 -
2019-03-23 04:19:07 +00:00
nickysn
89a40d5cf9 * updated OpenBSD syscall numbers for version 6.2
git-svn-id: trunk@41778 -
2019-03-23 04:17:35 +00:00
nickysn
14701521a1 * updated OpenBSD syscalls for version 6.1
git-svn-id: trunk@41777 -
2019-03-23 04:14:11 +00:00
nickysn
475ecdb2dc * updated OpenBSD syscall numbers to version 6.0
git-svn-id: trunk@41776 -
2019-03-23 04:12:51 +00:00
nickysn
72aec7c072 * updated OpenBSD syscall numbers to version 5.9
git-svn-id: trunk@41775 -
2019-03-23 04:06:14 +00:00
nickysn
259e3f9f63 * updated OpenBSD syscall numbers for OpenBSD 5.8
git-svn-id: trunk@41774 -
2019-03-23 03:55:47 +00:00
nickysn
828da99388 * updated syscall numbers for OpenBSD 5.7
git-svn-id: trunk@41773 -
2019-03-23 01:54:20 +00:00
nickysn
cee76bda5c + added comments about some retired syscall numbers, with the last supported
version. This is checked against OpenBSD versions 2.0 to 5.6, like the comment
  in the beginning of the file says (and the ones in this commit were missed).

git-svn-id: trunk@41772 -
2019-03-23 01:46:21 +00:00
nickysn
04ee584a7d - removed FPC 1.0.x bootstrapping compatibility ifdef from OpenBSD RTL Makefile
git-svn-id: trunk@41769 -
2019-03-22 17:35:35 +00:00
nickysn
6dec9ae064 + added some missing cdecl declarations to the OpenBSD startup code
git-svn-id: trunk@41766 -
2019-03-22 01:22:16 +00:00
nickysn
b6d2ef12ad - removed OpenBSD loaders that are not needed for bootstrapping with FPC 3.0.4
git-svn-id: trunk@41765 -
2019-03-22 01:08:37 +00:00
nickysn
516438fd19 * converted the i386 OpenBSD startup code to Pascal
git-svn-id: trunk@41764 -
2019-03-22 00:54:01 +00:00
nickysn
b4baba3454 * fixed the haltproc for shared libs
git-svn-id: trunk@41763 -
2019-03-21 23:37:47 +00:00
nickysn
01669ebf70 * use the actual _haltproc procedure, defined in the startup code on OpenBSD
* fixed the x86_64 syscall invocation in the OpenBSD _haltproc

git-svn-id: trunk@41762 -
2019-03-21 18:16:23 +00:00
nickysn
7638a9b7e1 - removed commented out gprof code from si_c.inc
git-svn-id: trunk@41761 -
2019-03-21 17:37:37 +00:00
nickysn
1f9b5d143e * call _monstartup instead of monstartup
git-svn-id: trunk@41758 -
2019-03-21 13:28:18 +00:00
nickysn
e4ffeb2266 + added OpenBSD startup units for gprof support
git-svn-id: trunk@41757 -
2019-03-21 12:52:25 +00:00
nickysn
bb911e2f01 - unused local variable removed
git-svn-id: trunk@41754 -
2019-03-20 16:26:38 +00:00
nickysn
f15c2db4b2 * moved some C type declarations to si_intf.inc
git-svn-id: trunk@41753 -
2019-03-20 16:23:34 +00:00
nickysn
fb3d287971 * fixed OpenBSD shared library initialization
git-svn-id: trunk@41752 -
2019-03-20 16:09:07 +00:00
nickysn
52a5669117 + enable weak externals for OpenBSD
* converted the reference to _init in si_dll to be a weak external. This way we
  can support creating shared libraries that link to the C library as well as
  libraries that do not. If libc was linked, the compiler will link in
  crtbeginS.o and crtendS.o; _init is defined in crtbeginS.o and initializes the
  C library and calls all the C static constructors.

git-svn-id: trunk@41751 -
2019-03-20 15:13:47 +00:00
nickysn
aad032f133 * converted _FPC_proc___start in OpenBSD's si_dll.inc to pascal
git-svn-id: trunk@41750 -
2019-03-20 14:55:35 +00:00
nickysn
fb793ff251 - comment out more unused gprof code
git-svn-id: trunk@41746 -
2019-03-19 18:32:54 +00:00
nickysn
2960399f9a * call c_exit directly in case PASCALMAIN finishes, to avoid inline asm entirely
in the _FPC_proc___start routine in the libc version of the OpenBSD startup
  code for x86_64

git-svn-id: trunk@41745 -
2019-03-19 18:28:20 +00:00
nickysn
4715ad605b - don't export the ___start symbol in the OpenBSD startup code
git-svn-id: trunk@41744 -
2019-03-19 17:40:46 +00:00
nickysn
144f31c94f * call the exit() routine from the C libraries in the FPC haltproc on OpenBSD
x86_64, libc startup code

git-svn-id: trunk@41743 -
2019-03-19 17:27:11 +00:00
nickysn
094ad635f7 - don't call monstartup, because that initializes the gprof profiler and should
only be called for programs, compiled with -pg (which is not yet implemented
  for the OpenBSD target and which will use a different sysinit unit for such
  programs, when implemented)

git-svn-id: trunk@41741 -
2019-03-19 16:51:04 +00:00
nickysn
34a8032e11 * link to crtbegin.o/crtend.o instead of crtbeginS.o/crtendS.o when creating
normal OpenBSD programs (not shared libraries) that link to the C library,
  even when PIC code generation has been turned on. This is what gcc and clang
  do on this platform.

git-svn-id: trunk@41740 -
2019-03-19 16:36:38 +00:00
nickysn
d1a91a380b * the OpenBSD x86_64 C library startup code converted to Pascal
git-svn-id: trunk@41739 -
2019-03-19 14:58:46 +00:00
nickysn
76623648e4 * updated the declarations to externals in the C library in the OpenBSD startup
code si_c.inc, in preparation to converting the startup procedure to Pascal

git-svn-id: trunk@41738 -
2019-03-19 14:42:31 +00:00
nickysn
cf2aa6fdb7 * slight change to the OpenBSD startup code, to allow Low(__progname_storage)<>0
(not that it's going to be changed that way, but it doesn't hurt for the code
  to be more robust; and it doesn't affect performance, since the compiler
  optimizes x-0 to x)

git-svn-id: trunk@41737 -
2019-03-19 13:34:42 +00:00
nickysn
60d21cc041 * converted _FPC_proc___start in the OpenBSD x86_64 nonlibc startup code to Pascal
git-svn-id: trunk@41736 -
2019-03-18 19:08:22 +00:00
nickysn
b56c181500 + added comments with the parameters of _FPC_proc___start in the OpenBSD x86_64 startup code
git-svn-id: trunk@41735 -
2019-03-18 18:31:32 +00:00
nickysn
7e24c07690 + added comment for the parameter, containing the environment
git-svn-id: trunk@41734 -
2019-03-18 18:14:11 +00:00
nickysn
66744f2f1e * _strrchr in the OpenBSD x86_64 startup code converted to Pascal
git-svn-id: trunk@41733 -
2019-03-18 17:28:46 +00:00
pierre
74fed2a4cd Regenerate Makefile's after fpcmake change in commit #41721
git-svn-id: trunk@41723 -
2019-03-17 14:45:03 +00:00
nickysn
df11fcc9e3 * compilation fix for i386-openbsd
git-svn-id: trunk@41711 -
2019-03-15 13:46:58 +00:00
nickysn
d8f79c7363 * converted the openbsd_ident.as loader to pascal
git-svn-id: trunk@41710 -
2019-03-15 13:35:10 +00:00
nickysn
ea5168aa16 * ported dllprt0.as for OpenBSD x86_64 to inline asm in si_dll.inc
git-svn-id: trunk@41708 -
2019-03-14 22:53:22 +00:00
nickysn
19e1336043 * fixed the _eprol and _etext references in si_c.inc for OpenBSD x86_64
git-svn-id: trunk@41706 -
2019-03-14 21:44:39 +00:00
nickysn
c856879c96 * ported OpenBSD's x86_64 cprt0.as to inline asm in si_c.inc
git-svn-id: trunk@41705 -
2019-03-14 21:13:17 +00:00
nickysn
52c53f0d18 + include si_impl.inc in si_c.pp and si_dll.pp
git-svn-id: trunk@41704 -
2019-03-14 20:39:22 +00:00
nickysn
e93a3b5bf4 + link the openbsd_ident module in the SysInit units
git-svn-id: trunk@41703 -
2019-03-14 18:10:37 +00:00
nickysn
16abd6aa13 + added loader openbsd_ident.as, containing only the .note.openbsd.ident
section, required by OpenBSD to identify the ELF binary as OpenBSD-native

git-svn-id: trunk@41702 -
2019-03-14 18:06:24 +00:00
nickysn
29557b97fb * fixed error, caused by double definition of operatingsystem_result
git-svn-id: trunk@41701 -
2019-03-14 17:33:44 +00:00