#627 Cygwin & Pipes

build problems
open
Bruno Haible
clisp (525)
5
2012-02-07
2012-02-07
Todd Pierce
No

Hello CLISP crew!

This is not really a bug. After all, Cygwin just started supporting named pipes. It appears, though, that the build of CLISP being distributed along with Cygwin doesn't recognize them. The version of CLISP is this:

Welcome to GNU CLISP 2.48 (2009-07-28)

Since CLISP is turrning out to be the most comfy place for my artificial intelligence to, well... think.

The behavior I noticed is that CLISP would just lock when trying to write to a pipe. Writing to files works fine. Reading from the pipe in another terminal window invoked an error in the CLISP session.

I'll mention this to the Cygwin guys too. I just want you to be on the same page.

Thanks for all the help.

Sincerely,

-Todd

Discussion

  • Reini Urban
    Reini Urban
    2012-02-08

    Maybe because clisp upstream decided to read from pipes with crlf line-endings, so \n will not end a line. Only the cygwin release reads from pipes binary. Which makes more sense to cygwin, since we (cygwin) cannot deal with crlf and we want to pipe streams with line endings to clisp.

    Otherwise I see no difference but i haven't tested the new named pipes yet.

     
  • Sam Steingold
    Sam Steingold
    2012-02-08

    Todd: maybe you could try binary i/o with pipes?

    Reini: clisp accepts all 3 line terminators (cr, lf, crlf) on input,
    please see http://clisp.org/impnotes/clhs-newline.html

     
  • Todd Pierce
    Todd Pierce
    2012-02-08

    Someone mentioned that this could be a CRLF issue in the mailing list.

    This is not an issue that occurs when reading or writing to the pipe, this is something that happens when opening it.. If you can even call Cygwin having pipes yet.

    As I mentioned before, all the file open/close read/write happens fine. It's just when dealing with these new Cygwin pipes that things get strange.

    And no, I still haven't posted this matter with the Cygwin guys... hell... I'm homeless.

    -Todd cambio y fuera

     
  • Todd Pierce
    Todd Pierce
    2012-02-08

    This bug report is now marked as "pending"/"invalid".
    This means that we think that the problem you report is not a problem with CLISP.
    Unless you - the reporter - act within 2 weeks, the bug will be permanently closed.
    Sorry about the inconvenience - we hope your silence means that you agree that this is not a bug in CLISP.

     
  • Todd Pierce
    Todd Pierce
    2012-03-05

    Crew:

    Opening the file binary or not seems to cause the open file to lock. Here (the open hidden in my own function):

    [2]> (setf stream (open-sparser "../stanford-parser/fifoin"))

    locks the repl. However, if I try to read from the other end of the pipe, I do get this error (binary or not):

    *** - UNIX error 22 (EINVAL): Invalid argument
    The following restarts are available:
    ABORT :R1 Abort main loop

    *** - UNIX error 11 (EWOULDBLOCK): Operation would block
    The following restarts are available:
    ABORT :R1 Abort main loop

    So, I'm not sure what is going on there. I'm hoping I can just port my whole project to a real unix system soon. Whatever happens, I'll mention this stuff to the cygwin guys.

    Thanks for keeping an eye out for me.

    -Todd

     
  • Todd Pierce
    Todd Pierce
    2013-03-30

    Hi all,

    So, it looks like the Cygwin people fixed the pipes but then forgot to include clisp in their distribution.

    -Todd

     
  • Todd Pierce
    Todd Pierce
    2013-04-09

    Hi All,

    I managed to install CLISP for Cygwin manually (it doesn't seem to install with the new Cygwin installer). Pipes are working great for all of the Cygwin utilities now, but still not for CLISP. Just thought I'd mention that. I'm considering compiling it myself... still gotta figure out how to do that.

    -Todd