# Compile failure on IRIX 6.5

**URL:** <https://www.ruby-forum.com/t/compile-failure-on-irix-6-5/68741>\
**Category:** Ruby\
**Created:** [September 15, 2006, 12:58am UTC](https://www.ruby-forum.com/t/compile-failure-on-irix-6-5/68741 "2006-09-15T00:58:47Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![joe-dumoulin](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/j/9dc877/32.png) [@joe-dumoulin](https://www.ruby-forum.com/u/joe-dumoulin)\
**Post date:** [September 15, 2006, 12:58am UTC](https://www.ruby-forum.com/t/compile-failure-on-irix-6-5/68741/1 "2006-09-15T00:58:47Z")

</div>

Any ideas?

gmake[1]: Entering directory `/users/mz652c/src/ruby-1.8.5/ext/pty’  
/usr/bin/cc -I. -I…/… -I…/…/. -I…/…/./ext/pty  
-DHAVE\_SYS\_STROPTS\_H -DHAVE\_\_GETPTY -KPIC -g -c pty.c  
cc-1164 cc: WARNING File = pty.c, Line = 286  
Argument of type “VALUE (_)()" is incompatible with parameter of type  
"VALUE (_)(VALUE)”.

```
    rb_protect(pty_exec, (VALUE)&arg, &status);
               ^

```

cc-1552 cc: WARNING File = pty.c, Line = 199  
The variable “currentPid” is set but never used.

```
  static int i,master,slave,currentPid;
                                           ^

```

cc-1166 cc: ERROR File = pty.c, Line = 396  
Expected a declaration.

}  
^

cc-1012 cc: WARNING File = pty.c, Line = 400  
Parsing restarts here after previous syntax error.

```
  int *master, *slave;
                     ^

```

cc-1166 cc: ERROR File = pty.c, Line = 401  
Expected a declaration.

{  
^

cc-1174 cc: WARNING File = pty.c, Line = 88  
The variable “MasterDevice” was declared but never referenced.

char \*MasterDevice = “/dev/pty%s”,  
^

cc-1174 cc: WARNING File = pty.c, Line = 89  
The variable “SlaveDevice” was declared but never referenced.

```
    *SlaveDevice = "/dev/tty%s",
     ^

```

cc-1174 cc: WARNING File = pty.c, Line = 90  
The variable “deviceNo” was declared but never referenced.

```
    *deviceNo[] = {
     ^

```

cc-1113 cc: ERROR File = pty.c, Line = 179  
The function “getDevice” was referenced but not defined.

static void getDevice \_((int\*, int\*));  
^

3 errors detected in the compilation of “pty.c”.  
gmake[1]: \*\*\* [pty.o] Error 2

---

<div class="post-metadata">

**Author:** ![joe-dumoulin](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/j/9dc877/32.png) [@joe-dumoulin](https://www.ruby-forum.com/u/joe-dumoulin)\
**Post date:** [September 15, 2006, 9:53am UTC](https://www.ruby-forum.com/t/compile-failure-on-irix-6-5/68741/2 "2006-09-15T09:53:23Z")

</div>

Hi,

At Fri, 15 Sep 2006 07:58:21 +0900,  
Joe Van D. wrote in [ruby-talk:214515]:

> Any ideas?

Sorry, my mistake.

# Index: ext/pty/pty.c

RCS file: /home/K8052/cvs/ruby/ext/pty/pty.c,v  
retrieving revision 1.19.2.4  
diff -U 2 -p -u -r1.19.2.4 pty.c  
— ext/pty/pty.c 26 Jul 2006 09:15:31 -0000 1.19.2.4  
+++ ext/pty/pty.c 15 Sep 2006 07:46:41 -0000  
@@ -63,5 +63,5 @@ char _MasterDevice = “/dev/ptym/pty%s”,  
};  
 #elif defined(\_IBMESA) /_ AIX/ESA \*/  
-static  
+static  
char \*MasterDevice = “/dev/ptyp%s”,  
\*SlaveDevice = “/dev/ttyp%s”,  
@@ -85,5 +85,5 @@ char \*MasterDevice = “/dev/ptyp%s”,  
};  
#elif !defined(HAVE\_PTSNAME)  
-static  
+static  
char \*MasterDevice = “/dev/pty%s”,  
\*SlaveDevice = “/dev/tty%s”,  
@@ -184,8 +184,11 @@ struct exec\_info {  
};

+static VALUE pty\_exec \_((VALUE v));  
+  
static VALUE  
-pty\_exec(arg)

- struct exec\_info \*arg;  
+pty\_exec(v)

- VALUE v;  
{
- struct exec\_info \*arg = (struct exec\_info \*)v;  
return rb\_f\_exec(arg-\>argc, arg-\>argv);  
}  
@@ -196,6 +199,6 @@ establishShell(argc, argv, info)  
VALUE \*argv;  
struct pty\_info \*info;  
-{

- static int i,master,slave,currentPid;  
+{

- int i,master,slave;  
char \*p,\*getenv();  
struct passwd \*pwent;  
@@ -232,6 +235,4 @@ establishShell(argc, argv, info)

- currentPid = getpid();
- /\*
  - Set free from process group and controlling terminal  
@@ -245,5 +246,5 @@ establishShell(argc, argv, info)  
perror(“setpgrp()”);

# else /\* SETGRP\_VOID \*/

- if (setpgrp(0, currentPid) == -1)

- if (setpgrp(0, getpid()) == -1)  
rb\_sys\_fail(“setpgrp()”);  
if ((i = open("/dev/tty", O\_RDONLY)) \< 0)  
@@ -333,5 +334,4 @@ get\_device\_once(master, slave, fail)

- 

- MakeOpenFile(rport, rfptr);  
MakeOpenFile(wport, wfptr);

---

<div class="post-metadata">

**Author:** ![joe-dumoulin](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/j/9dc877/32.png) [@joe-dumoulin](https://www.ruby-forum.com/u/joe-dumoulin)\
**Post date:** [September 15, 2006, 10:05am UTC](https://www.ruby-forum.com/t/compile-failure-on-irix-6-5/68741/3 "2006-09-15T10:05:25Z")

</div>

Hi,

In message “Re: Compile failure on IRIX 6.5”  
on Fri, 15 Sep 2006 16:53:47 +0900, “Nobuyoshi N.”  
[removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid) writes:

|At Fri, 15 Sep 2006 07:58:21 +0900,  
|Joe Van D. wrote in [ruby-talk:214515]:  
|\> Any ideas?  
|  
|Sorry, my mistake.

Apply the patch, please.

```
						matz.

```
