Commit 3e525997 by Richard Kenner

(i386-sequent-ptx): Properly get version number.

From-SVN: r10030
parent 83750c27
...@@ -422,6 +422,10 @@ esac ...@@ -422,6 +422,10 @@ esac
#echo "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" 1>&2 #echo "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" 1>&2
cat >dummy.c <<EOF cat >dummy.c <<EOF
#ifdef _SEQUENT_
# include <sys/types.h>
# include <sys/utsname.h>
#endif
main () main ()
{ {
#if defined (sony) #if defined (sony)
...@@ -485,7 +489,18 @@ main () ...@@ -485,7 +489,18 @@ main ()
#endif #endif
#if defined (_SEQUENT_) #if defined (_SEQUENT_)
struct utsname un;
uname(&un);
if (strncmp(un.version, "V2", 2) == 0) {
printf ("i386-sequent-ptx2\n"); exit (0);
}
if (strncmp(un.version, "V1", 2) == 0) { /* XXX is V1 correct? */
printf ("i386-sequent-ptx1\n"); exit (0);
}
printf ("i386-sequent-ptx\n"); exit (0); printf ("i386-sequent-ptx\n"); exit (0);
#endif #endif
#if defined (vax) #if defined (vax)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment