diff options
author | Eric Botcazou <ebotcazou@adacore.com> | 2014-04-09 14:54:29 +0000 |
---|---|---|
committer | Eric Botcazou <ebotcazou@gcc.gnu.org> | 2014-04-09 14:54:29 +0000 |
commit | ebe0249e2414d67136ee45b72d269389e764f4de (patch) | |
tree | 84d7407f6ee7eb8701b437be3631cc15a607af29 /gcc/ada/s-linux-hppa.ads | |
parent | 5e1f630ae8b479db169fac18f181ed5ad6dd2a31 (diff) | |
download | gcc-ebe0249e2414d67136ee45b72d269389e764f4de.zip gcc-ebe0249e2414d67136ee45b72d269389e764f4de.tar.gz gcc-ebe0249e2414d67136ee45b72d269389e764f4de.tar.bz2 |
re PR ada/54040 ([x32] Incorrect timeval and timespec)
PR ada/54040
PR ada/59346
* s-osinte-x32.adb: New file.
* s-linux.ads (Time): New section.
* s-linux-alpha.ads (Time): Likewise.
* s-linux-android.ads (Time: Likewise.
* s-linux-hppa.ads (Time): Likewise.
* s-linux-mipsel.ads (Time): Likewise.
* s-linux-sparc.ads (Time): Likewise.
* s-linux-x32.ads (Time): Likewise.
* s-osprim-x32.ads (timespec): Adjust.
* s-osinte-linux.ads (Time): Define local subtypes for those defined
in System.Linux.
* s-taprop-linux.adb (Monotonic_Clock): Do not define timeval.
* s-osinte-hpux.ads (timespec): Revert POSIX breakage.
* s-osinte-kfreebsd-gnu.ads (timespec): Likewise.
* s-osinte-solaris-posix.ads (timespec): Likewise.
* s-osinte-posix.adb (To_Timespec): Likewise.
* gcc-interface/Makefile.in (x32/Linux): Use s-osinte-x32.adb.
From-SVN: r209244
Diffstat (limited to 'gcc/ada/s-linux-hppa.ads')
-rw-r--r-- | gcc/ada/s-linux-hppa.ads | 26 |
1 files changed, 21 insertions, 5 deletions
diff --git a/gcc/ada/s-linux-hppa.ads b/gcc/ada/s-linux-hppa.ads index 9046150..8f7d811 100644 --- a/gcc/ada/s-linux-hppa.ads +++ b/gcc/ada/s-linux-hppa.ads @@ -6,7 +6,7 @@ -- -- -- S p e c -- -- -- --- Copyright (C) 2008-2011, Free Software Foundation, Inc. -- +-- Copyright (C) 2008-2014, Free Software Foundation, Inc. -- -- -- -- GNARL is free software; you can redistribute it and/or modify it under -- -- terms of the GNU General Public License as published by the Free Soft- -- @@ -35,14 +35,30 @@ -- PLEASE DO NOT add any with-clauses to this package or remove the pragma -- Preelaborate. This package is designed to be a bottom-level (leaf) package. +with Interfaces.C; + package System.Linux is pragma Preelaborate; - ------------ - -- time_t -- - ------------ + ---------- + -- Time -- + ---------- + + subtype long is Interfaces.C.long; + subtype suseconds_t is Interfaces.C.long; + subtype time_t is Interfaces.C.long; + + type timespec is record + tv_sec : time_t; + tv_nsec : long; + end record; + pragma Convention (C, timespec); - type time_t is new Long_Integer; + type timeval is record + tv_sec : time_t; + tv_usec : suseconds_t; + end record; + pragma Convention (C, timeval); ----------- -- Errno -- |