+/* Get HP-UX major release number. Returns zero if the
+ release is not known. */
+
+static int
+get_hpux_major_release (void)
+{
+ static int hpux_major_release = -1;
+
+ if (hpux_major_release == -1)
+ {
+ struct utsname x;
+ char *p;
+
+ uname (&x);
+ p = strchr (x.release, '.');
+ hpux_major_release = p ? atoi (p + 1) : 0;
+ }
+
+ return hpux_major_release;
+}
+
+/* DL header flag defines. */
+#define SHLIB_TEXT_PRIVATE_ENABLE 0x4000
+
+/* The DL header is documented in <shl.h>. We are only interested
+ in the flags field to determine whether the executable wants shared
+ libraries mapped private. */
+struct {
+ short junk[37];
+ short flags;
+} dl_header;
+