aboutsummaryrefslogtreecommitdiff
path: root/gcc/ada/s-oscons-tmplt.c
diff options
context:
space:
mode:
authorArnaud Charlet <charlet@gcc.gnu.org>2009-07-28 10:15:44 +0200
committerArnaud Charlet <charlet@gcc.gnu.org>2009-07-28 10:15:44 +0200
commit056b0f6f80112c19254a0c265d52720d299c65bc (patch)
treeb06b173a93c4867a60c4e103f58ba1f992668109 /gcc/ada/s-oscons-tmplt.c
parent5391897dbe2d7f3ae6a827c8573c465901d88897 (diff)
downloadgcc-056b0f6f80112c19254a0c265d52720d299c65bc.zip
gcc-056b0f6f80112c19254a0c265d52720d299c65bc.tar.gz
gcc-056b0f6f80112c19254a0c265d52720d299c65bc.tar.bz2
[multiple changes]
2009-07-28 Sergey Rybin <rybin@adacore.com> * gnat_ugn.texi: Add section about gnatcheck rule exemption. 2009-07-28 Vadim Godunko <godunko@adacore.com> * s-oscons-tmplt.c: Define _XOPEN_SOURCE on Linux, otherwise IOV_MAX is not defined by limits.h. * g-socket.adb (Receive_Vector): Use minimum length from user's vector length and maximum supported length of data vector. 2009-07-28 Gary Dismukes <dismukes@adacore.com> * usage.adb: Inhibit printing gcc-specific switches for AAMP target. * make.adb: Call Get_Target_Parameters before calling Usage so that VM_Target and AAMP_On_Target will be set. From-SVN: r150147
Diffstat (limited to 'gcc/ada/s-oscons-tmplt.c')
-rw-r--r--gcc/ada/s-oscons-tmplt.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/gcc/ada/s-oscons-tmplt.c b/gcc/ada/s-oscons-tmplt.c
index b5dd2a8..c4218c2 100644
--- a/gcc/ada/s-oscons-tmplt.c
+++ b/gcc/ada/s-oscons-tmplt.c
@@ -78,6 +78,11 @@ pragma Style_Checks ("M32766");
** $ RUN xoscons
**/
+#if defined (__linux__) && !defined (_XOPEN_SOURCE)
+/* For Linux _XOPEN_SOURCE must be defined, otherwise IOV_MAX is not defined */
+#define _XOPEN_SOURCE 500
+#endif
+
#include <stdlib.h>
#include <string.h>
#include <limits.h>